Package org.robwork.sdurwsim
Class KinematicBodyPtr
- java.lang.Object
-
- org.robwork.sdurwsim.KinematicBodyPtr
-
public class KinematicBodyPtr extends java.lang.Object
Ptr stores a pointer and optionally takes ownership of the value.
-
-
Constructor Summary
Constructors Constructor Description KinematicBodyPtr()
Default constructor yielding a NULL-pointer.KinematicBodyPtr(long cPtr, boolean cMemoryOwn)
KinematicBodyPtr(KinematicBody ptr)
Do not take ownership of ptr.
ptr can be null.
The constructor is implicit on purpose.
-
Method Summary
-
-
-
Constructor Detail
-
KinematicBodyPtr
public KinematicBodyPtr(long cPtr, boolean cMemoryOwn)
-
KinematicBodyPtr
public KinematicBodyPtr()
Default constructor yielding a NULL-pointer.
-
KinematicBodyPtr
public KinematicBodyPtr(KinematicBody ptr)
Do not take ownership of ptr.
ptr can be null.
The constructor is implicit on purpose.
-
-
Method Detail
-
getCPtr
public static long getCPtr(KinematicBodyPtr obj)
-
delete
public void delete()
-
deref
public KinematicBody deref()
The pointer stored in the object.
-
__ref__
public KinematicBody __ref__()
Dereferencing operator.
-
getDeref
public KinematicBody getDeref()
Member access operator.
-
equals
public boolean equals(KinematicBody p)
-
isShared
public boolean isShared()
check if this Ptr has shared ownership or none
ownership- Returns:
- true if Ptr has shared ownership, false if it has no ownership.
-
isNull
public boolean isNull()
checks if the pointer is null- Returns:
- Returns true if the pointer is null
-
getBodyFrame
public Frame getBodyFrame()
-
getFrames
public FrameVector getFrames()
-
getInfo
public BodyInfo getInfo()
-
getName
public java.lang.String getName()
-
getMaterialID
public java.lang.String getMaterialID()
-
getInertia
public InertiaMatrixd getInertia()
-
setMass
public void setMass(double m)
-
setMass
public void setMass(double m, InertiaMatrixd inertia)
-
setMass
public void setMass(double m, InertiaMatrixd inertia, Vector3D com)
-
reset
public void reset(State state)
-
calcEnergy
public double calcEnergy(State state)
-
getTransformW
public Transform3D getTransformW(State state)
-
pTbf
public Transform3D pTbf(State state)
-
pTcom
public Transform3D pTcom(State state)
-
wTbf
public Transform3D wTbf(State state)
-
wTcom
public Transform3D wTcom(State state)
-
place
public Transform3D place(CollisionDetectorPtr coldect, State state, Vector3D dir)
-
place
public Transform3D place(CollisionDetectorPtr coldect, State state)
-
-