public class Structure extends Variable
| Modifier and Type | Class and Description |
|---|---|
static class |
Structure.Field
Represent a structure field.
|
| Modifier and Type | Field and Description |
|---|---|
protected java.util.Set<Structure.Field> |
fields |
name, struct, type, valueblock, rootSTRUCT_ARRAY, STRUCT_SCALAR, STRUCT_STRUCTURE, TYPE_BOOL, TYPE_DYNAMIC, TYPE_FLOAT, TYPE_INTEGER, TYPE_NUMERIC, TYPE_STRING, TYPE_UNDEF| Constructor and Description |
|---|
Structure(java.lang.String name)
Constructor.
|
Structure(java.lang.String name,
short type)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addField(Structure.Field field)
Add a field for this structure.
|
java.lang.Object |
clone() |
java.lang.String |
getExpressionName()
Return the structure name.
|
java.util.Set<Structure.Field> |
getFields()
Return the structure fields.
|
short |
getResultStructure()
Return the structure of the result for the expression.
|
short |
getResultType()
Return the type of the Variable.
|
void |
setValue(java.lang.String varName,
java.lang.Object value)
Do nothing.
|
equals, getVariable, getVariables, hashCode, isLocalcheckType, eval, evalAsBoolean, evalAsFloat, evalAsInt, getExpression, getName, getStructure, getType, getValue, getValueAsBoolean, getValueAsFloat, getValueAsInt, initType, setDefaultValue, setName, setStructure, setType, setType, setValue, setValueAsBoolean, setValueAsFloat, setValueAsIntgetParentBlock, getRoot, setParentBlock, setRootfinalize, getClass, notify, notifyAll, toString, wait, wait, waitgetLocalVariable, getLocalVariables, getParentBlock, getRoot, getVariable, getVariables, hasVariable, hasVariable, removeVariable, setParentBlockprotected java.util.Set<Structure.Field> fields
public Structure(java.lang.String name)
name - the structure namepublic Structure(java.lang.String name,
short type)
name - the structure nametype - the structure typepublic java.lang.Object clone()
throws java.lang.CloneNotSupportedException
clone in interface Expressionclone in class Variablejava.lang.CloneNotSupportedExceptionpublic void addField(Structure.Field field)
field - the fieldpublic java.util.Set<Structure.Field> getFields()
public java.lang.String getExpressionName()
getExpressionName in interface ExpressiongetExpressionName in class Variablepublic short getResultType()
VariablegetResultType in interface ExpressiongetResultType in class Variablepublic short getResultStructure()
ExpressionExpressionType.STRUCT_SCALAR: a scalar valueExpressionType.STRUCT_ARRAY: an array valuegetResultStructure in interface ExpressiongetResultStructure in class VariableCopyright © 2018 Herve Girod. All Rights Reserved. Documentation and source under the BSD licence