Gray C++ Libraries  0.0.2
A set of C++ libraries for MSVC, GNU on Windows, WinCE, Linux
GrayLib::cScriptableInterfaceTemplate< TYPE > Class Template Reference

#include <cScriptableInterface.h>

Inheritance diagram for GrayLib::cScriptableInterfaceTemplate< TYPE >:
GrayLib::cScriptableInterfaceDef Gray::CObject

Public Member Functions

 cScriptableInterfaceTemplate (const TYPEINFO_t &TypeInfo, const ATOMCHAR_t *pszName, cScriptableProp *pProps, cScriptableMethod *pMethods, cScriptableInterfaceDef *pSubInterface, const ATOMCHAR_t *pszHelp)
 
virtual void InitScriptInterfaceDef ()
 things that cannot be done at static construct time. More...
 
void InitScriptInterfaceDef ()
 
- Public Member Functions inherited from GrayLib::cScriptableInterfaceDef
virtual cScriptableInterfaceDefPtr _stdcall get_ScriptInterfaceDef () const
 
 cScriptableInterfaceDef (const TYPEINFO_t &TypeInfo, const ATOMCHAR_t *pszName, cScriptableProp *pProps, cScriptableMethod *pMethods, cScriptableInterfaceDef *pSubInterface, const ATOMCHAR_t *pszHelp)
 
virtual ~cScriptableInterfaceDef ()
 
virtual bool isValidCheck () const noexcept
 < memory allocation and structure definitions are valid. More...
 
const ATOMCHAR_tget_Name () const noexcept
 
SCRIPTINTERFACEID_t get_InterfaceID () const noexcept
 
SCRIPTPROPID_t get_MethodQty () const noexcept
 
virtual cScriptableMethodGetMethodPtr (SCRIPTPROPID_t index) const noexcept
 
virtual SCRIPTPROPID_t GetMethodIndex (const cScriptableMethod *pMethod) const
 
SCRIPTPROPID_t FindMethodIndex (const ATOMCHAR_t *pszName) const
 
cScriptableMethodFindMethodPtrI (const ATOMCHAR_t *pszName) const
 
SCRIPTPROPID_t get_PropQty () const
 
virtual cScriptablePropGetPropPtr (SCRIPTPROPID_t index) const
 
virtual SCRIPTPROPID_t GetPropIndex (const cScriptableProp *pProp) const
 
SCRIPTPROPID_t FindPropIndex (const ATOMCHAR_t *pszName) const
 
cScriptablePropFindPropPtrI (const ATOMCHAR_t *pszName) const
 
bool SetMethodPrivLevel (const ATOMCHAR_t *pszMethod, PLEVEL_TYPE ePrivLevel)
 Adjust a privilege level for a method of this class. More...
 
bool IsInterfaceInit () const
 
HRESULT SerializeOutput (cStreamOutput &out, PLEVEL_TYPE ePrivLevel) const
 
void InitSubInterfaces ()
 Manage all my sub-interfaces. More...
 
bool HasSubInterface (const cScriptableInterfaceDef *pInterfaceDef) const
 
bool HasInterface (const cScriptableInterfaceDef *pInterfaceDef) const
 
void AddSubInterfaceProps (cScriptableInterfaceDef *pInterface)
 
void AddSubInterfaces (cScriptableInterfaceDef *pSubInterface)
 search All sub classes as well. More...
 
const cScriptableMethodFindMethodStr (const ATOMCHAR_t *pszName) const
 
const cScriptablePropFindPropStr (const ATOMCHAR_t *pszName) const
 
const cScriptablePropFindPropOrMethodStr (const ATOMCHAR_t *pszName) const
 
const cScriptableMethodFindMethodHash (ATOMCODE_t nKey) const
 Find by string hash code. (assume no collisions) More...
 
const cScriptablePropFindPropHash (ATOMCODE_t nKey) const
 
- Public Member Functions inherited from Gray::CObject
virtual ~CObject ()
 
virtual void AssertValid () const
 < memory allocation and structure definitions are valid. More...
 
virtual void Serialize (cArchive &a)
 

Additional Inherited Members

- Public Types inherited from GrayLib::cScriptableInterfaceDef
enum  P_TYPE_ { P_QTY }
 < if the InterfaceDef is itself an interface. More...
 
- Public Attributes inherited from GrayLib::cScriptableInterfaceDef
const TYPEINFO_tm_TypeInfo
 The C++ typeid(class type) this refers to. (we could derive m_pszName?) MUST HAVE RTTI on! More...
 
const ATOMCHAR_tm_pszName
 Interface Name. More...
 
cScriptableInterfaceDefm_pSubInterface
 primary sub class. (can actually be multi(m_aSubInterfacesAll) or none(nullptr)) More...
 
const char * m_pszHelp
 helpful description for human readers. More...
 
SCRIPTINTERFACEID_t m_nInterfaceID
 enum id to define the class. similar to XOBJTIDX_TYPE ? More...
 
cArraySortPtrName< const cScriptableProp, ATOMCHAR_tm_aPropsAll
 
cArraySortPtrName< const cScriptableMethod, ATOMCHAR_tm_aMethodsAll
 Complete list of all Methods. (includes sub class methods) More...
 
cArraySortPtrHash< const cScriptableProp, ATOMCODE_tm_aPropsAllHash
 We may search by hash code. More...
 
cArraySortPtrHash< const cScriptableMethod, ATOMCODE_tm_aMethodsAllHash
 
cArraySortVal< SCRIPTINTERFACEID_tm_aSubInterfacesAll
 List of interfaces I'm based on (Already added to m_aMethodsAll and m_aPropsAll. More...
 
UINT m_nInstances
 define get_ScriptInterfaceDef() More...
 
- Static Public Attributes inherited from GrayLib::cScriptableInterfaceDef
static cScriptableProp sm_Props [P_QTY+1]
 
static cScriptableInterfaceDef sm_ScriptInterfaceDef
 
- Protected Attributes inherited from GrayLib::cScriptableInterfaceDef
bool m_bInitInterface
 has this been synchronized with the base classes. More...
 
SCRIPTPROPID_t m_iPropQty
 get_PropQty() More...
 
SCRIPTPROPID_t m_iMethodQty
 get_MethodQty() More...
 

Detailed Description

template<class TYPE>
class GrayLib::cScriptableInterfaceTemplate< TYPE >

This class needs a special complex version to init it's multiple interfaces. It has multiple base IScriptableObj(s) and therefore cScriptableInterfaceDef(s)

Constructor & Destructor Documentation

◆ cScriptableInterfaceTemplate()

template<class TYPE >
GrayLib::cScriptableInterfaceTemplate< TYPE >::cScriptableInterfaceTemplate ( const TYPEINFO_t TypeInfo,
const ATOMCHAR_t pszName,
cScriptableProp pProps,
cScriptableMethod pMethods,
cScriptableInterfaceDef pSubInterface,
const ATOMCHAR_t pszHelp 
)
inline

Member Function Documentation

◆ InitScriptInterfaceDef() [1/2]

template<class TYPE >
virtual void GrayLib::cScriptableInterfaceTemplate< TYPE >::InitScriptInterfaceDef ( )
virtual

things that cannot be done at static construct time.

Reimplemented from GrayLib::cScriptableInterfaceDef.

◆ InitScriptInterfaceDef() [2/2]

void GrayLib::cScriptableInterfaceTemplate< cScriptContextObj >::InitScriptInterfaceDef ( )
virtual

things that cannot be done at static construct time. Such as attaching multiple base classes etc.

Add props and methods to the class def.

Just init the simple class.

Note
This is overridden by interfaces that have multiple sub interfaces.

Reimplemented from GrayLib::cScriptableInterfaceDef.


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