Component for synchronization between some master data object and its "slaves". More...
#include <CObjectSynchronizerComp.h>
Public Types | |
typedef icomp::CComponentBase | BaseClass |
Protected Member Functions | |
virtual void | OnUpdate (const istd::IChangeable::ChangeSet &changeSet) |
Called on update of observed model. More... | |
virtual void | OnComponentCreated () |
virtual void | OnComponentDestroyed () |
![]() | |
bool | IsComponentActive () const |
Check if component is active. More... | |
virtual const icomp::IRealComponentStaticInfo & | GetComponentStaticInfo () const =0 |
Get access to static info of this component. More... | |
![]() | |
void | SetModelPtr (imod::IModel *modelPtr) |
Set internal model pointer to specified value. More... | |
CSingleModelObserverBase () | |
virtual | ~CSingleModelObserverBase () |
imod::IModel * | GetObservedModel () const |
Get access to observed model. More... | |
imod::IModel * | GetModelPtr () const |
Get access to observed model. More... | |
void | EnsureModelDetached () |
Make sure this observer is detached. More... | |
void | SetObservedIds (const istd::IChangeable::ChangeSet &changeMask) |
Set list of ID's beeing observed. More... | |
virtual bool | IsModelAttached (const imod::IModel *modelPtr=NULL) const |
Check if specified model is attached. More... | |
virtual bool | OnModelAttached (imod::IModel *modelPtr, istd::IChangeable::ChangeSet &changeMask) |
This call back function will be called, if an observable object is about to be attached. More... | |
virtual bool | OnModelDetached (imod::IModel *modelPtr) |
This call back function will be called, if an observable object is about to be detached. More... | |
virtual void | BeforeUpdate (imod::IModel *modelPtr) |
This function will be called before update of the observer contents occures. More... | |
virtual void | AfterUpdate (imod::IModel *modelPtr, const istd::IChangeable::ChangeSet &changeSet) |
This function will be called after update of the observer contents occures. More... | |
Additional Inherited Members | |
![]() | |
CComponentBase () | |
Create component and assign it to specific context. More... | |
virtual const ICompositeComponent * | GetParentComponent (bool ownerOnly=false) const |
Get parent of this component. More... | |
virtual void * | GetInterface (const istd::CClassInfo &interfaceType, const QByteArray &subId="") |
Get access to specified component interface. More... | |
virtual const IComponentContext * | GetComponentContext () const |
Get access to component context describing all application-specified component information loaded from components registry. More... | |
virtual void | SetComponentContext (const icomp::IComponentContext *contextPtr, const ICompositeComponent *parentPtr, bool isParentOwner) |
Set component context of this component. More... | |
![]() | |
virtual | ~IPolymorphic () |
![]() | |
typedef imod::IModel | ModelType |
![]() | |
static const icomp::IRealComponentStaticInfo & | InitStaticInfo (IComponent *componentPtr) |
static QByteArray | GetComponentId (const icomp::IComponentContext *componentContextPtr, const QByteArray &contextId=QByteArray()) |
![]() | |
static const istd::IChangeable::ChangeSet | s_undoChanges |
Component for synchronization between some master data object and its "slaves".
On component initialization the slave objects are initialized with data of "master" object. On each change of the "master" data, the slave objects will be automatically synchronized.
Definition at line 22 of file CObjectSynchronizerComp.h.
Definition at line 27 of file CObjectSynchronizerComp.h.
|
protectedvirtual |
Reimplemented from icomp::CComponentBase.
|
protectedvirtual |
Reimplemented from icomp::CComponentBase.
|
protectedvirtual |
Called on update of observed model.
This method is designed to be overload by derrived classes.
Reimplemented from imod::CSingleModelObserverBase.
© 2007-2017 Witold Gantzke and Kirill Lepskiy