1.00.9
C++ Simulated Travel Demand Generation Library
Loading...
Searching...
No Matches
DemandDistribution.cpp
Go to the documentation of this file.
1
// //////////////////////////////////////////////////////////////////////
2
// Import section
3
// //////////////////////////////////////////////////////////////////////
4
// STL
5
#include <cassert>
6
#include <sstream>
7
// StdAir
8
#include <stdair/stdair_date_time_types.hpp>
9
// TraDemGen
10
#include <
trademgen/basic/DemandDistribution.hpp
>
11
12
namespace
TRADEMGEN
{
13
14
// /////////////////////////////////////////////////////
15
DemandDistribution::DemandDistribution
(
const
stdair::NbOfRequests_T& iMean,
16
const
stdair::StdDevValue_T& iStdDev)
17
: _meanNumberOfRequests (iMean),
18
_stdDevNumberOfRequests (iStdDev) {
19
}
20
21
// /////////////////////////////////////////////////////
22
DemandDistribution::DemandDistribution
() {
23
}
24
25
// /////////////////////////////////////////////////////
26
DemandDistribution::~DemandDistribution
() {
27
}
28
29
// /////////////////////////////////////////////////////
30
DemandDistribution::
31
DemandDistribution
(
const
DemandDistribution
& iDemandDistribution)
32
: _meanNumberOfRequests (iDemandDistribution._meanNumberOfRequests),
33
_stdDevNumberOfRequests (iDemandDistribution._stdDevNumberOfRequests) {
34
}
35
36
// /////////////////////////////////////////////////////
37
void
DemandDistribution::fromStream
(std::istream& ioIn) {
38
}
39
40
// /////////////////////////////////////////////////////
41
const
std::string
DemandDistribution::describe
()
const
{
42
std::ostringstream oStr;
43
oStr <<
"N ("
<<
_meanNumberOfRequests
<<
", "
44
<<
_stdDevNumberOfRequests
<<
")"
;
45
return
oStr.str();
46
}
47
48
// /////////////////////////////////////////////////////
49
std::string
DemandDistribution::display
()
const
{
50
std::ostringstream oStr;
51
oStr <<
describe
() << std::endl;
52
return
oStr.str();
53
}
54
55
}
56
DemandDistribution.hpp
TRADEMGEN
Definition
BasConst.cpp:10
TRADEMGEN::DemandDistribution
Class modeling the distribution of a demand type.
Definition
DemandDistribution.hpp:20
TRADEMGEN::DemandDistribution::DemandDistribution
DemandDistribution()
Definition
DemandDistribution.cpp:22
TRADEMGEN::DemandDistribution::_meanNumberOfRequests
stdair::NbOfRequests_T _meanNumberOfRequests
Definition
DemandDistribution.hpp:67
TRADEMGEN::DemandDistribution::~DemandDistribution
~DemandDistribution()
Definition
DemandDistribution.cpp:26
TRADEMGEN::DemandDistribution::fromStream
void fromStream(std::istream &ioIn)
Definition
DemandDistribution.cpp:37
TRADEMGEN::DemandDistribution::describe
const std::string describe() const
Definition
DemandDistribution.cpp:41
TRADEMGEN::DemandDistribution::display
std::string display() const
Definition
DemandDistribution.cpp:49
TRADEMGEN::DemandDistribution::_stdDevNumberOfRequests
stdair::StdDevValue_T _stdDevNumberOfRequests
Definition
DemandDistribution.hpp:72
Generated on Sat Jan 27 2024 00:00:00 for TraDemGen by
1.10.0