pub struct PromotionCode {
pub code: String,
pub issuer: Option<Option<String>>,
}Expand description
PromotionCode : The promotion code is a token that reduces the price at POST booking time OR Token that reduces the price at POST trip-offer-collection time OR Token to receive offers that are not available without it.
Fields§
§code: StringThe code issued by the issuer
issuer: Option<Option<String>>The party that issues the promotion code, in case of a railway it’s its RICS code
Implementations§
Source§impl PromotionCode
impl PromotionCode
Sourcepub fn new(code: String) -> PromotionCode
pub fn new(code: String) -> PromotionCode
The promotion code is a token that reduces the price at POST booking time OR Token that reduces the price at POST trip-offer-collection time OR Token to receive offers that are not available without it.
Trait Implementations§
Source§impl Clone for PromotionCode
impl Clone for PromotionCode
Source§fn clone(&self) -> PromotionCode
fn clone(&self) -> PromotionCode
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PromotionCode
impl Debug for PromotionCode
Source§impl Default for PromotionCode
impl Default for PromotionCode
Source§fn default() -> PromotionCode
fn default() -> PromotionCode
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for PromotionCode
impl<'de> Deserialize<'de> for PromotionCode
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for PromotionCode
impl PartialEq for PromotionCode
Source§impl Serialize for PromotionCode
impl Serialize for PromotionCode
impl StructuralPartialEq for PromotionCode
Auto Trait Implementations§
impl Freeze for PromotionCode
impl RefUnwindSafe for PromotionCode
impl Send for PromotionCode
impl Sync for PromotionCode
impl Unpin for PromotionCode
impl UnwindSafe for PromotionCode
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more