public class DirectionVector extends PointingElement
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
AXIS_TAG
axis
|
static java.lang.String |
FRAME_TAG
frame
|
static java.lang.String |
LATITUDE_TAG
lat
|
static java.lang.String |
LONGITUDE_TAG
lon
|
static java.lang.String |
ORIGIN_TAG
origin
|
static java.lang.String |
REF_TAG
ref
|
static java.lang.String |
ROTATE_TAG
rotate
|
static java.lang.String |
ROTATION_ANGLE_TAG
rotationAngle
|
static java.lang.String |
ROTATION_AXIS_TAG
rotationAxis
|
static java.lang.String |
TARGET_TAG
target
|
static java.lang.String |
UNITS_TAG
units
|
static java.lang.String |
X_TAG
x
|
static java.lang.String |
Y_TAG
y
|
static java.lang.String |
Z_TAG
z
|
| Constructor and Description |
|---|
DirectionVector(PointingElement org) |
DirectionVector(java.lang.String type) |
DirectionVector(java.lang.String type,
PointingElement pm) |
DirectionVector(java.lang.String type,
java.lang.String reference)
Creates a Direction vector referenced to another direction vector
Direction vectors can be defined by referencing to
direction vectors that were previously defined and
got a name assigned.
|
DirectionVector(java.lang.String type,
java.lang.String frame,
float longitude,
float latitude)
Creates a fixed direction vector expressed in spherical coordinates
For spherical coordinates the element must
contain the child elements
|
DirectionVector(java.lang.String type,
java.lang.String frame,
float x,
float y,
float z)
Creates a fixed direction vector expressed in cartesian coordinates
For cartesian coordinates the element must
contain the child elements
|
DirectionVector(java.lang.String type,
java.lang.String origin,
java.lang.String target)
Creates a state vector based in Origin and Target
This representation is used to define a direction
vector from two state vectors.
|
DirectionVector(java.lang.String type,
java.lang.String axis,
java.lang.String rotationAxis,
float rotationAngle)
Creates a rotated Direction Vector
This representation allows to define a direction
vector by right-handed rotation of the direction
vector axis around rotationAxis by the angle
rotationAngle.
|
DirectionVector(java.lang.String type,
java.lang.String frame,
java.lang.String unitLongitude,
float longitude,
java.lang.String unitLatitude,
float latitude)
Creates a fixed direction vector expressed in spherical coordinates
For spherical coordinates the element must
contain the child elements
|
DirectionVector(java.lang.String type,
java.lang.String axis,
java.lang.String rotationAxis,
java.lang.String rotationAngleUnit,
float rotationAngle)
Creates a rotated Direction Vector
This representation allows to define a direction
vector by right-handed rotation of the direction
vector axis around rotationAxis by the angle
rotationAngle.
|
| Modifier and Type | Method and Description |
|---|---|
DirectionVector |
copy() |
java.lang.String |
getAxis()
For rotated direction vector, get the axis this vector reference
|
java.lang.String |
getFrame()
Return the frame to which the vector is relative
|
float |
getLatitude()
For a direction vector expressed in spherical coordinates, get the latitude
|
float |
getLatitude(java.lang.String unit)
For a direction vector expressed in spherical coordinates, get the latitude in the given unit
|
java.lang.String |
getLatitudeUnit()
For a direction vector expressed in spherical coordinates, get the unit where the latitude is expressed.
|
float |
getLongitude()
For a direction vector expressed in spherical coordinates, get the longitude
|
float |
getLongitude(java.lang.String unit)
For a direction vector expressed in spherical coordinates, get the longitude in the given unit
|
java.lang.String |
getLongitudeUnit()
For a direction vector expressed in spherical coordinates, get the unit where the longitude is expressed.
|
java.lang.String |
getOrigin()
For state vector based in Origin and Target, get the Origin
|
java.lang.String |
getReference()
For referenced direction vectors set the name of the referenced vector
|
float |
getRotationAngle()
For rotated direction vector, get the rotation angle
|
float |
getRotationAngle(java.lang.String unit)
For rotated direction vector, get the rotation angle in the given unit
|
java.lang.String |
getRotationAngleUnit()
For rotated direction vector, get the units where the rotation angle is expressed.
|
java.lang.String |
getRotationAxis()
For rotated direction vector, get the axis this vector rotation axis
|
java.lang.String |
getTarget()
For state vector based in Origin and Target, get the Target
|
java.lang.String |
getUnit(java.lang.String field) |
float |
getX()
Get the x component of the fixed vector
|
float |
getY()
Get the y component of the fixed vector
|
float |
getZ()
Get the z component of the fixed vector
|
void |
setAxis(java.lang.String axis)
For rotated direction vector, set the axis this vector reference
|
void |
setBooleanField(java.lang.String field,
boolean value) |
void |
setFloatArrayField(java.lang.String field,
float[] xAngles) |
void |
setFloatField(java.lang.String field,
float value) |
void |
setFrame(java.lang.String frame)
Set the frame to which the vector is relative
|
void |
setIntegerField(java.lang.String field,
int value) |
void |
setLatitude(float latitude)
For a direction vector expressed in spherical coordinates, set the latitude in deg.
|
void |
setLatitude(java.lang.String units,
float latitude)
For a direction vector expressed in spherical coordinates, set the latitude
|
void |
setLongitude(float longitude)
For a direction vector expressed in spherical coordinates, set the longitude in deg.
|
void |
setLongitude(java.lang.String units,
float longitude)
For a direction vector expressed in spherical coordinates, set the longitude
|
void |
setOrigin(java.lang.String origin)
For state vector based in Origin and Target, set the Origin
|
void |
setReference(java.lang.String reference)
For referenced direction vectors set the name of the referenced vector
|
void |
setRotationAngle(float angle)
For rotated direction vector, set the rotation angle
|
void |
setRotationAngle(java.lang.String angleUnit,
float angle)
For rotated direction vector, set the rotation angle
|
void |
setRotationAxis(java.lang.String rotationAxis)
For rotated direction vector, set the axis this vector rotation axis
|
void |
setStringField(java.lang.String field,
java.lang.String value) |
void |
setTarget(java.lang.String target)
For state vector based in Origin and Target, set the Target
|
void |
setUnit(java.lang.String field,
java.lang.String unit) |
void |
setX(float x)
Set the x component of the fixed vector
|
void |
setY(float y)
Set the y component of the fixed vector
|
void |
setZ(float z)
Set the z component of the fixed vector
|
addAttribute, addChild, asDataset, copyFrom, equals, getAttribute, getAttributes, getChild, getChildren, getDescription, getFirstLevelTextContent, getName, getValue, hasAttributtes, hasChildren, readFrom, regenerate, removeAttribute, removeAttribute, setDescription, setValue, toString, toStringParameter, toXml, validatepublic static java.lang.String UNITS_TAG
public static java.lang.String X_TAG
public static java.lang.String Y_TAG
public static java.lang.String Z_TAG
public static java.lang.String FRAME_TAG
public static java.lang.String LATITUDE_TAG
public static java.lang.String LONGITUDE_TAG
public static java.lang.String ORIGIN_TAG
public static java.lang.String REF_TAG
public static java.lang.String TARGET_TAG
public static java.lang.String ROTATE_TAG
public static java.lang.String AXIS_TAG
public static java.lang.String ROTATION_AXIS_TAG
public static java.lang.String ROTATION_ANGLE_TAG
public DirectionVector(java.lang.String type,
PointingElement pm)
public DirectionVector(PointingElement org)
public DirectionVector(java.lang.String type)
public DirectionVector(java.lang.String type,
java.lang.String frame,
float x,
float y,
float z)
type - The type of direction vector (target, targetDir or dirVector)frame - The frame where this vector is expressed (SC,EME2000,CG)x - The x component of this vectory - The y component of this vectorz - The z component of this vectorpublic DirectionVector(java.lang.String type,
java.lang.String frame,
java.lang.String unitLongitude,
float longitude,
java.lang.String unitLatitude,
float latitude)
type - The type of direction vector (target, targetDir or dirVector)frame - The frame where this vector is expressed (SC,EME2000,CG)unitLongitude - Unit in which the longitude is expressedlongitude - LongitudeunitLatitude - Unit in which the latitude is expressedlatitude - Latitudepublic DirectionVector(java.lang.String type,
java.lang.String frame,
float longitude,
float latitude)
type - The type of direction vector (target, targetDir or dirVector)frame - The frame where this vector is expressed (SC,EME2000,CG)longitude - Longitude expressed in deg.latitude - Latitude expressed in deg.public DirectionVector(java.lang.String type,
java.lang.String origin,
java.lang.String target)
type - The type of direction vector (target, targetDir or dirVector)origin - Origin State vectortarget - Target State vectorpublic DirectionVector(java.lang.String type,
java.lang.String reference)
type - The type of direction vector (target, targetDir or dirVector)reference - Name of the referenced direction vectorpublic DirectionVector(java.lang.String type,
java.lang.String axis,
java.lang.String rotationAxis,
java.lang.String rotationAngleUnit,
float rotationAngle)
type - The type of direction vector (target, targetDir or dirVector)axis - The axis that this vector referencerotationAxis - Rotation axis of the vectorrotationAngleUnit - Unit in which the angle of rotation is expressedrotationAngle - Rotation anglepublic DirectionVector(java.lang.String type,
java.lang.String axis,
java.lang.String rotationAxis,
float rotationAngle)
type - The type of direction vector (target, targetDir or dirVector)axis - The axis that this vector referencerotationAxis - Rotation axis of the vectorrotationAngle - Rotation angle. It must be expressed in deg.public DirectionVector copy()
copy in class PointingElementpublic java.lang.String getUnit(java.lang.String field)
public void setUnit(java.lang.String field,
java.lang.String unit)
public void setFloatArrayField(java.lang.String field,
float[] xAngles)
public void setFloatField(java.lang.String field,
float value)
public void setIntegerField(java.lang.String field,
int value)
public void setStringField(java.lang.String field,
java.lang.String value)
public void setBooleanField(java.lang.String field,
boolean value)
public void setX(float x)
x - The x componentpublic void setY(float y)
y - The y componentpublic void setZ(float z)
z - The z componentpublic float getX()
public float getY()
public float getZ()
public java.lang.String getFrame()
public void setFrame(java.lang.String frame)
frame - Frame to which the vector is relativepublic void setLongitude(java.lang.String units,
float longitude)
units - Unit in which the longitude is expressedlongitude - Longitudepublic void setLongitude(float longitude)
longitude - Longitude in deg.public void setLatitude(java.lang.String units,
float latitude)
units - Unit in which the latitude is expressedlatitude - Latitudepublic void setLatitude(float latitude)
latitude - Latitude in deg.public float getLatitude()
public float getLatitude(java.lang.String unit)
unit - the desired unitpublic float getLongitude()
public float getLongitude(java.lang.String unit)
public java.lang.String getLongitudeUnit()
public java.lang.String getLatitudeUnit()
public void setOrigin(java.lang.String origin)
origin - Origin State vectorpublic void setTarget(java.lang.String target)
target - Target State vectorpublic java.lang.String getTarget()
public java.lang.String getOrigin()
public void setReference(java.lang.String reference)
reference - Name of the referenced vectorpublic java.lang.String getReference()
public void setAxis(java.lang.String axis)
axis - public java.lang.String getAxis()
public void setRotationAxis(java.lang.String rotationAxis)
rotationAxis - Rotation Axispublic java.lang.String getRotationAxis()
public void setRotationAngle(java.lang.String angleUnit,
float angle)
angleUnit - Unit in which the angle of rotation is expressedangle - Rotation anglepublic void setRotationAngle(float angle)
angle - Rotation angle. The rotation angle unit is set to deg.public float getRotationAngle()
public float getRotationAngle(java.lang.String unit)
unit - The desired unitpublic java.lang.String getRotationAngleUnit()