pub trait CountsNonmotonically {
// Required methods
fn can_inc(&self) -> bool;
fn inc_one(&self);
fn is_incrementable(&self) -> bool;
fn is_at_increment_bound(&self) -> bool;
fn is_within_increment_bound(&self) -> bool;
fn can_dec(&self) -> bool;
fn dec_one(&self);
fn is_decrementable(&self) -> bool;
fn is_at_decrement_bound(&self) -> bool;
fn is_within_decrement_bound(&self) -> bool;
}Expand description
Something that can counts up or down
Required Methods§
Sourcefn is_incrementable(&self) -> bool
fn is_incrementable(&self) -> bool
Is it incrementable based on internal counting behavior settings?
Sourcefn is_at_increment_bound(&self) -> bool
fn is_at_increment_bound(&self) -> bool
Is it at the increment bound?
Sourcefn is_within_increment_bound(&self) -> bool
fn is_within_increment_bound(&self) -> bool
Is it within the increment bound?
Sourcefn is_decrementable(&self) -> bool
fn is_decrementable(&self) -> bool
Is it incrementable based on internal counting behavior settings?
Sourcefn is_at_decrement_bound(&self) -> bool
fn is_at_decrement_bound(&self) -> bool
Is it at the decrement bound?
Sourcefn is_within_decrement_bound(&self) -> bool
fn is_within_decrement_bound(&self) -> bool
Is it within the decrement bound?