#[repr(C)]
pub struct esp_websocket_client_config_t {
Show 31 fields pub uri: *const c_char, pub host: *const c_char, pub port: c_int, pub username: *const c_char, pub password: *const c_char, pub path: *const c_char, pub disable_auto_reconnect: bool, pub user_context: *mut c_void, pub task_prio: c_int, pub task_stack: c_int, pub buffer_size: c_int, pub cert_pem: *const c_char, pub cert_len: usize, pub client_cert: *const c_char, pub client_cert_len: usize, pub client_key: *const c_char, pub client_key_len: usize, pub transport: esp_websocket_transport_t, pub subprotocol: *const c_char, pub user_agent: *const c_char, pub headers: *const c_char, pub pingpong_timeout_sec: c_int, pub disable_pingpong_discon: bool, pub use_global_ca_store: bool, pub skip_cert_common_name_check: bool, pub keep_alive_enable: bool, pub keep_alive_idle: c_int, pub keep_alive_interval: c_int, pub keep_alive_count: c_int, pub ping_interval_sec: usize, pub if_name: *mut ifreq,
}
Expand description

@brief Websocket client setup configuration

Fields

uri: *const c_char

< Websocket URI, the information on the URI can be overrides the other fields below, if any

host: *const c_char

< Domain or IP as string

port: c_int

< Port to connect, default depend on esp_websocket_transport_t (80 or 443)

username: *const c_char

< Using for Http authentication - Not supported for now

password: *const c_char

< Using for Http authentication - Not supported for now

path: *const c_char

< HTTP Path, if not set, default is /

disable_auto_reconnect: bool

< Disable the automatic reconnect function when disconnected

user_context: *mut c_void

< HTTP user data context

task_prio: c_int

< Websocket task priority

task_stack: c_int

< Websocket task stack

buffer_size: c_int

< Websocket buffer size

cert_pem: *const c_char

< Pointer to certificate data in PEM or DER format for server verify (with SSL), default is NULL, not required to verify the server. PEM-format must have a terminating NULL-character. DER-format requires the length to be passed in cert_len.

cert_len: usize

< Length of the buffer pointed to by cert_pem. May be 0 for null-terminated pem

client_cert: *const c_char

< Pointer to certificate data in PEM or DER format for SSL mutual authentication, default is NULL, not required if mutual authentication is not needed. If it is not NULL, also client_key has to be provided. PEM-format must have a terminating NULL-character. DER-format requires the length to be passed in client_cert_len.

client_cert_len: usize

< Length of the buffer pointed to by client_cert. May be 0 for null-terminated pem

client_key: *const c_char

< Pointer to private key data in PEM or DER format for SSL mutual authentication, default is NULL, not required if mutual authentication is not needed. If it is not NULL, also client_cert has to be provided. PEM-format must have a terminating NULL-character. DER-format requires the length to be passed in client_key_len

client_key_len: usize

< Length of the buffer pointed to by client_key_pem. May be 0 for null-terminated pem

transport: esp_websocket_transport_t

< Websocket transport type, see `esp_websocket_transport_t

subprotocol: *const c_char

< Websocket subprotocol

user_agent: *const c_char

< Websocket user-agent

headers: *const c_char

< Websocket additional headers

pingpong_timeout_sec: c_int

< Period before connection is aborted due to no PONGs received

disable_pingpong_discon: bool

< Disable auto-disconnect due to no PONG received within pingpong_timeout_sec

use_global_ca_store: bool

< Use a global ca_store for all the connections in which this bool is set.

skip_cert_common_name_check: bool

< Skip any validation of server certificate CN field

keep_alive_enable: bool

< Enable keep-alive timeout

keep_alive_idle: c_int

< Keep-alive idle time. Default is 5 (second)

keep_alive_interval: c_int

< Keep-alive interval time. Default is 5 (second)

keep_alive_count: c_int

< Keep-alive packet retry send count. Default is 3 counts

ping_interval_sec: usize

< Websocket ping interval, defaults to 10 seconds if not set

if_name: *mut ifreq

< The name of interface for data to go through. Use the default interface without setting

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.