Interface GeospatialIndex

  • All Superinterfaces:
    java.lang.AutoCloseable

    public interface GeospatialIndex
    extends java.lang.AutoCloseable

    A spatial index

    Since:
    4.0
    Version:
    4.0
    Author:
    Michael Grove
    • Method Detail

      • close

        void close()
        Close this index. This will close all open connections.
        Specified by:
        close in interface java.lang.AutoCloseable
      • setMetadata

        boolean setMetadata​(Metadata theMetadata)
                     throws GeoException
        Persist changes to the provided metadata. The provided metadata is not the complete set of options, only the options which have been updated.
        Parameters:
        theMetadata - the updated metadata
        Returns:
        true if the operation was successful, false otherwise
        Throws:
        GeoException - if there is an error persisting the metadata
      • getSpatialContext

        org.locationtech.spatial4j.context.SpatialContext getSpatialContext()
        Return the SpatialContext used by this index
        Returns:
        the spatial context
      • numFeatures

        long numFeatures()
        Return the number of feature in the spatial index
        Returns:
        the number of docs