Eclipse SUMO - Simulation of Urban MObility
MSTransportableDevice.h
Go to the documentation of this file.
1 /****************************************************************************/
2 // Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo
3 // Copyright (C) 2007-2019 German Aerospace Center (DLR) and others.
4 // This program and the accompanying materials
5 // are made available under the terms of the Eclipse Public License v2.0
6 // which accompanies this distribution, and is available at
7 // http://www.eclipse.org/legal/epl-v20.html
8 // SPDX-License-Identifier: EPL-2.0
9 /****************************************************************************/
16 // Abstract in-person device
17 /****************************************************************************/
18 #ifndef MSTransportableDevice_h
19 #define MSTransportableDevice_h
20 
21 
22 // ===========================================================================
23 // included modules
24 // ===========================================================================
25 #include <config.h>
26 
27 #include <string>
28 #include <vector>
29 #include <map>
30 #include <set>
31 #include <random>
32 #include "MSDevice.h"
33 
34 
35 // ===========================================================================
36 // class declarations
37 // ===========================================================================
38 class MSTransportable;
39 
40 
41 // ===========================================================================
42 // class definitions
43 // ===========================================================================
53 public:
59  MSTransportableDevice(MSTransportable& holder, const std::string& id) :
60  MSDevice(id), myHolder(holder) {
61  }
62 
63 
65  virtual ~MSTransportableDevice() { }
66 
67 
73  return myHolder;
74  }
75 
76 protected:
79 
80 private:
83 
86 
87 };
88 
89 
90 #endif
91 
92 /****************************************************************************/
MSTransportableDevice::myHolder
MSTransportable & myHolder
The person that stores the device.
Definition: MSTransportableDevice.h:78
MSTransportableDevice::~MSTransportableDevice
virtual ~MSTransportableDevice()
Destructor.
Definition: MSTransportableDevice.h:65
MSTransportableDevice::getHolder
MSTransportable & getHolder() const
Returns the person that holds this device.
Definition: MSTransportableDevice.h:72
MSTransportable
Definition: MSTransportable.h:58
MSDevice.h
MSTransportableDevice::MSTransportableDevice
MSTransportableDevice(const MSTransportableDevice &)
Invalidated copy constructor.
MSDevice
Abstract in-vehicle / in-person device.
Definition: MSDevice.h:63
MSTransportableDevice
Abstract in-person device.
Definition: MSTransportableDevice.h:52
MSTransportableDevice::MSTransportableDevice
MSTransportableDevice(MSTransportable &holder, const std::string &id)
Constructor.
Definition: MSTransportableDevice.h:59
config.h
MSTransportableDevice::operator=
MSTransportableDevice & operator=(const MSTransportableDevice &)
Invalidated assignment operator.