|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectmil.navy.nps.dis.PduElement
mil.navy.nps.dis.EulerAngle
Representation of an entity's orientation.
"Don't ask, don't tell" does NOT apply here. We can ask any entity about its orientation.
PduElement,
SerializationInterface| Field Summary | |
protected float |
phi
The third angle of rotation (around the local "Z" axis) in radians. |
protected float |
psi
The first angle of rotation (around the local "X" axis) in radians. |
int |
sizeOf
Constant value--size of an EulerAngle record when written out; here : sizeOf = 12 bytes. |
protected float |
theta
The second angle of rotation (around the local "Y" axis) in radians. |
| Constructor Summary | |
EulerAngle()
Constructs an new Entity Identifier, with initial values initiated to 0. |
|
EulerAngle(float pPsi,
float pTheta,
float pPhi)
Constructs an new EulerAngle Record, with variables values passed by parameters. |
|
| Method Summary | |
java.lang.Object |
clone()
Makes deep copies of all the instance variables, so we don't have two objects pointing to the same data. |
void |
deSerialize(java.io.DataInputStream pInputStream)
Deserialize our data from the input stream. |
float |
getPhi()
|
float |
getPsi()
|
float |
getTheta()
|
int |
length()
Returns the length of the object when serialized in a stream. |
void |
printValues(int indentLevel,
java.io.PrintStream printStream)
Prints the generated serialized object for debugging. |
void |
serialize(java.io.DataOutputStream outputStream)
Serialize our data out to the stream. |
void |
setPhi(float pPhi)
|
void |
setPsi(float pPsi)
|
void |
setTheta(float pTheta)
|
void |
setValues(float pPsi,
float pTheta,
float pPhi)
|
| Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected float psi
protected float theta
protected float phi
public final int sizeOf
sizeOf = 12 bytes.
| Constructor Detail |
public EulerAngle()
public EulerAngle(float pPsi,
float pTheta,
float pPhi)
pPsi - the rotation about z by anglepTheta - the rotation about y by anglepPhi - the rotation about x by angle| Method Detail |
public java.lang.Object clone()
PduElement
clone in class PduElementObjectpublic void serialize(java.io.DataOutputStream outputStream)
PduElementsuper.Serialize() to make sure
the superclasse's data is serialized out. The order
in which instance variables are serialized is significant. They must
be serialized in the same order they appear in the DIS
spec.
Prints out some information during execution if debugging flag is set.
serialize in interface SerializationInterfaceserialize in class PduElementoutputStream - the stream to which this object is serializedpublic void deSerialize(java.io.DataInputStream pInputStream)
PduElementsuper.deSerialize to make sure
the superclass's data are properly affected. The order
in which instance variables are serialized is significant. They must
be deSerialized in the same order as they have been serialized as specified by the DIS spec.
deSerialize in interface SerializationInterfacedeSerialize in class PduElementpInputStream - the stream from which this object is initializedpublic int length()
PduElement
length in class PduElement
public void printValues(int indentLevel,
java.io.PrintStream printStream)
PduElement
printValues in class PduElementindentLevel - number of spaces to indent for visibility
public void setValues(float pPsi,
float pTheta,
float pPhi)
public float getPsi()
public void setPsi(float pPsi)
public float getTheta()
public void setTheta(float pTheta)
public float getPhi()
public void setPhi(float pPhi)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||