CATable
ADE User Guide > ADE Server Class Reference >
ADE's CATable class provides the equivalent of an intelligent array. It is used to wrap an edit table, allowing your program to change cell values, or a result array, allowing you to access individual cells, slices, or even a graph image of the result.
A CATable for a result is most often obtained from a call to CAObject::ResultTable. The CAObject::Evaluate method also returns a CATable, used when you want to evaluate an arbitrary expression.
A CATable for an edit table is obtained from CAObject::DefTable.
Properties
{get,put} int GraphHeight
The height of the graph image, in pixels, generated by GraphToStream or GraphToFile.
{get,put} int GraphWidth
The width of the graph image, in pixels, generated by GraphToStream or GraphToFile.
{get,put} bool GraphWithStoredPivot
When set to true, the slicer state and table pivot saved with the model is used by GraphToStream and GraphToFile, producing the same graph as seen in Analytica. When false, your code is responsible for slicing out the slice of interest and for specifying the table pivot.
{get} variant IndexNames
Returns an array with the names of the indexes in SetIndexOrder.
{get,put} string Name
Sets and returns the name of the table object.
{get} CAIndex NthColumnIndex(n)
The nth column index in the table when it is viewed by Analytica.
{get} CAIndex NthRowIndex(n)
The nth row index in the table when it is viewed by Analytica.
{get} int NumColumnIndexes
The number of column indexes in the table when it is viewed in desktop Analytica.
{get} short NumDims
Returns the number of dimensions of the table.
{get} int NumRowIndexes
The number of row indexes in the table when it is viewed in desktop Analytica.
{get,put} CARenderingStyle RenderingStyle
Settings controlling out atomic values are passed.
{get,put} short ResultType
Sets and returns the result type for a result table. 0=mid, 1=mean, 2=sample, 3=PDF, 4=CDF, 5=Stats, 6=Bands.
{get,put} string TableType
Sets and returns the table type: v=result table, d=input table. For internal use only.
Methods
variant AtomicValue()
If the CATable is zero-dimensional (not an array), returns the atomic value.
variant GetDataByElements(variant IndexPtrs)
Returns the value of the specified cell in the specified input or result table. Cell is specified with integer pointers into each of the tables' indexes.
variant GetDataByLabels( variant IndexLabs )
Returns the value of the specified cell in the specified input or result table. Cell is specifed by index labels.
CAIndex GetIndexObject( string indexName )
Gets Index Object by it's name.
array GetSafeArray()
Retrieves the CATable as a SafeArray.
CAGraphPivot GraphPivot()
New to ADE 5.0
Returns a CAGraphPivot with information about the current pivot state and method for changing the pivot.
bool GraphToFile( string filename, string mimeType )
Saves a graph image of the result for the current object to a file.
bool GraphToStream( IStream stream, string mimeType )
Writes a graph image of the result for the current object to a stream.
string IndexName( short indexNum )
Returns the name of an object's specified index.
bool ObtainTable()
Refreshes table data.
bool PutSafeArray( variant theVal )
Replaces the CATable with the passed in value.
bool SetDataByElements( variant Element, variant IndexPtrs )
Sets the value of a cell in an input table. Cell located specified with pointers.
bool SetDataByLabels( variant ElementValue, variant indexLabels )
Sets the value of a cell in an input table. Cell located specified with labels.
bool SetIndexOrder( array(string) IndexArray )
Sets the index order for functions of CATable.
CATable Slice( CAIndex index, int n )
Returns a CATable result of the nth slice along index.
CATable Subscript( CAIndex index, variant label )
Returns a CATable result with the slice corresponding to the indicated label along index.
bool Update()
This method updates definitions of definition tables and requeries the engine for result tables. Must be called to cause changes made to a definition table to be placed in the model itself.
See Also
CAObject <- | CATable | -> CAIndex |
Enable comment auto-refresher