NLDiscreteEventBuilder.h

Go to the documentation of this file.
00001 /****************************************************************************/
00007 // missing_desc
00008 /****************************************************************************/
00009 // SUMO, Simulation of Urban MObility; see http://sumo.sourceforge.net/
00010 // Copyright 2001-2010 DLR (http://www.dlr.de/) and contributors
00011 /****************************************************************************/
00012 //
00013 //   This program is free software; you can redistribute it and/or modify
00014 //   it under the terms of the GNU General Public License as published by
00015 //   the Free Software Foundation; either version 2 of the License, or
00016 //   (at your option) any later version.
00017 //
00018 /****************************************************************************/
00019 #ifndef NLDiscreteEventBuilder_h
00020 #define NLDiscreteEventBuilder_h
00021 
00022 
00023 // ===========================================================================
00024 // included modules
00025 // ===========================================================================
00026 #ifdef _MSC_VER
00027 #include <windows_config.h>
00028 #else
00029 #include <config.h>
00030 #endif
00031 
00032 #include <xercesc/sax2/Attributes.hpp>
00033 #include <string>
00034 #include <map>
00035 #include <utils/xml/GenericSAXHandler.h>
00036 
00037 
00038 // ===========================================================================
00039 // class declarations
00040 // ===========================================================================
00041 class MSNet;
00042 
00043 
00044 // ===========================================================================
00045 // class definitions
00046 // ===========================================================================
00052 class NLDiscreteEventBuilder {
00053 public:
00055     enum ActionType {
00057         EV_SAVETLSTATE,
00059         EV_SAVETLSWITCHES,
00061         EV_SAVETLSWITCHSTATES
00062     };
00063 
00065     NLDiscreteEventBuilder(MSNet &net);
00066 
00068     ~NLDiscreteEventBuilder();
00069 
00071     void addAction(const SUMOSAXAttributes &attrs, const std::string &basePath);
00072 
00073 private:
00075     void buildSaveTLStateCommand(const SUMOSAXAttributes &attrs, const std::string &basePath);
00076 
00078     void buildSaveTLSwitchesCommand(const SUMOSAXAttributes &attrs, const std::string &basePath);
00079 
00081     void buildSaveTLSwitchStatesCommand(const SUMOSAXAttributes &attrs, const std::string &basePath);
00082 
00083 protected:
00085     typedef std::map<std::string, ActionType> KnownActions;
00086 
00088     KnownActions myActions;
00089 
00090     MSNet &myNet;
00091 
00092 };
00093 
00094 
00095 #endif
00096 
00097 /****************************************************************************/
00098 

Generated on Wed May 5 00:06:35 2010 for Sumo - Simulation of Urban MObility by  doxygen 1.5.6