Interface ShapeParser
public interface ShapeParser
first point of entry for a shape parser
-
Field Summary
Fields Modifier and Type Field Description static org.elasticsearch.common.ParseFieldFIELD_COORDINATESstatic org.elasticsearch.common.ParseFieldFIELD_GEOMETRIESstatic org.elasticsearch.common.ParseFieldFIELD_ORIENTATIONstatic org.elasticsearch.common.ParseFieldFIELD_TYPE -
Method Summary
Static Methods Modifier and Type Method Description static ShapeBuilderparse(java.lang.Object value)static ShapeBuilderparse(org.elasticsearch.common.xcontent.XContentParser parser)Create a newShapeBuilderfromXContentstatic ShapeBuilderparse(org.elasticsearch.common.xcontent.XContentParser parser, AbstractGeometryFieldMapper geometryMapper)Create a newShapeBuilderfromXContent
-
Field Details
-
FIELD_TYPE
static final org.elasticsearch.common.ParseField FIELD_TYPE -
FIELD_COORDINATES
static final org.elasticsearch.common.ParseField FIELD_COORDINATES -
FIELD_GEOMETRIES
static final org.elasticsearch.common.ParseField FIELD_GEOMETRIES -
FIELD_ORIENTATION
static final org.elasticsearch.common.ParseField FIELD_ORIENTATION
-
-
Method Details
-
parse
static ShapeBuilder parse(org.elasticsearch.common.xcontent.XContentParser parser, AbstractGeometryFieldMapper geometryMapper) throws java.io.IOExceptionCreate a newShapeBuilderfromXContent- Parameters:
parser- parser to read the GeoShape fromgeometryMapper- document field mapper reference required for spatial parameters relevant to the shape construction process (e.g., orientation) todo: refactor to place build specific parameters in the SpatialContext- Returns:
ShapeBuilderread from the parser or null if the parsers current token has beennull- Throws:
java.io.IOException- if the input could not be read
-
parse
static ShapeBuilder parse(org.elasticsearch.common.xcontent.XContentParser parser) throws java.io.IOExceptionCreate a newShapeBuilderfromXContent- Parameters:
parser- parser to read the GeoShape from- Returns:
ShapeBuilderread from the parser or null if the parsers current token has beennull- Throws:
java.io.IOException- if the input could not be read
-
parse
- Throws:
java.io.IOException
-