org.odejava
Class JointGroup

java.lang.Object
  extended by org.odejava.JointGroup

public class JointGroup
extends Object

A joint group is a special container that holds joints in a world. Joints can be added to a group, and then when those joints are no longer needed the entire group of joints can be very quickly destroyed with one function call. However, individual joints in a group can not be destroyed before the entire group is emptied. This is most useful with contact joints, which are added and remove from the world in groups every time step. Created 20.12.2003 (dd.mm.yyyy)

Author:
Jani Laakso E-mail: jani.laakso@itmill.com see http://odejava.dev.java.net

Field Summary
protected  LinkedList<Joint> jointList
           
protected  HashMap<String,Joint> jointMap
           
 
Constructor Summary
JointGroup()
           
JointGroup(String name)
          Create jointGroup normally (id=0).
JointGroup(String name, int id)
          Create joint group in the given jointGroupId.
 
Method Summary
 void addJoint(Joint joint)
           
 void delete()
           
 void empty()
           
 org.odejava.ode.SWIGTYPE_p_dJointGroupID getId()
           
 Joint getJoint(String name)
          Get joint by name.
 LinkedList<Joint> getJointList()
           
 HashMap<String,Joint> getJointMap()
           
 String getName()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

jointList

protected LinkedList<Joint> jointList

jointMap

protected HashMap<String,Joint> jointMap
Constructor Detail

JointGroup

public JointGroup(String name,
                  int id)
Create joint group in the given jointGroupId. If you wish to create joint group normally, set id to 0.

Parameters:
name - name
id - the jointGroupId

JointGroup

public JointGroup(String name)
Create jointGroup normally (id=0).


JointGroup

public JointGroup()
Method Detail

getName

public final String getName()

addJoint

public void addJoint(Joint joint)

getId

public org.odejava.ode.SWIGTYPE_p_dJointGroupID getId()
Returns:
Returns the jointGroupId.

empty

public void empty()

getJointList

public LinkedList<Joint> getJointList()
Returns:
Returns the jointList.

getJointMap

public HashMap<String,Joint> getJointMap()
Returns:
Returns the jointMap.

getJoint

public Joint getJoint(String name)
Get joint by name.

Parameters:
name -
Returns:
joint

delete

public void delete()