#include <DoBaseI.h>
Public Member Functions | |
Virtuals | |
Interface members | |
virtual DynObjType *docall | doGetType (const DynI **pself=0) const |
virtual DynI *docall | GetByName (const char *name, int type_id) |
virtual DynI *docall | GetByIndex (int index, DynStr &ds, int type_id=0) |
virtual bool docall | Set (const char *name, DynI *pdi) |
virtual bool docall | Remove (DynI *pdi) |
Inlines | |
Inline convenience functions | |
DynI * | Get (const char *name) |
virtual DynObjType* docall NamedRefI::doGetType | ( | const DynI ** | pself = 0 |
) | const [virtual] |
Returns type of this object. Each type that wants to make itself known should override this method. DynI knows its own type so we get the type without any lookup. It is faster and works without registration.
pself | allows fetching the actual 'this' used inside doGetType (from a side base, this will be different to the 'this' of the caller). |
Reimplemented from DynI.
Reimplemented in DoRunTimeC.
virtual DynI* docall NamedRefI::GetByName | ( | const char * | name, | |
int | type_id | |||
) | [inline, virtual] |
Lookup a named object.
name | is the name which the object is known by | |
type_id | is the type of the object or 0 if don't care |
virtual DynI* docall NamedRefI::GetByIndex | ( | int | index, | |
DynStr & | ds, | |||
int | type_id = 0 | |||
) | [inline, virtual] |
Lookup a named object using index.
index | lookup the n:th object of this type | |
ds | store name of object here | |
type_id | is the type of the object or 0 if don't care |
virtual bool docall NamedRefI::Set | ( | const char * | name, | |
DynI * | pdi | |||
) | [inline, virtual] |
Store a named object. An implementation is free to return false if the object is not accepted (i.e. it does not implement NotifierI)
name | is the name by which the object can later be looked up | |
pdi | the object to be known with this name |
virtual bool docall NamedRefI::Remove | ( | DynI * | pdi | ) | [inline, virtual] |
Manually remove a named object.
pdi | the object to be removed |