Struct rust_tdlib::types::SetNetworkType
source · pub struct SetNetworkType { /* private fields */ }
Expand description
Sets the current network type. Can be called before authorization. Calling this method forces all network connections to reopen, mitigating the delay in switching between different networks, so it must be called whenever the network is changed, even if the network type remains the same. Network type is used to check whether the library can use the network at all and also for collecting detailed network data usage statistics
Implementations§
Trait Implementations§
source§impl AsRef<SetNetworkType> for SetNetworkType
impl AsRef<SetNetworkType> for SetNetworkType
source§fn as_ref(&self) -> &SetNetworkType
fn as_ref(&self) -> &SetNetworkType
Converts this type into a shared reference of the (usually inferred) input type.
source§impl Clone for SetNetworkType
impl Clone for SetNetworkType
source§fn clone(&self) -> SetNetworkType
fn clone(&self) -> SetNetworkType
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 SetNetworkType
impl Debug for SetNetworkType
source§impl Default for SetNetworkType
impl Default for SetNetworkType
source§fn default() -> SetNetworkType
fn default() -> SetNetworkType
Returns the “default value” for a type. Read more
source§impl<'de> Deserialize<'de> for SetNetworkType
impl<'de> Deserialize<'de> for SetNetworkType
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