Difference between revisions of "CATable::Subscript"

(Created page with '<< class CATable = Subscript(indexObj, label) = Returns a slice of a table for which index «indexObj» is equal to «label». It returns a new CATable object w…')
 
Line 1: Line 1:
[[CATable|<< class CATable]]
+
[[Category:ADE User Guide]]
 
+
[[ADE User Guide]] > [[ADE Server Class Reference]] > [[CATable]]
 +
<languages />
 +
<translate>
 
= Subscript(indexObj, label) =
 
= Subscript(indexObj, label) =
  
Line 30: Line 32:
 
* [[CATable::Slice]]
 
* [[CATable::Slice]]
 
* [[CATable::AtomicValue]]
 
* [[CATable::AtomicValue]]
 +
</translate>

Revision as of 01:13, 16 June 2015

ADE User Guide > ADE Server Class Reference > CATable

Other languages:
English • ‎中文

Subscript(indexObj, label)

Returns a slice of a table for which index «indexObj» is equal to «label». It returns a new CATable object with one fewer dimension than the original table. When used on a DefTable, the sliced DefTable acts as a SubTable, changing elements in the slice of the original table.

Parameters

indexObj
CAObject
label
variant – the label in the index

Return value

CATable

Example Usage

CATable tab = obj.ResultTable;
CAIndex in1 = tab.GetIndexObject("In1");
CATable subTab = obj.Subscript(in1,"January")

Remarks

The use of CATable::Subscript(..) on a DefTable, acting as a SubTable, was introduced in 4.2.3.

When applied to a 1-D table, a 0-D table result, which is a non-array containing only one atomic value. At that point, the CATable::AtomicValue method is used to access the value.

See Also

Comments


You are not allowed to post comments.