net.phys2d.raw
Class StaticBody

java.lang.Object
  extended bynet.phys2d.raw.Body
      extended bynet.phys2d.raw.StaticBody

public class StaticBody
extends Body

A body that will not move


Field Summary
 
Fields inherited from class net.phys2d.raw.Body
INFINITE_MASS
 
Constructor Summary
StaticBody(Shape shape)
          Create a static body
StaticBody(java.lang.String name, Shape shape)
          Create a static body
 
Method Summary
 boolean isMoveable()
          Check if this body can move
 boolean isResting()
          Check if this body has been detected as resting and hence is considered static.
 boolean isRotatable()
          Check if this body can rotate.
 boolean isStatic()
          Check if this body is static
 
Methods inherited from class net.phys2d.raw.Body
addBit, added, addExcludedBody, addForce, adjustAngularVelocity, adjustBiasedAngularVelocity, adjustBiasedVelocity, adjustPosition, adjustPosition, adjustRotation, adjustVelocity, canRest, collided, disabled, endFrame, equals, getAngularVelocity, getAngularVelocityDelta, getBiasedAngularVelocity, getBiasedVelocity, getBitmask, getConnected, getConnected, getDamping, getEnergy, getExcludedList, getForce, getFriction, getGravityEffected, getI, getID, getLastAngularVelocity, getLastPosition, getLastVelocity, getMass, getPosition, getPositionDelta, getRestitution, getRotation, getRotDamping, getShape, getTorque, getTouching, getUserData, getVelocity, getVelocityDelta, hashCode, isTouchingStatic, move, removeBit, removeExcludedBody, resetBias, set, setAdded, setBitmask, setCanRest, setDamping, setEnabled, setForce, setFriction, setGravityEffected, setIsResting, setMaxVelocity, setMoveable, setPosition, setRestitution, setRotatable, setRotation, setRotDamping, setShape, setTorque, setUserData, toString, validateVelocity
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

StaticBody

public StaticBody(Shape shape)
Create a static body

Parameters:
shape - The shape representing this body

StaticBody

public StaticBody(java.lang.String name,
                  Shape shape)
Create a static body

Parameters:
name - The name to assign to the body
shape - The shape representing this body
Method Detail

isRotatable

public boolean isRotatable()
Description copied from class: Body
Check if this body can rotate.

Overrides:
isRotatable in class Body
Returns:
True if this body can rotate
See Also:
Body.isRotatable()

isMoveable

public boolean isMoveable()
Description copied from class: Body
Check if this body can move

Overrides:
isMoveable in class Body
Returns:
True if this body can move
See Also:
Body.isMoveable()

isStatic

public boolean isStatic()
Check if this body is static

Overrides:
isStatic in class Body
Returns:
True if this body is static

isResting

public boolean isResting()
Description copied from class: Body
Check if this body has been detected as resting and hence is considered static.

Overrides:
isResting in class Body
Returns:
True if the body is considered static since it's resting
See Also:
Body.isResting()