Skip to main content

CliContextLawsExt

Trait CliContextLawsExt 

Source
pub trait CliContextLawsExt<This, Commands>
where This: CliCommandsObserved<Commands = Commands>, Commands: Clone,
{ // Required method fn law_cli_within<Operation, Sources, Mode>( &self, operation: Operation, sources: Sources, mode: Mode, commands: &Commands, ) -> CliLawResult where This: CliContextAlg<Operation, Sources, Mode, InnerCommands = Commands, Commands = Commands>, Operation: OperationAlg, Sources: CliSources<Operation::Args> + CliNamedSources; }
Expand description

States that a context adds its global arguments to every command beneath it and changes nothing else.

Required Methods§

Source

fn law_cli_within<Operation, Sources, Mode>( &self, operation: Operation, sources: Sources, mode: Mode, commands: &Commands, ) -> CliLawResult
where This: CliContextAlg<Operation, Sources, Mode, InnerCommands = Commands, Commands = Commands>, Operation: OperationAlg, Sources: CliSources<Operation::Args> + CliNamedSources,

Checks that commands applied within operation describe the same commands, each taking the operation’s arguments, read from sources, ahead of any context it already had.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<This, Commands> CliContextLawsExt<This, Commands> for This
where This: CliCommandsObserved<Commands = Commands>, Commands: Clone,

States that a context adds its global arguments to every command beneath it and changes nothing else.