org.graffiti.graphics
Class Dash

java.lang.Object
  extended by org.graffiti.graphics.Dash

public class Dash
extends Object

Class that encapsulates the information needed to specify stroke properties.

Version:
$Revision: 5768 $
Author:
schoeffl

Constructor Summary
Dash()
          Constructs a new Dash.
Dash(float[] da, float dp)
          Constructs a new Dash.
 
Method Summary
 boolean equals(Object that)
          Checks if that Dash is equal to this Dash.
 float[] getDashArray()
          Returns the dashArray.
 float getDashPhase()
          Returns the dashPhase.
 int hashCode()
          Returns a hash code for this Dash object.
 void setDashArray(float[] da)
          Sets the dashArray to the given array.
 void setDashPhase(float dp)
          Sets the dashPhase to the given value.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Dash

public Dash()
Constructs a new Dash. Initializes the dashArray with null and the dashPhase with 0.0.


Dash

public Dash(float[] da,
            float dp)
Constructs a new Dash. Sets the dashArray and the dashPhase to the given values.

Parameters:
da - the array to set the dashArray to.
dp - the value to set the dashPhase to.
Method Detail

setDashArray

public void setDashArray(float[] da)
Sets the dashArray to the given array.

Parameters:
da - the array to set the dashArray to.

getDashArray

public float[] getDashArray()
Returns the dashArray.

Returns:
the dashArray.

setDashPhase

public void setDashPhase(float dp)
Sets the dashPhase to the given value.

Parameters:
dp - the new value for the dashPhase.

getDashPhase

public float getDashPhase()
Returns the dashPhase.

Returns:
the dashPhase.

equals

public boolean equals(Object that)
Checks if that Dash is equal to this Dash.

Overrides:
equals in class Object
Parameters:
that - the Dash this will be compared to
Returns:
true, if the dashes (i.e. their dashPhase and their dashArray) are equal, false, if not

hashCode

public int hashCode()
Returns a hash code for this Dash object.

Overrides:
hashCode in class Object
Returns:
a hash code value for this object.


Generated at 2012-05-30 11:00:36 PM CEST