IBM Visualization Data Explorer Programmer's Reference

[ Bottom of Page | Previous Page | Next Page | Table of Contents | Partial Table of Contents | Index ]

DXTypeCheck, DXTypeCheckV

Function

Check that an Array meets a set of specifications.

Syntax

#include <dx/dx.h>


Array DXTypeCheck(Array a, Type type, Category category, int rank, ...)
Array DXTypeCheckV(Array a, Type type, Category category, int rank, int *shape)

Functional Details

The routine returns a if that Array meets the specifications given by type, category, rank, and shape. Otherwise, it returns NULL. The shape is specified by shape for DXTypeCheckV or by the last rank arguments for DXTypeCheck. For DXTypeCheckV, if shape is NULL, the type, category, and rank are checked, but the shape is not.

rank specifies the rank of the items in the Array: Scalars have rank 0, vectors have rank 1, and so on.

shape has rank entries representing the list of dimensions of the structure. For rank 0 items (scalars) there is no shape. For rank 1 items (vectors) the shape is a single number corresponding to the number of dimensions. For rank 2 structures, the shape is two (2) numbers, and so on. shape specifies the rank of the items in the Array: the number of dimensions in each item of the Array. Shape has entries where each entry represents the size of the item in that dimension.

The type is one of the following:


TYPE_BYTE            TYPE_HYPER        TYPE_SHORT
TYPE_UBYTE           TYPE_INT          TYPE_USHORT
TYPE_DOUBLE          TYPE_UINT         TYPE_STRING
TYPE_FLOAT

The category is either CATEGORY_REAL or CATEGORY_COMPLEX.

Return Value

Return a or returns NULL (e.g., if the type does not match).

See Also

DXGetArrayInfo

12.3 , "Array Class".


[ Top of Page | Previous Page | Next Page | Table of Contents | Partial Table of Contents | Index ]
[Data Explorer Documentation | QuickStart Guide | User's Guide | User's Reference | Programmer's Reference | Installation and Configuration Guide ]

[Data Explorer Home Page]


[IBM Home Page | Order | Search | Contact IBM | Legal ]