java.io.Serializable
, java.lang.Cloneable
, GradientPaintTransformer
, PublicCloneable
public class StandardGradientPaintTransformer extends java.lang.Object implements GradientPaintTransformer, java.lang.Cloneable, PublicCloneable, java.io.Serializable
GradientPaint
to range over the width of a target
shape.Constructor | Description |
---|---|
StandardGradientPaintTransformer() |
Creates a new transformer.
|
StandardGradientPaintTransformer(GradientPaintTransformType type) |
Creates a new transformer.
|
Modifier and Type | Method | Description |
---|---|---|
java.lang.Object |
clone() |
Returns a clone of the transformer.
|
boolean |
equals(java.lang.Object obj) |
Tests this instance for equality with an arbitrary object.
|
int |
hashCode() |
Returns a hash code for this object.
|
java.awt.GradientPaint |
transform(java.awt.GradientPaint paint,
java.awt.Shape target) |
Transforms a
GradientPaint instance. |
public StandardGradientPaintTransformer()
public StandardGradientPaintTransformer(GradientPaintTransformType type)
type
- the transform type.public java.awt.GradientPaint transform(java.awt.GradientPaint paint, java.awt.Shape target)
GradientPaint
instance.transform
in interface GradientPaintTransformer
paint
- the original paint.target
- the target shape.public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
obj
- the object to test against (null
permitted).public java.lang.Object clone() throws java.lang.CloneNotSupportedException
clone
in interface PublicCloneable
clone
in class java.lang.Object
java.lang.CloneNotSupportedException
- not thrown by this class, but
subclasses (if any) might.public int hashCode()
hashCode
in class java.lang.Object