org.apache.blur.analysis.type
Class DateFieldTypeDefinition

java.lang.Object
  extended by org.apache.blur.analysis.FieldTypeDefinition
      extended by org.apache.blur.analysis.type.NumericFieldTypeDefinition
          extended by org.apache.blur.analysis.type.DateFieldTypeDefinition

public class DateFieldTypeDefinition
extends NumericFieldTypeDefinition


Field Summary
static String DATE_FORMAT
           
static String NAME
           
static String TIME_UNIT
           
 
Constructor Summary
DateFieldTypeDefinition()
           
 
Method Summary
 void configure(String fieldNameForThisInstance, Map<String,String> properties, org.apache.hadoop.conf.Configuration configuration)
          Configures the field type.
 Iterable<? extends org.apache.lucene.document.Field> getFieldsForColumn(String family, Column column)
          Gets the Fields for indexing from a single Column.
 Iterable<? extends org.apache.lucene.document.Field> getFieldsForSubColumn(String family, Column column, String subName)
          Gets the Fields for indexing from a single Column, but should not be stored because the original value should be stored in the main Column.
 String getName()
          Gets the name of the field type.
 org.apache.lucene.search.Query getNewRangeQuery(String field, String part1, String part2, boolean startInclusive, boolean endInclusive)
           
 org.apache.lucene.search.SortField getSortField(boolean reverse)
           
 
Methods inherited from class org.apache.blur.analysis.type.NumericFieldTypeDefinition
checkSupportForCustomQuery, checkSupportForFuzzyQuery, checkSupportForPrefixQuery, checkSupportForRegexQuery, checkSupportForSorting, checkSupportForWildcardQuery, getAnalyzerForIndex, getAnalyzerForQuery, isNumeric
 
Methods inherited from class org.apache.blur.analysis.FieldTypeDefinition
getAlternateFieldNames, getColumnName, getCustomQuery, getFamily, getFieldType, getProperties, getSubColumnName, isFieldLessIndexed, isSortEnable, setColumnName, setFamily, setFieldLessIndexed, setFieldType, setProperties, setSortEnable, setSubColumnName
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TIME_UNIT

public static final String TIME_UNIT
See Also:
Constant Field Values

DATE_FORMAT

public static final String DATE_FORMAT
See Also:
Constant Field Values

NAME

public static final String NAME
See Also:
Constant Field Values
Constructor Detail

DateFieldTypeDefinition

public DateFieldTypeDefinition()
Method Detail

getName

public String getName()
Description copied from class: FieldTypeDefinition
Gets the name of the field type.

Specified by:
getName in class FieldTypeDefinition
Returns:
the name.

configure

public void configure(String fieldNameForThisInstance,
                      Map<String,String> properties,
                      org.apache.hadoop.conf.Configuration configuration)
Description copied from class: FieldTypeDefinition
Configures the field type.

Specified by:
configure in class FieldTypeDefinition
properties - the properties.

getFieldsForColumn

public Iterable<? extends org.apache.lucene.document.Field> getFieldsForColumn(String family,
                                                                               Column column)
Description copied from class: FieldTypeDefinition
Gets the Fields for indexing from a single Column.

Specified by:
getFieldsForColumn in class FieldTypeDefinition
column - the Column
Returns:
the Iterable of fields.

getFieldsForSubColumn

public Iterable<? extends org.apache.lucene.document.Field> getFieldsForSubColumn(String family,
                                                                                  Column column,
                                                                                  String subName)
Description copied from class: FieldTypeDefinition
Gets the Fields for indexing from a single Column, but should not be stored because the original value should be stored in the main Column.

Specified by:
getFieldsForSubColumn in class FieldTypeDefinition
column - the Column
Returns:
the Iterable of fields.

getNewRangeQuery

public org.apache.lucene.search.Query getNewRangeQuery(String field,
                                                       String part1,
                                                       String part2,
                                                       boolean startInclusive,
                                                       boolean endInclusive)
Specified by:
getNewRangeQuery in class NumericFieldTypeDefinition

getSortField

public org.apache.lucene.search.SortField getSortField(boolean reverse)
Specified by:
getSortField in class FieldTypeDefinition


Copyright © 2012-2014 The Apache Software Foundation. All Rights Reserved.