Enum GradientType
- java.lang.Object
-
- java.lang.Enum<GradientType>
-
- org.pepstock.charba.client.colors.GradientType
-
- All Implemented Interfaces:
Serializable
,Comparable<GradientType>
,Key
public enum GradientType extends Enum<GradientType> implements Key
A gradient must have a type.
The possible types are:
- LINEAR
- RADIAL
- Author:
- Andrea "Stock" Stocchero
-
-
Enum Constant Summary
Enum Constants Enum Constant Description LINEAR
Creates an image consisting of a progressive transition between two or more colors along a straight line.
Here is the definition.RADIAL
Creates an image consisting of a progressive transition between two or more colors that radiate from an origin.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getCssStatement()
Returns the CSS statement which represents the gradient type.String
value()
Returns the name value of propertystatic GradientType
valueOf(String name)
Returns the enum constant of this type with the specified name.static GradientType[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
LINEAR
public static final GradientType LINEAR
Creates an image consisting of a progressive transition between two or more colors along a straight line.
Here is the definition.
-
RADIAL
public static final GradientType RADIAL
Creates an image consisting of a progressive transition between two or more colors that radiate from an origin. Its shape may be a circle or an ellipse.
Here is the definition.
-
-
Method Detail
-
values
public static GradientType[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (GradientType c : GradientType.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static GradientType valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
value
public String value()
Description copied from interface:Key
Returns the name value of property
-
getCssStatement
public String getCssStatement()
Returns the CSS statement which represents the gradient type.- Returns:
- the CSS statement which represents the gradient type
-
-