pub struct PerformanceBenchmark { /* private fields */ }
Expand description
Performance benchmark runner
Implementations§
Source§impl PerformanceBenchmark
impl PerformanceBenchmark
pub fn new(rules: Vec<Box<dyn Rule>>) -> Self
pub fn with_memory_measurement(self) -> Self
Sourcepub fn benchmark_rule(
&self,
rule: &dyn Rule,
content: &str,
) -> RulePerformanceResult
pub fn benchmark_rule( &self, rule: &dyn Rule, content: &str, ) -> RulePerformanceResult
Benchmark a single rule with given content
Sourcepub fn benchmark_all_rules(&self, content: &str) -> AggregatePerformanceResult
pub fn benchmark_all_rules(&self, content: &str) -> AggregatePerformanceResult
Benchmark all rules with given content
Sourcepub fn run_comprehensive_benchmark(
&self,
) -> HashMap<String, AggregatePerformanceResult>
pub fn run_comprehensive_benchmark( &self, ) -> HashMap<String, AggregatePerformanceResult>
Run comprehensive performance tests with different content sizes
Sourcepub fn print_performance_report(
&self,
results: &HashMap<String, AggregatePerformanceResult>,
)
pub fn print_performance_report( &self, results: &HashMap<String, AggregatePerformanceResult>, )
Print detailed performance report
Auto Trait Implementations§
impl Freeze for PerformanceBenchmark
impl !RefUnwindSafe for PerformanceBenchmark
impl Send for PerformanceBenchmark
impl Sync for PerformanceBenchmark
impl Unpin for PerformanceBenchmark
impl !UnwindSafe for PerformanceBenchmark
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more