CComposedBitmapProviderComp.h
Go to the documentation of this file.
1 #ifndef iimg_CComposedBitmapProviderComp_included
2 #define iimg_CComposedBitmapProviderComp_included
3 
4 
5 // ACF includes
6 #include <iimg/IBitmapProvider.h>
8 #include <icomp/CComponentBase.h>
10 #include <iprm/COptionsManager.h>
11 
12 
13 namespace iimg
14 {
15 
16 
21  public icomp::CComponentBase,
22  virtual public iimg::IMultiBitmapProvider,
23  protected iprm::COptionsManager
24 {
25 public:
27 
28  I_BEGIN_COMPONENT(CComposedBitmapProviderComp);
29  I_REGISTER_INTERFACE(iimg::IMultiBitmapProvider);
30  I_ASSIGN_MULTI_0(m_bitmapProvidersCompPtr, "BitmapProviders", "List of input bitmap providers", true);
31  I_ASSIGN_TO(m_bitmapProviderModelsCompPtr, m_bitmapProvidersCompPtr, false);
32  I_ASSIGN_MULTI_0(m_bitmapLabelsAttrPtr, "BitmapLabels", "List of bitmap labels", false);
33  I_ASSIGN_MULTI_0(m_bitmapDescriptionsAttrPtr, "BitmapDescriptions", "List of bitmap descriptions", false);
34  I_END_COMPONENT;
35 
37 
38  // reimplemented (iimg::IMultiBitmapProvider)
39  virtual const iprm::IOptionsList* GetBitmapListInfo() const;
40  virtual int GetBitmapsCount() const;
41  virtual const iimg::IBitmap* GetBitmap(int bitmapIndex) const;
42 
43 protected:
44  // reimplemented (icomp::CComponentBase)
45  virtual void OnComponentCreated();
46  virtual void OnComponentDestroyed();
47 
48 private:
49  I_MULTIREF(iimg::IBitmapProvider, m_bitmapProvidersCompPtr);
50  I_MULTIREF(imod::IModel, m_bitmapProviderModelsCompPtr);
51  I_MULTITEXTATTR(m_bitmapLabelsAttrPtr);
52  I_MULTITEXTATTR(m_bitmapDescriptionsAttrPtr);
53 
54  imod::CModelUpdateBridge m_updateBridge;
55 };
56 
57 
58 } // namespace iimg
59 
60 
61 #endif // !iimg_CComposedBitmapProviderComp_included
62 
63 
Base class for component implementation.
virtual int GetBitmapsCount() const
Get number of produced bitmaps.
Constraints of selection from set of possibilities.
Definition: IOptionsList.h:22
Definition of single plane bitmap.
Definition: IBitmap.h:17
Supplier allowing to access of multiple produced bitmaps.
virtual const iimg::IBitmap * GetBitmap(int bitmapIndex) const
Get access to produced bitmap object.
Reflects the changes of observed objects as changes of some other object (over istd::IChangeable), typically delegated to itself.
Component for composition/grouping of more single bitmap providers.
Common interface for model objects, that supports Model/Observer design pattern.
Definition: IModel.h:23
virtual const iprm::IOptionsList * GetBitmapListInfo() const
Get optional information about bitmaps in form of section constraints.
Bitmap supplier allowing to access of produced bitmap.
Implementation of a simple options manager.

© 2007-2017 Witold Gantzke and Kirill Lepskiy