[−][src]Trait streamcatcher::Transform
Allows an input bytestream to be modified before it is stored.
Must be implemented alongside NeedsBytes in a functional transform.
Required methods
fn transform_read(
&mut self,
src: &mut TInput,
buf: &mut [u8]
) -> IoResult<TransformPosition>
&mut self,
src: &mut TInput,
buf: &mut [u8]
) -> IoResult<TransformPosition>
Data transform, given access to the underlying Read
object and the destination buffer.
Transforms are free to make no change to buf
without marking the stream as finalised:
see TransformPosition for the semantics.
Implementors
impl<T: Read> Transform<T> for Identity
[src]
fn transform_read(
&mut self,
src: &mut T,
buf: &mut [u8]
) -> IoResult<TransformPosition>
[src]
&mut self,
src: &mut T,
buf: &mut [u8]
) -> IoResult<TransformPosition>