00001 #ifndef REVISION_FILTER_QBOX_H 00002 #define REVISION_FILTER_QBOX_H 00003 00004 #include "QBox.h" 00005 #include "Expression.h" 00006 #include "CP.h" 00007 00008 BOREALIS_NAMESPACE_BEGIN; 00009 00010 class RevisionFilterQBox : public QBox { 00011 00012 private: 00013 EvalContext _ctxt; 00014 vector<ptr<Expression> > _expressions; 00015 00016 bool _passOnFalsePort; 00017 unsigned int _output_tuple_size; 00018 00019 unsigned int _expr_count; // _expressions.size() 00020 00021 /****** Added on this box *******/ 00022 int _revision_id_counter; 00023 map<int, const char*> _revision_tuple_store; 00024 00025 protected: 00026 void setupImpl() throw (AuroraException); 00027 void initImpl() throw (AuroraException); 00028 void runImpl(QBoxInvocation&) throw (AuroraException); 00029 00030 /***** Added on this box *****/ 00031 // If a CPView exists on my stream, then return it. 00032 CPView* getCPView(unsigned int port); 00033 00034 00035 AURORA_DECLARE_QBOX(RevisionFilterQBox, "revisionfilter"); 00036 }; 00037 00038 BOREALIS_NAMESPACE_END; 00039 00040 #endif