gio::prelude

Trait ConverterExt

source
pub trait ConverterExt:
    IsA<Converter>
    + Sealed
    + 'static {
    // Provided methods
    fn convert_bytes(&self, bytes: &Bytes) -> Result<Bytes, Error> { ... }
    fn reset(&self) { ... }
}
Expand description

Trait containing all Converter methods.

§Implementors

CharsetConverter, Converter, ZlibCompressor, ZlibDecompressor

Provided Methods§

source

fn convert_bytes(&self, bytes: &Bytes) -> Result<Bytes, Error>

Available on crate feature v2_82 only.

Applies @self to the data in @bytes.

§bytes

the data to convert

§Returns

A newly-allocated GBytes with the converted data, or NULL if an error occurred

source

fn reset(&self)

Resets all internal state in the converter, making it behave as if it was just created. If the converter has any internal state that would produce output then that output is lost.

Object Safety§

This trait is not object safe.

Implementors§