17 #ifndef MSParkingArea_h 18 #define MSParkingArea_h 76 const std::vector<std::string>& lines,
MSLane& lane,
77 double begPos,
double endPos,
int capacity,
78 double width,
double length,
double angle,
const std::string& name,
169 virtual void addLotEntry(
double x,
double y,
double z,
170 double width,
double length,
double angle);
A lane area vehicles can halt at.
int index
the running index
Position myPosition
The position of the vehicle when parking in this space.
int myLastFreeLot
Last free lot number (-1 no free lot)
A lane area vehicles can halt at.
void enter(SUMOVehicle *what, double beg, double end)
Called if a vehicle enters this stop.
double myReservationMaxLength
Position getVehiclePosition(const SUMOVehicle &forVehicle) const
Returns the position of parked vehicle.
MSParkingArea & operator=(const MSParkingArea &)
Invalidated assignment operator.
double myLength
The length.
double getVehicleAngle(const SUMOVehicle &forVehicle) const
Returns the angle of parked vehicle.
double myAngle
The default angle of each parking space.
SUMOTime myReservationTime
track parking reservations from the lane for the current time step
Representation of a vehicle.
double myEndPos
The position along the lane that the vehicle needs to reach for entering this lot.
A point in 2D or 3D with translation and scaling methods.
PositionVector myShape
The roadside shape of this parkingArea.
double myLength
The default length of each parking space.
int getCapacity() const
Returns the area capacity.
std::vector< LotSpaceDefinition > mySpaceOccupancies
All the spaces in this parking area.
void computeLastFreePos()
Computes the last free position on this stop.
bool parkOnRoad() const
whether vehicles park on the road
MSParkingArea(const std::string &id, const std::vector< std::string > &lines, MSLane &lane, double begPos, double endPos, int capacity, double width, double length, double angle, const std::string &name, bool onRoad)
Constructor.
int getOccupancy() const
Returns the area occupancy.
virtual void addLotEntry(double x, double y, double z, double width, double length, double angle)
Add a lot entry to parking area.
double getLength() const
Returns the lot rectangle length.
int myCapacity
Stop area capacity.
bool myOnRoad
Whether vehicles stay on the road.
void leaveFrom(SUMOVehicle *what)
Called if a vehicle leaves this stop.
double getWidth() const
Returns the lot rectangle width.
virtual ~MSParkingArea()
Destructor.
double getLastFreePosWithReservation(SUMOTime t, const SUMOVehicle &forVehicle)
Returns the last free position on this stop including reservatiosn from the current lane and time ste...
Representation of a single lot space.
double getLastFreePos() const
double myWidth
The default width of each parking space.
Representation of a lane in the micro simulation.
double getAngle() const
Returns the lot rectangle angle.
SUMOVehicle * vehicle
The last parked vehicle or 0.
double myRotation
The rotation.