Class PropertyTreeScriptWrapper.ArrayWrapper
java.lang.Object
org.python.core.PyObject
org.python.core.PySequence
com.inductiveautomation.ignition.common.script.abc.AbstractJythonSequence
com.inductiveautomation.ignition.common.script.abc.AbstractMutableJythonSequence
com.inductiveautomation.perspective.gateway.script.PropertyTreeScriptWrapper.ArrayWrapper
- All Implemented Interfaces:
JythonSequence
,MutableJythonSequence
,Serializable
- Enclosing class:
- PropertyTreeScriptWrapper
Special array that writes back to the underling property tree
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.python.core.PySequence
org.python.core.PySequence.DefaultIndexDelegate
Nested classes/interfaces inherited from class org.python.core.PyObject
org.python.core.PyObject.ConversionException
-
Field Summary
Fields inherited from class org.python.core.PySequence
delegator
Fields inherited from class org.python.core.PyObject
attributes, gcMonitorGlobal, objtype, TYPE
-
Method Summary
Modifier and TypeMethodDescriptionorg.python.core.PyObject
__add__
(org.python.core.PyObject other) Override to allow adding another sequence to this one, using the bare+
operator.int
__len__()
void
append
(org.python.core.PyObject element) Addselement
to the end of the sequence.org.python.core.PyInteger
count
(org.python.core.PyObject element) Return occurrences ofelement
in sequence.protected void
del
(int index) void
extend
(org.python.core.PyObject sequence) Adds all elements fromsequence
to the end of the sequence.int
index
(org.python.core.PyObject element) Returns the position of the first occurrence ofelement
in the sequence.void
insert
(int index, org.python.core.PyObject element) Addselement
to sequence at positionindex
.org.python.core.PyObject
pop
(int index) Pops the element atindex
off the sequence and returns it.protected org.python.core.PyObject
pyget
(int index) protected void
pyset
(int i, org.python.core.PyObject value) void
remove
(org.python.core.PyObject element) Removeselement
from the sequence, if it exists.protected org.python.core.PyObject
repeat
(int count) Implements the repeat operation, which is used by Jython when performingsequence * count
, which returns a new list containing sequence * count items.protected List<? extends org.python.core.PyObject>
sublist
(int start, int stop) Retrieve a subset of this sequence, fromstart
(inclusive) tostop
(exclusive).Methods inherited from class com.inductiveautomation.ignition.common.script.abc.AbstractMutableJythonSequence
__imul__, delslice, pop, setslice, sort
Methods inherited from class com.inductiveautomation.ignition.common.script.abc.AbstractJythonSequence
__mul__, __repr__, __rmul__, __str__, getslice, isMappingType, isNumberType, isSequenceType, toString
Methods inherited from class org.python.core.PySequence
__delitem__, __delslice__, __eq__, __finditem__, __finditem__, __ge__, __getitem__, __getslice__, __gt__, __iter__, __le__, __lt__, __ne__, __nonzero__, __setitem__, __setitem__, __setslice__, __tojava__, boundToSequence, cmp, delRange, fastSequence, isSubType, runsupportedopMessage, sliceLength, unsupportedopMessage
Methods inherited from class org.python.core.PyObject
__abs__, __and__, __call__, __call__, __call__, __call__, __call__, __call__, __call__, __call__, __call__, __call__, __call__, __call__, __call__, __call__, __call__, __call__, __cmp__, __coerce__, __coerce_ex__, __complex__, __contains__, __delattr__, __delattr__, __delete__, __delitem__, __delslice__, __dir__, __div__, __divmod__, __ensure_finalizer__, __findattr__, __findattr__, __findattr_ex__, __finditem__, __float__, __floordiv__, __format__, __get__, __getattr__, __getattr__, __getitem__, __getnewargs__, __getslice__, __hash__, __hex__, __iadd__, __iand__, __idiv__, __idivmod__, __ifloordiv__, __ilshift__, __imod__, __index__, __int__, __invert__, __ior__, __ipow__, __irshift__, __isub__, __iternext__, __itruediv__, __ixor__, __long__, __lshift__, __mod__, __neg__, __not__, __oct__, __or__, __pos__, __pow__, __pow__, __radd__, __rand__, __rawdir__, __rdiv__, __rdivmod__, __reduce__, __reduce_ex__, __reduce_ex__, __rfloordiv__, __rlshift__, __rmod__, __ror__, __rpow__, __rrshift__, __rshift__, __rsub__, __rtruediv__, __rxor__, __set__, __setattr__, __setattr__, __setitem__, __setslice__, __sub__, __truediv__, __trunc__, __unicode__, __xor__, _add, _and, _callextra, _cmp, _div, _divmod, _doget, _doget, _doset, _eq, _floordiv, _ge, _gt, _iadd, _iand, _idiv, _idivmod, _ifloordiv, _ilshift, _imod, _imul, _in, _ior, _ipow, _irshift, _is, _isnot, _isub, _itruediv, _ixor, _jcall, _jcallexc, _jthrow, _le, _lshift, _lt, _mod, _mul, _ne, _notin, _or, _pow, _rshift, _sub, _truediv, _unsupportedop, _xor, adaptToCoerceTuple, asDouble, asIndex, asIndex, asInt, asInt, asIterable, asLong, asLong, asName, asName, asString, asString, asStringOrNull, asStringOrNull, bit_length, conjugate, delDict, delType, dispatch__init__, equals, fastGetClass, fastGetDict, finalize, getDict, getJavaProxy, getType, hashCode, impAttr, implementsDescrDelete, implementsDescrGet, implementsDescrSet, invoke, invoke, invoke, invoke, invoke, invoke, isCallable, isDataDescr, isIndex, isInteger, mergeClassDict, mergeDictAttr, mergeListAttr, noAttributeError, object___subclasshook__, readonlyAttributeError, setDict, setType
Methods inherited from interface com.inductiveautomation.ignition.common.script.abc.JythonSequence
__contains__, __iter__, __mul__, __repr__, __rmul__
-
Method Details
-
pyget
protected org.python.core.PyObject pyget(int index) - Specified by:
pyget
in classAbstractJythonSequence
-
__len__
public int __len__()- Specified by:
__len__
in interfaceJythonSequence
- Overrides:
__len__
in classorg.python.core.PyObject
- Returns:
- the length of this mapping.
-
index
public int index(org.python.core.PyObject element) Description copied from interface:JythonSequence
Returns the position of the first occurrence ofelement
in the sequence. -
count
public org.python.core.PyInteger count(org.python.core.PyObject element) Description copied from interface:JythonSequence
Return occurrences ofelement
in sequence. -
repeat
protected org.python.core.PyObject repeat(int count) Description copied from class:AbstractJythonSequence
Implements the repeat operation, which is used by Jython when performingsequence * count
, which returns a new list containing sequence * count items. If count is <= 0, returns an empty sequence, ideally of the same type.- Specified by:
repeat
in classAbstractJythonSequence
- Parameters:
count
- The number of times to repeat the sequence in the output.
-
__add__
public org.python.core.PyObject __add__(org.python.core.PyObject other) Description copied from interface:MutableJythonSequence
Override to allow adding another sequence to this one, using the bare+
operator. Should return this sequence, with the additional elements fromother
added to the end.- Specified by:
__add__
in interfaceMutableJythonSequence
- Specified by:
__add__
in classAbstractJythonSequence
- Returns:
- the result of the mul, or
null
if this operation is not defined
-
pyset
protected void pyset(int i, org.python.core.PyObject value) - Specified by:
pyset
in classAbstractMutableJythonSequence
-
del
protected void del(int index) - Overrides:
del
in classorg.python.core.PySequence
-
append
public void append(org.python.core.PyObject element) Description copied from interface:MutableJythonSequence
Addselement
to the end of the sequence.- Specified by:
append
in interfaceMutableJythonSequence
- Specified by:
append
in classAbstractMutableJythonSequence
-
extend
public void extend(org.python.core.PyObject sequence) Description copied from interface:MutableJythonSequence
Adds all elements fromsequence
to the end of the sequence.- Specified by:
extend
in interfaceMutableJythonSequence
- Specified by:
extend
in classAbstractMutableJythonSequence
-
remove
public void remove(org.python.core.PyObject element) throws org.python.core.PyException Description copied from interface:MutableJythonSequence
Removeselement
from the sequence, if it exists.- Specified by:
remove
in interfaceMutableJythonSequence
- Specified by:
remove
in classAbstractMutableJythonSequence
- Throws:
org.python.core.PyException
-Py.ValueError
if the element is not in the sequence.
-
pop
public org.python.core.PyObject pop(int index) throws org.python.core.PyException Description copied from interface:MutableJythonSequence
Pops the element atindex
off the sequence and returns it. Should support negative values forindex
, to indicate offset from the end of the sequence.- Specified by:
pop
in interfaceMutableJythonSequence
- Specified by:
pop
in classAbstractMutableJythonSequence
- Throws:
org.python.core.PyException
-Py.IndexError
if the index is not in range.
-
insert
public void insert(int index, org.python.core.PyObject element) Description copied from interface:MutableJythonSequence
Addselement
to sequence at positionindex
.- Specified by:
insert
in interfaceMutableJythonSequence
- Specified by:
insert
in classAbstractMutableJythonSequence
-
sublist
Description copied from class:AbstractJythonSequence
Retrieve a subset of this sequence, fromstart
(inclusive) tostop
(exclusive).- Specified by:
sublist
in classAbstractJythonSequence
- See Also:
-