Data.Any, Data.Array, Data.Bool, Data.Byte, Data.Char, Data.Double, Data.Enum, Data.Float, Data.Int, Data.JSON, Data.Long, Data.MapData, Data.Nil, Data.Obj, Data.Short, Data.Str, Data.Structure, Data.Switch, Data.Union, Data.Url, Data.Void, Data.Xml
STATE_INVALID, STATE_MODIFIED, STATE_UNCHANGED
Constructor and Description |
---|
Array(ServiceDefinition.Data def)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
short |
addValue(java.lang.Object v)
Add the value of the element or the next index.
|
Data<?> |
clone() |
short |
copy(Data<?> data)
Copy the value of another Data.
|
java.util.List<java.lang.Object> |
copyValue()
Copy the current value and return it.
|
int |
countElements()
Return the number of elements in the array.
|
Type |
getElementsType()
Return the array elements type.
|
java.util.List<java.lang.Object> |
getValue()
Return the data value.
|
java.lang.Object |
getValue(int index)
Return the value for an index.
|
boolean |
getValueAsBoolean(int index)
Return the value for an index as a boolean.
|
char |
getValueAsChar(int index)
Return the value for an index as a char.
|
boolean |
getValueAsData(Data<?> data)
Apply the value on another data array.
|
Data<?> |
getValueAsData(int index)
Return the value of an element as a Data.
|
double |
getValueAsDouble(int index)
Return the value for an index as a double.
|
float |
getValueAsFloat(int index)
Return the value for an index as a float.
|
int |
getValueAsInt(int index)
Return the value for an index as an int.
|
java.util.List<java.lang.Object> |
getValueAsList()
Return the value as a List.
|
long |
getValueAsLong(int index)
Return the value for an index as a long.
|
short |
getValueAsShort(int index)
Return the value for an index as a short.
|
java.lang.String |
getValueAsString(int index)
Return the value for an index as a String.
|
boolean |
isEqualsTo(java.lang.Object o)
Return true if the current value of the data is equal to a current object value.
|
java.util.Iterator<Data<?>> |
iterator()
Return an iterator on each index on the array.
|
short |
popValue()
Pop the array value.
|
short |
pushValue(java.lang.Object v)
Push a value in the array.
|
short |
setArrayValue(java.util.List<java.lang.Object> value)
Set the array value.
|
void |
setArrayValue(java.lang.Object[] value)
Set the array value.
|
short |
setBooleanValue(boolean v,
int index)
Set the value of the element at a specified index.
|
short |
setCharValue(char v,
int index)
Set the value of the element at a specified index.
|
short |
setDoubleValue(float v,
int index)
Set the value of the element at a specified index.
|
short |
setFloatValue(float v,
int index)
Set the value of the element at a specified index.
|
short |
setIntValue(int v,
int index)
Set the value of the element at a specified index.
|
short |
setLongValue(long v,
int index)
Set the value of the element at a specified index.
|
short |
setShortValue(short v,
int index)
Set the value of the element at a specified index.
|
short |
setStringValue(java.lang.String v,
int index)
Set the value of the element at a specified index.
|
short |
setValue(java.lang.Object value)
Set the data value.
|
short |
setValue(java.lang.Object v,
int index)
Set the value of the element at a specified index.
|
copy, copy, getDataChangeBehavior, getDefinition, getDescription, getName, getTopic, getType, getValue, getValueAsArray, getValueAsBoolean, getValueAsByte, getValueAsChar, getValueAsDouble, getValueAsDouble, getValueAsFloat, getValueAsFloat, getValueAsInt, getValueAsJSON, getValueAsLong, getValueAsMap, getValueAsShort, getValueAsString, getValueAsStructure, getValueAsUnion, getValueAsURL, getValueAsXML, hasChanged, isContinuous, isNumeric, setBooleanValue, setByteValue, setChanged, setCharValue, setDoubleValue, setDoubleValue, setFloatValue, setFloatValue, setIntValue, setLongValue, setShortValue, setStringValue, setValueFromInstance, touch
public Array(ServiceDefinition.Data def)
def
- the ServiceDefinitionpublic short copy(Data<?> data)
public Type getElementsType()
public boolean isEqualsTo(java.lang.Object o)
isEqualsTo
in class Data<ArrayType>
o
- the specified object valuepublic void setArrayValue(java.lang.Object[] value)
value
- the valuepublic short setArrayValue(java.util.List<java.lang.Object> value)
value
- the valuepublic int countElements()
public short setValue(java.lang.Object value)
public short addValue(java.lang.Object v)
v
- the value for the elementDataState
public short setValue(java.lang.Object v, int index)
index
- the index in the arrayv
- the value for the element at the specific indexDataState
public short pushValue(java.lang.Object v)
v
- the value to pushpublic short popValue()
public boolean getValueAsBoolean(int index)
index
- the indexpublic int getValueAsInt(int index)
index
- the indexpublic short getValueAsShort(int index)
index
- the indexpublic long getValueAsLong(int index)
index
- the indexpublic float getValueAsFloat(int index)
index
- the indexpublic double getValueAsDouble(int index)
index
- the indexpublic char getValueAsChar(int index)
index
- the indexpublic java.lang.String getValueAsString(int index)
index
- the indexpublic java.lang.Object getValue(int index)
index
- the indexpublic short setIntValue(int v, int index)
index
- the index in the arrayv
- the value for the element at the specific indexDataState
public short setShortValue(short v, int index)
index
- the index in the arrayv
- the value for the element at the specific indexDataState
public short setLongValue(long v, int index)
index
- the index in the arrayv
- the value for the element at the specific indexDataState
public short setCharValue(char v, int index)
index
- the index in the arrayv
- the value for the element at the specific indexDataState
public short setFloatValue(float v, int index)
index
- the index in the arrayv
- the value for the element at the specific indexDataState
public short setDoubleValue(float v, int index)
index
- the index in the arrayv
- the value for the element at the specific indexDataState
public short setStringValue(java.lang.String v, int index)
index
- the index in the arrayv
- the value for the element at the specific indexDataState
public short setBooleanValue(boolean v, int index)
index
- the index in the arrayv
- the value for the element at the specific indexDataState
public java.util.List<java.lang.Object> getValueAsList()
public boolean getValueAsData(Data<?> data)
getValueAsData
in class Data<ArrayType>
data
- the data arraypublic Data<?> getValueAsData(int index)
index
- the indexpublic java.util.List<java.lang.Object> getValue()
public java.util.List<java.lang.Object> copyValue()
public Data<?> clone() throws java.lang.CloneNotSupportedException
Copyright ©2017-2023 Dassault Aviation. All Rights Reserved. Documentation and source under the LGPL v3 licence