TraDemGen Logo  1.00.0
C++ Simulated Travel Demand Generation Library
 All Classes Namespaces Files Functions Variables Typedefs Friends Pages
RandomGenerationContext.hpp
Go to the documentation of this file.
1 #ifndef __TRADEMGEN_BAS_RANDOM_GENERATION_CONTEXT_HPP
2 #define __TRADEMGEN_BAS_RANDOM_GENERATION_CONTEXT_HPP
3 
4 // //////////////////////////////////////////////////////////////////////
5 // Import section
6 // //////////////////////////////////////////////////////////////////////
7 // STL
8 #include <iosfwd>
9 #include <string>
10 // StdAir
11 #include <stdair/stdair_basic_types.hpp>
12 #include <stdair/stdair_maths_types.hpp>
13 #include <stdair/basic/StructAbstract.hpp>
14 
15 namespace TRADEMGEN {
16 
20  struct RandomGenerationContext : public stdair::StructAbstract {
21  public:
22  // ////////// Getters /////////
26  const stdair::Count_T& getNumberOfRequestsGeneratedSoFar() const {
27  return _numberOfRequestsGeneratedSoFar;
28  }
29 
34  const stdair::Probability_T& getCumulativeProbabilitySoFar() const {
35  return _cumulativeProbabilitySoFar;
36  }
37 
38  public:
39  // ////////// Setters /////////
43  void setNumberOfRequestsGeneratedSoFar (const stdair::Count_T& iCount) {
44  _numberOfRequestsGeneratedSoFar = iCount;
45  }
46 
51  void setCumulativeProbabilitySoFar (const stdair::Probability_T& iProb) {
52  _cumulativeProbabilitySoFar = iProb;
53  }
54 
55 
56  public:
57  // ////////// Constructors and destructors /////////
62 
67 
72 
73 
74  public:
75  // /////////////// Business Methods //////////
80 
84  void reset();
85 
86 
87  public:
88  // ////////////// Display Support Methods //////////
92  const std::string describe() const;
93 
94 
95  private:
96  // ////////// Attributes //////////
100  stdair::Count_T _numberOfRequestsGeneratedSoFar;
101 
106  stdair::Probability_T _cumulativeProbabilitySoFar;
107  };
108 
109 }
110 #endif // __STDAIR_BAS_RANDOM_GENERATION_CONTEXT_HPP