algoanim.primitives
Class Arc

java.lang.Object
  extended by algoanim.primitives.Primitive
      extended by algoanim.primitives.Arc

public class Arc
extends Primitive

Represents an arc defined by a center, a radius and an angle.

Author:
Stephan Mehlhase

Field Summary
 
Fields inherited from class algoanim.primitives.Primitive
gen
 
Constructor Summary
Arc(ArcGenerator ag, Node aCenter, Node aRadius, java.lang.String name, DisplayOptions display, ArcProperties ep)
          Instantiates the Arc and calls the create() method of the associated ArcGenerator.
 
Method Summary
 Node getCenter()
          Returns the center of this Arc.
 ArcProperties getProperties()
          Returns the properties of this Arc.
 Node getRadius()
          Returns the radius of this Arc.
 void setName(java.lang.String newName)
          Sets the name of this Primitive.
 
Methods inherited from class algoanim.primitives.Primitive
changeColor, exchange, getDisplayOptions, getName, hide, hide, moveBy, moveTo, moveVia, rotate, rotate, show, show
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Arc

public Arc(ArcGenerator ag,
           Node aCenter,
           Node aRadius,
           java.lang.String name,
           DisplayOptions display,
           ArcProperties ep)
Instantiates the Arc and calls the create() method of the associated ArcGenerator.

Parameters:
ag - the appropriate code Generator.
aCenter - the center of this Arc.
aRadius - the radius of this Arc.
name - the name of this Arc.
display - [optional] the DisplayOptions for this Arc.
ep - [optional] the ArcProperties.
Method Detail

getCenter

public Node getCenter()
Returns the center of this Arc.

Returns:
the center of this Arc.

getProperties

public ArcProperties getProperties()
Returns the properties of this Arc.

Returns:
the properties of this Arc.

getRadius

public Node getRadius()
Returns the radius of this Arc.

Returns:
the radius of this Arc.

setName

public void setName(java.lang.String newName)
Description copied from class: Primitive
Sets the name of this Primitive.

Overrides:
setName in class Primitive
Parameters:
newName - the new name for this Primitive.
See Also:
Primitive.setName(java.lang.String)