Package com.android.ddmlib.log
Enum EventValueDescription.ValueType
- java.lang.Object
-
- java.lang.Enum<EventValueDescription.ValueType>
-
- com.android.ddmlib.log.EventValueDescription.ValueType
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<EventValueDescription.ValueType>
- Enclosing class:
- EventValueDescription
public static enum EventValueDescription.ValueType extends java.lang.Enum<EventValueDescription.ValueType>
Represents the type of a numerical value. This is used to display values of vastly different type/range in graphs.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description ALLOCATIONS
BYTES
ID
MILLISECONDS
NOT_APPLICABLE
OBJECTS
PERCENT
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
checkType(EventContainer.EventValueType type)
Checks that theEventContainer.EventValueType
is compatible with theEventValueDescription.ValueType
.int
getValue()
Returns the integer value of the enum.static EventValueDescription.ValueType
getValueType(int value)
Returns aEventValueDescription.ValueType
from an integer value, ornull
if no match were found.java.lang.String
toString()
static EventValueDescription.ValueType
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static EventValueDescription.ValueType[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
NOT_APPLICABLE
public static final EventValueDescription.ValueType NOT_APPLICABLE
-
OBJECTS
public static final EventValueDescription.ValueType OBJECTS
-
BYTES
public static final EventValueDescription.ValueType BYTES
-
MILLISECONDS
public static final EventValueDescription.ValueType MILLISECONDS
-
ALLOCATIONS
public static final EventValueDescription.ValueType ALLOCATIONS
-
ID
public static final EventValueDescription.ValueType ID
-
PERCENT
public static final EventValueDescription.ValueType PERCENT
-
-
Method Detail
-
values
public static EventValueDescription.ValueType[] 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 (EventValueDescription.ValueType c : EventValueDescription.ValueType.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static EventValueDescription.ValueType 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
-
checkType
public void checkType(EventContainer.EventValueType type) throws InvalidValueTypeException
Checks that theEventContainer.EventValueType
is compatible with theEventValueDescription.ValueType
.- Parameters:
type
- theEventContainer.EventValueType
to check.- Throws:
InvalidValueTypeException
- if the types are not compatible.
-
getValueType
public static EventValueDescription.ValueType getValueType(int value)
Returns aEventValueDescription.ValueType
from an integer value, ornull
if no match were found.- Parameters:
value
- the integer value.
-
getValue
public int getValue()
Returns the integer value of the enum.
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Enum<EventValueDescription.ValueType>
-
-