Interface GeospatialIndex

All Superinterfaces:
AutoCloseable

public interface GeospatialIndex extends AutoCloseable

A spatial index

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

    • close

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

      GeospatialIndexConnection openConnection() throws GeoException
      Open a connection to the index
      Returns:
      the new connection
      Throws:
      GeoException - if there was an error while opening the connection
    • getMetadata

      Metadata getMetadata()
      Return metadata describing this index. This is a read-only view of the metadata. Changes to the metadata should use setMetadata(com.complexible.stardog.metadata.Metadata).
      Returns:
      the metadata
    • 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