![]() |
User Manual, Developers Guide and API Documentation |
![]() |
00001 /****************************************************************************** 00002 * WNS (Wireless Network Simulator) * 00003 * __________________________________________________________________________ * 00004 * * 00005 * Copyright (C) 2004-2006 * 00006 * Chair of Communication Networks (ComNets) * 00007 * Kopernikusstr. 16, D-52074 Aachen, Germany * 00008 * phone: ++49-241-80-27910 (phone), fax: ++49-241-80-22242 * 00009 * email: wns@comnets.rwth-aachen.de * 00010 * www: http://wns.comnets.rwth-aachen.de * 00011 ******************************************************************************/ 00012 00013 #ifndef WNS_LDK_TOOLS_INSEQUENCECHECKER_HPP 00014 #define WNS_LDK_TOOLS_INSEQUENCECHECKER_HPP 00015 00016 #include <WNS/ldk/Processor.hpp> 00017 #include <WNS/ldk/CommandTypeSpecifier.hpp> 00018 #include <WNS/ldk/HasReceptor.hpp> 00019 #include <WNS/ldk/HasConnector.hpp> 00020 #include <WNS/ldk/HasDeliverer.hpp> 00021 00022 #include <WNS/Cloneable.hpp> 00023 #include <WNS/pyconfig/View.hpp> 00024 #include <WNS/logger/Logger.hpp> 00025 00026 namespace wns { namespace ldk { namespace tools { 00027 00028 class InSequenceCheckerCommand : 00029 public wns::ldk::Command 00030 { 00031 public: 00032 InSequenceCheckerCommand() 00033 { 00034 magic.sequenceID = 0; 00035 } 00036 00037 struct {} local; 00038 struct {} peer; 00039 struct { 00040 unsigned int sequenceID; 00041 } magic; 00042 }; // InSequenceChecker 00043 00049 class InSequenceChecker : 00050 public wns::ldk::Processor<InSequenceChecker>, 00051 public wns::ldk::CommandTypeSpecifier<InSequenceCheckerCommand>, 00052 public wns::ldk::HasReceptor<>, 00053 public wns::ldk::HasConnector<>, 00054 public wns::ldk::HasDeliverer<>, 00055 public wns::Cloneable<InSequenceChecker> 00056 { 00057 public: 00061 explicit 00062 InSequenceChecker(wns::ldk::fun::FUN* fun, const wns::pyconfig::View& config); 00063 00067 virtual 00068 ~InSequenceChecker(); 00069 00070 private: 00075 virtual void 00076 processOutgoing(const wns::ldk::CompoundPtr&); 00077 00078 virtual void 00079 processIncoming(const wns::ldk::CompoundPtr&); 00081 00082 unsigned int sequenceIDOutgoing; 00083 unsigned int sequenceIDExpected; 00084 00085 wns::logger::Logger logger; 00086 }; 00087 00088 } // tools 00089 } // ldk 00090 } // wns 00091 #endif // NOT defined WNS_LDK_TOOLS_INSEQUENCECHECKER_HPP 00092 00093
1.5.5