reSIProcate/DialogUsageManager  9680
DumFeatureChain.hxx
Go to the documentation of this file.
00001 #ifndef RESIP_DumFeatureChain_HXX
00002 #define RESIP_DumFeatureChain_HXX 
00003 
00004 #include <vector>
00005 #include "rutil/SharedPtr.hxx"
00006 
00007 namespace resip
00008 {
00009 
00010 class DumFeature;
00011 
00012 class DumFeatureChain
00013 {
00014    public: 
00015       typedef std::vector<SharedPtr<DumFeature> > FeatureList;
00016       
00017       enum ProcessingResultMask
00018       {
00019          EventTakenBit = 1 << 0, //don't pass on, don't delete event
00020          ChainDoneBit = 1 << 1 //if true chain can be deleted
00021       };                              
00022 
00023       //legal combinations
00024       enum ProcessingResult
00025       {
00026          EventTaken = EventTakenBit, //don't delete event
00027          ChainDone = ChainDoneBit,  //event not consumed by chain
00028          ChainDoneAndEventTaken = ChainDoneBit | EventTakenBit
00029       };
00030 
00031       DumFeatureChain(DialogUsageManager& dum, const FeatureList& features, TargetCommand::Target& target);
00032      
00033       ProcessingResult process(Message* msg);      
00034 
00035    private:       
00036       // std::bit_vector mActiveFeatures;  //vector<bool> is the correct way on most platforms
00037       std::vector<bool> mActiveFeatures;
00038       FeatureList mFeatures;
00039 };
00040  
00041 }
00042 
00043 #endif
00044 
00045