TfChannel: telepathy-farstream Reference Manual

## TfChannel TfChannel — Handle the MediaSignalling or Call media interfaces on a Channel |

## Functions

void | tf_channel_new_async ()
TfChannel * | tf_channel_new_finish ()
gboolean | tf_channel_bus_message ()

## Properties

TpChannel * | channel | Read / Write / Construct Only
GPtrArray * | fs-conferences | Read
gchar * | object-path | Read

## Signals

void | closed | Run Last
void | content-added | Run Last
void | content-removed | Run Last
void | fs-conference-added | Run Last
void | fs-conference-removed | Run Last

## Types and Values

| TfChannel

## Object Hierarchy

        GObject
        ╰── TfChannel

## Implemented Interfaces

TfChannel implements GAsyncInitable.

## Description

This class handles the org.freedesktop.Telepathy.Channel.Interface.MediaSignalling on a channel using Farstream or the media part of the org.freedesktop.Telepathy.Channel.Type.Call that has HardwareStreaming=FALSE

## Functions

### tf_channel_new_async ()

    void
    tf_channel_new_async (TpChannel *channel_proxy,
                          GAsyncReadyCallback callback,
                          gpointer user_data);

Creates a new TfChannel from an existing channel proxy, the new TfChannel object will be return in the async callback.

The user must call `tf_channel_new_finish()` in the callback to get the finished object.

#### Parameters

channel_proxy | a TpChannel proxy |
callback | a GAsyncReadyCallback to call when the channel is ready |
user_data | the data to pass to callback function |

### tf_channel_new_finish ()

    TfChannel *
    tf_channel_new_finish (GObject *object,
                           GAsyncResult *result,
                           GError **error);

Completes the construction of a TfChannel.

#### Parameters

object | The GObject |
result | a GAsyncResult |
error | the location of a GError or `NULL` to ignore it |

#### Returns

a TfChannel or `NULL` if there was an error

Since: 0.2.2

### tf_channel_bus_message ()

    gboolean
    tf_channel_bus_message (TfChannel *channel,
                            GstMessage *message);

You must call this function on call messages received on the async bus. GstMessages are not modified.

#### Parameters

channel | A TfChannel |
message | A GstMessage received from the bus |

#### Returns

`TRUE` if the message has been handled, `FALSE` otherwise

## Types and Values

### TfChannel

    typedef struct _TfChannel TfChannel;

All members of the object are private

## Property Details

### The `“channel”` property

      “channel”                  TpChannel *

Telepathy channel object which this media channel should operate on.

Flags: Read / Write / Construct Only

### The `“fs-conferences”` property

      “fs-conferences”           GPtrArray *

GPtrArray of Farstream FsConferences for this channel.

Flags: Read

### The `“object-path”` property

      “object-path”              gchar *

D-Bus object path of the Telepathy channel which this channel operates on.

Flags: Read

Default value: NULL

## Signal Details

### The `“closed”` signal

    void
    user_function (TfChannel *arg0,
                   gpointer   user_data)

This function is called after a channel is closed, either because it has been closed by the connection manager or because we had a locally generated error.

#### Parameters

user_data | user data set when the signal handler was connected. |

Flags: Run Last

### The `“content-added”` signal

    void
    user_function (TfChannel *tfchannel,
                   TfContent *content,
                   gpointer   user_data)

Tells the application that a content has been added. In the callback for this signal, the application should set its preferred codecs, and hook up to any signal from TfContent it cares about. Special care should be made to connect “src-pad-added” as well as the “start-sending” and “stop-sending” signals.

#### Parameters

tfchannel | the TfChannel |
content | a TfContent |
user_data | user data set when the signal handler was connected. |

Flags: Run Last

### The `“content-removed”` signal

    void
    user_function (TfChannel *tfchannel,
                   TfContent *content,
                   gpointer   user_data)

Tells the application that a content is being removed.

#### Parameters

tfchannel | the TfChannel |
content | a TfContent |
user_data | user data set when the signal handler was connected. |

Flags: Run Last

### The `“fs-conference-added”` signal

    void
    user_function (TfChannel    *tfchannel,
                   FsConference *conf,
                   gpointer      user_data)

When this signal is emitted, the conference should be added to the application's pipeline.

#### Parameters

tfchannel | the TfChannel |
conf | a FsConference |
user_data | user data set when the signal handler was connected. |

Flags: Run Last

### The `“fs-conference-removed”` signal

    void
    user_function (TfChannel    *tfchannel,
                   FsConference *conf,
                   gpointer      user_data)

When this signal is emitted, the conference should be remove from the application's pipeline.

#### Parameters

tfchannel | the TfChannel |
conf | a FsConference |
user_data | user data set when the signal handler was connected. |

Flags: Run Last