16 FareFeatures::FareFeatures()
28 FareFeatures::FareFeatures (
const FareFeatures& iFeatures)
29 : _key (iFeatures.getKey()), _parent (NULL) {
33 FareFeatures::FareFeatures (
const Key_T& iKey)
34 : _key (iKey), _parent (NULL) {
43 std::ostringstream oStr;
51 bool oIsTripTypeValidFlag =
true;
56 if (iBookingRequestTripType == lFareTripType) {
58 return oIsTripTypeValidFlag;
65 return oIsTripTypeValidFlag;
69 oIsTripTypeValidFlag =
false;
70 return oIsTripTypeValidFlag;
79 if (lMinimumDayDuration > iStayDuration) {
90 bool oIsAdvancePurchaseValidFlag =
true;
94 const DateOffset_T lMinimumAdvancedPurchase (lAdvancedPurchase);
95 const DateTime_T lCriticalDate = iFlightDateTime - lMinimumAdvancedPurchase;
97 if (lCriticalDate < iBookingRequestDateTime) {
98 oIsAdvancePurchaseValidFlag =
false;
99 return oIsAdvancePurchaseValidFlag;
boost::posix_time::ptime DateTime_T
Handle on the StdAir library context.
bool isAdvancePurchaseValid(const DateTime_T &iBookingRequestDateTime, const DateTime_T &iFlightDateTime) const
const TripType_T TRIP_TYPE_OUTBOUND
std::string toString() const
const std::string describeKey() const
const DayDuration_T NO_STAY_DURATION
const DayDuration_T & getMinimumStay() const
const TripType_T TRIP_TYPE_INBOUND
const TripType_T & getTripType() const
const SaturdayStay_T SATURDAY_STAY
const TripType_T TRIP_TYPE_ONE_WAY
const NonRefundable_T NON_REFUNDABLE
const DayDuration_T NO_ADVANCE_PURCHASE
bool isStayDurationValid(const DayDuration_T &) const
boost::gregorian::date_duration DateOffset_T
const DayDuration_T & getAdvancePurchase() const
const ChangeFees_T CHANGE_FEES
const TripType_T TRIP_TYPE_ROUND_TRIP
bool isTripTypeValid(const TripType_T &) const