SUMO - Simulation of Urban MObility
NIVissimNodeParticipatingEdge.cpp
Go to the documentation of this file.
1 /****************************************************************************/
2 // Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo
3 // Copyright (C) 2001-2017 German Aerospace Center (DLR) and others.
4 /****************************************************************************/
5 //
6 // This program and the accompanying materials
7 // are made available under the terms of the Eclipse Public License v2.0
8 // which accompanies this distribution, and is available at
9 // http://www.eclipse.org/legal/epl-v20.html
10 //
11 /****************************************************************************/
17 // -------------------
18 /****************************************************************************/
19 
20 
21 // ===========================================================================
22 // included modules
23 // ===========================================================================
24 #ifdef _MSC_VER
25 #include <windows_config.h>
26 #else
27 #include <config.h>
28 #endif
29 
30 
31 #include "NIVissimEdge.h"
32 #include "NIVissimConnection.h"
34 
35 
36 
38  int edgeid, double frompos, double topos)
39  : myEdgeID(edgeid), myFromPos(frompos), myToPos(topos) {}
40 
42 
43 
44 int
46  return myEdgeID;
47 }
48 
49 
50 bool
52  return
53  (myFromPos < myToPos && myFromPos >= pos && myToPos <= pos)
54  ||
55  (myFromPos > myToPos && myFromPos <= pos && myToPos >= pos);
56 }
57 
58 double
60  return myFromPos;
61 }
62 
63 
64 double
66  return myToPos;
67 }
68 
69 
70 
71 /****************************************************************************/
72 
NIVissimNodeParticipatingEdge(int edgeid, double frompos, double topos)