- Main Page
- Classes
- Files
- Directories

- Class List
- Class Hierarchy
- Class Members

Public Member Functions | Static Public Member Functions

# FbxEvent< T > Class Template Reference

Search for all occurrences

## Detailed Description

### template<typename T>
class FbxEvent< T >

FBX event class, derived from FbxEventBase, and it contains a type ID for event.

It's a template class. You can derive your own types of even. Such as:

     class FbxEventCustom : public FbxEvent<FbxEventCustom>

See also:
  FbxObjectPropertyChanged FbxEventReferencedDocument FbxEventPostExport
  FbxEventPostImport FbxEventPreExport FbxEventPreImport FbxEventPopulateSystemLibrary

Remarks:
  A FBX event is something that is emitted by an emitter, with the goal of being filled by the listener that listen to it. An object(emitter) can emit a certain type of event, the plug-in(listener) who are listening to that type of event, will receive a signal and take action to process the event data.

The whole process of event is:
  - 1. Create an emitter and a listener, then bind them together via the same event handler.
  - 2. Emitter can emit an event at certain conditions. The event could be handled by event handler.
  - 3. Once an event is emitted, the listener to this event will receive a signal.
  - 4. And then the listener could process the event data according to the types of event, by calling event handler.

Note:
  The event data is process by the callback function of event handler.

See also:
  FbxEventBase FbxEventHandler FbxListener FbxEmitter

Definition at line 134 of file fbxevent.h.

`#include <fbxevent.h>`

Inheritance diagram for FbxEvent< T >:
[legend]

List of all members.

## Public Member Functions
virtual | ~FbxEvent ()
| Destructor.
virtual int | GetTypeId () const
| Retrieve the event type ID.
## Static Public Member Functions
static void | ForceTypeId (int pTypeId)
| Update the type ID of current event with the given type ID.
static int | GetStaticTypeId ()
| Retrieve the event type ID.

## Constructor & Destructor Documentation

virtual ~FbxEvent | ( |  | ) | `[inline, virtual]`

Destructor.

Definition at line 138 of file fbxevent.h.

    {}

## Member Function Documentation

static void ForceTypeId | ( | int | pTypeId | ) | `[inline, static]`

Search for all occurrences

Update the type ID of current event with the given type ID.

Parameters:

  pTypeId | the new type ID.

Definition at line 143 of file fbxevent.h.

        {
            // This is to handle specific cases where the type ID must be hard coded
            // It is useful for shared event across DLL. We can then guarantee that
            // The ID of a certain type will always have the same ID
            smTypeId = pTypeId;
        }

virtual int GetTypeId | ( |  | ) | const`[inline, virtual]`

Search for all occurrences

Retrieve the event type ID.

Note:
  This may be called from multiple threads.

Returns:
  type id

Implements FbxEventBase.

Definition at line 155 of file fbxevent.h.

        {
            return GetStaticTypeId();
        }

static int GetStaticTypeId | ( |  | ) | `[inline, static]`

Search for all occurrences

Retrieve the event type ID.

Returns:
  type id

Definition at line 163 of file fbxevent.h.

        {
            if( !smTypeId )
            {
                if( !smTypeId )
                {
                    // If this does not compile, you need to add
                    // FBXSDK_EVENT_DECLARE(YourEventClassName) to your class declaration
                    smTypeId  = FbxEventBase::GetStaticTypeId(T::FbxEventName());
                }
            }

           return smTypeId;
        }

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

- fbxsdk/core/fbxevent.h