00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025 #ifndef __BAP_TV_VESSEL__
00026 #define __BAP_TV_VESSEL__
00027
00028
00029 #include "def.h"
00030
00031 using std::istream;
00032 using std::ostream;
00033 using leda::set;
00034
00035 class TVVessel
00036 {
00037 public:
00038 TVVessel();
00039 TVVessel(int anID, int aLength);
00040 TVVessel(const TVVessel& aVessel);
00041 ~TVVessel();
00042 TVVessel& operator=(const TVVessel& aVessel);
00043 void Print(const int& aWidth = 1, const int& aDetail = 0) const;
00044
00045 friend istream& operator>>(istream& anIS, TVVessel& aVessel);
00046 friend ostream& operator<<(ostream& anOS, const TVVessel& aVessel);
00047 friend int compare(const TVVessel& aV1, const TVVessel& aV2);
00048
00049 int ID() const;
00050 int Length() const;
00051 int Containers() const;
00052 int Import() const;
00053 int Export() const;
00054 int Transhipment() const;
00055 int StartTimeZone() const;
00056 int EndTimeZone() const;
00057 int Arrival() const;
00058 int Departure() const;
00059 int Section() const;
00060 const set<int>& Neighbours() const;
00061 const set<int>& Destinations() const;
00062
00063 int Import(int aNumContainers);
00064 int Export(int aNumContainers);
00065 int StartTimeZone(int aTimeZone);
00066 int EndTimeZone(int aTimeZone);
00067 int Arrival(int aTime);
00068 int Departure(int aTime);
00069 int Section(int aSection);
00070 void AddNeighbour(int aVessel);
00071 void AddTranshipment(int aValue);
00072 void AddDestination(int aSection);
00073 void RemoveDestination(int aSection);
00074
00075 private:
00076 int mID;
00077 int mLength;
00078 int mContainers;
00079 int mImport, mExport, mTranshipment;
00080 int mStartTimeZone, mEndTimeZone;
00081 int mArrival, mDeparture;
00082 int mSection;
00083 set<int> mNeighbours;
00084 set<int> mPotentialDestinations;
00085 };
00086
00087
00088 #endif