Trait gstreamer::prelude::PresetExt [−][src]
pub trait PresetExt: 'static { fn delete_preset(&self, name: &str) -> Result<(), BoolError>; fn meta(&self, name: &str, tag: &str) -> Option<GString>; fn preset_names(&self) -> Vec<GString>; fn property_names(&self) -> Vec<GString>; fn is_editable(&self) -> bool; fn load_preset(&self, name: &str) -> Result<(), BoolError>; fn rename_preset(
&self,
old_name: &str,
new_name: &str
) -> Result<(), BoolError>; fn save_preset(&self, name: &str) -> Result<(), BoolError>; fn set_meta(
&self,
name: &str,
tag: &str,
value: Option<&str>
) -> Result<(), BoolError>; }
Required methods
fn delete_preset(&self, name: &str) -> Result<(), BoolError>
[src]
Delete the given preset.
name
preset name to remove
Returns
true
for success, false
if e.g. there is no preset with that name
fn meta(&self, name: &str, tag: &str) -> Option<GString>
[src]
Gets the value
for an existing meta data tag
. Meta data tag
names can be
something like e.g. “comment”. Returned values need to be released when done.
name
preset name
tag
meta data item name
value
value
Returns
true
for success, false
if e.g. there is no preset with that name
or no value for the given tag
fn preset_names(&self) -> Vec<GString>
[src]
Get a copy of preset names as a None
terminated string array.
Returns
list with names, use g_strfreev()
after usage.
fn property_names(&self) -> Vec<GString>
[src]
Get a the names of the GObject properties that can be used for presets.
Returns
an
array of property names which should be freed with g_strfreev()
after use.
fn is_editable(&self) -> bool
[src]
Check if one can add new presets, change existing ones and remove presets.
Returns
fn load_preset(&self, name: &str) -> Result<(), BoolError>
[src]
Load the given preset.
name
preset name to load
Returns
true
for success, false
if e.g. there is no preset with that name
fn rename_preset(&self, old_name: &str, new_name: &str) -> Result<(), BoolError>
[src]
Renames a preset. If there is already a preset by the new_name
it will be
overwritten.
old_name
current preset name
new_name
new preset name
Returns
true
for success, false
if e.g. there is no preset with old_name
fn save_preset(&self, name: &str) -> Result<(), BoolError>
[src]
Save the current object settings as a preset under the given name. If there
is already a preset by this name
it will be overwritten.
name
preset name to save
Returns
fn set_meta(
&self,
name: &str,
tag: &str,
value: Option<&str>
) -> Result<(), BoolError>
[src]
&self,
name: &str,
tag: &str,
value: Option<&str>
) -> Result<(), BoolError>
Sets a new value
for an existing meta data item or adds a new item. Meta
data tag
names can be something like e.g. “comment”. Supplying None
for the
value
will unset an existing value.
name
preset name
tag
meta data item name
value
new value
Returns
true
for success, false
if e.g. there is no preset with that name
Implementors
impl<O: IsA<Preset>> PresetExt for O
[src]
impl<O: IsA<Preset>> PresetExt for O
[src]fn delete_preset(&self, name: &str) -> Result<(), BoolError>
[src]
fn meta(&self, name: &str, tag: &str) -> Option<GString>
[src]
fn preset_names(&self) -> Vec<GString>
[src]
fn property_names(&self) -> Vec<GString>
[src]
fn is_editable(&self) -> bool
[src]
fn load_preset(&self, name: &str) -> Result<(), BoolError>
[src]
fn rename_preset(&self, old_name: &str, new_name: &str) -> Result<(), BoolError>
[src]
fn save_preset(&self, name: &str) -> Result<(), BoolError>
[src]
fn set_meta(
&self,
name: &str,
tag: &str,
value: Option<&str>
) -> Result<(), BoolError>
[src]
&self,
name: &str,
tag: &str,
value: Option<&str>
) -> Result<(), BoolError>