Trait combine::primitives::Positioner
[−]
[src]
pub trait Positioner: PartialEq { type Position: Clone + Ord; fn start() -> Self::Position; fn update(&self, position: &mut Self::Position); }
Trait for updating the position for types which can be yielded from a Stream.
Associated Types
Required Methods
fn start() -> Self::Position
Creates a start position
fn update(&self, position: &mut Self::Position)
Updates the position given that self has been taken from the stream
Implementations on Foreign Types
impl<'a, T: ?Sized> Positioner for &'a T where
T: Positioner, [src]
T: Positioner,
impl<T> Positioner for [T] where
T: Positioner, [src]
T: Positioner,
impl Positioner for str[src]
type Position = SourcePosition
fn start() -> SourcePosition[src]
fn update(&self, position: &mut SourcePosition)[src]
impl Positioner for char[src]
type Position = SourcePosition
fn start() -> SourcePosition[src]
fn update(&self, position: &mut SourcePosition)[src]
impl Positioner for u8[src]
type Position = BytePosition
fn start() -> BytePosition[src]
fn update(&self, b: &mut BytePosition)[src]
Implementors
impl<'a, T> Positioner for SliceStream<'a, T> where
T: Positioner + 'a, type Position = T::Position;