Public Types | Public Member Functions | Protected Member Functions | List of all members
iinsp::CSupplierActivationProxyComp Class Reference

Supplier activation proxy. More...

#include <CSupplierActivationProxyComp.h>

Inheritance diagram for iinsp::CSupplierActivationProxyComp:
icomp::CComponentBase iinsp::IEnableableSupplier icomp::IComponent iinsp::ISupplier istd::IPolymorphic istd::IChangeable istd::IPolymorphic

Public Types

typedef icomp::CComponentBase BaseClass
 
- Public Types inherited from iinsp::IEnableableSupplier
enum  ChangeFlags { CF_SUPPLIER_ACTIVATION = 0x6326416 }
 Data model change notification flags. More...
 
- Public Types inherited from iinsp::ISupplier
enum  WorkStatus {
  WS_INVALID, WS_INIT, WS_LOCKED, WS_OK,
  WS_CANCELED, WS_FAILED
}
 
enum  ChangeFlags { CF_SUPPLIER_RESULTS = 0x6326415 }
 Data model change notification flags. More...
 
enum  MessageContainerType { MCT_RESULTS, MCT_TEMP, MTC_LAST = MCT_TEMP }
 

Public Member Functions

 CSupplierActivationProxyComp ()
 
virtual bool SetSupplierEnabled (bool isEnabled=true)
 Set supplier's activation state. More...
 
virtual bool IsSupplierEnabled () const
 Get activation state of the supplier. More...
 
virtual bool IsStateFixed () const
 Get true if the state of the supplier is fixed and cannot be changed. More...
 
virtual int GetWorkStatus () const
 Get status of last work. More...
 
virtual imod::IModelGetWorkStatusModel () const
 Get access to the status model of the supplier. More...
 
virtual void InvalidateSupplier ()
 Called to signalize that this supplier is invalid. More...
 
virtual void EnsureWorkInitialized ()
 Force the supplier to initialize its work. More...
 
virtual void EnsureWorkFinished ()
 Ensure that all objects are produced. More...
 
virtual void ClearWorkResults ()
 Remove all stored work results. More...
 
virtual const
ilog::IMessageContainer
GetWorkMessages (int messageType) const
 Get messages outputted by this work. More...
 
virtual iprm::IParamsSetGetModelParametersSet () const
 Get parameter set using by this supplier. More...
 
- Public Member Functions inherited from icomp::IComponent
virtual const ICompositeComponentGetParentComponent (bool ownerOnly=false) const =0
 
virtual void * GetInterface (const istd::CClassInfo &interfaceType, const QByteArray &subId="")=0
 
virtual const IComponentContextGetComponentContext () const =0
 
virtual void SetComponentContext (const icomp::IComponentContext *contextPtr, const ICompositeComponent *parentPtr, bool isParentOwner)=0
 

Protected Member Functions

virtual void OnComponentCreated ()
 
virtual void OnComponentDestroyed ()
 

Detailed Description

Supplier activation proxy.

This component can be used to add enable/disable logic to any suppler.

Definition at line 22 of file CSupplierActivationProxyComp.h.

Member Typedef Documentation

Definition at line 27 of file CSupplierActivationProxyComp.h.

Constructor & Destructor Documentation

iinsp::CSupplierActivationProxyComp::CSupplierActivationProxyComp ( )

Member Function Documentation

virtual void iinsp::CSupplierActivationProxyComp::ClearWorkResults ( )
virtual

Remove all stored work results.

This set also work state to WS_INIT.

Implements iinsp::ISupplier.

virtual void iinsp::CSupplierActivationProxyComp::EnsureWorkFinished ( )
virtual

Ensure that all objects are produced.

Implements iinsp::ISupplier.

virtual void iinsp::CSupplierActivationProxyComp::EnsureWorkInitialized ( )
virtual

Force the supplier to initialize its work.

First if work is initialized, new calculation can be done.

Implements iinsp::ISupplier.

virtual iprm::IParamsSet* iinsp::CSupplierActivationProxyComp::GetModelParametersSet ( ) const
virtual

Get parameter set using by this supplier.

The pointed object will not be relocated - no reconnect is needed if it is observed. If the supplier doesn't support parameters, it returns NULL.

Implements iinsp::ISupplier.

virtual const ilog::IMessageContainer* iinsp::CSupplierActivationProxyComp::GetWorkMessages ( int  containerType) const
virtual

Get messages outputted by this work.

The pointed object will not be relocated - no reconnect is needed if it is observed. If the supplier doesn't support list of messages, it returns NULL.

Parameters
containerTypetype of message container,
See Also
MessageContainerType.

Implements iinsp::ISupplier.

virtual int iinsp::CSupplierActivationProxyComp::GetWorkStatus ( ) const
virtual

Get status of last work.

Please note, that this status is not a part of supplier model and can be changed without any notification. If you want to observe the status model of the supplier, please use the GetWorkStatusModel method.

Returns
work status defined in iinsp::ISupplier::WorkStatus.
See Also
GetWorkStatusModel

Implements iinsp::ISupplier.

virtual imod::IModel* iinsp::CSupplierActivationProxyComp::GetWorkStatusModel ( ) const
virtual

Get access to the status model of the supplier.

Implements iinsp::ISupplier.

virtual void iinsp::CSupplierActivationProxyComp::InvalidateSupplier ( )
virtual

Called to signalize that this supplier is invalid.

This signal will be transfered to all supplier which are registered as output.

Returns
true, if initialization could be done.

Implements iinsp::ISupplier.

virtual bool iinsp::CSupplierActivationProxyComp::IsStateFixed ( ) const
virtual

Get true if the state of the supplier is fixed and cannot be changed.

Implements iinsp::IEnableableSupplier.

virtual bool iinsp::CSupplierActivationProxyComp::IsSupplierEnabled ( ) const
virtual

Get activation state of the supplier.

Implements iinsp::IEnableableSupplier.

virtual void iinsp::CSupplierActivationProxyComp::OnComponentCreated ( )
protectedvirtual
virtual void iinsp::CSupplierActivationProxyComp::OnComponentDestroyed ( )
protectedvirtual
virtual bool iinsp::CSupplierActivationProxyComp::SetSupplierEnabled ( bool  isEnabled = true)
virtual

Set supplier's activation state.

If the state of supplier cannot be changed, the method will failed.

See Also
IsStateFixed

Implements iinsp::IEnableableSupplier.


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

© 2007-2017 Witold Gantzke and Kirill Lepskiy