Class mil.navy.nps.dis.LinearAcceleration
java.lang.Object
|
+----mil.navy.nps.dis.PduElement
|
+----mil.navy.nps.dis.LinearAcceleration
- public class LinearAcceleration
- extends PduElement
- Version:
- 1.0
- Author:
- Don McGregor (http://www.stl.nps.navy.mil/~mcgredo)
- Location:
-
http://www.stl.nps.navy.mil/dis-java-vrml/mil/navy/nps/dis/LinearAcceleration.java
- Hierarchy Diagram:
- Summary:
- Linerar Acceleration shall be represented as a vector with components in either World Coordinate System or Entities Coordinate System
depending on the value in the Dead Recoking Algorithm Field.Each vector component shall represent
acceleration in meters per second squared.
- Explanation
- Acceleration Describes the Acceleration of an object, in x, y, z 32 bit
floating point terms expressed in world's coordinate system or entit.
In fact DIS uses the vector record where an entity coordinate vector,
a linear acceleration or a linear velocity vector stands.
We have a particular class for each of those, we provides us with stronger typing, hence improves security.
- History:
- 07Mar97 /Don McGregor /New
- 16Apr97 /Don McGregor /PrintStream passed to printValues
- 12Aug97 /Don Brutzman /elaborated printValues
- 8Dec97 /Ronan Fauglas /changes for documentation templates + complements in documentation
- 11Dec97 /Ronan Fauglas /changes access methods names from "variable()" to "getVariable()"
- References:
- DIS Data Dictionary:
Linear Acceleration Vector Record
- DIS specification : IEEE 1278.1, Section 5.3.33.2
- See Also:
- PduElement, mil.navy.nps.util.SerializationInterface, EntityCoordinate, LinearVelocity
Field Summary
|
int
|
sizeOf
Constant value--size of a Linear Acceleration record when written out; here :sizeOf = 12 bytes .
|
float
|
x
First coordinate of acceleration along the X axis, in a cartesian coordinate system.
|
float
|
y
Second coordinate of acceleration along the Y axis, in a cartesian coordinate system.
|
float
|
z
Third coordinate of acceleration along the Z axis, in a cartesian coordinate system.
|
Constructor Summary
|
LinearAcceleration()
Constructs an new Acceleration Object, acceleration's value is 0.
|
LinearAcceleration(float pX,
float pY,
float pZ)
Constructs a new Acceleration object whose coordinate values are passed in parameters.
|
Methods inherited from class java.lang.Object
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
x
protected float x
- First coordinate of acceleration along the X axis, in a cartesian coordinate system.
- Value:
- In meters by second.
y
protected float y
- Second coordinate of acceleration along the Y axis, in a cartesian coordinate system.
- Value:
- In meters by second.
z
protected float z
- Third coordinate of acceleration along the Z axis, in a cartesian coordinate system.
- Value:
- In meters by second.
sizeOf
public final int sizeOf
- Constant value--size of a Linear Acceleration record when written out; here :
sizeOf = 12 bytes
.
LinearAcceleration
public LinearAcceleration()
- Constructs an new Acceleration Object, acceleration's value is 0.
LinearAcceleration
public LinearAcceleration(float pX,
float pY,
float pZ)
- Constructs a new Acceleration object whose coordinate values are passed in parameters.
- Parameters:
pX
- the first coordinate in the cartesian coordinate system
pY
- the second coordinate in the cartesian coordinate system
pZ
- the third coordinate in the cartesian coordinate system
clone
public java.lang.Object clone()
- Overrides:
- clone in class PduElement
serialize
public void serialize(java.io.DataOutputStream outputStream)
- Throws:
- java.lang.RuntimeException - when IO error occurs.
- Overrides:
- serialize in class PduElement
deSerialize
public void deSerialize(java.io.DataInputStream pInputStream)
- Throws:
- java.lang.RuntimeException - when IO error occurs.
- Overrides:
- deSerialize in class PduElement
length
public int length()
- Overrides:
- length in class PduElement
printValues
public void printValues(int indentLevel,
java.io.PrintStream printStream)
- Overrides:
- printValues in class PduElement
setValues
public void setValues(float pX,
float pY,
float pZ)
getX
public float getX()
setX
public void setX(float pX)
getY
public float getY()
setY
public void setY(float pY)
getZ
public float getZ()
setZ
public void setZ(float pZ)