Struct botapi::gen_types::LabeledPriceBuilder
source · pub struct LabeledPriceBuilder { /* private fields */ }
Expand description
This object represents a portion of the price for goods or services.
Implementations§
source§impl LabeledPriceBuilder
impl LabeledPriceBuilder
pub fn new(label: String, amount: i64) -> Self
sourcepub fn set_amount(self, amount: i64) -> Self
pub fn set_amount(self, amount: i64) -> Self
Price of the product in the smallest units of the currency (integer, not float/double). For example, for a price of US$ 1.45 pass amount = 145. See the exp parameter in currencies.json, it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).
pub fn build(self) -> LabeledPrice
Trait Implementations§
source§impl Clone for LabeledPriceBuilder
impl Clone for LabeledPriceBuilder
source§fn clone(&self) -> LabeledPriceBuilder
fn clone(&self) -> LabeledPriceBuilder
Returns a copy 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 LabeledPriceBuilder
impl Debug for LabeledPriceBuilder
source§impl Default for LabeledPriceBuilder
impl Default for LabeledPriceBuilder
source§fn default() -> LabeledPriceBuilder
fn default() -> LabeledPriceBuilder
Returns the “default value” for a type. Read more
source§impl<'de> Deserialize<'de> for LabeledPriceBuilder
impl<'de> Deserialize<'de> for LabeledPriceBuilder
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