pub struct PassportElementErrorTranslationFileBuilder { /* private fields */ }Expand description
Represents an issue with one of the files that constitute the translation of a document. The error is considered resolved when the file changes.
Implementations§
source§impl PassportElementErrorTranslationFileBuilder
impl PassportElementErrorTranslationFileBuilder
pub fn new(source: String, file_hash: String, message: String) -> Self
sourcepub fn set_source(self, source: String) -> Self
pub fn set_source(self, source: String) -> Self
Error source, must be translation_file
sourcepub fn set_type(self, tg_type: String) -> Self
pub fn set_type(self, tg_type: String) -> Self
Type of element of the user’s Telegram Passport which has the issue, one of “passport”, “driver_license”, “identity_card”, “internal_passport”, “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration”, “temporary_registration”
sourcepub fn set_file_hash(self, file_hash: String) -> Self
pub fn set_file_hash(self, file_hash: String) -> Self
Base64-encoded file hash
sourcepub fn set_message(self, message: String) -> Self
pub fn set_message(self, message: String) -> Self
Error message
pub fn build(self) -> PassportElementErrorTranslationFile
Trait Implementations§
source§impl Clone for PassportElementErrorTranslationFileBuilder
impl Clone for PassportElementErrorTranslationFileBuilder
source§fn clone(&self) -> PassportElementErrorTranslationFileBuilder
fn clone(&self) -> PassportElementErrorTranslationFileBuilder
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 Default for PassportElementErrorTranslationFileBuilder
impl Default for PassportElementErrorTranslationFileBuilder
source§fn default() -> PassportElementErrorTranslationFileBuilder
fn default() -> PassportElementErrorTranslationFileBuilder
Returns the “default value” for a type. Read more
source§impl<'de> Deserialize<'de> for PassportElementErrorTranslationFileBuilder
impl<'de> Deserialize<'de> for PassportElementErrorTranslationFileBuilder
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
Auto Trait Implementations§
impl RefUnwindSafe for PassportElementErrorTranslationFileBuilder
impl Send for PassportElementErrorTranslationFileBuilder
impl Sync for PassportElementErrorTranslationFileBuilder
impl Unpin for PassportElementErrorTranslationFileBuilder
impl UnwindSafe for PassportElementErrorTranslationFileBuilder
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