Enum Constant and Description |
---|
PERCENTAGE
Unit code representing in percentage of the containing element
defined by terminal.
|
PIXELS
Unit code representing pixels.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getSymbol() |
static SizeUnit |
getUnitFromSymbol(java.lang.String symbol) |
java.lang.String |
toString() |
static SizeUnit |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static SizeUnit[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final SizeUnit PIXELS
public static final SizeUnit PERCENTAGE
public static SizeUnit[] values()
for (SizeUnit c : SizeUnit.values()) System.out.println(c);
public static SizeUnit valueOf(java.lang.String name)
name
- the name of the enum constant to be returned.java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is nullpublic java.lang.String getSymbol()
public java.lang.String toString()
toString
in class java.lang.Enum<SizeUnit>
public static SizeUnit getUnitFromSymbol(java.lang.String symbol)