rwth-info3/Aufgabenblock_2/Weg.h

42 lines
754 B
C
Raw Permalink Normal View History

2011-10-18 21:53:59 +02:00
#ifndef WEG_H_
#define WEG_H_
#include <list>
#include <string>
#include "AktivesVO.h"
#include "LazyListe.h"
2011-10-18 21:53:59 +02:00
using namespace std;
class Fahrzeug; /* Forward Deklaration */
class Weg : public AktivesVO {
public:
2011-11-03 14:44:41 +01:00
typedef enum {
Innerorts, /* 50 km/h */
Landstrasse, /* 100 km/h */
Autobahn /* unbegrenzt */
} Begrenzung;
2011-10-18 21:53:59 +02:00
Weg();
Weg(string sName, double dLaenge, Begrenzung eLimit = Autobahn);
virtual ~Weg();
void vAbfertigung();
2011-11-01 13:43:39 +01:00
void vAnnahme(Fahrzeug *pFz, double dStartZeit = 0);
2011-11-03 14:44:41 +01:00
void vAbgabe(Fahrzeug *pFz);
2011-10-18 21:53:59 +02:00
double getLaenge() const;
2011-11-01 13:43:39 +01:00
Begrenzung getLimit() const;
2011-10-18 21:53:59 +02:00
ostream& ostreamAusgabe(ostream &stream) const;
private:
double p_dLaenge;
Begrenzung p_eLimit;
LazyListe<Fahrzeug *> p_pFahrzeuge;
2011-10-18 21:53:59 +02:00
};
#endif /* WEG_H_ */