Struct matrix_sdk::ClientConfig [−][src]
pub struct ClientConfig { /* fields omitted */ }
Expand description
Configuration for the creation of the Client
.
When setting the StateStore
it is up to the user to open/connect
the storage backend before client creation.
Example
// To pass all the request through mitmproxy set the proxy and disable SSL
// verification
let client_config = ClientConfig::new()
.proxy("http://localhost:8080")
.unwrap()
.disable_ssl_verification();
Implementations
Disable SSL verification for the HTTP requests.
Set a custom HTTP user agent for the client.
Set the path for storage.
Arguments
path
- The path where the stores should save data in. It is the callers responsibility to make sure that the path exists.
In the default configuration the client will open default implementations for the crypto store and the state store. It will use the given path to open the stores. If no path is provided no store will be opened
Set the passphrase to encrypt the crypto store.
Argument
passphrase
- The passphrase that will be used to encrypt the data in the cryptostore.
This is only used if no custom cryptostore is set.
Set the default timeout, fail and retry behavior for all HTTP requests.
Get the RequestConfig
Trait Implementations
Returns the “default value” for a type. Read more
Auto Trait Implementations
impl !RefUnwindSafe for ClientConfig
impl Send for ClientConfig
impl Sync for ClientConfig
impl Unpin for ClientConfig
impl !UnwindSafe for ClientConfig
Blanket Implementations
Mutably borrows from an owned value. Read more
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more