Struct ladspa::PortConnection [] [src]

pub struct PortConnection<'a> {
    pub port: Port,
    pub data: PortData<'a>,
}

Represents a connection between a port and the data attached to the port by the plugin host.

Fields

port: Port

The port which the data is connected to.

data: PortData<'a>

The data connected to the port. It's usually simpler to use the various unwrap_* functions than to interface with this directly.

Methods

impl<'a> PortConnection<'a>
[src]

fn unwrap_audio(&'a self) -> &'a [Data]

Returns a slice pointing to the internal data of an audio input port. Panics if this port is not an AudioIn port.

fn unwrap_audio_mut(&'a self) -> RefMut<'a, &'a mut [Data]>

Returns a mutable slice pointing to the internal data of an audio output port. Panics if this port is not an AudioOut port.

fn unwrap_control(&'a self) -> &'a Data

Returns a refrence to the internal data of an control input port. Panics if this port is not an ControlIn port.

fn unwrap_control_mut(&'a self) -> RefMut<'a, &'a mut Data>

Returns a mutable refrence to the internal data of an audio output port. Panics if this port is not an ControlOut port.