pub struct ProxyEncoder { /* private fields */ }Expand description
Proxy encoder with support for various codecs and settings.
Implementations§
Source§impl ProxyEncoder
impl ProxyEncoder
Sourcepub fn new(settings: ProxyGenerationSettings) -> Result<Self>
pub fn new(settings: ProxyGenerationSettings) -> Result<Self>
Create a new proxy encoder with the given settings.
Sourcepub async fn encode(
&self,
input: &Path,
output: &Path,
) -> Result<ProxyEncodeResult>
pub async fn encode( &self, input: &Path, output: &Path, ) -> Result<ProxyEncodeResult>
Encode a proxy from the input file.
§Errors
Returns an error if:
- Input file does not exist or cannot be read
- Output path is invalid
- Encoding fails
Sourcepub fn settings(&self) -> &ProxyGenerationSettings
pub fn settings(&self) -> &ProxyGenerationSettings
Get the current settings.
Sourcepub fn set_settings(&mut self, settings: ProxyGenerationSettings) -> Result<()>
pub fn set_settings(&mut self, settings: ProxyGenerationSettings) -> Result<()>
Update the settings.
Auto Trait Implementations§
impl Freeze for ProxyEncoder
impl RefUnwindSafe for ProxyEncoder
impl Send for ProxyEncoder
impl Sync for ProxyEncoder
impl Unpin for ProxyEncoder
impl UnsafeUnpin for ProxyEncoder
impl UnwindSafe for ProxyEncoder
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more