Interface ShapeParser
public interface ShapeParser
first point of entry for a shape parser
-
Field Summary
Modifier and TypeFieldDescriptionstatic org.elasticsearch.common.xcontent.ParseField
static org.elasticsearch.common.xcontent.ParseField
static org.elasticsearch.common.xcontent.ParseField
static org.elasticsearch.common.xcontent.ParseField
-
Method Summary
Modifier and TypeMethodDescriptionstatic ShapeBuilder
static ShapeBuilder
parse(org.elasticsearch.common.xcontent.XContentParser parser)
Create a newShapeBuilder
fromXContent
static ShapeBuilder
parse(org.elasticsearch.common.xcontent.XContentParser parser, AbstractGeometryFieldMapper geometryMapper)
Create a newShapeBuilder
fromXContent
-
Field Details
-
FIELD_TYPE
static final org.elasticsearch.common.xcontent.ParseField FIELD_TYPE -
FIELD_COORDINATES
static final org.elasticsearch.common.xcontent.ParseField FIELD_COORDINATES -
FIELD_GEOMETRIES
static final org.elasticsearch.common.xcontent.ParseField FIELD_GEOMETRIES -
FIELD_ORIENTATION
static final org.elasticsearch.common.xcontent.ParseField FIELD_ORIENTATION
-
-
Method Details
-
parse
static ShapeBuilder parse(org.elasticsearch.common.xcontent.XContentParser parser, AbstractGeometryFieldMapper geometryMapper) throws IOExceptionCreate a newShapeBuilder
fromXContent
- 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:
ShapeBuilder
read from the parser or null if the parsers current token has beennull
- Throws:
IOException
- if the input could not be read
-
parse
static ShapeBuilder parse(org.elasticsearch.common.xcontent.XContentParser parser) throws IOExceptionCreate a newShapeBuilder
fromXContent
- Parameters:
parser
- parser to read the GeoShape from- Returns:
ShapeBuilder
read from the parser or null if the parsers current token has beennull
- Throws:
IOException
- if the input could not be read
-
parse
- Throws:
IOException
-