MATLAB Application Program Interface
  Go to function:
    Search    Help Desk 
mxIsClass    Examples   See Also

True if mxArray is a member of the specified class

C Syntax

Arguments

array_ptr
  Pointer to an array.

name
  The array category that you are testing. Specify name as a string (not as an enumerated constant). You can specify any one of the following predefined constants:

Value of Name
Corresponding Class
"double"
mxDOUBLE_CLASS
"sparse"
mxSPARSE_CLASS
"char"
mxCHAR_CLASS
"cell"
mxCELL_CLASS
"struct"
mxSTRUCT_CLASS
"single"
mxSINGLE_CLASS
"int8"
mxINT8_CLASS
"uint8"
mxUINT8_CLASS
"int16"
mxINT16_CLASS
"uint16"
mxUINT16_CLASS
"int32"
mxINT32_CLASS
"uint32"
mxUINT32_CLASS
<class_name>
    where class_name is the name of a specific MATLAB or custom object.
mxOBJECT_CLASS
"unknown"
mxUNKNOWN_CLASS

Or, you can specify one of your own class names.

For example,

is equivalent to calling

which is equivalent to calling

Note that it is most efficient to use the mxIsDouble form.

Returns

true if array_ptr points to an array having category name; otherwise, returns false.

Description

Each mxArray is tagged as being a certain type. Call mxIsClass to determine if the specified mxArray has this type.

Example

See mxisclass.c in the mx subdirectory of the examples directory.

See Also

mxIsEmpty, mxGetClassID, mxClassID



[ Previous | Help Desk | Next ]