Class SpatialArgsParser


  • public class SpatialArgsParser
    extends Object
    Parses a string that usually looks like "OPERATION(SHAPE)" into a SpatialArgs object. The set of operations supported are defined in SpatialOperation, such as "Intersects" being a common one. The shape portion is defined by WKT org.locationtech.spatial4j.io.WktShapeParser, but it can be overridden/customized via parseShape(String, org.locationtech.spatial4j.context.SpatialContext). There are some optional name-value pair parameters that follow the closing parenthesis. Example:
       Intersects(ENVELOPE(-10,-8,22,20)) distErrPct=0.025
     

    In the future it would be good to support something at least semi-standardized like a variant of [E]CQL.