Instance.PropertyArray

Description

Utility functions to operate on PropertyArray types of Concepts.

Note - In the Instance.PropertyArray functions, you will see references to "concepts". In the context of ActiveMatrix Decisions, concepts are equivalent to BOM types.

Functions

NameSignature and Synopsis
appendBooleanvoid appendBoolean (PropertyArrayBoolean arr, boolean value, long time)
Creates a new propertyAtomBoolean and appends it to the end of the PropertyArray. Or by doing instanceX.arr[instanceX.arr@length] = value, the engine uses system current time.
appendContainedConceptvoid appendContainedConcept (PropertyArrayContainedConcept arr, ContainedConcept instance, long time)
Creates a new PropertyAtomContainedConcept set to instance and adds it to the end of the PropertyArray arr. Or by doing instanceX.arr[instanceX.arr@length] = instance, the engine uses system current time.
appendDateTimevoid appendDateTime (PropertyArrayDateTime arr, DateTime value, long time)
Creates a new propertyAtomDateTime of value and appends it to the end of the PropertyArray. Or by doing instanceX.arr[instanceX.arr@length] = value, the engine uses system current time.
appendDoublevoid appendDouble (PropertyArrayDouble arr, double value, long time)
Creates a new propertyAtomDouble of value and appends it to the end of the PropertyArray. Or by doing instanceX.arr[instanceX.arr@length] = value, the engine uses system current time.
appendIntvoid appendInt (PropertyArrayInt arr, int value, long time)
Creates a new propertyAtomInt of value and appends it to the end of the PropertyArray. Or by doing instanceX.arr[instanceX.arr@length] = value, the engine uses system current time.
appendLongvoid appendLong (PropertyArrayLong arr, long value, long time)
Creates a new propertyAtomLong of value and appends it to the end of the PropertyArray. Or by doing instanceX.arr[instanceX.arr@length] = value, the engine uses system current time.
appendStringvoid appendString (PropertyArrayString arr, String value, long time)
Creates a new propertyAtomString of value and appends it to the end of the PropertyArray. Or by doing instanceX.arr[instanceX.arr@length] = value, the engine uses system current time.
clearvoid clear (PropertyArray arr)
Removes all elements from arr.
deletevoid delete (PropertyArray arr, int index)
Deletes the array element in arr located at index and shifts any subsequent elements to the left (subtracts one from their indices)
indexOfBooleanint indexOfBoolean(PropertyArrayBoolean arr, boolean value)
Returns the index in the PropertyArrayBoolean of the first occurrence of the specified boolean value, or -1 if the PropertyArrayBoolean does not contain this boolean value.
indexOfContainedConceptint indexOfContainedConcept(PropertyArrayContainedConcept arr, ContainedConcept instance)
Returns the index in the PropertyArrayContainedConcept of the first occurrence of the specified ContainedConcept instance, or -1 if the PropertyArrayContainedConcept does not contain this ContainedConcept instance.
indexOfDateTimeint indexOfDateTime(PropertyArrayDateTime arr, DateTime value)
Returns the index in the PropertyArrayDateTime of the first occurrence of the specified DateTime value, or -1 if the PropertyArrayDateTime does not contain this DateTime value.
indexOfDoubleint indexOfDouble(PropertyArrayDouble arr, double value)
Returns the index in the PropertyArrayDouble of the first occurrence of the specified double value, or -1 if the PropertyArrayDouble does not contain this double value.
indexOfIntint indexOfInt(PropertyArrayInt arr, int value)
Returns the index in the PropertyArrayInt of the first occurrence of the specified int value, or -1 if the PropertyArrayInt does not contain this int value.
indexOfLongint indexOfLong(PropertyArrayLong arr, long value)
Returns the index in the PropertyArrayLong of the first occurrence of the specified long value, or -1 if the PropertyArrayLong does not contain this long value.
indexOfStringint indexOfString(PropertyArrayString arr, String value)
Returns the index in the PropertyArrayString of the first occurrence of the specified String value, or -1 if the PropertyArrayString does not contain this String value.
removeBooleanboolean removeBoolean (PropertyArrayBoolean arr, boolean value)
Removes the first occurrence of PropertyAtomBoolean for which the current value equals to value from a PropertyArrayBoolean. It returns true and shifts all the subsequent array elements PropertyAtomBoolean to the left (substracts one to their indices) if the PropertyAtomBoolean is found, false otherwise.
removeContainedConceptboolean removeContainedConcept (PropertyArrayContainedConcept arr, ContainedConcept instance)
Removes the first occurrence of PropertyAtomContainedConcept for which the current value is set to instance from a PropertyArrayContainedConcept. It returns true and shifts all the subsequent array elements PropertyAtomContainedConcept to the left (substracts one to their indices) if the PropertyAtomContainedConcept is found, false otherwise.
removeDateTimeboolean removeDateTime (PropertyArrayDateTime arr, DateTime value)
Removes the first occurrence of PropertyAtomDateTime for which the current value equals to value from a PropertyArrayDateTime. It returns true and shifts all the subsequent array elements PropertyAtomDateTime to the left (substracts one to their indices) if no PropertyAtomDateTime is found, false otherwise.
removeDoubleboolean removeDouble (PropertyArrayDouble arr, double value)
Removes the first occurrence of PropertyAtomDouble for which the current value equals to value from a PropertyArrayDouble. It returns true and shifts all the subsequent array elements PropertyAtomDouble to the left (substracts one to their indices) if the PropertyAtomDouble is found, false otherwise.
removeIntboolean removeInt (PropertyArrayInt arr, int value)
Removes the first occurrence of PropertyAtomInt for which the current value equals to value from a PropertyArrayInt. It returns true and shifts all the subsequent array elements PropertyAtomInt to the left (substracts one to their indices) if the PropertyAtomInt is found, false otherwise.
removeLongboolean removeLong (PropertyArrayLong arr, long value)
Removes the first occurrence of PropertyAtomLong for which the current value equals to value from a PropertyArrayLong. It returns true and shifts all the subsequent array elements PropertyAtomLong to the left (substracts one to their indices) if the PropertyAtomLong is found, false otherwise.
removeStringboolean removeString (PropertyArrayString arr, String value)
Removes the first occurrence of PropertyAtomString for which the current value equals to value from a PropertyArrayString. It returns true and shifts all the subsequent array elements PropertyAtomString to the left (substracts one to their indices) if the PropertyAtomString is found, false otherwise.
toArrayBooleanboolean[] toArrayBoolean(PropertyArrayBoolean arr)
Returns a boolean[] containing all of the boolean values in a PropertyArrayBoolean in the correct order
toArrayConceptConcept[] toArrayConcept(PropertyArrayConcept arr)
Returns a Concept[] containing all of the instances in a PropertyArrayConcept in the correct order
toArrayContainedConceptContainedConcept[] toArrayContainedConcept(PropertyArrayContainedConcept arr)
Returns a ContainedConcept[] containing all of the instances in a PropertyArrayContainedConcept in the correct order
toArrayDateTimeDateTime[] toArrayDateTime(PropertyArrayDateTime arr)
Returns a DateTime[] containing all of the DateTime values in a PropertyArrayDateTime in the correct order
toArrayDoubledouble[] toArrayDouble(PropertyArray arr)
Returns a double[] containing all of the double values in a PropertyArray in the correct order.
toArrayIntint[] toArrayInt(PropertyArray arr)
Returns a int[] containing all of the int values in a PropertyArray in the correct order
toArrayLonglong[] toArrayLong(PropertyArray arr)
Returns a long[] containing all of the long values in a PropertyArray in the correct order
toArrayStringString[] toArrayString(PropertyArray arr)
Returns a String[] containing all of the String values in a PropertyArray in the correct order