| java.lang.Object org.apache.solr.schema.FieldProperties org.apache.solr.schema.FieldType org.apache.solr.schema.DateField
DateField | public class DateField extends FieldType (Code) | | FieldType that can represent any Date/Time with millisecond precisison.
Date Format for the XML, incoming and outgoing:
A date field shall be of the form 1995-12-31T23:59:59Z
The trailing "Z" designates UTC time and is mandatory.
Optional fractional seconds are allowed: 1995-12-31T23:59:59.999Z
All other parts are mandatory.
This format was derived to be standards compliant (ISO 8601) and is a more
restricted form of the canonical representation of dateTime from XML
schema part 2.
http://www.w3.org/TR/xmlschema-2/#dateTime
"In 1970 the Coordinated Universal Time system was devised by an
international advisory group of technical experts within the International
Telecommunication Union (ITU). The ITU felt it was best to designate a
single abbreviation for use in all languages in order to minimize
confusion. Since unanimous agreement could not be achieved on using
either the English word order, CUT, or the French word order, TUC, the
acronym UTC was chosen as a compromise."
This FieldType also supports incoming "Date Math" strings for computing
values by adding/rounding internals of time relative "NOW",
ie: "NOW+1YEAR", "NOW/DAY", etc.. -- see
DateMathParser for more examples.
author: yonik version: $Id: DateField.java 542679 2007-05-29 22:28:21Z ryan $ See Also: XML schema part 2 |
getThreadLocalDateFormat | protected DateFormat getThreadLocalDateFormat()(Code) | | Returns a formatter that can be use by the current thread if needed to
convert Date objects to the Internal representation.
|
Methods inherited from org.apache.solr.schema.FieldType | public Field createField(SchemaField field, String externalVal, float boost)(Code)(Java Doc) public Analyzer getAnalyzer()(Code)(Java Doc) protected Field.Index getFieldIndex(SchemaField field, String internalVal)(Code)(Java Doc) protected Field.Store getFieldStore(SchemaField field, String internalVal)(Code)(Java Doc) protected Field.TermVector getFieldTermVec(SchemaField field, String internalVal)(Code)(Java Doc) public Analyzer getQueryAnalyzer()(Code)(Java Doc) abstract public SortField getSortField(SchemaField field, boolean top)(Code)(Java Doc) protected SortField getStringSort(SchemaField field, boolean reverse)(Code)(Java Doc) public String getTypeName()(Code)(Java Doc) public ValueSource getValueSource(SchemaField field)(Code)(Java Doc) public String indexedToReadable(String indexedForm)(Code)(Java Doc) protected void init(IndexSchema schema, Map<String, String> args)(Code)(Java Doc) public boolean isTokenized()(Code)(Java Doc) protected void restrictProps(int props)(Code)(Java Doc) public void setAnalyzer(Analyzer analyzer)(Code)(Java Doc) void setArgs(IndexSchema schema, Map<String, String> args)(Code)(Java Doc) public void setQueryAnalyzer(Analyzer analyzer)(Code)(Java Doc) void setTypeName(String typeName)(Code)(Java Doc) public String storedToIndexed(Fieldable f)(Code)(Java Doc) public String storedToReadable(Fieldable f)(Code)(Java Doc) public String toExternal(Fieldable f)(Code)(Java Doc) public String toInternal(String val)(Code)(Java Doc) public String toString()(Code)(Java Doc) abstract public void write(XMLWriter xmlWriter, String name, Fieldable f) throws IOException(Code)(Java Doc) abstract public void write(TextResponseWriter writer, String name, Fieldable f) throws IOException(Code)(Java Doc)
|
|
|