pub trait ApplyApChange: Sized {
    fn apply_known_ap_change(self, ap_change: usize) -> Option<Self>;
    fn can_apply_unknown(&self) -> bool;

    fn apply_ap_change(self, ap_change: ApChange) -> Result<Self, ApChangeError> { ... }
    fn unchecked_apply_known_ap_change(self, ap_change: usize) -> Self { ... }
}
Expand description

Trait for applying ap changes.

Required Methods§

Attempts to apply ap change, fail on overflow only.

Can unknown ap change be applied.

Provided Methods§

Attempts to apply ap change.

Same as Self::apply_known_ap_change but unchecked.

Implementors§