CSingleFeatureConsumer.h
Go to the documentation of this file.
1 #ifndef iipr_CSingleFeatureConsumer_included
2 #define iipr_CSingleFeatureConsumer_included
3 
4 
5 // ACF includes
6 #include <istd/TDelPtr.h>
9 
10 
11 namespace iipr
12 {
13 
14 
19  virtual public IFeaturesConsumer,
20  virtual public IFeaturesProvider
21 {
22 public:
23 
28  {
33 
38 
43  };
44 
45  CSingleFeatureConsumer(int featurePolicy = FP_FIRST);
46 
51  int GetFeaturePolicy() const;
52 
57  void SetFeaturePolicy(int featurePolicy);
58 
59  // reimplemented (iipr::IFeaturesConsumer)
60  virtual void ResetFeatures();
61  virtual bool AddFeature(const imeas::INumericValue* featurePtr, bool* isFullPtr = NULL);
62 
63  // reimplemented (iipr::IFeaturesProvider)
64  virtual int GetFeaturesCount() const;
65  virtual const imeas::INumericValue& GetFeature(int index) const;
66 
67 private:
69 
70  int m_featurePolicy;
71 };
72 
73 
74 } // namespace iipr
75 
76 
77 #endif // !iipr_CSingleFeatureConsumer_included
78 
79 
virtual void ResetFeatures()
Remove all features from this container.
Only heaviest feature is stored in the container.
virtual const imeas::INumericValue & GetFeature(int index) const
Get access to single feature.
FeaturePolicy
Control storing of the features in the container.
Only first feature is stored in the container.
Container allowing access to features.
CSingleFeatureConsumer(int featurePolicy=FP_FIRST)
int GetFeaturePolicy() const
Get feature adding policy.
Only last feature is stored in the container.
void SetFeaturePolicy(int featurePolicy)
Set feature adding policy.
Feature consumer implmentation storing one feature only.
virtual int GetFeaturesCount() const
Get number of stored features.
virtual bool AddFeature(const imeas::INumericValue *featurePtr, bool *isFullPtr=NULL)
Add new feature to the set of features.
General parameter set containing list of numeric values.
Definition: INumericValue.h:20
Common interface for a features container consuming feature objects.

© 2007-2017 Witold Gantzke and Kirill Lepskiy