Wp.Link¶
- Subclasses:
None
Methods¶
- Inherited:
Wp.GlobalProxy (4), Wp.Proxy (4), Wp.Object (12), GObject.Object (37), Wp.PipewireObject (9)
- Structs:
class |
|
|
Virtual Methods¶
- Inherited:
Wp.Proxy (4), Wp.Object (4), GObject.Object (7), Wp.PipewireObject (7)
Properties¶
- Inherited:
Wp.GlobalProxy (3), Wp.Proxy (2), Wp.Object (4), Wp.PipewireObject (3)
Name |
Type |
Flags |
Short Description |
---|---|---|---|
r |
state |
Signals¶
- Inherited:
Name |
Short Description |
---|---|
Fields¶
- Inherited:
Class Details¶
- class Wp.Link(**kwargs)¶
- Bases:
- Abstract:
No
- Structure:
The
Wp.Link
class allows accessing the properties and methods of a PipeWire link object (struct pw_link). AWp.Link
is constructed internally when a new link appears on the PipeWire registry and it is made available through theWp.ObjectManager
API. Alternatively, aWp.Link
can also be constructed usingWp.Link.new_from_factory
(), which creates a new link object on the remote PipeWire server by calling into a factory.- classmethod new_from_factory(core, factory_name, properties)¶
- Parameters:
core (
Wp.Core
) – the wireplumber corefactory_name (
str
) – the pipewire factory name to construct the linkproperties (
Wp.Properties
orNone
) – the properties to pass to the factory
- Returns:
the new link or
None
if the core is not connected and therefore the link cannot be created- Return type:
Constructs a link on the PipeWire server by asking the remote factory factory_name to create it.
Because of the nature of the PipeWire protocol, this operation completes asynchronously at some point in the future. In order to find out when this is done, you should call
Wp.Object.activate
(), requesting at leastWp.ProxyFeatures.PROXY_FEATURE_BOUND
. When this feature is ready, the link is ready for use on the server. If the link cannot be created, this activation operation will fail.
- get_linked_object_ids()¶
- Returns:
- output_node:
the bound id of the output (source) node
- output_port:
the bound id of the output (source) port
- input_node:
the bound id of the input (sink) node
- input_port:
the bound id of the input (sink) port
- Return type:
(output_node:
int
, output_port:int
, input_node:int
, input_port:int
)
Retrieves the ids of the objects that are linked by this link.
- get_state()¶
- Returns:
the current state of the link
- error:
the error
- Return type:
(
Wp.LinkState
, error:str
)
Gets the current state of the link.
New in version 0.4.11.
Signal Details¶
- Wp.Link.signals.state_changed(link, object, p0)¶
- Signal Name:
state-changed
- Flags:
- Parameters:
link (
Wp.Link
) – The object which received the signalobject (
Wp.LinkState
) –p0 (
Wp.LinkState
) –
Property Details¶
- Wp.Link.props.state¶
- Name:
state
- Type:
- Default Value:
- Flags:
state