Struct htsget_lambda::DataServerConfig
source · pub struct DataServerConfig { /* private fields */ }
Expand description
Configuration for the htsget server.
Implementations§
source§impl DataServerConfig
impl DataServerConfig
sourcepub fn new(
enabled: bool,
addr: SocketAddr,
local_path: PathBuf,
serve_at: PathBuf,
tls: Option<CertificateKeyPair>,
cors: CorsConfig
) -> DataServerConfig
pub fn new( enabled: bool, addr: SocketAddr, local_path: PathBuf, serve_at: PathBuf, tls: Option<CertificateKeyPair>, cors: CorsConfig ) -> DataServerConfig
Create a new data server config.
sourcepub fn addr(&self) -> SocketAddr
pub fn addr(&self) -> SocketAddr
Get the address.
sourcepub fn local_path(&self) -> &Path
pub fn local_path(&self) -> &Path
Get the local path.
sourcepub fn tls(&self) -> Option<&CertificateKeyPair>
pub fn tls(&self) -> Option<&CertificateKeyPair>
Get the TLS config
sourcepub fn into_tls(self) -> Option<CertificateKeyPair>
pub fn into_tls(self) -> Option<CertificateKeyPair>
Get the TLS config
sourcepub fn cors(&self) -> &CorsConfig
pub fn cors(&self) -> &CorsConfig
Get cors config.
sourcepub fn allow_credentials(&self) -> bool
pub fn allow_credentials(&self) -> bool
Get allow credentials.
sourcepub fn allow_origins(&self) -> &AllowType<HeaderValue, TaggedAllowTypes>
pub fn allow_origins(&self) -> &AllowType<HeaderValue, TaggedAllowTypes>
Get allow origins.
sourcepub fn allow_headers(&self) -> &AllowType<HeaderName, TaggedTypeAll>
pub fn allow_headers(&self) -> &AllowType<HeaderName, TaggedTypeAll>
Get allow headers.
sourcepub fn allow_methods(&self) -> &AllowType<Method, TaggedTypeAll>
pub fn allow_methods(&self) -> &AllowType<Method, TaggedTypeAll>
Get allow methods.
sourcepub fn expose_headers(&self) -> &AllowType<HeaderName, TaggedTypeAll>
pub fn expose_headers(&self) -> &AllowType<HeaderName, TaggedTypeAll>
Get the expose headers.
Trait Implementations§
source§impl Clone for DataServerConfig
impl Clone for DataServerConfig
source§fn clone(&self) -> DataServerConfig
fn clone(&self) -> DataServerConfig
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 DataServerConfig
impl Debug for DataServerConfig
source§impl Default for DataServerConfig
impl Default for DataServerConfig
source§fn default() -> DataServerConfig
fn default() -> DataServerConfig
Returns the “default value” for a type. Read more
source§impl<'de> Deserialize<'de> for DataServerConfigwhere
DataServerConfig: Default,
impl<'de> Deserialize<'de> for DataServerConfigwhere DataServerConfig: Default,
source§fn deserialize<__D>(
__deserializer: __D
) -> Result<DataServerConfig, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>( __deserializer: __D ) -> Result<DataServerConfig, <__D as Deserializer<'de>>::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Serialize for DataServerConfig
impl Serialize for DataServerConfig
source§fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>( &self, __serializer: __S ) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where __S: Serializer,
Serialize this value into the given Serde serializer. Read more