Package com.luciad.format.s57
Class TLcdS57Node
java.lang.Object
com.luciad.shape.ALcdShape
com.luciad.shape.ALcdPoint
com.luciad.shape.shape2D.ALcd2DEditablePoint
com.luciad.shape.shape3D.ALcd3DEditablePoint
com.luciad.format.s57.TLcdS57Node
- All Implemented Interfaces:
ILcdBounded
,ILcdBounds
,ILcdPoint
,ILcdPointList
,ILcdPolypoint
,ILcdShape
,ILcd2DEditablePoint
,ILcd2DEditableShape
,ILcd3DEditablePoint
,ILcd3DEditableShape
,ILcdCloneable
,Serializable
,Cloneable
Represents a node in the S-57 domain model.
An S-57 node is a simple point geometry, and can be part of a Point, Line or Area Feature.
- Since:
- 11.0
- See Also:
-
Constructor Summary
ConstructorDescriptionTLcdS57Node
(int aId, double aX, double aY) Constructs an S-57 node with the given ID and coordinates. -
Method Summary
Modifier and TypeMethodDescriptionReturns a copy of thisILcdBounds
object that is also anILcd2DEditableBounds
.Returns a copy of thisILcdPoint
that is also anILcd2DEditablePoint
.Returns a copy of thisILcdBounds
object that is also anILcd3DEditableBounds
.Returns a copy of thisILcdPoint
that is also anILcd3DEditablePoint
.boolean
Returns whether the given object has the same class and the same coordinates.int
getId()
Returns the ID of this node, unique among all nodes within the model.double
getX()
Returns the x coordinate of thisILcdPoint
.double
getY()
Returns the y coordinate of thisILcdPoint
.double
getZ()
Returns the z coordinate of thisILcdPoint
.int
hashCode()
The hash code of this shape is the hash code of its class, in order to be consistent with theALcdShape.equals(Object)
method.boolean
interacts2D
(double aLon, double aLat, double aWidth, double aHeight) Checks whether thisILcdBounds
object interacts with the given rectangle in the 2D space.void
move3D
(double aX, double aY, double aZ) Moves thisILcd3DEditableShape
to the given point in the 3D space.Methods inherited from class com.luciad.shape.shape3D.ALcd3DEditablePoint
move2D, move3D, toString, translate3D
Methods inherited from class com.luciad.shape.shape2D.ALcd2DEditablePoint
move2D, translate2D
Methods inherited from class com.luciad.shape.ALcdPoint
contains2D, contains2D, contains2D, contains3D, contains3D, contains3D, getBounds, getCosX, getCosY, getDepth, getFocusPoint, getHeight, getLocation, getMaxX, getMaxY, getMaxZ, getMinX, getMinY, getMinZ, getPoint, getPointCount, getSinX, getSinY, getTanX, getTanY, getWidth, interacts2D, interacts3D, interacts3D, isDefined
Methods inherited from class com.luciad.shape.ALcdShape
clone, contains2D, contains3D, fromDomainObject
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.luciad.shape.shape2D.ILcd2DEditableShape
move2D, translate2D
Methods inherited from interface com.luciad.shape.ILcdBounded
getBounds
Methods inherited from interface com.luciad.shape.ILcdBounds
getCenter
Methods inherited from interface com.luciad.util.ILcdCloneable
clone
Methods inherited from interface com.luciad.shape.ILcdPoint
getCosX, getCosY, getSinX, getSinY, getTanX, getTanY
Methods inherited from interface com.luciad.shape.ILcdPointList
getPointSFCT, getX, getY, getZ
Methods inherited from interface com.luciad.shape.ILcdShape
contains2D, contains2D, contains3D, contains3D, getFocusPoint
-
Constructor Details
-
TLcdS57Node
public TLcdS57Node(int aId, double aX, double aY) Constructs an S-57 node with the given ID and coordinates.- Parameters:
aId
- an ID for this edge, unique within the model.aX
- the X coordinate of this node.aY
- the Y coordinate of this node.
-
-
Method Details
-
getId
public int getId()Returns the ID of this node, unique among all nodes within the model.- Returns:
- the ID of this node, unique among all nodes within the model.
-
move3D
public void move3D(double aX, double aY, double aZ) Description copied from interface:ILcd3DEditableShape
Moves thisILcd3DEditableShape
to the given point in the 3D space. The focus point is used as the handle by which the shape is moved.- Parameters:
aX
- the x coordinate of the point.aY
- the y coordinate of the point.aZ
- the z coordinate of the point.
-
getX
public double getX()Description copied from interface:ILcdPoint
Returns the x coordinate of thisILcdPoint
.- Returns:
- the x coordinate of this
ILcdPoint
.
-
getY
public double getY()Description copied from interface:ILcdPoint
Returns the y coordinate of thisILcdPoint
.- Returns:
- the y coordinate of this
ILcdPoint
.
-
getZ
public double getZ()Description copied from interface:ILcdPoint
Returns the z coordinate of thisILcdPoint
.- Specified by:
getZ
in interfaceILcdPoint
- Overrides:
getZ
in classALcd2DEditablePoint
- Returns:
- 0.
-
cloneAs2DEditablePoint
Description copied from interface:ILcdPoint
Returns a copy of thisILcdPoint
that is also anILcd2DEditablePoint
. This makes sure that the first two dimensions of the copy are writable,- Returns:
- a copy of this
ILcdPoint
that is also anILcd2DEditablePoint
. This makes sure that the first two dimensions of the copy are writable, even if the originalILcdPoint
object may be read-only. - See Also:
-
cloneAs3DEditablePoint
Description copied from interface:ILcdPoint
Returns a copy of thisILcdPoint
that is also anILcd3DEditablePoint
. This makes sure that all three dimensions of the copy are writable,- Returns:
- a copy of this
ILcdPoint
that is also anILcd3DEditablePoint
. This makes sure that all three dimensions of the copy are writable, even if the originalILcdPoint
object may be read-only. - See Also:
-
cloneAs2DEditableBounds
Description copied from interface:ILcdBounds
Returns a copy of thisILcdBounds
object that is also anILcd2DEditableBounds
. This makes sure that the first two dimensions of the copy are writable, even if the originalILcdBounds
object may be read-only.- Returns:
- a copy of this
ILcdBounds
object that is also anILcd2DEditableBounds
. This makes sure that the first two dimensions of the copy are writable, even if the originalILcdBounds
object may be read-only. - See Also:
-
cloneAs3DEditableBounds
Description copied from interface:ILcdBounds
Returns a copy of thisILcdBounds
object that is also anILcd3DEditableBounds
. This makes sure that all three dimensions of the copy are writable, even if the originalILcdBounds
object may be read-only.- Returns:
- a copy of this
ILcdBounds
object that is also anILcd3DEditableBounds
. This makes sure that all three dimensions of the copy are writable, even if the originalILcdBounds
object may be read-only. - See Also:
-
interacts2D
public boolean interacts2D(double aLon, double aLat, double aWidth, double aHeight) Description copied from interface:ILcdBounds
Checks whether thisILcdBounds
object interacts with the given rectangle in the 2D space. Only the first two dimensions of theILcdBounds
object are considered.If this bounds is
undefined
, the result is false.- Specified by:
interacts2D
in interfaceILcdBounds
- Overrides:
interacts2D
in classALcdPoint
- Parameters:
aLon
- the x coordinate of the rectangle.aLat
- the y coordinate of the rectangle.aWidth
- the width of the rectangle.aHeight
- the height of the rectangle.- Returns:
true
if thisILcdBounds
object touches or overlaps to any extent with the given rectangle,false
otherwise.
-
equals
Description copied from class:ALcdPoint
Returns whether the given object has the same class and the same coordinates.- Specified by:
equals
in interfaceILcdPoint
- Overrides:
equals
in classALcdPoint
- Parameters:
aObject
- theObject
to compare to.- Returns:
- false if aObject is an ILcdPoint object with different 3D coordinates or the object is not an ILcdPoint. If the objects do have the same 3D coordinates, the return value is defined by the specific implementations of ILcdPoint and may still be false.
-
hashCode
public int hashCode()Description copied from class:ALcdShape
The hash code of this shape is the hash code of its class, in order to be consistent with theALcdShape.equals(Object)
method. Extensions should refine this implementation, based on their properties.
-