public class FreeTypeMgr extends TypeMgr
Constructor and Description |
---|
FreeTypeMgr()
Create a type map.
|
Modifier and Type | Method and Description |
---|---|
int |
add(java.lang.String name)
Add a type to the type map.
|
void |
clear()
Clear the type map (remove all types).
|
int |
getCode(java.lang.String name)
Map a type name to the corresponding type code.
|
java.lang.String |
getName(int code)
Map a type code to the corresponding type name.
|
boolean |
isFixed()
Check whether a type manager is fixed (is not extendable).
|
int |
size()
Get the current number of types.
|
getBase, isSpecial, isWildcard
public FreeTypeMgr()
public boolean isFixed()
public void clear()
public int size()
public int add(java.lang.String name)
If the name is already present, no new mapping is added, but the code already associated with the name is returned, thus automatically avoiding duplicate entries.
add
in class TypeMgr
name
- the name of the typeTypeMgr.isFixed()
public int getCode(java.lang.String name)