Class AppDataChunk

3DS Max Plug-In SDK

Class AppDataChunk

See Also: Class Animatable, Class Class_ID.

class AppDataChunk

Description:

This class represents an individual AppData chunk. All methods of this class are implemented by the system.

Data Members:

public:

Class_ID classID;

The Class_ID of the owner of this chunk.

SClass_ID superClassID;

The SuperClassID of the owner of this chunk.

DWORD subID;

An extra ID that lets the owner identify its sub chunks.

DWORD length;

The length of the data in bytes.

void *data;

The chunk data itself.

Methods:

Prototype:

AppDataChunk(Class_ID cid, SClass_ID sid, DWORD sbid, DWORD len, void *d);

Remarks:

Constructor. The data members are initialized to the values passed. Note that the data pointer should be allocated with standard malloc() since it will be freed using free() in the destructor.

Parameters:

Class_ID cid

The Class_ID of the owner of this chunk.

SClass_ID sid

The SuperClassID of the owner of this chunk.

DWORD sbid

An extra ID that lets the owner identify its sub chunks.

DWORD len

The length of the data in bytes.

void *d

The chunk data itself.

Prototype:

AppDataChunk();

Remarks:

Constructor. The length is set to 0 and the data pointer set to NULL.

Prototype:

~AppDataChunk()

Remarks:

Destructor. The AppData is freed using free(data). Since this is how the data is freed, the plug-in must use malloc() to allocate the memory.

Prototype:

IOResult Load(ILoad *iload);

Remarks:

The system implements this method to load the AppDataChunk from disk.

Prototype:

IOResult Save(ISave *isave);

Remarks:

The system implements this method to save the AppDataChunk to disk.