pub struct ClientBuilder { /* private fields */ }Implementations§
Source§impl ClientBuilder
impl ClientBuilder
pub fn new() -> Self
pub fn set_api_id(&mut self, api_id: i32)
pub fn with_api_id(self, api_id: i32) -> Self
pub fn set_api_hash<S: Into<String>>(&mut self, api_hash: S)
pub fn with_api_hash<S: Into<String>>(self, api_hash: S) -> Self
pub fn set_auth(&mut self, auth: Auth)
pub fn with_auth(self, auth: Auth) -> Self
pub fn set_session_store( &mut self, session_store: Box<dyn SessionStore + Sync + Send>, )
pub fn with_session_store( self, session_store: Box<dyn SessionStore + Sync + Send>, ) -> Self
pub fn set_modules<S: Into<Arc<Vec<Module>>>>(&mut self, s: S)
pub fn with_modules<S: Into<Arc<Vec<Module>>>>(self, s: S) -> Self
pub fn set_init_params(&mut self, s: Option<InitParams>)
pub fn with_init_params(self, s: Option<InitParams>) -> Self
pub fn build(self) -> Result<Client>
Auto Trait Implementations§
impl Freeze for ClientBuilder
impl !RefUnwindSafe for ClientBuilder
impl Send for ClientBuilder
impl Sync for ClientBuilder
impl Unpin for ClientBuilder
impl !UnwindSafe for ClientBuilder
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