![]() |
Leviathan
0.8.0.0
Leviathan game engine
|
BaseNotifiable for use in scripts. More...
#include <ScriptNotifiers.h>
Public Member Functions | |
DLLEXPORT | ScriptNotifiable (asIScriptFunction *functiontocall) |
virtual DLLEXPORT | ~ScriptNotifiable () |
![]() | |
BaseNotifiableAll () | |
~BaseNotifiableAll () | |
![]() | |
BaseNotifiable (BaseNotifiableAll *ourptr) | |
virtual | ~BaseNotifiable () |
void | ReleaseParentHooks (Lock &guard) |
Release function which releases all hooks. More... | |
bool | UnConnectFromNotifier (Lock &guard, BaseNotifier< BaseNotifierAll, BaseNotifiableAll > *specificnotifier, Lock ¬ifierlock) |
The actual implementation of UnConnectFromNotifier. More... | |
bool | UnConnectFromNotifier (Lock &guard, BaseNotifier< BaseNotifierAll, BaseNotifiableAll > *specificnotifier) |
FORCE_INLINE bool | UnConnectFromNotifier (BaseNotifier< BaseNotifierAll, BaseNotifiableAll > *specificnotifier) |
Disconnects this from a previously connected notifier. More... | |
bool | UnConnectFromNotifier (int id) |
This searches the connected notifiers and calls the above function with it's pointer. More... | |
virtual void | NotifyAll (Lock &guard) |
Notifies all the parents of this object about something. More... | |
bool | IsConnectedTo (BaseNotifier< BaseNotifierAll, BaseNotifiableAll > *check, Lock &guard) |
Actual implementation of this method. More... | |
FORCE_INLINE bool | IsConnectedTo (BaseNotifier< BaseNotifierAll, BaseNotifiableAll > *check) |
Returns true when the specified object is already connected. More... | |
bool | ConnectToNotifier (BaseNotifier< BaseNotifierAll, BaseNotifiableAll > *owner) |
Connects this to a notifier object calling all the needed functions. More... | |
bool | ConnectToNotifier (Lock &unlockable, BaseNotifier< BaseNotifierAll, BaseNotifiableAll > *owner) |
Variant for already locked objects. More... | |
void | _OnUnhookNotifier (Lock &locked, BaseNotifier< BaseNotifierAll, BaseNotifiableAll > *parent, Lock &parentlock) |
Callback called by the parent, used to not to call the unhook again on the parent. More... | |
void | _OnHookNotifier (Lock &locked, BaseNotifier< BaseNotifierAll, BaseNotifiableAll > *parent, Lock &parentlock) |
Called by parent to hook, and doesn't call the parent's functions. More... | |
BaseNotifiableAll * | GetActualPointerToNotifiableObject () |
Gets the internal pointer to the actual object. More... | |
![]() | |
DLLEXPORT | ThreadSafeGeneric () |
DLLEXPORT | ~ThreadSafeGeneric () |
FORCE_INLINE void | VerifyLock (RecursiveLock &guard) const |
FORCE_INLINE void | VerifyLock (Lock &lockit) const |
![]() | |
ReferenceCounted (const ReferenceCounted &other)=delete | |
ReferenceCounted & | operator= (const ReferenceCounted &other)=delete |
FORCE_INLINE void | AddRef () const |
FORCE_INLINE void | Release () const |
removes a reference and deletes the object if reference count reaches zero More... | |
FORCE_INLINE void | AddRef () |
FORCE_INLINE void | Release () |
int32_t | GetRefCount () const |
Returns the reference count. More... | |
Protected Member Functions | |
virtual void | OnNotified (Lock &ownlock, BaseNotifierAll *parent, Lock &parentlock) override |
Calls into the script engine. More... | |
![]() | |
virtual void | _OnNotifierConnected (Lock &guard, BaseNotifierAll *parentadded, Lock &parentlock) |
virtual void | _OnNotifierDisconnected (Lock &guard, BaseNotifierAll *parentremoved, Lock &parentlock) |
![]() | |
DLLEXPORT | ReferenceCounted () |
virtual DLLEXPORT | ~ReferenceCounted () |
Protected Attributes | |
asIScriptFunction * | CallbackFunction |
The function that is called when this is notified. More... | |
![]() | |
BaseNotifiableAll * | PointerToOurNotifiable |
Stores a pointer to the object that is inherited from this. More... | |
std::vector< BaseNotifier< BaseNotifierAll, BaseNotifiableAll > * > | ConnectedToParents |
Vector of other objects that this is connected to. More... | |
![]() | |
MutexType | ObjectsLock |
Additional Inherited Members | |
![]() | |
using | LockT = typename LockTypeResolver< MutexType >::LType |
![]() | |
using | basepointer = boost::intrusive_ptr< ReferenceCounted > |
using | refcountedpointer = boost::intrusive_ptr< ReferenceCounted > |
![]() | |
template<class ActualType > | |
static boost::intrusive_ptr< ActualType > | WrapPtr (ActualType *ptr) |
Creates an intrusive_ptr from raw pointer. More... | |
template<class ActualType , class... Args> | |
static boost::intrusive_ptr< ActualType > | MakeShared (Args &&... args) |
Constructs a new instance and wraps it. More... | |
BaseNotifiable for use in scripts.
Definition at line 36 of file ScriptNotifiers.h.
DLLEXPORT Leviathan::ScriptNotifiable::ScriptNotifiable | ( | asIScriptFunction * | functiontocall | ) |
Definition at line 42 of file ScriptNotifiers.cpp.
|
virtual |
Definition at line 48 of file ScriptNotifiers.cpp.
|
overrideprotectedvirtual |
Calls into the script engine.
Reimplemented from Leviathan::BaseNotifiable< BaseNotifierAll, BaseNotifiableAll >.
Definition at line 60 of file ScriptNotifiers.cpp.
|
protected |
The function that is called when this is notified.
Definition at line 51 of file ScriptNotifiers.h.