pub struct CapsRef(/* private fields */);
Implementations§
source§impl CapsRef
impl CapsRef
pub fn as_ptr(&self) -> *const GstCaps
pub fn as_mut_ptr(&self) -> *mut GstCaps
pub unsafe fn from_ptr<'a>(ptr: *const GstCaps) -> &'a Self
pub unsafe fn from_mut_ptr<'a>(ptr: *mut GstCaps) -> &'a mut Self
pub fn copy(&self) -> Caps
pub fn upcast_ref(&self) -> &MiniObjectRef
pub fn upcast_mut(&mut self) -> &mut MiniObjectRef
pub fn ptr_eq(this: &CapsRef, other: &CapsRef) -> bool
source§impl CapsRef
impl CapsRef
sourcepub fn set(&mut self, name: impl IntoGStr, value: impl ToSendValue + Sync)
pub fn set(&mut self, name: impl IntoGStr, value: impl ToSendValue + Sync)
Sets field name
to the given value value
.
Overrides any default or previously defined value for name
.
sourcepub fn set_if(
&mut self,
name: impl IntoGStr,
value: impl ToSendValue + Sync,
predicate: bool,
)
pub fn set_if( &mut self, name: impl IntoGStr, value: impl ToSendValue + Sync, predicate: bool, )
Sets field name
to the given inner value if value
is Some
.
This has no effect if the predicate
evaluates to false
,
i.e. default or previous value for name
is kept.
sourcepub fn set_if_some(
&mut self,
name: impl IntoGStr,
value: Option<impl ToSendValue + Sync>,
)
pub fn set_if_some( &mut self, name: impl IntoGStr, value: Option<impl ToSendValue + Sync>, )
Sets field name
to the given inner value if value
is Some
.
This has no effect if the value is None
, i.e. default or previous value for name
is kept.
sourcepub fn set_from_iter<V: ValueType + ToSendValue + FromIterator<SendValue> + Sync>(
&mut self,
name: impl IntoGStr,
iter: impl IntoIterator<Item = impl ToSendValue>,
)
pub fn set_from_iter<V: ValueType + ToSendValue + FromIterator<SendValue> + Sync>( &mut self, name: impl IntoGStr, iter: impl IntoIterator<Item = impl ToSendValue>, )
Sets field name
using the given ValueType
V
built from iter
’s the Item
s.
Overrides any default or previously defined value for name
.
sourcepub fn set_if_not_empty<V: ValueType + ToSendValue + FromIterator<SendValue> + Sync>(
&mut self,
name: impl IntoGStr,
iter: impl IntoIterator<Item = impl ToSendValue>,
)
pub fn set_if_not_empty<V: ValueType + ToSendValue + FromIterator<SendValue> + Sync>( &mut self, name: impl IntoGStr, iter: impl IntoIterator<Item = impl ToSendValue>, )
Sets field name
using the given ValueType
V
built from iter
’s Items, if
iter` is not empty.
This has no effect if iter
is empty, i.e. previous value for name
is unchanged.
sourcepub fn set_value(&mut self, name: impl IntoGStr, value: SendValue)
pub fn set_value(&mut self, name: impl IntoGStr, value: SendValue)
Sets field name
to the given value value
.
Overrides any default or previously defined value for name
.
sourcepub fn set_value_if(
&mut self,
name: impl IntoGStr,
value: SendValue,
predicate: bool,
)
pub fn set_value_if( &mut self, name: impl IntoGStr, value: SendValue, predicate: bool, )
Sets field name
to the given inner value if value
is Some
.
This has no effect if the predicate
evaluates to false
,
i.e. default or previous value for name
is kept.
sourcepub fn set_value_if_some(
&mut self,
name: impl IntoGStr,
value: Option<SendValue>,
)
pub fn set_value_if_some( &mut self, name: impl IntoGStr, value: Option<SendValue>, )
Sets field name
to the given inner value if value
is Some
.
This has no effect if the value is None
, i.e. default or previous value for name
is kept.
pub fn structure(&self, idx: usize) -> Option<&StructureRef>
pub fn structure_mut(&mut self, idx: usize) -> Option<&mut StructureRef>
pub fn features(&self, idx: usize) -> Option<&CapsFeaturesRef>
pub fn features_mut(&mut self, idx: usize) -> Option<&mut CapsFeaturesRef>
pub fn set_features(&mut self, idx: usize, features: Option<CapsFeatures>)
pub fn set_features_simple(&mut self, features: Option<CapsFeatures>)
pub fn size(&self) -> usize
pub fn len(&self) -> usize
pub fn iter(&self) -> Iter<'_> ⓘ
pub fn iter_mut(&mut self) -> IterMut<'_> ⓘ
pub fn iter_with_features(&self) -> IterFeatures<'_> ⓘ
pub fn iter_with_features_mut(&mut self) -> IterFeaturesMut<'_> ⓘ
pub fn append_structure(&mut self, structure: Structure)
pub fn append_structure_full( &mut self, structure: Structure, features: Option<CapsFeatures>, )
pub fn remove_structure(&mut self, idx: usize)
pub fn append(&mut self, other: Caps)
pub fn can_intersect(&self, other: &Self) -> bool
pub fn intersect(&self, other: &Self) -> Caps
pub fn intersect_with_mode(&self, other: &Self, mode: CapsIntersectMode) -> Caps
pub fn is_always_compatible(&self, other: &Self) -> bool
pub fn is_any(&self) -> bool
pub fn is_empty(&self) -> bool
pub fn is_fixed(&self) -> bool
pub fn is_equal_fixed(&self, other: &Self) -> bool
pub fn is_strictly_equal(&self, other: &Self) -> bool
pub fn is_subset(&self, superset: &Self) -> bool
pub fn is_subset_structure(&self, structure: &StructureRef) -> bool
pub fn is_subset_structure_full( &self, structure: &StructureRef, features: Option<&CapsFeaturesRef>, ) -> bool
pub fn subtract(&self, other: &Self) -> Caps
pub fn serialize(&self, flags: SerializeFlags) -> GString
pub fn foreach<F: FnMut(&CapsFeaturesRef, &StructureRef) -> ControlFlow<()>>( &self, func: F, ) -> bool
pub fn map_in_place<F: FnMut(&mut CapsFeaturesRef, &mut StructureRef) -> ControlFlow<()>>( &mut self, func: F, ) -> bool
pub fn filter_map_in_place<F: FnMut(&mut CapsFeaturesRef, &mut StructureRef) -> CapsFilterMapAction>( &mut self, func: F, )
Trait Implementations§
source§impl Extend<(Structure, CapsFeatures)> for CapsRef
impl Extend<(Structure, CapsFeatures)> for CapsRef
source§fn extend<T: IntoIterator<Item = (Structure, CapsFeatures)>>(&mut self, iter: T)
fn extend<T: IntoIterator<Item = (Structure, CapsFeatures)>>(&mut self, iter: T)
source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
extend_one
)source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
extend_one
)source§impl Extend<(Structure, Option<CapsFeatures>)> for CapsRef
impl Extend<(Structure, Option<CapsFeatures>)> for CapsRef
source§fn extend<T: IntoIterator<Item = (Structure, Option<CapsFeatures>)>>(
&mut self,
iter: T,
)
fn extend<T: IntoIterator<Item = (Structure, Option<CapsFeatures>)>>( &mut self, iter: T, )
source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
extend_one
)source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
extend_one
)source§impl Extend<Caps> for CapsRef
impl Extend<Caps> for CapsRef
source§fn extend<T: IntoIterator<Item = Caps>>(&mut self, iter: T)
fn extend<T: IntoIterator<Item = Caps>>(&mut self, iter: T)
source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
extend_one
)source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
extend_one
)source§impl Extend<Structure> for CapsRef
impl Extend<Structure> for CapsRef
source§fn extend<T: IntoIterator<Item = Structure>>(&mut self, iter: T)
fn extend<T: IntoIterator<Item = Structure>>(&mut self, iter: T)
source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
extend_one
)source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
extend_one
)source§impl<'a> FromValue<'a> for &'a CapsRef
impl<'a> FromValue<'a> for &'a CapsRef
§type Checker = GenericValueTypeOrNoneChecker<&'a CapsRef>
type Checker = GenericValueTypeOrNoneChecker<&'a CapsRef>
source§unsafe fn from_value(value: &'a Value) -> Self
unsafe fn from_value(value: &'a Value) -> Self
Value
. Read moresource§impl<'a> IntoIterator for &'a CapsRef
impl<'a> IntoIterator for &'a CapsRef
§type IntoIter = IterFeatures<'a>
type IntoIter = IterFeatures<'a>
§type Item = (&'a StructureRef, &'a CapsFeaturesRef)
type Item = (&'a StructureRef, &'a CapsFeaturesRef)
source§impl<'a> IntoIterator for &'a mut CapsRef
impl<'a> IntoIterator for &'a mut CapsRef
§type IntoIter = IterFeaturesMut<'a>
type IntoIter = IterFeaturesMut<'a>
§type Item = (&'a mut StructureRef, &'a mut CapsFeaturesRef)
type Item = (&'a mut StructureRef, &'a mut CapsFeaturesRef)
source§impl PartialEq<Caps> for CapsRef
impl PartialEq<Caps> for CapsRef
source§impl PartialEq<CapsRef> for Caps
impl PartialEq<CapsRef> for Caps
source§impl PartialEq for CapsRef
impl PartialEq for CapsRef
source§impl StaticType for CapsRef
impl StaticType for CapsRef
source§fn static_type() -> Type
fn static_type() -> Type
Self
.impl Eq for CapsRef
impl Send for CapsRef
impl Sync for CapsRef
Auto Trait Implementations§
impl Freeze for CapsRef
impl RefUnwindSafe for CapsRef
impl Unpin for CapsRef
impl UnwindSafe for CapsRef
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
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>
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>
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