#include <GaudiKernel/IConverter.h>
Inheritance diagram for IConverter:
Public Types | |
| enum | Status { SUCCESS = IInterface::SUCCESS, INVALID_ADDRESS = IInterface::LAST_ERROR+1, INVALID_OBJECT, NO_MEMORY, NO_SOURCE_OBJECT } |
| Status code. More... | |
Public Methods | |
| virtual StatusCode | initialize () = 0 |
| Initialize the converter. More... | |
| virtual StatusCode | finalize () = 0 |
| Terminate the converter. More... | |
| virtual const CLID& | objType () const = 0 |
| Retrieve the class type of objects the converter produces. More... | |
| virtual unsigned char | repSvcType () const = 0 |
| Retrieve the class type of the data store the converter uses. More... | |
| virtual StatusCode | setDataProvider (IDataProviderSvc* pService) = 0 |
| Set Data provider service. More... | |
| virtual IDataProviderSvc* | dataProvider () = 0 |
| Get Data provider service. More... | |
| virtual StatusCode | createObj (IOpaqueAddress* pAddress, DataObject*& refpObject) = 0 |
| Create the transient representation of an object. More... | |
| virtual StatusCode | fillObjRefs (IOpaqueAddress* pAddress, DataObject* pObject) = 0 |
| Resolve the references of the created transient object. More... | |
| virtual StatusCode | updateObj (IOpaqueAddress* pAddress, DataObject* refpObject) = 0 |
| Update the transient object from the other representation. More... | |
| virtual StatusCode | updateObjRefs (IOpaqueAddress* pAddress, DataObject* pObject) = 0 |
| Update the references of an updated transient object. More... | |
| virtual StatusCode | createRep (DataObject* pObject, IOpaqueAddress*& refpAddress) = 0 |
| Convert the transient object to the requested representation. More... | |
| virtual StatusCode | fillRepRefs (IOpaqueAddress* pAddress, DataObject* pObject) = 0 |
| Resolve the references of the converted object. More... | |
| virtual StatusCode | updateRep (IOpaqueAddress* pAddress, DataObject* pObject) = 0 |
| Update the converted representation of a transient object. More... | |
| virtual StatusCode | updateRepRefs (IOpaqueAddress* pAddress, DataObject* pObject) = 0 |
| Update the references of an already converted object. More... | |
Static Public Methods | |
| const InterfaceID& | interfaceID () |
| Retrieve interface ID. More... | |
Concrete examples are e.g. converters creating transient objects representing parts of an event from the persistent (and disk based) representations. Converters will have to deal with the technology both representations are based on: in the upper example they have to know about the database internals as well as the structure of the transient representations. The converters know about the mechanism to retrieve persistent objects (ZEBRA, Objectivity, ) and only pass abstract instances of the converted objects, hence shielding the calling service from internals.
Data converters are meant to be light. This means there should not be all-in-one converters, which are able to convert the "world", but rather many converters. Each converter is then able to create a representation of a given type.
In order to function a converter must be able to
The interface should cover the entry points of concrete converter instances in order to serve conversion requests.
Definition at line 60 of file IConverter.h.
|
|
Status code.
Reimplemented from IInterface. Definition at line 181 of file IConverter.h. |
|
|
Create the transient representation of an object. The transient representation is created by loading the persistent object using the source information contained in the address.
Reimplemented in Converter. Referenced by ConversionSvc::createObj(). |
|
|
Convert the transient object to the requested representation. e.g. conversion to persistent objects.
Reimplemented in Converter. |
|
|
Get Data provider service.
Reimplemented in Converter. |
|
|
Resolve the references of the created transient object. After the object creation references of the objects pointing to objects outside its scope will have to be filled. The actual objects will not be loaded, but the recipe to load them will be present.
Reimplemented in Converter. Referenced by ConversionSvc::createObj(). |
|
|
Resolve the references of the converted object. After the requested representation was created the references in this representation must be resolved.
Reimplemented in Converter. |
|
|
Terminate the converter.
Reimplemented in Converter. |
|
|
Initialize the converter.
Reimplemented in Converter. Referenced by ConversionSvc::initializeConverter(). |
|
|
Retrieve interface ID.
Reimplemented from IInterface. Definition at line 63 of file IConverter.h. |
|
|
Retrieve the class type of objects the converter produces.
Reimplemented in Converter. Referenced by ConversionSvc::addConverter(). |
|
|
Retrieve the class type of the data store the converter uses.
Reimplemented in Converter. Referenced by ConversionSvc::addConverter(). |
|
|
Set Data provider service.
Reimplemented in Converter. |
|
|
Update the transient object from the other representation. The transient representation will be updated by loading the persistent object using the source information contained in the address and then refill transient data.
Reimplemented in Converter. Referenced by ConversionSvc::updateObj(). |
|
|
Update the references of an updated transient object. After the object was updated alse the references of the objects pointing to objects outside its scope will have to be filled. The actual pointers to objects will only be filled if already present. Otherwise only the recipe to load them will be present.
Reimplemented in Converter. Referenced by ConversionSvc::updateObj(). |
|
|
Update the converted representation of a transient object.
Reimplemented in Converter. Referenced by ConversionSvc::updateReps(). |
|
|
Update the references of an already converted object. The object must be retrieved before it can be updated.
Reimplemented in Converter. |
1.2.3 written by Dimitri van Heesch,
© 1997-2000