23.12.2012 Views

MATLAB Function Reference Volume 1: A - E - Bad Request

MATLAB Function Reference Volume 1: A - E - Bad Request

MATLAB Function Reference Volume 1: A - E - Bad Request

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

2class<br />

Purpose Create object or return class of object<br />

Syntax str = class(object)<br />

obj = class(s,'class_name')<br />

obj = class(s,'class_name',parent1,parent2...)<br />

obj = class(struct([]),'class_name',parent1,parent2...)<br />

Description str = class(object) returns a string specifying the class of object.<br />

The following table lists the object class names that may be returned. All<br />

except the last one are <strong>MATLAB</strong> classes.<br />

cell Cell array<br />

char Characters array<br />

double Double-precision floating point number array<br />

function handle Array of values for calling functions indirectly<br />

int8 8-bit signed integer array<br />

int16 16-bit signed integer array<br />

int32 32-bit signed integer array<br />

sparse 2-D real (or complex) sparse array<br />

struct Structure array<br />

uint8 8-bit unsigned integer array<br />

uint16 16-bit unsigned integer array<br />

uint32 32-bit unsigned integer array<br />

'matlab_class_name' Name of user-defined <strong>MATLAB</strong> class<br />

'java_class_name' Name of Java class<br />

obj = class(s,'class_name') creates an object of <strong>MATLAB</strong> class<br />

'class_name' using structure s as a template. This syntax is valid only in a<br />

function named class_name.m in a directory named @class_name (where<br />

'class_name' is the same as the string passed into class).<br />

class<br />

2-261

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!