public class enumobj extends contentbase
Represents an enum instance. As noted in the serialization spec, this consists of merely the class description (represented by a classdesc) and the string corresponding to the enum's value. No other fields are ever serialized.
Modifier and Type | Field and Description |
---|---|
classdesc |
classdesc
The enum's class description.
|
stringobj |
value
The string that represents the enum's value.
|
handle, isExceptionObject, type
Constructor and Description |
---|
enumobj(int handle,
classdesc cd,
stringobj so)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
toJson(java.lang.String indetation,
java.util.Map<classdesc,java.util.Map<field,java.lang.Object>> fielddata,
boolean child)
Analogy for toString method; however, outputs its string in json formatting.
|
java.lang.String |
toString() |
getHandle, getType, isExceptionObject, setIsExceptionObject, validate
public classdesc classdesc
public stringobj value
public java.lang.String toJson(java.lang.String indetation, java.util.Map<classdesc,java.util.Map<field,java.lang.Object>> fielddata, boolean child)
content
Analogy for toString method; however, outputs its string in json formatting. Returns the exact json representation of object with indentation.
Inherited by multiple classes via contentbase, often calls itself for another object
toJson
in interface content
toJson
in class contentbase
indetation
- starting indentation for json outputfielddata
- used when calling this method for inner instances
so the instance has info about its variables.
Instance info is saved in another content space than
info about its field variables, so it must be provided by parameter
to inner instanceschild
- tells that the instance is child of another because of indentationpublic java.lang.String toString()
toString
in class java.lang.Object