public class TLcdHelipad extends Object implements ILcdEditableHelipad
ILcdHelipad
.
This implementation performs a discretization of the helipad in geodetic coordinates.
Modifier and Type | Field and Description |
---|---|
static TLcdDataProperty |
GEOMETRY_PROPERTY
The geometry property of the helipad type.
|
static TLcdDataProperty |
HELIPAD_TYPE_PROPERTY
The HelipadType property of the helipad type.
|
static TLcdDataProperty |
LENGTH_PROPERTY
The Length property of the helipad type.
|
static TLcdDataProperty |
WIDTH_PROPERTY
The Width property of the helipad type.
|
CLOCKWISE, COUNTERCLOCKWISE, INVALID_ORIENTATION
INTERPOLATION_CIRCLE_BY_3POINTS, INTERPOLATION_CIRCLE_BY_CENTERPOINT, INTERPOLATION_CIRCULARARC_BY_3POINTS, INTERPOLATION_CIRCULARARC_BY_BULGE, INTERPOLATION_CIRCULARARC_BY_CENTERPOINT, INTERPOLATION_ELLIPTICAL, INTERPOLATION_GEODESIC, INTERPOLATION_LINEAR, INTERPOLATION_MIXED, INTERPOLATION_RHUMB
Constructor and Description |
---|
TLcdHelipad()
Deprecated.
|
TLcdHelipad(TLcdDataType aDataType)
Creates a new instance for the given type.
|
TLcdHelipad(TLcdHelipad aHelipad)
Construct a new
TLcdHelipad object based on an existing one. |
Modifier and Type | Method and Description |
---|---|
void |
addLeg(ILcdGeoPathLeg aLeg)
Adds the specified leg to the end of this GeoPath.
|
Object |
clone()
Returns a clone of this
TLcdHelipad object. |
void |
computePointSFCT(double aV,
ILcd3DEditablePoint aILcd3DEditablePoint)
Computes a point of the curve, defined by the given parameter.
|
boolean |
contains2D(double v,
double v1)
Checks whether this
ILcdShape contains the given point in
the 2D space. |
boolean |
contains2D(ILcdPoint aPoint)
Checks whether this
ILcdShape contains the given ILcdPoint in the 2D space. |
boolean |
contains3D(double v,
double v1,
double v2)
Checks whether this
ILcdShape contains the given point in
the 3D space. |
boolean |
contains3D(ILcdPoint aPoint)
Checks whether this
ILcdShape contains the given ILcdPoint in the 3D space. |
ILcdBounds |
getBounds()
Returns the
ILcdBounds by which the geometry of this ILcdBounded object
is bounded. |
TLcdDataType |
getDataType()
Returns the type of this data object.
|
ILcdPoint |
getEndPoint()
Retrieves the end point of the curve.
|
double |
getEndTangent2D()
Returns the angle of the curve's tangent at the end point,
in degrees counterclockwise from the direction at 3 o'clock.
|
ILcdPoint |
getFocusPoint()
Returns the focus point of this
ILcdShape . |
TLcdHelipadType |
getHelipadType()
Returns the type of this helipad.
|
String |
getInterpolation()
Returns the interpolation method used by this curve.
|
ILcdGeoPathLeg |
getLeg(int aIndex)
Returns the
ILcdGeoPathLeg at the given index. |
int |
getLegCount()
Returns the number of legs in this
ILcdGeoPath . |
double |
getLength()
Returns the length of this helipad.
|
double |
getLength2D(double aV,
double aV1)
Returns the length between two points of the curve,
defined by the given parameters.
|
int |
getLineSegmentIntersectionCount(ILcdPoint aILcdPoint,
ILcdPoint aILcdPoint1)
Returns the number of intersections between this curve and a line segment
defined by the two specified points.
|
int |
getOrientation()
Returns the orientation of this
ILcdPolygon :
ILcdPolygon.CLOCKWISE or ILcdPolygon.COUNTERCLOCKWISE . |
ILcdPoint |
getPoint(int aIndex)
Returns the
ILcdPoint at a given index. |
int |
getPointCount()
Returns the number of
ILcdPoint objects in the list. |
ILcdPoint |
getStartPoint()
Retrieves the start point of the curve.
|
double |
getStartTangent2D()
Returns the angle of the curve's tangent at the start point,
in degrees counterclockwise from the direction at 3 o'clock.
|
double |
getTangent2D(double aV)
Returns the angle of the curve's tangent in the point defined
by the given parameter, in degrees counterclockwise from the
direction at 3 o'clock.
|
Object |
getValue(String aPropertyName)
Convenience method that returns the value of the property with the given name.
|
Object |
getValue(TLcdDataProperty aProperty)
Returns the value of the given property.
|
double |
getWidth()
Returns the width of this helipad.
|
boolean |
hasValue(String aPropertyName)
Indicates whether this data object has a value for the given property.
|
boolean |
hasValue(TLcdDataProperty aProperty)
Indicates whether this data object has a value for the given property.
|
void |
insertLegAt(ILcdGeoPathLeg aLeg,
int anIndex)
Adds a
ILcdGeoPathLeg object to the ILcdEditableGeoPath
on the specified index. |
void |
invalidate()
Discards the geometry cached with this helipad and recalculates it.
|
void |
removeLegAt(int anIndex)
Removes the
ILcdGeoPathLeg object on the specified index from the
from ILcdEditableGeoPath . |
void |
setHelipadType(TLcdHelipadType aHelipadType)
Specifies the type of this helipad.
|
void |
setLength(double aLength)
Specifies the length of this helipad.
|
void |
setValue(String aPropertyName,
Object aValue)
Convenience method that sets the value of the property with the given name.
|
void |
setValue(TLcdDataProperty aProperty,
Object aValue)
Sets the value of the given property for this data object.
|
void |
setWidth(double aWidth)
Specifies the width of this helipad.
|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getPointSFCT, getX, getY, getZ
public static final TLcdDataProperty HELIPAD_TYPE_PROPERTY
TLcdHelipadType
.public static final TLcdDataProperty WIDTH_PROPERTY
Double
.public static final TLcdDataProperty LENGTH_PROPERTY
Double
.public static final TLcdDataProperty GEOMETRY_PROPERTY
ILcdGeoPath
.@Deprecated public TLcdHelipad()
TLcdHelipad(TLcdDataType)
TLcdHelipad
object.public TLcdHelipad(TLcdHelipad aHelipad)
TLcdHelipad
object based on an existing one.aHelipad
- The helipad to copy.public TLcdHelipad(TLcdDataType aDataType)
aDataType
- the data type of the returned instanceIllegalArgumentException
- if TLcdAISDataTypes.Helipad
is not assignable from
the given data typeTLcdAISDataTypes.Helipad
public TLcdHelipadType getHelipadType()
ILcdHelipad
getHelipadType
in interface ILcdHelipad
public double getWidth()
ILcdHelipad
getWidth
in interface ILcdHelipad
public double getLength()
ILcdHelipad
getLength
in interface ILcdHelipad
public void setHelipadType(TLcdHelipadType aHelipadType)
ILcdEditableHelipad
setHelipadType
in interface ILcdEditableHelipad
aHelipadType
- a value for the typepublic void setWidth(double aWidth)
ILcdEditableHelipad
setWidth
in interface ILcdEditableHelipad
aWidth
- a value for the widthpublic void setLength(double aLength)
ILcdEditableHelipad
setLength
in interface ILcdEditableHelipad
aLength
- a value for the lengthpublic int getLegCount()
ILcdGeoPath
ILcdGeoPath
.getLegCount
in interface ILcdGeoPath
ILcdGeoPath
.public ILcdGeoPathLeg getLeg(int aIndex)
ILcdGeoPath
ILcdGeoPathLeg
at the given index.getLeg
in interface ILcdGeoPath
aIndex
- an index.ILcdGeoPathLeg
at the given index.public void addLeg(ILcdGeoPathLeg aLeg)
ILcdEditableGeoPath
addLeg
in interface ILcdEditableGeoPath
aLeg
- an ILcdGeoPathLeg
public void insertLegAt(ILcdGeoPathLeg aLeg, int anIndex)
ILcdEditableGeoPath
ILcdGeoPathLeg
object to the ILcdEditableGeoPath
on the specified index.insertLegAt
in interface ILcdEditableGeoPath
aLeg
- the ILcdGeoPathLeg
object to be added to the
ILcdEditableGeoPath
.anIndex
- the index in the ILcdEditableAirspace
where the
ILcdAirspaceSegment
object must be added.public void removeLegAt(int anIndex)
ILcdEditableGeoPath
ILcdGeoPathLeg
object on the specified index from the
from ILcdEditableGeoPath
.removeLegAt
in interface ILcdEditableGeoPath
anIndex
- the index in the ILcdEditableGeoPath
where the
ILcdGeoPathLeg
object must be removed.public ILcdBounds getBounds()
ILcdBounded
ILcdBounds
by which the geometry of this ILcdBounded
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
of TLcdLonLatBounds
or TLcdXYBounds
.
getBounds
in interface ILcdBounded
ILcdBounds
by which the geometry of this ILcdBounded
object
is bounded.public ILcdPoint getFocusPoint()
ILcdShape
ILcdShape
.getFocusPoint
in interface ILcdShape
ILcdShape
.public boolean contains2D(ILcdPoint aPoint)
ILcdShape
ILcdShape
contains the given ILcdPoint
in the 2D space.
Only the first two dimensions of the ILcdShape
and the ILcdPoint
are considered.contains2D
in interface ILcdShape
aPoint
- the ILcdPoint
to test.ILcdShape.contains2D(double, double)
public boolean contains2D(double v, double v1)
ILcdShape
ILcdShape
contains the given point in
the 2D space. Only the first two dimensions of the ILcdShape
are considered.contains2D
in interface ILcdShape
v
- the x coordinate of the point.v1
- the y coordinate of the point.public boolean contains3D(ILcdPoint aPoint)
ILcdShape
ILcdShape
contains the given ILcdPoint
in the 3D space.contains3D
in interface ILcdShape
aPoint
- the ILcdPoint
to test.ILcdShape.contains3D(double, double, double)
public boolean contains3D(double v, double v1, double v2)
ILcdShape
ILcdShape
contains the given point in
the 3D space.contains3D
in interface ILcdShape
v
- the x coordinate of the point.v1
- the y coordinate of the point.v2
- the z coordinate of the point.public Object clone()
TLcdHelipad
object.
Note: the features of the new object are a shallow clone of the features of
this object.clone
in interface ILcdCloneable
clone
in class Object
TLcdHelipad
object.Object.clone()
public int getOrientation()
ILcdPolygon
ILcdPolygon
:
ILcdPolygon.CLOCKWISE
or ILcdPolygon.COUNTERCLOCKWISE
.getOrientation
in interface ILcdPolygon
ILcdPolygon
:
ILcdPolygon.CLOCKWISE
or ILcdPolygon.COUNTERCLOCKWISE
.
This method should not return INVALID_ORIENTATION
, which is only to be used for resetting the orientation
so that it can be recalculated.public int getPointCount()
ILcdPointList
ILcdPoint
objects in the list.getPointCount
in interface ILcdPointList
ILcdPoint
objects in the list.public ILcdPoint getPoint(int aIndex) throws IndexOutOfBoundsException
ILcdPointList
ILcdPoint
at a given index.getPoint
in interface ILcdPointList
aIndex
- a valid index in the list of ILcdPoint
objects.ILcdPoint
at the given index.IndexOutOfBoundsException
- if the given index is out of bounds.public void invalidate()
public TLcdDataType getDataType()
ILcdDataObject
null
.getDataType
in interface ILcdDataObject
public Object getValue(TLcdDataProperty aProperty)
ILcdDataObject
Returns the value of the given property.
If the property is a collection, the returned value will never be null. If the property has not been set, an empty collection of the appropriate type will be returned (Set, List or Map).
The property must not be null, and must be declared in the data object's type
or in one of its super types.
Otherwise an IllegalArgumentException
is thrown.
getValue
in interface ILcdDataObject
aProperty
- the property for which the value is to be returnedpublic Object getValue(String aPropertyName)
ILcdDataObject
Convenience method that returns the value of the property with the given name.
If more than one property exists with the given name, the most specific property should be used (this is the property defined by the most specialized type in this object's data type hierarchy). SeeILcdDataObject.getValue(TLcdDataProperty)
for more information.getValue
in interface ILcdDataObject
aPropertyName
- the name of the property of which the value is to be returnedTLcdDataType.getProperty(String)
public void setValue(TLcdDataProperty aProperty, Object aValue)
ILcdDataObject
Sets the value of the given property for this data object. The implementation is allowed to throw an exception if the given value can't be set.
The given property must be declared in thedata object's type
or in one of its super types. In
other words, getDataType().getProperties().contains( aProperty ) should always be true.
Otherwise, the implementation should throw an IllegalArgumentException
.setValue
in interface ILcdDataObject
aProperty
- the property for which the value is to be setaValue
- the value to setTLcdDataType.getProperty(String)
public void setValue(String aPropertyName, Object aValue)
ILcdDataObject
Convenience method that sets the value of the property with the given name.
If more than one property exists with the given name, the most specific property should be used (this is the property defined by the most specialized type in this object's data type hierarchy). SeeILcdDataObject.setValue(TLcdDataProperty, Object)
for more information.setValue
in interface ILcdDataObject
aPropertyName
- the name of the property of which the value is to be setaValue
- the value to setpublic boolean hasValue(TLcdDataProperty aProperty)
ILcdDataObject
aProperty
is from the right data type
, and this instance has a value for it: returns true
aProperty
is from the right data type
, and this instance has no value for it: returns false
aProperty
is not from the right data type
: not allowed, you will get IllegalArgumentExceptionaProperty
is null
: not allowed, you will get NullPointerExceptionhasValue
in interface ILcdDataObject
aProperty
- the property for which to return whether a value is present or not.true
if this data object has a value for the given property, false
otherwise.public boolean hasValue(String aPropertyName)
ILcdDataObject
ILcdDataObject.hasValue(TLcdDataProperty)
for more information.hasValue
in interface ILcdDataObject
aPropertyName
- the name of the property for which to return whether a value is present
or not.true
if this data object has a value for the property with the given name,
false
otherwise.public ILcdPoint getStartPoint()
ILcdCurve
This is equivalent to computePointSFCT(0)
.
getStartPoint
in interface ILcdCurve
public ILcdPoint getEndPoint()
ILcdCurve
This is equivalent to computePointSFCT(1)
.
getEndPoint
in interface ILcdCurve
public double getStartTangent2D()
ILcdCurve
The tangent orientation is from the start point towards the rest of the shape.
This is the same as getTangent2D(0)
.
getStartTangent2D
in interface ILcdCurve
public double getEndTangent2D()
ILcdCurve
The tangent orientation is from the end point, away from the curve before it.
This is the same as getTangent2D(1)
.
getEndTangent2D
in interface ILcdCurve
public double getTangent2D(double aV)
ILcdCurve
The tangent orientation is from the point at parameter aParam
towards the rest of the shape.
ILcdCurve.getStartTangent2D()
.ILcdCurve.getEndTangent2D()
.getTangent2D
in interface ILcdCurve
aV
- a value of the closed interval [0,1]public double getLength2D(double aV, double aV1)
ILcdCurve
aParam1 == aParam2
, the length is 0.aParam1 == 0 and aParam2 == 1
, the length is the whole length of the curve.aParam1 > aParam2
, the length is (aParam1 to 1
) + (0 to aParam2
).getLength2D
in interface ILcdCurve
aV
- a value of the closed interval [0,1]aV1
- a value of the closed interval [0,1]public void computePointSFCT(double aV, ILcd3DEditablePoint aILcd3DEditablePoint)
ILcdCurve
ILcdCurve.getStartPoint()
.ILcdCurve.getEndPoint()
.computePointSFCT
in interface ILcdCurve
aV
- a value of the closed interval [0,1]aILcd3DEditablePoint
- the point to store the computed curve point inpublic String getInterpolation()
ILcdCurve
A set of predefined constants are defined in this interface,
which are used by the default ILcdCurve
implementations
provided by LuciadLightspeed.
Custom implementations can define their own constants, and use them to interpret the interpolation of the curve.
getInterpolation
in interface ILcdCurve
public int getLineSegmentIntersectionCount(ILcdPoint aILcdPoint, ILcdPoint aILcdPoint1)
ILcdCurve
This information can be used to perform containment calculations, if this curve is closed or if this curve is part of a composite closed curve. By determining the number of intersections between this curve and a line segment starting from a given point in a fixed direction, one can determine whether a point is located within the closed curve by using the even-odd rule.
getLineSegmentIntersectionCount
in interface ILcdCurve
aILcdPoint
- the first point of the line segmentaILcdPoint1
- the second point of the line segment