Struct partial_function::PartialFunction [−][src]
pub struct PartialFunction<B, O> where
B: PartialOrd, { /* fields omitted */ }
Define a functions defined by multiple functions parts. See BoundedFunction. Uses bounds as [lower,higher], except in the case of a lower bound overlapping a higher bound. In this case, the lower bound always take precedence.
Methods
impl<B, O> PartialFunction<B, O> where
B: PartialOrd,
[src]
impl<B, O> PartialFunction<B, O> where
B: PartialOrd,
pub fn new() -> PartialFunctionBuilder<B, O>
[src]
pub fn new() -> PartialFunctionBuilder<B, O>
Creates a new PartialFunctionBuilder
pub fn eval(&self, x: B) -> Option<O>
[src]
pub fn eval(&self, x: B) -> Option<O>
Evaluates the partial function. Returns None if no function is defined.
Auto Trait Implementations
impl<B, O> Send for PartialFunction<B, O> where
B: Send,
impl<B, O> Send for PartialFunction<B, O> where
B: Send,
impl<B, O> Sync for PartialFunction<B, O> where
B: Sync,
impl<B, O> Sync for PartialFunction<B, O> where
B: Sync,