00001 #ifndef __RMOL_BOM_BUCKET_HPP 00002 #define __RMOL_BOM_BUCKET_HPP 00003 00004 // ////////////////////////////////////////////////////////////////////// 00005 // Import section 00006 // ////////////////////////////////////////////////////////////////////// 00007 // RMOL 00008 #include <rmol/field/FldYieldRange.hpp> 00009 #include <rmol/field/FldDistributionParameters.hpp> 00010 #include <rmol/bom/BomAbstract.hpp> 00011 00012 namespace RMOL { 00013 00015 class Demand; 00016 00047 class Bucket : public BomAbstract { 00051 friend class FacBucket; 00052 friend class FacBucketHolder; 00053 00054 public: 00055 // ///////// Getters //////// 00057 const FldYieldRange& getYieldRange() const { 00058 return _yieldRange; 00059 } 00061 double getProtection() const { 00062 return _protection; 00063 } 00065 double getCumulatedProtection() const { 00066 return _cumulatedProtection; 00067 } 00069 double getCumulatedBookingLimit() const { 00070 return _cumulatedBookingLimit; 00071 } 00073 double getBookingLimit() const { 00074 return _bookingLimit; 00075 } 00076 00078 const FldDistributionParameters& getDistributionParameters() const; 00079 00081 const double getMean() const; 00082 00084 const double getStandardDeviation() const; 00085 00087 const double getUpperYield() const; 00088 00090 const double getAverageYield() const; 00091 00093 const double getLowerYield() const; 00094 00095 00096 // ///////// Setters //////// 00098 void setProtection (const double iProtection) { 00099 _protection = iProtection; 00100 } 00101 00103 void setCumulatedProtection (const double iProtection) { 00104 _cumulatedProtection = iProtection; 00105 } 00106 00108 void setBookingLimit (const double iBookingLimit) { 00109 _bookingLimit = iBookingLimit; 00110 } 00111 00113 void setCumulatedBookingLimit (const double iBookingLimit) { 00114 _cumulatedBookingLimit = iBookingLimit; 00115 } 00116 00118 void setDemand (Demand& iDemand); 00119 00121 void setYieldRange (const double iYield); 00122 00124 void setDemandParameters (const double, const double); 00125 00126 public: 00127 // ///////// Display methods //////// 00130 void toStream (std::ostream&) const; 00131 00134 void fromStream (std::istream&); 00135 00137 std::string toString() const; 00138 00141 const std::string describeKey() const; 00142 00145 const std::string describeShortKey() const; 00146 00148 const std::string display() const; 00149 00151 const std::string shortDisplay() const; 00152 00153 00154 private: 00157 Bucket (); 00158 Bucket (const Bucket&); 00159 Bucket (const FldYieldRange&); 00161 virtual ~Bucket(); 00162 00164 Demand& getDemand() const; 00165 00166 private: 00168 Demand* _demand; 00169 00171 FldYieldRange _yieldRange; 00172 00174 double _protection; 00175 00177 double _cumulatedProtection; 00178 00180 double _bookingLimit; 00181 00183 double _cumulatedBookingLimit; 00184 }; 00185 } 00186 #endif // __RMOL_BOM_BUCKET_HPP
Generated on Fri Sep 11 06:31:59 2009 for RMOL by Doxygen 1.5.8