Enum GradientColorStop.OffsetType
- java.lang.Object
-
- java.lang.Enum<GradientColorStop.OffsetType>
-
- com.itextpdf.kernel.colors.gradients.GradientColorStop.OffsetType
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<GradientColorStop.OffsetType>
- Enclosing class:
- GradientColorStop
public static enum GradientColorStop.OffsetType extends java.lang.Enum<GradientColorStop.OffsetType>
Represents the possible offset type
-
-
Constructor Summary
Constructors Modifier Constructor Description private
OffsetType()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static GradientColorStop.OffsetType
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static GradientColorStop.OffsetType[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
ABSOLUTE
public static final GradientColorStop.OffsetType ABSOLUTE
The absolute offset value from the target coordinates vector's start
-
AUTO
public static final GradientColorStop.OffsetType AUTO
The automatic offset evaluation. The offset value should be evaluated automatically based on the whole stop colors list specified for the gradient. The general auto offset logic should be the next: - find the previous and the next specified offset or hint offset values - the sublist of sequent auto offsets should spread evenly between the found values
-
RELATIVE
public static final GradientColorStop.OffsetType RELATIVE
The relative offset value to the target coordinates vector. The0
value means the target vector start, the1
value means the target vector end.
-
-
Method Detail
-
values
public static GradientColorStop.OffsetType[] 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 (GradientColorStop.OffsetType c : GradientColorStop.OffsetType.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static GradientColorStop.OffsetType valueOf(java.lang.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:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
-