pub trait ReaderWithOptions<T>: Sealed {
    type Error;
    type Item;
    type Options;

    // Required method
    fn read(
        source: T,
        options: &Self::Options
    ) -> Result<Self::Item, Self::Error>;
}
Expand description

A trait that enables reading from various sources, with configuration options.

Required Associated Types§

Required Methods§

source

fn read(source: T, options: &Self::Options) -> Result<Self::Item, Self::Error>

Reads an instance of Self::Item from the given source, using the given options.

Object Safety§

This trait is not object safe.

Implementors§

source§

impl ReaderWithOptions<&File> for ba2::fo4::File<'static>

§

type Error = Error

§

type Item = File<'static>

§

type Options = ReadOptions

source§

impl ReaderWithOptions<&File> for ba2::tes4::File<'static>

§

type Error = Error

§

type Item = File<'static>

§

type Options = ReadOptions

source§

impl ReaderWithOptions<&Path> for ba2::fo4::File<'static>

§

type Error = Error

§

type Item = File<'static>

§

type Options = ReadOptions

source§

impl ReaderWithOptions<&Path> for ba2::tes4::File<'static>

§

type Error = Error

§

type Item = File<'static>

§

type Options = ReadOptions

source§

impl<'bytes> ReaderWithOptions<Borrowed<'bytes>> for ba2::fo4::File<'bytes>

§

type Error = Error

§

type Item = File<'bytes>

§

type Options = ReadOptions

source§

impl<'bytes> ReaderWithOptions<Borrowed<'bytes>> for ba2::tes4::File<'bytes>

§

type Error = Error

§

type Item = File<'bytes>

§

type Options = ReadOptions

source§

impl<'bytes> ReaderWithOptions<Copied<'bytes>> for ba2::fo4::File<'static>

§

type Error = Error

§

type Item = File<'static>

§

type Options = ReadOptions

source§

impl<'bytes> ReaderWithOptions<Copied<'bytes>> for ba2::tes4::File<'static>

§

type Error = Error

§

type Item = File<'static>

§

type Options = ReadOptions