ACF $AcfVersion:0$
Public Member Functions | List of all members
imod::CModelProxy Class Reference

Implementation of the model proxy. More...

#include <CModelProxy.h>

Inheritance diagram for imod::CModelProxy:
imod::IModel istd::IPolymorphic

Public Member Functions

 CModelProxy ()
 
void SetModelPtr (imod::IModel *modelPtr)
 
void ResetModel ()
 
virtual bool AttachObserver (IObserver *observerPtr) override
 Attaches model object to observer observerPtr.
 
virtual void DetachObserver (IObserver *observerPtr) override
 Detaches model object from observer observerPtr.
 
virtual void DetachAllObservers () override
 Detaches all attached observers.
 
virtual bool IsAttached (const IObserver *observerPtr) const override
 Returns true if observer observer is attached to this model object.
 
- Public Member Functions inherited from istd::IPolymorphic
virtual ~IPolymorphic ()
 

Detailed Description

Implementation of the model proxy.

This class can be used to switch model connections behind the proxy.

Definition at line 23 of file CModelProxy.h.

Constructor & Destructor Documentation

◆ CModelProxy()

imod::CModelProxy::CModelProxy ( )

Member Function Documentation

◆ AttachObserver()

virtual bool imod::CModelProxy::AttachObserver ( IObserver observerPtr)
overridevirtual

Attaches model object to observer observerPtr.

Warning
Please note, that double call of this function for the same observer will cause an assertion.
Parameters
observerPtrobserver, cannot be NULL.

Implements imod::IModel.

◆ DetachAllObservers()

virtual void imod::CModelProxy::DetachAllObservers ( )
overridevirtual

Detaches all attached observers.

Implements imod::IModel.

◆ DetachObserver()

virtual void imod::CModelProxy::DetachObserver ( IObserver observerPtr)
overridevirtual

Detaches model object from observer observerPtr.

Warning
Please note, that call of this function for the observer which is not attached to the observer observer will cause an assertion. To prevent this, you can use the isAttached() function.

Implements imod::IModel.

◆ IsAttached()

virtual bool imod::CModelProxy::IsAttached ( const IObserver observerPtr) const
overridevirtual

Returns true if observer observer is attached to this model object.

Implements imod::IModel.

◆ ResetModel()

void imod::CModelProxy::ResetModel ( )

◆ SetModelPtr()

void imod::CModelProxy::SetModelPtr ( imod::IModel modelPtr)

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