# TBasicGenericData Class Reference
[Base Classes for plugins]

Inheritance diagram for TBasicGenericData:

List of all members.

## Public Member Functions
virtual MCErr MCCOMAPI | QueryInterface (const MCIID &riid, void **ppvObj)
virtual uint32 MCCOMAPI | AddRef ()
virtual int32 MCCOMAPI | Edit (I3DShScene *scene)
virtual TMCDynamicString &MCCOMAPI | GetName ()=0
virtual void MCCOMAPI | Clone (I3DExGenericData **clone)=0
virtual MCCOMErr MCCOMAPI | Read (IShTokenStream *stream, ReadAttributeProc readUnknown, void *privData)=0
virtual MCCOMErr MCCOMAPI | Write (IShTokenStream *stream)=0
virtual MCCOMErr MCCOMAPI | FinishRead (IStreamContext *streamContext)

## Detailed Description

Basic Generic Data class. Derive from this for a default implementation of I3DExGenericData

See also:
  I3DExGenericData7

## Member Function Documentation

virtual uint32 MCCOMAPI TBasicGenericData::AddRef | ( |  | ) | `[inline, virtual]`

Increments the reference count of the object

Reimplemented from TBasicDataExchanger.

virtual void MCCOMAPI TBasicGenericData::Clone | ( | I3DExGenericData ** | clone | ) | `[pure virtual]`

Creates a copy of the data.

Implements I3DExGenericData.

virtual int32 MCCOMAPI TBasicGenericData::Edit | ( | I3DShScene * | scene | ) | `[virtual]`

Edit a generic data. This is usually used to open a dialog so that the user can modify the date that are stored in the generic data.

Parameters:

  | scene | A pointer to the current scene.

Implements I3DExGenericData.

virtual MCCOMErr MCCOMAPI TBasicGenericData::FinishRead | ( | IStreamContext * | streamContext | ) | `[inline, virtual]`

This function is called after everything in the component has been read. It allows, for instance, postcomputation on the values that have been read.

Parameters:

  | streamContext | the context of the stream where the values have been read

Implements IExStreamIO.

virtual TMCDynamicString& MCCOMAPI TBasicGenericData::GetName | ( |  | ) | `[pure virtual]`

Returns the name of the object

Implements I3DExGenericData.

virtual MCErr MCCOMAPI TBasicGenericData::QueryInterface | ( | const MCIID & | riid,
|  | void ** | ppvObj |
| ) |  |  | `[virtual]`

Check if the object supports a given interface and returns a pointer to that interface if it does. Note that QueryInterface will increment the reference count of the object by one if the interface is found.

Parameters:

  | riid | GUID of the interface
  | ppvObj | A pointer to the pointer being returned.

Reimplemented from TBasicDataExchanger.

virtual MCCOMErr MCCOMAPI TBasicGenericData::Read | ( | IShTokenStream * | stream,
|  | ReadAttributeProc | readUnknown,
|  | void * | privData |
| ) |  |  | `[pure virtual]`

Read the extra data of a component from a stream. The data will be enclosed in a begin '{' token and an end '}' token. Even if no extra data is read, this function should at least read these two tokens.

Parameters:

  | stream | A token stream
  | readUnknown | A callback function to call when an unknown token is encountered.
  | privData | The private data that should be passed to the callback.

Implements IExStreamIO.

virtual MCCOMErr MCCOMAPI TBasicGenericData::Write | ( | IShTokenStream * | stream | ) | `[pure virtual]`

Writes extra data that are not stored in the parameter map of the component. Unlike Read (cf. above), this function should not write the enclosing tokens, but just the extra data.

Parameters:

  | stream | A tocken stream

Implements IExStreamIO.

The documentation for this class was generated from the following file:

- BasicGenericData.h