Struct gstreamer::FormattedSegment

source ·
pub struct FormattedSegment<T: FormattedValueIntrinsic> { /* private fields */ }
Expand description

GLib type: Inline allocated boxed type with stack copy semantics.

Implementations§

source§

impl<T: FormattedValueIntrinsic> FormattedSegment<T>

source

pub fn as_ptr(&self) -> *mut GstSegment

source

pub unsafe fn from_glib_ptr_borrow<'a>(ptr: *const GstSegment) -> &'a Self

Borrows the underlying C value.

source

pub unsafe fn from_glib_ptr_borrow_mut<'a>(ptr: *mut GstSegment) -> &'a mut Self

Borrows the underlying C value mutably.

source§

impl FormattedSegment<GenericFormattedValue>

source

pub fn reset_with_format(&mut self, format: Format)

source

pub fn set_format(&mut self, format: Format)

source

pub fn downcast<T: FormattedValueIntrinsic>( self, ) -> Result<FormattedSegment<T>, Self>

source

pub fn downcast_ref<T: FormattedValueIntrinsic>( &self, ) -> Option<&FormattedSegment<T>>

source

pub fn downcast_mut<T: FormattedValueIntrinsic>( &mut self, ) -> Option<&mut FormattedSegment<T>>

source§

impl<T: FormattedValueIntrinsic> FormattedSegment<T>

source

pub fn new() -> Self

source

pub fn upcast(self) -> Segment

source

pub fn upcast_ref(&self) -> &Segment

source

pub fn reset(&mut self)

source

pub fn clip( &self, start: impl CompatibleFormattedValue<T>, stop: impl CompatibleFormattedValue<T>, ) -> Option<(T::FullRange, T::FullRange)>

source

pub fn do_seek( &mut self, rate: f64, flags: SeekFlags, start_type: SeekType, start: impl CompatibleFormattedValue<T>, stop_type: SeekType, stop: impl CompatibleFormattedValue<T>, ) -> Option<bool>

source

pub fn offset_running_time(&mut self, offset: i64) -> Result<(), BoolError>

source

pub fn set_running_time( &mut self, running_time: impl CompatibleFormattedValue<T>, ) -> Result<(), BoolError>

source

pub fn flags(&self) -> SegmentFlags

source

pub fn set_flags(&mut self, flags: SegmentFlags)

source

pub fn rate(&self) -> f64

source

pub fn set_rate(&mut self, rate: f64)

source

pub fn applied_rate(&self) -> f64

source

pub fn set_applied_rate(&mut self, applied_rate: f64)

source

pub fn format(&self) -> Format

source

pub fn base(&self) -> T::FullRange

source

pub fn set_base(&mut self, base: impl CompatibleFormattedValue<T>)

source

pub fn offset(&self) -> T::FullRange

source

pub fn set_offset(&mut self, offset: impl CompatibleFormattedValue<T>)

source

pub fn start(&self) -> T::FullRange

source

pub fn set_start(&mut self, start: impl CompatibleFormattedValue<T>)

source

pub fn stop(&self) -> T::FullRange

source

pub fn set_stop(&mut self, stop: impl CompatibleFormattedValue<T>)

source

pub fn time(&self) -> T::FullRange

source

pub fn set_time(&mut self, time: impl CompatibleFormattedValue<T>)

source

pub fn position(&self) -> T::FullRange

source

pub fn set_position(&mut self, position: impl CompatibleFormattedValue<T>)

source

pub fn duration(&self) -> T::FullRange

source

pub fn set_duration(&mut self, duration: impl CompatibleFormattedValue<T>)

source§

impl<T> FormattedSegment<T>

source

pub fn position_from_running_time( &self, running_time: impl CompatibleFormattedValue<T>, ) -> T::FullRange

source

pub fn position_from_stream_time( &self, stream_time: impl CompatibleFormattedValue<T>, ) -> T::FullRange

source

pub fn to_running_time( &self, position: impl CompatibleFormattedValue<T>, ) -> T::FullRange

source

pub fn to_stream_time( &self, position: impl CompatibleFormattedValue<T>, ) -> T::FullRange

source§

impl<T> FormattedSegment<T>

Trait Implementations§

source§

impl<T: FormattedValueIntrinsic> AsRef<FormattedSegment<GenericFormattedValue>> for FormattedSegment<T>

source§

fn as_ref(&self) -> &Segment

Converts this type into a shared reference of the (usually inferred) input type.
source§

impl<T: FormattedValueIntrinsic> Clone for FormattedSegment<T>

source§

fn clone(&self) -> Self

Copies the inline boxed type by value with the type-specific copy function.

1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<T: FormattedValueIntrinsic> Debug for FormattedSegment<T>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<T: FormattedValueIntrinsic> Default for FormattedSegment<T>

source§

fn default() -> Self

Returns the “default value” for a type. Read more
source§

impl<'de, T: SpecificFormattedValueIntrinsic> Deserialize<'de> for FormattedSegment<T>

source§

fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>

Deserialize this value from the given Serde deserializer. Read more
source§

impl<T: FormattedValueIntrinsic> Drop for FormattedSegment<T>

source§

fn drop(&mut self)

Executes the destructor for this type. Read more
source§

impl<T: FormattedValueIntrinsic> From<FormattedSegment<T>> for Value

source§

fn from(v: FormattedSegment<T>) -> Value

Converts to this type from the input type.
source§

impl<T: FormattedValueIntrinsic> PartialEq for FormattedSegment<T>

source§

fn eq(&self, other: &Self) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl<T: FormattedValueIntrinsic> Serialize for FormattedSegment<T>

source§

fn serialize<S: Serializer>(&self, serializer: S) -> Result<S::Ok, S::Error>

Serialize this value into the given Serde serializer. Read more
source§

impl<T: FormattedValueIntrinsic> StaticType for FormattedSegment<T>

source§

fn static_type() -> Type

Returns the type identifier of Self.
source§

impl<T: FormattedValueIntrinsic> Eq for FormattedSegment<T>

source§

impl<T: FormattedValueIntrinsic> Send for FormattedSegment<T>

source§

impl<T: FormattedValueIntrinsic> Sync for FormattedSegment<T>

Auto Trait Implementations§

§

impl<T> Freeze for FormattedSegment<T>

§

impl<T> RefUnwindSafe for FormattedSegment<T>
where T: RefUnwindSafe,

§

impl<T> Unpin for FormattedSegment<T>
where T: Unpin,

§

impl<T> UnwindSafe for FormattedSegment<T>
where T: UnwindSafe,

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> CloneToUninit for T
where T: Clone,

source§

default unsafe fn clone_to_uninit(&self, dst: *mut T)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dst. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> IntoClosureReturnValue for T
where T: Into<Value>,

source§

impl<T> IntoEither for T

source§

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 more
source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

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
source§

impl<T> StaticTypeExt for T
where T: StaticType,

source§

fn ensure_type()

Ensures that the type has been registered with the type system.
source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T> ToSendValue for T
where T: Send + ToValue + ?Sized,

source§

fn to_send_value(&self) -> SendValue

Returns a SendValue clone of self.
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T> TryFromClosureReturnValue for T
where T: for<'a> FromValue<'a> + StaticType + 'static,

source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

source§

impl<'a, T, C, E> FromValueOptional<'a> for T
where T: FromValue<'a, Checker = C>, C: ValueTypeChecker<Error = ValueTypeMismatchOrNoneError<E>>, E: Error + Send + 'static,