pub struct BenchmarkArgs {
pub pages: usize,
pub algorithm: String,
pub pattern: String,
}Expand description
Arguments for benchmark command.
Fields§
§pages: usizeNumber of pages to compress.
Short form is -n, not -p: pattern below explicitly claims -p,
and a derived short here claimed it too. clap catches that in a
debug_assert, so EVERY trueno-zram benchmark invocation – including
--help – panicked before reaching this code. Nothing ever ran the
command, so nothing noticed.
algorithm: StringAlgorithm to benchmark (lz4, zstd, all).
pattern: StringData pattern (zero, random, text, mixed).
Trait Implementations§
Source§impl Args for BenchmarkArgs
impl Args for BenchmarkArgs
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
Append to
Command so it can instantiate self via
FromArgMatches::update_from_arg_matches_mut Read moreSource§impl Debug for BenchmarkArgs
impl Debug for BenchmarkArgs
Source§impl FromArgMatches for BenchmarkArgs
impl FromArgMatches for BenchmarkArgs
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>
Assign values from
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>
Assign values from
ArgMatches to self.Auto Trait Implementations§
impl Freeze for BenchmarkArgs
impl RefUnwindSafe for BenchmarkArgs
impl Send for BenchmarkArgs
impl Sync for BenchmarkArgs
impl Unpin for BenchmarkArgs
impl UnsafeUnpin for BenchmarkArgs
impl UnwindSafe for BenchmarkArgs
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