pub struct GlobalFlags {
pub destination: DestinationFlags,
pub output: OutputFlags,
pub limits: LimitFlags,
pub safety: SafetyFlags,
pub diagnostics: DiagnosticFlags,
}Expand description
Every global flag, grouped by purpose.
Fields§
§destination: DestinationFlagsWhich server this invocation talks to.
output: OutputFlagsWhat the answer looks like and how much of it comes back.
limits: LimitFlagsThe ceilings on time and on simultaneous work.
safety: SafetyFlagsWhat this invocation is allowed to change.
diagnostics: DiagnosticFlagsWhat reaches the auxiliary channel, and in which language.
Implementations§
Source§impl GlobalFlags
impl GlobalFlags
Sourcepub fn pipeline(&self, config: &Config) -> Result<Pipeline>
pub fn pipeline(&self, config: &Config) -> Result<Pipeline>
Builds the output pipeline these flags describe.
The stored settings are read here rather than defaulted, because the
ceiling per cell is a published key and the mark on the command line is
only what overrides it. Building the pipeline from the mark alone, as
this once did, made output.truncate_cell a setting the product stored,
read back and reported as being in force while cutting nothing.
§Errors
Returns a usage failure when a filter expression is malformed, so a typo is refused rather than silently matching nothing, and a config failure when a stored value is outside its domain.
Sourcepub fn refuse_a_profile_over_a_flow(&self, shape: OutputFormat) -> Result<()>
pub fn refuse_a_profile_over_a_flow(&self, shape: OutputFormat) -> Result<()>
Refuses a profile of the whole set written as a continuous flow.
FR-040 refuses this combination outright rather than quietly gathering: a caller who asked for a flow AND for a profile of the whole set asked for two things that cannot both hold, and silently honouring one of them would answer a question nobody put.
The shape is taken as the resolved one rather than read from the mark on the command line. Reading the mark, as this once did, let a caller who had stored a line-oriented shape ask for a profile and receive one, while a caller who wrote the same shape on the command line was refused — the same request answered two ways by where the shape was written.
§Errors
Returns a usage failure when a profile was asked for over a shape that carries one record per line.
Trait Implementations§
Source§impl Args for GlobalFlags
impl Args for GlobalFlags
Source§fn augment_args<'b>(__clap_app: Command) -> Command
fn augment_args<'b>(__clap_app: Command) -> Command
Source§fn augment_args_for_update<'b>(__clap_app: Command) -> Command
fn augment_args_for_update<'b>(__clap_app: Command) -> Command
Command so it can instantiate self via
FromArgMatches::update_from_arg_matches_mut Read moreSource§impl Clone for GlobalFlags
impl Clone for GlobalFlags
Source§impl Debug for GlobalFlags
impl Debug for GlobalFlags
Source§impl FromArgMatches for GlobalFlags
impl FromArgMatches for GlobalFlags
Source§fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
Source§fn from_arg_matches_mut(
__clap_arg_matches: &mut ArgMatches,
) -> Result<Self, Error>
fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches, ) -> Result<Self, Error>
Source§fn update_from_arg_matches(
&mut self,
__clap_arg_matches: &ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches, ) -> Result<(), Error>
ArgMatches to self.Source§fn update_from_arg_matches_mut(
&mut self,
__clap_arg_matches: &mut ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches_mut( &mut self, __clap_arg_matches: &mut ArgMatches, ) -> Result<(), Error>
ArgMatches to self.