Class GeospatialTypes

java.lang.Object
org.apache.orc.geospatial.GeospatialTypes

public class GeospatialTypes extends Object
A list of geospatial types from all instances in the Geometry or Geography column, or an empty list if they are not known. The GeospatialTypes instance becomes invalid in the following cases: - When an unknown or unsupported geometry type is encountered during update - When merging with another invalid GeospatialTypes instance - When explicitly aborted using abort() When invalid, the types list is cleared and remains empty. All subsequent updates and merges are ignored until reset() is called.
  • Constructor Details

    • GeospatialTypes

      public GeospatialTypes(Set<Integer> types)
    • GeospatialTypes

      public GeospatialTypes(Set<Integer> types, boolean valid)
    • GeospatialTypes

      public GeospatialTypes()
  • Method Details

    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • getTypes

      public Set<Integer> getTypes()
    • update

      public void update(org.locationtech.jts.geom.Geometry geometry)
      Updates the types list with the given geometry's type. If the geometry type is unknown, the instance becomes invalid.
      Parameters:
      geometry - the geometry to process
    • merge

      public void merge(GeospatialTypes other)
    • reset

      public void reset()
    • isValid

      public boolean isValid()
    • copy

      public GeospatialTypes copy()
    • toString

      public String toString()
      Overrides:
      toString in class Object