Package net.sf.eBusx.geo
Class GeoMultiPolygon
- java.lang.Object
-
- net.sf.eBus.messages.EMessageObject
-
- net.sf.eBus.messages.EField
-
- net.sf.eBusx.geo.GeoObject
-
- net.sf.eBusx.geo.GeoMultiPolygon
-
- All Implemented Interfaces:
java.io.Serializable
public final class GeoMultiPolygon extends GeoObject
Contains zero or more GeoJSON polygons.- Author:
- Charles W. Rapp
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classGeoMultiPolygon.BuilderBuilder class used to create GeoJSON multi-polygon instances.-
Nested classes/interfaces inherited from class net.sf.eBusx.geo.GeoObject
GeoObject.GeoBuilder<F extends GeoObject,B extends GeoObject.GeoBuilder<F,?>>, GeoObject.GeoType
-
-
Field Summary
Fields Modifier and Type Field Description GeoPolygon[]polygonsGeoJSON polygon array.-
Fields inherited from class net.sf.eBusx.geo.GeoObject
boundingBox, MAX_LATITUDE, MAX_LONGITUDE, MIN_LATITUDE, MIN_LONGITUDE, type
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static GeoMultiPolygon.Builderbuilder()Returns a new instance of anGeoMultiPolygonbuilder.booleanequals(java.lang.Object o)Returnstrueifois the same instance asthis GeoMultiPolygonor ifois a non-null GeoMultiPolygoninstance whose polygons array equalsthis GeoMultiPolygon's array.inthashCode()Returns hash of polygons.booleanisEmpty()Returnstrueif this multi-polygon elements has no line polygons;falseotherwise.java.lang.StringtoString()Returns text specifying GeoJSON type and attributes-
Methods inherited from class net.sf.eBusx.geo.GeoObject
validateLatitude, validateLongitude
-
-
-
-
Field Detail
-
polygons
public final GeoPolygon[] polygons
GeoJSON polygon array. May be empty but notnull.
-
-
Method Detail
-
equals
public boolean equals(java.lang.Object o)
Returnstrueifois the same instance asthis GeoMultiPolygonor ifois a non-null GeoMultiPolygoninstance whose polygons array equalsthis GeoMultiPolygon's array.- Overrides:
equalsin classjava.lang.Object- Parameters:
o- comparison object.- Returns:
trueifoequalsthis GeoMultiPolygoninstance.
-
hashCode
public int hashCode()
Returns hash of polygons.- Overrides:
hashCodein classjava.lang.Object- Returns:
- polygons hash.
-
toString
public java.lang.String toString()
Description copied from class:GeoObjectReturns text specifying GeoJSON type and attributes
-
isEmpty
public boolean isEmpty()
Returnstrueif this multi-polygon elements has no line polygons;falseotherwise.- Returns:
trueif this element contains no polygons.
-
builder
public static GeoMultiPolygon.Builder builder()
Returns a new instance of anGeoMultiPolygonbuilder.- Returns:
- GeoJSON multi-polygon builder.
- See Also:
GeoMultiPolygon.Builder
-
-