edu.byu.phun.body
Class Arm

java.lang.Object
  extended by edu.byu.phun.PropertyContainer
      extended by edu.byu.phun.Obj3D
          extended by edu.byu.phun.GroupObj
              extended by edu.byu.phun.body.BodyPart
                  extended by edu.byu.phun.body.Arm

public class Arm
extends BodyPart

This defines an arm for the male body. This class controls the elbow and provides access to the foreArm, which controls the rest of the arm.


Field Summary
 ForeArm foreArm
          This provides access to all of the arm from the forearm down including the wrist and hand.
 
Constructor Summary
Arm()
          Creates a new arm object with the origin at the shoulder.
 
Method Summary
 double getElbowFlex()
          Returns the flex of the elbow.
 Color getShirtColor()
          Returns the current color of the shirt.
 Color getSkinColor()
          Returns the color of the skin
 void setElbowFlex(double degrees)
          This sets the number of degrees that the elbow should be flexed.
 void setShirtColor(Color color)
          This changes the color of the sleeve.
 void setSkinColor(Color color)
          This changes the color of the skin.
 
Methods inherited from class edu.byu.phun.GroupObj
addPart, getPart, getPart, nParts, partNames, removePart, removePart, setColor, setPart
 
Methods inherited from class edu.byu.phun.Obj3D
getBounds, getColor, getLocation, getName, getRotX, getRotY, getRotZ, getScaleX, getScaleY, getScaleZ, getShininess, setColor, setLocation, setLocation, setName, setRotX, setRotY, setRotZ, setScale, setScale, setScaleX, setScaleY, setScaleZ, setShininess, toString
 
Methods inherited from class edu.byu.phun.PropertyContainer
getPropertyC, getPropertyD, getPropertyP, getPropertyS, propertyIsColor, propertyIsDouble, propertyIsPoint, propertyIsSettable, propertyIsString, propertyNames, setProperty, setProperty
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

foreArm

public ForeArm foreArm
This provides access to all of the arm from the forearm down including the wrist and hand.

Constructor Detail

Arm

public Arm()
Creates a new arm object with the origin at the shoulder.

Method Detail

setShirtColor

public void setShirtColor(Color color)
This changes the color of the sleeve. It is generally called by the MaleBody rather than being called directly.

Parameters:
color - the new color of the sleeve.

getShirtColor

public Color getShirtColor()
Returns the current color of the shirt.

Returns:
the shirt color.

setSkinColor

public void setSkinColor(Color color)
This changes the color of the skin. It is generally called by the MaleBody rather than being called directly.

Parameters:
color - new skin color.

getSkinColor

public Color getSkinColor()
Returns the color of the skin

Returns:
skin color.

setElbowFlex

public void setElbowFlex(double degrees)
This sets the number of degrees that the elbow should be flexed.

Parameters:
degrees - the flex angle of the elbow. Zero degrees will have the arm straight. 180 degrees will bring the hand up to the shoulder.

getElbowFlex

public double getElbowFlex()
Returns the flex of the elbow.

Returns:
the degrees of elbow flex.
See Also:
setElbowFlex(double)