Class TLcdGML31Polygon
- All Implemented Interfaces:
ILcdDataObject
,ILcdBounded
,ILcdEditableSurface
,ILcdShape
,ILcdSurface
,ILcdCloneable
,ILcdDeepCloneable
,ILcdFeatured
,ILcdSelfDescribedFeatured
,Serializable
,Cloneable
- Since:
- 10.0
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionstatic final TLcdDataProperty
Data property that maps to theexterior
element.static final TLcdDataProperty
Property that maps on thegid
attribute.static final TLcdDataProperty
Data property that maps to theinterior
element.Fields inherited from class com.luciad.format.gml31.model.TLcdGML31AbstractGeometry
SRS_PROPERTY
Fields inherited from class com.luciad.format.gml31.model.TLcdGML31AbstractGML
DESCRIPTION_PROPERTY, ID_PROPERTY, META_DATA_PROPERTY_PROPERTY, NAME_PROPERTY
-
Constructor Summary
ConstructorDescriptionTLcdGML31Polygon
(TLcdDataType aType) TLcdGML31Polygon
(TLcdDataType aDataType, ILcdModelReference aSrs) Constructs a polygon and initializes its model reference (srs).Constructs a polygon and initializes its model reference (srs). -
Method Summary
Modifier and TypeMethodDescriptionclone()
Returns a deep clone of this object.Returns a deep clone of this object.boolean
contains2D
(double aX, double aY) Checks whether thisILcdShape
contains the given point in the 2D space.boolean
contains2D
(ILcdPoint aPoint) Checks whether thisILcdShape
contains the givenILcdPoint
in the 2D space.boolean
contains3D
(double aX, double aY, double aZ) Checks whether thisILcdShape
contains the given point in the 3D space.boolean
contains3D
(ILcdPoint aPoint) Checks whether thisILcdShape
contains the givenILcdPoint
in the 3D space.Returns theILcdBounds
by which the geometry of thisILcdBounded
object is bounded.Returns the role value contained in the value of theEXTERIOR_PROPERTY
property.Returns the exterior boundary of this surface.Returns the focus point of thisILcdShape
.getGid()
Gets the value of theGID_PROPERTY
property.Gets the value of theINTERIOR_PROPERTY
property adapted to a list ofTLcdGML31AbstractRing
instances.Returns the holes in this surface, as a list ofILcdRing
instances.void
setExterior
(TLcdGML31AbstractRing aValue) Sets the value of the property that maps to theexterior
element.void
setExteriorRing
(ILcdRing aExteriorRing) Sets the exterior boundary of this surface.void
Sets the value of theGID_PROPERTY
property.Methods inherited from class com.luciad.format.gml31.model.TLcdGML31AbstractGeometry
getSrs, setSrs, toString
Methods inherited from class com.luciad.format.gml31.model.TLcdGML31AbstractGML
getDescription, getId, getMetaDataProperty, getName, setDescription, setId
Methods inherited from class com.luciad.datamodel.TLcdFeaturedDataObject
canSetFeature, getFeature, getFeature, getFeatureCount, getFeaturedDescriptor, setFeature, setFeature
Methods inherited from class com.luciad.datamodel.TLcdDataObject
getDataType, getValue, getValue, hasValue, hasValue, setValue, setValue
-
Field Details
-
EXTERIOR_PROPERTY
Data property that maps to theexterior
element. The possible values for this property are instances ofTLcdGML31AbstractRingProperty
. -
INTERIOR_PROPERTY
Data property that maps to theinterior
element. The possible values for this property are instances ofList<TLcdGML31AbstractRingProperty>
. -
GID_PROPERTY
Property that maps on thegid
attribute. Acceptable values for this property are instances ofjava.lang.String
.
-
-
Constructor Details
-
TLcdGML31Polygon
public TLcdGML31Polygon() -
TLcdGML31Polygon
-
TLcdGML31Polygon
Constructs a polygon and initializes its model reference (srs).- Parameters:
aSrs
- the model reference for this object- See Also:
-
TLcdGML31Polygon
Constructs a polygon and initializes its model reference (srs).- Parameters:
aDataType
- the data type for this objectaSrs
- the model reference for this object- See Also:
-
-
Method Details
-
setExteriorRing
Description copied from interface:ILcdEditableSurface
Sets the exterior boundary of this surface.Note that this implementations may throw a
ClassCastException
orIllegalArgumentException
in case the class of the ring is not compatible with the implementation of the surface. Implementations should specify in their documentation all restrictions that apply in this context.- Specified by:
setExteriorRing
in interfaceILcdEditableSurface
- Parameters:
aExteriorRing
- the exterior boundary of this surface.
-
getExteriorRing
Description copied from interface:ILcdSurface
Returns the exterior boundary of this surface.- Specified by:
getExteriorRing
in interfaceILcdSurface
- Returns:
- the exterior boundary of this surface.
-
getInteriorRings
Description copied from interface:ILcdEditableSurface
Returns the holes in this surface, as a list ofILcdRing
instances. If there are no holes, an empty list is returned.The returned list is editable and can be used to add, remove or replace interior rings.
- Specified by:
getInteriorRings
in interfaceILcdEditableSurface
- Specified by:
getInteriorRings
in interfaceILcdSurface
- Returns:
- an editable list containing zero or more rings, representing the holes in this surface.
-
contains2D
public boolean contains2D(double aX, double aY) Description copied from interface:ILcdShape
Checks whether thisILcdShape
contains the given point in the 2D space. Only the first two dimensions of theILcdShape
are considered.- Specified by:
contains2D
in interfaceILcdShape
- Overrides:
contains2D
in classTLcdGML31AbstractGeometry
- Parameters:
aX
- the x coordinate of the point.aY
- the y coordinate of the point.- Returns:
- the boolean result of the containment test.
-
contains3D
public boolean contains3D(double aX, double aY, double aZ) Description copied from interface:ILcdShape
Checks whether thisILcdShape
contains the given point in the 3D space.- Specified by:
contains3D
in interfaceILcdShape
- Overrides:
contains3D
in classTLcdGML31AbstractGeometry
- Parameters:
aX
- the x coordinate of the point.aY
- the y coordinate of the point.aZ
- the z coordinate of the point.- Returns:
- the boolean result of the containment test.
-
contains2D
Description copied from interface:ILcdShape
Checks whether thisILcdShape
contains the givenILcdPoint
in the 2D space. Only the first two dimensions of theILcdShape
and theILcdPoint
are considered.- Specified by:
contains2D
in interfaceILcdShape
- Overrides:
contains2D
in classTLcdGML31AbstractGeometry
- Parameters:
aPoint
- theILcdPoint
to test.- Returns:
- the boolean result of the containment test.
- See Also:
-
contains3D
Description copied from interface:ILcdShape
Checks whether thisILcdShape
contains the givenILcdPoint
in the 3D space.- Specified by:
contains3D
in interfaceILcdShape
- Overrides:
contains3D
in classTLcdGML31AbstractGeometry
- Parameters:
aPoint
- theILcdPoint
to test.- Returns:
- the boolean result of the containment test.
- See Also:
-
getFocusPoint
Description copied from interface:ILcdShape
Returns the focus point of thisILcdShape
.- Specified by:
getFocusPoint
in interfaceILcdShape
- Overrides:
getFocusPoint
in classTLcdGML31AbstractGeometry
- Returns:
- the focus point of this
ILcdShape
.
-
getBounds
Description copied from interface:ILcdBounded
Returns theILcdBounds
by which the geometry of thisILcdBounded
object is bounded.If the geometry does not allow retrieving valid bounds (for example a polyline with 0 points) the return value is unspecified. It is highly recommended to return an
undefined
bounds. You can create undefined bounds using the default constructors ofTLcdLonLatBounds
orTLcdXYBounds
.- Specified by:
getBounds
in interfaceILcdBounded
- Overrides:
getBounds
in classTLcdGML31AbstractGeometry
- Returns:
- the
ILcdBounds
by which the geometry of thisILcdBounded
object is bounded.
-
clone
Description copied from class:TLcdDataObject
Returns a deep clone of this object. This method delegates toTLcdDataObject.clone(Map)
.- Specified by:
clone
in interfaceILcdCloneable
- Overrides:
clone
in classTLcdDataObject
- Returns:
- a deep clone of this object
- See Also:
-
clone
Description copied from class:TLcdDataObject
Returns a deep clone of this object. If the clone is not already present in the dictionary, a new instance if created as follows:- First, a new instance is created using Java's clone() mechanism.
- Then, all properties of this object are cloned and set on the newly created
instance. A property is cloned as follows:
- If the property value is an
ILcdDataObject
, the value is cloned by first creating a new instance via thevalue.getDataType().newInstance()
method, and then cloning its properties one by one. - If the value implements
ILcdDeepCloneable
orILcdCloneable
then this interface is used to clone the value. - Otherwise, the property value is copied by reference.
- If the property value is an
- Specified by:
clone
in interfaceILcdDeepCloneable
- Overrides:
clone
in classTLcdDataObject
- Parameters:
aObjectDictionary
- the Object dictionary that keeps track of the objects for which a clone has already been made, and their corresponding clone Object.- Returns:
- a deep clone of this object
-
getExterior
Returns the role value contained in the value of theEXTERIOR_PROPERTY
property. Returnsnull
if the value of theEXTERIOR_PROPERTY
property isnull
.A boundary of a surface consists of a number of rings. In the normal 2D case, one of these rings is distinguished as being the exterior boundary. In a general manifold this is not always possible, in which case all boundaries shall be listed as interior boundaries, and the exterior will be empty.
- Returns:
- the role value of the
EXTERIOR_PROPERTY
property. - See Also:
-
setExterior
Sets the value of the property that maps to theexterior
element. to a new instance of the association classTLcdGML31AbstractRingProperty
initialized with the given role value. In case the given role value isnull
, theEXTERIOR_PROPERTY
property is set tonull
.A boundary of a surface consists of a number of rings. In the normal 2D case, one of these rings is distinguished as being the exterior boundary. In a general manifold this is not always possible, in which case all boundaries shall be listed as interior boundaries, and the exterior will be empty.
- Parameters:
aValue
- the role value to set for theEXTERIOR_PROPERTY
property.
-
getInterior
Gets the value of theINTERIOR_PROPERTY
property adapted to a list ofTLcdGML31AbstractRing
instances.A boundary of a surface consists of a number of rings. The "interior" rings seperate the surface / surface patch from the area enclosed by the rings.
- Returns:
- the value of the
INTERIOR_PROPERTY
property adapted to a list ofTLcdGML31AbstractRing
instances. - See Also:
-
getGid
Gets the value of theGID_PROPERTY
property.This attribute is included for backward compatibility with GML 2 and is deprecated with GML 3. This identifer is superceded by "gml:id" inherited from AbstractGMLType. The attribute "gid" should not be used anymore and may be deleted in future versions of GML without further notice.
- Returns:
- the value of the
GID_PROPERTY
property.
-
setGid
Sets the value of theGID_PROPERTY
property.This attribute is included for backward compatibility with GML 2 and is deprecated with GML 3. This identifer is superceded by "gml:id" inherited from AbstractGMLType. The attribute "gid" should not be used anymore and may be deleted in future versions of GML without further notice.
- Parameters:
aValue
- the value to set for theGID_PROPERTY
property.
-