Wp.SiAdapter

g GObject.GInterface GObject.GInterface Wp.SiAdapter Wp.SiAdapter GObject.GInterface->Wp.SiAdapter

Implementations:

None

Methods

get_ports_format ()

get_ports_state ()

set_ports_format (format, mode, callback, *data)

set_ports_format_finish (res)

Virtual Methods

do_get_ports_format ()

do_get_ports_state ()

do_set_ports_format (format, mode, callback, data)

do_set_ports_format_finish (res)

Properties

None

Signals

Name

Short Description

adapter-ports-state-changed

Fields

None

Class Details

class Wp.SiAdapter
Bases:

GObject.GInterface

Structure:

Wp.SiAdapterInterface

An interface for port adapters

get_ports_format()
Returns:

The format used to configure the ports of the adapter session item. Some items automatically choose a format when being activated, others never set a format on activation and the user needs to manually set it externally with Wp.SiAdapter.set_ports_format().

mode:

the mode

Return type:

(Wp.SpaPod, mode: str or None)

Gets the format used to configure the adapter session item’s ports.

get_ports_state()
Returns:

The state of the ports

Return type:

Wp.SiAdapterPortsState

Gets the ports state.

New in version 0.4.10.

set_ports_format(format, mode, callback, *data)
Parameters:

Sets the format and configures the adapter session item ports using the given format.

The result of the operation can be checked using the Wp.SiAdapter.set_ports_format_finish() API. If format is None, the adapter will be configured with the default format. If mode is None, the adapter will use “dsp” mode.

set_ports_format_finish(res)
Parameters:

res (Gio.AsyncResult) – the async result

Raises:

GLib.Error

Returns:

True on success, False if there was an error

Return type:

bool

Finishes the operation started by wp_si_adapter_set_format(). This is meant to be called in the callback that was passed to that method.

do_get_ports_format() virtual
Returns:

The format used to configure the ports of the adapter session item. Some items automatically choose a format when being activated, others never set a format on activation and the user needs to manually set it externally with Wp.SiAdapter.set_ports_format().

mode:

the mode

Return type:

(Wp.SpaPod, mode: str or None)

Gets the format used to configure the adapter session item’s ports.

do_get_ports_state() virtual
Returns:

The state of the ports

Return type:

Wp.SiAdapterPortsState

Gets the ports state.

New in version 0.4.10.

do_set_ports_format(format, mode, callback, data) virtual
Parameters:

Sets the format and configures the adapter session item ports using the given format.

The result of the operation can be checked using the Wp.SiAdapter.set_ports_format_finish() API. If format is None, the adapter will be configured with the default format. If mode is None, the adapter will use “dsp” mode.

do_set_ports_format_finish(res) virtual
Parameters:

res (Gio.AsyncResult) – the async result

Returns:

True on success, False if there was an error

Return type:

bool

Finishes the operation started by wp_si_adapter_set_format(). This is meant to be called in the callback that was passed to that method.

Signal Details

Wp.SiAdapter.signals.adapter_ports_state_changed(si_adapter, object, p0)
Signal Name:

adapter-ports-state-changed

Flags:

RUN_LAST

Parameters: