simtools.shapes
Class StrokeParameters

java.lang.Object
  extended by simtools.shapes.StrokeParameters
All Implemented Interfaces:
java.io.Serializable

public class StrokeParameters
extends java.lang.Object
implements java.io.Serializable

Class StrokeParameters Summary: This class is the data model to build and handle easily strokes and more particularly java.awt.Stroke objects

See Also:
Serialized Form

Field Summary
 float param1
           
 float param2
           
 float thickness
           
 
Constructor Summary
StrokeParameters()
           
StrokeParameters(float param1, float param2)
           
StrokeParameters(float param1, float param2, float thickness)
           
StrokeParameters(StrokeParameters d)
           
 
Method Summary
 java.awt.Stroke createStroke()
           
static java.awt.Stroke createStroke(float f1, float f2)
          A hook to fill this Abstract2D shape
static java.awt.Stroke createStroke(float f1, float f2, float width)
          A hook to fill this Abstract2D shape
 boolean equals(java.lang.Object obj)
           
 boolean equalsIgnoreThickness(java.lang.Object obj)
           
 void setThickness(float thickness)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

param1

public float param1

param2

public float param2

thickness

public float thickness
Constructor Detail

StrokeParameters

public StrokeParameters()

StrokeParameters

public StrokeParameters(float param1,
                        float param2)

StrokeParameters

public StrokeParameters(float param1,
                        float param2,
                        float thickness)

StrokeParameters

public StrokeParameters(StrokeParameters d)
Method Detail

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object

equalsIgnoreThickness

public boolean equalsIgnoreThickness(java.lang.Object obj)

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

setThickness

public void setThickness(float thickness)

createStroke

public java.awt.Stroke createStroke()

createStroke

public static java.awt.Stroke createStroke(float f1,
                                           float f2)
A hook to fill this Abstract2D shape

Parameters:
f1 - : the param1 for the creation of a stroke
f2 - : the param2 for the creation of a stroke
Returns:
java.awt.Stroke : the stroke created, if parameters are corrupted return a not dashed stroke

createStroke

public static java.awt.Stroke createStroke(float f1,
                                           float f2,
                                           float width)
A hook to fill this Abstract2D shape

Parameters:
f1 - : the param1 for the creation of a stroke
f2 - : the param2 for the creation of a stroke
width - : the width for the creation of a stroke
Returns:
java.awt.Stroke : the stroke created, if parameters are corrupted return a not dashed stroke