@Immutable public class EnumTypedef extends CDMNode
annotations, dodsname, group, immutable, parentstruct, shortName, sort| Constructor and Description |
|---|
EnumTypedef(java.lang.String name,
java.util.Map<java.lang.Integer,java.lang.String> map)
Make an EnumTypedef with base type ENUM4.
|
EnumTypedef(java.lang.String name,
java.util.Map<java.lang.Integer,java.lang.String> map,
DataType basetype)
Make an EnumTypedef setting the base type (must be ENUM1, ENUM2, ENUM4).
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object o) |
boolean |
equalsMapOnly(java.lang.Object o) |
DataType |
getBaseType()
One of DataType.ENUM1, DataType.ENUM2, or DataType.ENUM4.
|
com.google.common.collect.ImmutableList<java.lang.String> |
getEnumStrings()
Deprecated.
use getMap()
|
com.google.common.collect.ImmutableMap<java.lang.Integer,java.lang.String> |
getMap() |
int |
hashCode() |
java.lang.Integer |
lookupEnumInt(java.lang.String name)
Get the enum value corresponding to the name.
|
java.lang.String |
lookupEnumString(int e)
Get the name corresponding to the enum value.
|
java.lang.String |
toString() |
java.lang.String |
writeCDL(boolean strict)
Deprecated.
use CDLWriter
|
protected void |
writeCDL(java.util.Formatter out,
Indent indent,
boolean strict)
Deprecated.
use CDLWriter
|
annotate, annotation, getDODSName, getFullName, getFullNameEscaped, getGroup, getImmutable, getName, getParentGroup, getParentStructure, getShortName, getSort, isMemberOfStructure, localhash, setDODSName, setImmutable, setParentGroup, setParentStructure, setShortName, setSort, unwrappublic EnumTypedef(java.lang.String name,
java.util.Map<java.lang.Integer,java.lang.String> map)
public EnumTypedef(java.lang.String name,
java.util.Map<java.lang.Integer,java.lang.String> map,
DataType basetype)
@Deprecated public com.google.common.collect.ImmutableList<java.lang.String> getEnumStrings()
public com.google.common.collect.ImmutableMap<java.lang.Integer,java.lang.String> getMap()
public DataType getBaseType()
@Nullable public java.lang.String lookupEnumString(int e)
@Nullable public java.lang.Integer lookupEnumInt(java.lang.String name)
@Deprecated public java.lang.String writeCDL(boolean strict)
strict - if true, write in strict adherence to CDL definition.@Deprecated
protected void writeCDL(java.util.Formatter out,
Indent indent,
boolean strict)
public boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic boolean equalsMapOnly(java.lang.Object o)
public int hashCode()
hashCode in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Object