pub trait NumericProperty<'t>: Property<'t> {
    // Required methods
    fn add(&self, value: <Self as Property<'t>>::Type);
    fn subtract(&self, value: <Self as Property<'t>>::Type);
    fn get(&self) -> Result<<Self as Property<'t>>::Type, Error>;
}
Expand description

Trait implemented by numeric properties providing common operations.

Required Methods§

source

fn add(&self, value: <Self as Property<'t>>::Type)

Add the given |value| to the property current value.

source

fn subtract(&self, value: <Self as Property<'t>>::Type)

Subtract the given |value| from the property current value.

source

fn get(&self) -> Result<<Self as Property<'t>>::Type, Error>

Return the current value of the property for testing. NOTE: This is a temporary feature to aid unit test of Inspect clients. It will be replaced by a more comprehensive Read API implementation.

Implementors§