[][src]Trait ptero::context::Context

pub trait Context {
    pub fn get_current_text_mut(&mut self) -> Result<&mut String, ContextError>;
pub fn get_current_text(&self) -> Result<&String, ContextError>;
pub fn load_text(&mut self) -> Result<&str, ContextError>; }

Context with essential methods for every encoder/decoder.

Required methods

pub fn get_current_text_mut(&mut self) -> Result<&mut String, ContextError>[src]

Gets currently loaded cover text fragment mutably.

Returns

Result which is either &mut String or ContextError.

pub fn get_current_text(&self) -> Result<&String, ContextError>[src]

Gets currently loaded cover text fragment as read-only.

Returns

Result which is either &String or ContextError.

pub fn load_text(&mut self) -> Result<&str, ContextError>[src]

Loads next cover text fragment.

Returns

Result which is either &String or ContextError. Returned string is the newly loaded fragment.

Loading content...

Implementors

Loading content...