Class MEvent
Encapsulates information about a single Mono (managed) event belonging to some managed class. This object also allows you to invoke this event or register other methods to it.
Inheritance
Assembly: FlaxEngine.dll
File: Engine/Scripting/ManagedCLR/MEvent.h
Syntax
public class MEvent
Constructors
MEvent(MClass* parentClass, void* handle, const char* name)
Declaration
public MEvent(MClass* parentClass, void* handle, const char* name)
Parameters
MClass
parentClass
|
void
handle
|
char
name
|
Fields
_addMethod
_attributes
Declaration
protected Array<MObject* > _attributes
Field Value
Array<MObject >
|
_handle
Declaration
protected void* _handle
Field Value
void
|
_hasAddMonoMethod
Declaration
protected int32 _hasAddMonoMethod
Field Value
int32
|
_hasCachedAttributes
Declaration
protected int32 _hasCachedAttributes
Field Value
int32
|
_hasRemoveMonoMethod
Declaration
protected int32 _hasRemoveMonoMethod
Field Value
int32
|
_name
_parentClass
_removeMethod
Methods
GetAddMethod()
GetAttribute(const MClass* klass)
Returns an instance of an attribute of the specified type. Returns null if the event doesn't have such an attribute.
Declaration
public MObject* GetAttribute(const MClass* klass) const
Parameters
MClass
klass
The attribute class to take. |
Returns
MObject
The attribute object. |
GetAttributes()
Returns an instance of all attributes connected with given event. Returns null if the event doesn't have any attributes.
Declaration
public Array<MObject* > GetAttributes() const
Returns
Array<MObject >
The array of attribute objects. |
GetName()
GetParentClass()
Returns the parent class that this method is contained with.
Declaration
public MClass* GetParentClass() const
Returns
MClass
|
GetRemoveMethod()
GetType()
Gets the event type class.
Declaration
public MType* GetType() const
Returns
MType
|
GetVisibility()
Gets event visibility in the class.
Declaration
public MVisibility GetVisibility() const
Returns
MVisibility
|
HasAttribute()
Checks if event has an attribute of any type.
Declaration
public bool HasAttribute() const
Returns
bool
True if has any custom attribute, otherwise false. |
HasAttribute(const MClass* klass)
Checks if event has an attribute of the specified type.
Declaration
public bool HasAttribute(const MClass* klass) const
Parameters
MClass
klass
The attribute class to check. |
Returns
bool
True if has attribute of that class type, otherwise false. |
IsStatic()
Returns true if event is static.
Declaration
public bool IsStatic() const
Returns
bool
|