iObjectRegistry Struct Reference
[Shared Class Facility (SCF)]
This interface serves as a registry of other objects.
More...
#include <objreg.h>
Inheritance diagram for iObjectRegistry:

Public Methods | |
virtual void | Clear ()=0 |
Clear the object registry and release all references. | |
virtual bool | Register (iBase *, char const *tag=0)=0 |
Register an object with this registry. | |
virtual void | Unregister (iBase *, char const *tag=0)=0 |
Unregister an object with this registry. | |
virtual iBase * | Get (char const *tag)=0 |
Get the registered object corresponding with the given tag. | |
virtual iBase * | Get (char const *tag, scfInterfaceID id, int version)=0 |
Get the registered object corresponding with the given tag and implementing the specified interface. | |
virtual csPtr< iObjectRegistryIterator > | Get (scfInterfaceID id, int version)=0 |
Get an iterator with all objects implementing the given interface. | |
virtual csPtr< iObjectRegistryIterator > | Get ()=0 |
Get an iterator with all objects in this object registry. |
Detailed Description
This interface serves as a registry of other objects.The object registry is thread-safe.
Definition at line 49 of file objreg.h.
Member Function Documentation
|
Clear the object registry and release all references.
Implemented in csObjectRegistry. |
|
Get an iterator with all objects in this object registry. Note that the iterator iterates over a copy of the elements in the object registry so no thread-locking on the object registry happens except at the time the iterator is created. Implemented in csObjectRegistry. |
|
Get an iterator with all objects implementing the given interface. Note that the iterator iterates over a copy of the elements in the object registry so no thread-locking on the object registry happens except at the time the iterator is created. Implemented in csObjectRegistry. |
|
Get the registered object corresponding with the given tag and implementing the specified interface. The iBase pointers returned by the iterator will be the requested interface itself so there is no need to do further QueryInterface(). This function will increase the ref count of the returned object. Implemented in csObjectRegistry. |
|
Get the registered object corresponding with the given tag. This function will increase the ref count of the returned object. Implemented in csObjectRegistry. |
|
Register an object with this registry. The same object can be registered multiple times but in that case it is probably best to have different tags so they can be distinguished. This function will increase the ref count of the given object. Note that a given tag (if non-0) may only be registered once. This function will return false otherwise. This function will also fail if this object registry is being cleared. Implemented in csObjectRegistry. |
|
Unregister an object with this registry. If 'tag' is not given then it will unregister all occurrences of the given object in the registry (i.e. for all tags). If 'tag' is given then only the object that has that tag will be unregistered. This function will decrease the ref count of the given object. Implemented in csObjectRegistry. |
The documentation for this struct was generated from the following file:
- iutil/objreg.h
Generated for Crystal Space by doxygen 1.2.18