Enum wpexec::ModuleType

source ·
pub(crate) enum ModuleType {
    Lua,
    LuaConfig,
    Wireplumber,
    Pipewire,
}
Expand description

The type of module to be loaded

Variants§

§

Lua

§

LuaConfig

§

Wireplumber

A native WirePlumber module

§

Pipewire

Implementations§

source§

impl ModuleType

source

pub(crate) fn is_lua(&self) -> bool

source

pub(crate) fn module_dir(&self) -> Option<&'static str>

Environment variable that affects path resolution for this module type

The wireplumber ComponentLoader generally doesn’t accept absolute paths for modules. This environment variable can be modified in order to help it find the module to load.

source

pub(crate) fn loader_module(&self) -> Option<&'static str>

A module that provides the necessary loader

While wireplumber has built-in support for loading modules, the Lua scripting engine is itself implemented as a module, which must be loaded first. Afterwards, lua scripts may be loaded as modules (well, components) themselves.

source

pub(crate) fn loader_type(&self) -> &'static str

The type name expected by a ComponentLoader

This is passed on to Core::load_component.

Trait Implementations§

source§

impl Clone for ModuleType

source§

fn clone(&self) -> ModuleType

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl Debug for ModuleType

source§

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

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

impl ValueEnum for ModuleType

source§

fn value_variants<'a>() -> &'a [Self]

All possible argument values, in display order.
source§

fn to_possible_value<'a>(&self) -> Option<PossibleValue>

The canonical argument value. Read more
source§

fn from_str(input: &str, ignore_case: bool) -> Result<Self, String>

Parse an argument into Self.
source§

impl Copy for ModuleType

Auto Trait Implementations§

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> 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> 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, 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, 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.