public class SpatialFieldBridgeByHash extends SpatialFieldBridge implements ParameterizedBridge
Modifier and Type | Field and Description |
---|---|
static int |
DEFAULT_BOTTOM_SPATIAL_HASH_LEVEL |
static int |
DEFAULT_TOP_SPATIAL_HASH_LEVEL |
latitudeField, latitudeIndexedFieldName, longitudeField, longitudeIndexedFieldName
Constructor and Description |
---|
SpatialFieldBridgeByHash() |
SpatialFieldBridgeByHash(int topSpatialHashLevel,
int bottomSpatialHashLevel) |
SpatialFieldBridgeByHash(int topSpatialHashLevel,
int bottomSpatialHashLevel,
String latitudeField,
String longitudeField) |
Modifier and Type | Method and Description |
---|---|
void |
configureFieldMetadata(String name,
FieldMetadataBuilder builder)
Allows this bridge to expose meta-data about the fields it creates.
|
void |
set(String name,
Object value,
Document document,
LuceneOptions luceneOptions)
Actual overridden method that does the indexing
|
void |
setParameterValues(Map parameters)
Override method for default min and max spatial hash level
|
capitalize, getLatitude, getLongitude
public static final int DEFAULT_TOP_SPATIAL_HASH_LEVEL
public static final int DEFAULT_BOTTOM_SPATIAL_HASH_LEVEL
public SpatialFieldBridgeByHash()
public SpatialFieldBridgeByHash(int topSpatialHashLevel, int bottomSpatialHashLevel)
public void configureFieldMetadata(String name, FieldMetadataBuilder builder)
MetadataProvidingFieldBridge
configureFieldMetadata
in interface MetadataProvidingFieldBridge
configureFieldMetadata
in class SpatialFieldBridge
name
- The default field name; Should be used consistently with
FieldBridge.set(String, Object, org.apache.lucene.document.Document, LuceneOptions)
.builder
- Builder for exposing field-related meta-datapublic void set(String name, Object value, Document document, LuceneOptions luceneOptions)
set
in interface FieldBridge
set
in class SpatialFieldBridge
name
- of the fieldvalue
- of the fielddocument
- document being indexedluceneOptions
- current indexing options and accessorspublic void setParameterValues(Map parameters)
setParameterValues
in interface ParameterizedBridge
parameters
- Map containing the topSpatialHashLevel and bottomSpatialHashLevel valuesCopyright © 2006-2017 Red Hat, Inc. All Rights Reserved