pub struct OfferSummary {
pub minimal_price: Box<Price>,
pub overall_service_class: Box<ServiceClass>,
pub overall_travel_class: Option<String>,
pub overall_accommodation_type: Option<String>,
pub overall_accommodation_sub_type: Option<String>,
pub overall_flexibility: String,
pub minimal_indicated_consumption: Option<Box<IndicatedConsumption>>,
}Expand description
OfferSummary : The offer summary indicates the most relevant service class, level, flexibility or accommodation that describe this offer, but this does not imply that these values exactly apply to all parts of the offer. Let’s consider, as a simplified example, a trip composed of two legs, one with both 1st and 2nd class, and one with only 2nd. On this trip, the railway is expected to propose one offer with overallServiceClass FIRST composed of one admission in 1st class on the first legs and one admission in 2nd class on the second one, plus a second offer with overallServiceClass SECOND composed of two second class admissions. Likewise for all ‘overall’ attributes. The purpose of these attributes is to convey to the client system the service class, level, flexibility and accommodation that best represent this offer so to facilitate presentation to the final user. The offerSummary must be provided for product based offers. It is not needed for fares.
Fields§
§minimal_price: Box<Price>§overall_service_class: Box<ServiceClass>§overall_travel_class: Option<String>Traditional first and second class.
overall_accommodation_type: Option<String>Accommodation type definition out of the Accommodation Type Code List Listed values here are examples.
overall_accommodation_sub_type: Option<String>Accommodation sub type definition out of the Accommodation Sub Type Code List Listed values here are examples.
overall_flexibility: String§minimal_indicated_consumption: Option<Box<IndicatedConsumption>>Implementations§
Source§impl OfferSummary
impl OfferSummary
Sourcepub fn new(
minimal_price: Price,
overall_service_class: ServiceClass,
overall_flexibility: String,
) -> OfferSummary
pub fn new( minimal_price: Price, overall_service_class: ServiceClass, overall_flexibility: String, ) -> OfferSummary
The offer summary indicates the most relevant service class, level, flexibility or accommodation that describe this offer, but this does not imply that these values exactly apply to all parts of the offer. Let’s consider, as a simplified example, a trip composed of two legs, one with both 1st and 2nd class, and one with only 2nd. On this trip, the railway is expected to propose one offer with overallServiceClass FIRST composed of one admission in 1st class on the first legs and one admission in 2nd class on the second one, plus a second offer with overallServiceClass SECOND composed of two second class admissions. Likewise for all ‘overall’ attributes. The purpose of these attributes is to convey to the client system the service class, level, flexibility and accommodation that best represent this offer so to facilitate presentation to the final user. The offerSummary must be provided for product based offers. It is not needed for fares.
Trait Implementations§
Source§impl Clone for OfferSummary
impl Clone for OfferSummary
Source§fn clone(&self) -> OfferSummary
fn clone(&self) -> OfferSummary
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more