[][src]Struct saphir::server::ListenerBuilder

pub struct ListenerBuilder { /* fields omitted */ }

Methods

impl ListenerBuilder[src]

pub fn new() -> Self[src]

pub fn set_thread_pool_size(self, size: usize) -> Self[src]

Set the thread_pool size for request handling, default is number of available CPU

pub fn set_request_timeout_ms(self, timeout: u64) -> Self[src]

Set the default timeout for request in milliseconds. 0 means no timeout.

pub fn set_uri(self, uri: &str) -> Self[src]

Set the listener uri (supported format is ://:)

pub fn set_ssl_certificates(self, cert_path: &str, key_path: &str) -> Self[src]

Set the listener ssl certificates files. The cert needs to be PEM encoded while the key can be either RSA or PKCS8

pub fn set_ssl_config(
    self,
    cert_config: SslConfig,
    key_config: SslConfig
) -> Self
[src]

Set the listener ssl config. The cert needs to be PEM encoded while the key can be either RSA or PKCS8. The file path can be used or the file content directly where all \n and space have been removed.

pub fn build(self) -> ListenerConfig[src]

Builds a new Listener Configuration

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.