Class GeoCollection

  • All Implemented Interfaces:
    java.io.Serializable

    public final class GeoCollection
    extends GeoObject
    A collection of GeoJSON objects of different types.
    Author:
    Charles W. Rapp
    See Also:
    Serialized Form
    • Field Detail

      • geometries

        public final GeoObject[] geometries
        GeoJSON objects collection.
    • Method Detail

      • equals

        public boolean equals​(java.lang.Object o)
        Returns true if o is the same instance as this GeoCollection or if o is a non-null GeoCollection instance whose geometries array equals this GeoCollection's array.
        Overrides:
        equals in class java.lang.Object
        Parameters:
        o - comparison object.
        Returns:
        true if o equals this GeoCollection instance.
      • hashCode

        public int hashCode()
        Returns hash of geometries.
        Overrides:
        hashCode in class java.lang.Object
        Returns:
        geometries hash.
      • toString

        public java.lang.String toString()
        Description copied from class: GeoObject
        Returns text specifying GeoJSON type and attributes
        Overrides:
        toString in class GeoObject
        Returns:
        human-readable text containing GeoJSON type name and attributes.
      • isEmpty

        public boolean isEmpty()
        Returns true if this GeoObject collection has no items; false otherwise.
        Returns:
        true if this element contains no items.
      • builder

        public static GeoCollection.Builder builder()
        Returns a new instance of an GeoCollection builder.
        Returns:
        GeoJSON collection builder.