java.lang.Object
org.jfree.svg.util.LinearGradientPaintKey
A wrapper for a
LinearGradientPaint
that can be used as the key
for a Map
(including a HashMap
). This class is
used internally by SVGGraphics2D
to track and re-use gradient
definitions. LinearGradientPaint
itself does not implement the
equals()
and hashCode()
methods, so it doesn't make a good
key for a Map
.- Since:
- 1.9
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
paint
-
-
Constructor Details
-
LinearGradientPaintKey
Creates a new instance.- Parameters:
lgp
- the linear gradient paint (null
not permitted).
-
-
Method Details
-
getPaint
Returns theLinearGradientPaint
that was supplied to the constructor.- Returns:
- The
LinearGradientPaint
(nevernull
).
-
equals
Tests this instance for equality with an arbitrary object. -
hashCode
public int hashCode()Returns a hash code for this instance.
-