Struct htsget_lambda::Config
source · pub struct Config { /* private fields */ }
Expand description
Configuration for the htsget server.
Implementations§
source§impl Config
impl Config
sourcepub fn new(
formatting: FormattingStyle,
ticket_server: TicketServerConfig,
data_server: DataServerConfig,
service_info: ServiceInfo,
resolvers: Vec<Resolver, Global>
) -> Config
pub fn new( formatting: FormattingStyle, ticket_server: TicketServerConfig, data_server: DataServerConfig, service_info: ServiceInfo, resolvers: Vec<Resolver, Global> ) -> Config
Create a new config.
sourcepub fn parse_args_with_command(
augment_args: Command
) -> Result<Option<PathBuf>, Error>
pub fn parse_args_with_command( augment_args: Command ) -> Result<Option<PathBuf>, Error>
Parse the command line arguments. Returns the config path, or prints the default config.
Augment the Command
args from the clap
parser. Returns an error if the
sourcepub fn parse_args() -> Option<PathBuf>
pub fn parse_args() -> Option<PathBuf>
Parse the command line arguments. Returns the config path, or prints the default config.
sourcepub fn setup_tracing(&self) -> Result<(), Error>
pub fn setup_tracing(&self) -> Result<(), Error>
Setup tracing, using a global subscriber.
sourcepub fn formatting_style(&self) -> FormattingStyle
pub fn formatting_style(&self) -> FormattingStyle
Get the formatting style.
sourcepub fn ticket_server(&self) -> &TicketServerConfig
pub fn ticket_server(&self) -> &TicketServerConfig
Get the ticket server.
sourcepub fn data_server(&self) -> &DataServerConfig
pub fn data_server(&self) -> &DataServerConfig
Get the data server.
sourcepub fn into_data_server(self) -> DataServerConfig
pub fn into_data_server(self) -> DataServerConfig
Get the owned data server.
sourcepub fn service_info(&self) -> &ServiceInfo
pub fn service_info(&self) -> &ServiceInfo
Get service info.
sourcepub fn owned_resolvers(self) -> Vec<Resolver, Global>
pub fn owned_resolvers(self) -> Vec<Resolver, Global>
Get owned resolvers.
sourcepub fn resolvers_from_data_server_config(self) -> Config
pub fn resolvers_from_data_server_config(self) -> Config
Set the local resolvers from the data server config.
Trait Implementations§
source§impl<'de> Deserialize<'de> for Configwhere
Config: Default,
impl<'de> Deserialize<'de> for Configwhere Config: Default,
source§fn deserialize<__D>(
__deserializer: __D
) -> Result<Config, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>( __deserializer: __D ) -> Result<Config, <__D as Deserializer<'de>>::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Serialize for Config
impl Serialize for Config
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
Auto Trait Implementations§
impl !RefUnwindSafe for Config
impl Send for Config
impl Sync for Config
impl Unpin for Config
impl !UnwindSafe for Config
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more