public class LatLonPointSpatialField extends AbstractSpatialFieldType implements SchemaAware
LatLonPoint
and LatLonDocValuesField
. The
first is based on Lucene's "Points" API, which is a BKD Index. This field type is strictly limited to
coordinates in lat/lon decimal degrees. The accuracy is about a centimeter (1.042cm).Modifier and Type | Class and Description |
---|---|
static class |
LatLonPointSpatialField.LatLonPointSpatialStrategy |
FieldType.DefaultAnalyzer, FieldType.MultiValueSelector
argsParser, ctx, DISTANCE, distanceUnits, FILTER_PARAM, FORMAT, NONE, RECIP_DISTANCE, SCORE_PARAM, shapeReader, shapeWriter, supportedScoreModes
ANALYZER, args, AUTO_GENERATE_PHRASE_QUERIES, CHAR_FILTER, CHAR_FILTERS, CLASS_NAME, docValuesFormat, ENABLE_GRAPH_QUERIES, falseProperties, FILTER, FILTERS, INDEX, INDEX_ANALYZER, MULTI_TERM, MULTI_TERM_ANALYZER, POLY_FIELD_SEPARATOR, postingsFormat, properties, QUERY, QUERY_ANALYZER, similarity, SIMILARITY, similarityFactory, SYNONYM_QUERY_STYLE, TOKENIZER, trueProperties, TYPE, TYPE_NAME, typeName
BINARY, DOC_VALUES, INDEXED, LARGE_FIELD, MULTIVALUED, OMIT_NORMS, OMIT_POSITIONS, OMIT_TF_POSITIONS, REQUIRED, SORT_MISSING_FIRST, SORT_MISSING_LAST, STORE_OFFSETS, STORE_TERMOFFSETS, STORE_TERMPAYLOADS, STORE_TERMPOSITIONS, STORE_TERMVECTORS, STORED, TOKENIZED, UNINVERTIBLE, USE_DOCVALUES_AS_STORED
Constructor and Description |
---|
LatLonPointSpatialField() |
Modifier and Type | Method and Description |
---|---|
protected void |
checkSupportsDocValues()
Called by
FieldType.checkSchemaField(SchemaField) if the field has docValues. |
static String |
decodeDocValueToString(long value)
Decodes the docValues number into latitude and longitude components, formatting as "lat,lon".
|
void |
inform(IndexSchema schema)
Informs the
IndexSchema provided by the schema
parameter of an event (e.g., a new FieldType was added, etc. |
protected SpatialStrategy |
newSpatialStrategy(String fieldName)
Called from
AbstractSpatialFieldType.getStrategy(String) upon first use by fieldName. |
String |
toExternal(IndexableField f)
Convert the stored-field format to an external (string, human readable)
value
|
createField, createFields, createSpatialQuery, getDistanceUnits, getFieldQuery, getQueryFromSpatialArgs, getSortField, getSpatialContext, getSpecializedRangeQuery, getSphereRadius, getStoredValue, getStrategy, getSupportedScoreModes, getUninversionType, getValueSource, getValueSourceFromSpatialArgs, init, isPolyField, newSpatialArgsParser, parseDistanceUnits, parseShape, parseSpatialArgs, shapeToString, write
checkSchemaField, createField, getAnalyzerProperties, getClassArg, getDefaultMultiValueSelectorForSort, getDocValuesFormat, getExistenceQuery, getIndexAnalyzer, getNamedPropertyValues, getNonFieldPropertyArgs, getNumberType, getNumericSort, getPostingsFormat, getPrefixQuery, getQueryAnalyzer, getRangeQuery, getRewriteMethod, getSetQuery, getSimilarity, getSimilarityFactory, getSingleValueSource, getSortedNumericSortField, getSortedSetSortField, getSortField, getSpecializedExistenceQuery, getStringSort, getTypeName, hasProperty, indexedToReadable, indexedToReadable, isExplicitAnalyzer, isExplicitQueryAnalyzer, isMultiValued, isPointField, isTokenized, isUtf8Field, marshalBase64SortValue, marshalSortValue, marshalStringSortValue, multiValuedFieldCache, readableToIndexed, readableToIndexed, restrictProps, setArgs, setIndexAnalyzer, setIsExplicitAnalyzer, setIsExplicitQueryAnalyzer, setQueryAnalyzer, setSimilarity, storedToIndexed, storedToReadable, supportsAnalyzers, toInternal, toNativeType, toObject, toObject, toString, treatUnboundedRangeAsExistence, unmarshalBase64SortValue, unmarshalSortValue, unmarshalStringSortValue, useDocValuesAsStored, write
protected void checkSupportsDocValues()
FieldType
FieldType.checkSchemaField(SchemaField)
if the field has docValues. By default none do.checkSupportsDocValues
in class FieldType
public void inform(IndexSchema schema)
SchemaAware
IndexSchema
provided by the schema
parameter of an event (e.g., a new FieldType
was added, etc.inform
in interface SchemaAware
schema
- The IndexSchema
instance that inform of the update to.protected SpatialStrategy newSpatialStrategy(String fieldName)
AbstractSpatialFieldType
AbstractSpatialFieldType.getStrategy(String)
upon first use by fieldName. }newSpatialStrategy
in class AbstractSpatialFieldType
public String toExternal(IndexableField f)
FieldType
toExternal
in class FieldType
FieldType.toInternal(java.lang.String)
public static String decodeDocValueToString(long value)
LatLonDocValuesField
. The decimal output representation is reflective
of the available precision.value
- Non-null; stored location field dataCopyright © 2000-2020 Apache Software Foundation. All Rights Reserved.