SUMO - Simulation of Urban MObility
Main Page
Related Pages
Modules
Data Structures
Files
File List
Globals
All
Data Structures
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
MSEdgeWeightsStorage.h
Go to the documentation of this file.
1
/****************************************************************************/
8
// A storage for edge travel times and efforts
9
/****************************************************************************/
10
// SUMO, Simulation of Urban MObility; see http://sumo-sim.org/
11
// Copyright (C) 2001-2014 DLR (http://www.dlr.de/) and contributors
12
/****************************************************************************/
13
//
14
// This file is part of SUMO.
15
// SUMO is free software: you can redistribute it and/or modify
16
// it under the terms of the GNU General Public License as published by
17
// the Free Software Foundation, either version 3 of the License, or
18
// (at your option) any later version.
19
//
20
/****************************************************************************/
21
#ifndef MSEdgeWeightsStorage_h
22
#define MSEdgeWeightsStorage_h
23
24
25
// ===========================================================================
26
// included modules
27
// ===========================================================================
28
#ifdef _MSC_VER
29
#include <
windows_config.h
>
30
#else
31
#include <
config.h
>
32
#endif
33
34
#include <
utils/common/SUMOTime.h
>
35
#include <
utils/common/ValueTimeLine.h
>
36
37
38
// ===========================================================================
39
// class declarations
40
// ===========================================================================
41
class
MSEdge
;
42
class
SUMOVehicle
;
43
44
45
// ===========================================================================
46
// class definitions
47
// ===========================================================================
52
class
MSEdgeWeightsStorage
{
53
public
:
55
MSEdgeWeightsStorage
();
56
57
59
~MSEdgeWeightsStorage
();
60
61
68
bool
retrieveExistingTravelTime
(
const
MSEdge
*
const
e,
const
SUMOReal
t,
SUMOReal
& value)
const
;
69
70
77
bool
retrieveExistingEffort
(
const
MSEdge
*
const
e,
const
SUMOReal
t,
SUMOReal
& value)
const
;
78
79
86
void
addTravelTime
(
const
MSEdge
*
const
e,
SUMOReal
begin,
SUMOReal
end,
SUMOReal
value);
87
88
95
void
addEffort
(
const
MSEdge
*
const
e,
SUMOReal
begin,
SUMOReal
end,
SUMOReal
value);
96
97
101
void
removeTravelTime
(
const
MSEdge
*
const
e);
102
103
107
void
removeEffort
(
const
MSEdge
*
const
e);
108
109
114
bool
knowsTravelTime
(
const
MSEdge
*
const
e)
const
;
115
116
121
bool
knowsEffort
(
const
MSEdge
*
const
e)
const
;
122
123
124
private
:
126
std::map<const MSEdge*, ValueTimeLine<SUMOReal> >
myTravelTimes
;
127
129
std::map<const MSEdge*, ValueTimeLine<SUMOReal> >
myEfforts
;
130
131
132
private
:
134
MSEdgeWeightsStorage
(
const
MSEdgeWeightsStorage
&);
135
137
MSEdgeWeightsStorage
&
operator=
(
const
MSEdgeWeightsStorage
&);
138
139
140
};
141
142
143
#endif
144
145
/****************************************************************************/
146
tmp
buildd
sumo-0.21.0+dfsg
src
microsim
MSEdgeWeightsStorage.h
Generated on Thu Nov 20 2014 19:49:55 for SUMO - Simulation of Urban MObility by
1.8.1.2