## TpCallContent

TpCallContent — proxy object for a call content

## Synopsis

    #include <telepathy-glib/telepathy-glib.h>

                        TpCallContent;
    struct              TpCallContentClass;
    void                tp_call_content_init_known_interfaces
                                                            (void);
    #define             TP_CALL_CONTENT_FEATURE_CORE

    TpCallContentDisposition tp_call_content_get_disposition
                                                            (TpCallContent *self);
    TpMediaStreamType   tp_call_content_get_media_type      (TpCallContent *self);
    const gchar *       tp_call_content_get_name            (TpCallContent *self);
    GPtrArray *         tp_call_content_get_streams         (TpCallContent *self);

    void                tp_call_content_remove_async        (TpCallContent *self,
                                                             GAsyncReadyCallback callback,
                                                             gpointer user_data);
    gboolean            tp_call_content_remove_finish       (TpCallContent *self,
                                                             GAsyncResult *result,
                                                             GError **error);

    void                tp_call_content_send_tones_async    (TpCallContent *self,
                                                             const gchar *tones,
                                                             GCancellable *cancellable,
                                                             GAsyncReadyCallback callback,
                                                             gpointer user_data);
    gboolean            tp_call_content_send_tones_finish   (TpCallContent *self,
                                                             GAsyncResult *result,
                                                             GError **error);

## Object Hierarchy

      GObject
       +----TpProxy
             +----TpCallContent

## Properties

      "channel"                  TpCallChannel*        : Read / Write / Construct Only
      "connection"               TpConnection*         : Read / Write / Construct Only
      "disposition"              guint                 : Read
      "media-type"               guint                 : Read
      "name"                     gchar*                : Read
      "streams"                  GPtrArray*            : Read

## Signals

      "removed"                                        : Run Last
      "streams-added"                                  : Run Last
      "streams-removed"                                : Run Last

## Description

TpCallContent is a sub-class of TpProxy providing convenient API to represent TpCallChannel's content.

## Details

### TpCallContent

    typedef struct _TpCallContent TpCallContent;

Data structure representing a TpCallContent.

Since 0.17.5

### struct TpCallContentClass

    struct TpCallContentClass {
    };

The class of a TpCallContent.

Since 0.17.5

### tp_call_content_init_known_interfaces ()

    void                tp_call_content_init_known_interfaces
                                                            (void);

Ensure that the known interfaces for TpCallContent have been set up. This is done automatically when necessary, but for correct overriding of library interfaces by local extensions, you should call this function before calling `tp_proxy_or_subclass_hook_on_interface_add()` with first argument `TP_TYPE_CALL_CONTENT`.

Since 0.17.5

### TP_CALL_CONTENT_FEATURE_CORE

    #define             TP_CALL_CONTENT_FEATURE_CORE

Expands to a call to a function that returns a quark for the "core" feature on a TpCallContent.

One can ask for a feature to be prepared using the `tp_proxy_prepare_async()` function, and waiting for it to trigger the callback.

### tp_call_content_get_disposition ()

    TpCallContentDisposition tp_call_content_get_disposition
                                                            (TpCallContent *self);

`self` : | a TpCallContent
Returns : | the value of "disposition"

Since 0.17.5

### tp_call_content_get_media_type ()

    TpMediaStreamType   tp_call_content_get_media_type      (TpCallContent *self);

`self` : | a TpCallContent
Returns : | the value of "name"

Since 0.17.5

### tp_call_content_get_name ()

    const gchar *       tp_call_content_get_name            (TpCallContent *self);

`self` : | a TpCallContent
Returns : | the value of "name"

Since 0.17.5

### tp_call_content_get_streams ()

    GPtrArray *         tp_call_content_get_streams         (TpCallContent *self);

`self` : | a TpCallContent
Returns : | the value of "streams". [transfer none][type GLib.PtrArray][element-type TelepathyGLib.CallStream]

Since 0.17.5

### tp_call_content_remove_async ()

    void                tp_call_content_remove_async        (TpCallContent *self,
                                                             GAsyncReadyCallback callback,
                                                             gpointer user_data);

Remove the content from the call. This will cause "removed" to be emitted.

`self` : | a TpCallContent
`callback` : | a callback to call when the operation finishes
`user_data` : | data to pass to `callback`

Since 0.17.5

### tp_call_content_remove_finish ()

    gboolean            tp_call_content_remove_finish       (TpCallContent *self,
                                                             GAsyncResult *result,
                                                             GError **error);

Finishes `tp_call_content_remove_async()`.

`self` : | a TpCallContent
`result` : | a GAsyncResult
`error` : | a GError to fill

Since 0.17.5

### tp_call_content_send_tones_async ()

    void                tp_call_content_send_tones_async    (TpCallContent *self,
                                                             const gchar *tones,
                                                             GCancellable *cancellable,
                                                             GAsyncReadyCallback callback,
                                                             gpointer user_data);

Send `tones` DTMF code on `self` content. `self` must have the `TP_IFACE_CALL_CONTENT_INTERFACE_DTMF` interface.

If DTMF tones are already being played, this request is queued.

`self` : | a TpCallContent
`tones` : | a string representation of one or more DTMF events.
`cancellable` : | optional GCancellable object, `NULL` to ignore
`callback` : | a callback to call when the operation finishes
`user_data` : | data to pass to `callback`

Since 0.17.5

### tp_call_content_send_tones_finish ()

    gboolean            tp_call_content_send_tones_finish   (TpCallContent *self,
                                                             GAsyncResult *result,
                                                             GError **error);

Finishes `tp_call_content_send_tones_async()`.

`self` : | a TpCallContent
`result` : | a GAsyncResult
`error` : | a GError to fill
Returns : | `TRUE` on success, `FALSE` otherwise.

Since 0.17.5

## Property Details

### The `"channel"` property

      "channel"                  TpCallChannel*        : Read / Write / Construct Only

The parent TpCallChannel of the content.

Since 0.17.6

### The `"connection"` property

      "connection"               TpConnection*         : Read / Write / Construct Only

The TpConnection of the call.

Since 0.17.5

### The `"disposition"` property

      "disposition"              guint                 : Read

The disposition of this content, from TpCallContentDisposition.

Default value: 0

Since 0.17.5

### The `"media-type"` property

      "media-type"               guint                 : Read

The media type of this content, from TpMediaStreamType.

Default value: 0

Since 0.17.5

### The `"name"` property

      "name"                     gchar*                : Read

The name of this content.

Default value: ""

Since 0.17.5

### The `"streams"` property

      "streams"                  GPtrArray*            : Read

GPtrArray of TpCallStream objects. The list of stream objects that are part of this content.

It is NOT guaranteed that `TP_CALL_STREAM_FEATURE_CORE` is prepared on those objects.

Since 0.17.5

## Signal Details

### The `"removed"` signal

    void                user_function                      (TpCallContent *self,
                                                            gpointer       user_data)      : Run Last

The ::removed signal is emitted when `self` is removed from a TpCallChannel.

`self` : | the TpCallContent
`user_data` : | user data set when the signal handler was connected.

Since 0.17.5

### The `"streams-added"` signal

    void                user_function                      (TpCallContent *self,
                                                            GPtrArray     *streams,
                                                            gpointer       user_data)      : Run Last

The ::streams-added signal is emitted whenever TpCallStream are added to `self`.

It is NOT guaranteed that `TP_CALL_STREAM_FEATURE_CORE` is prepared on stream objects.

`self` : | the TpCallContent
`streams` : | a GPtrArray of newly added TpCallStream. [type GLib.PtrArray][element-type TelepathyGLib.CallStream]
`user_data` : | user data set when the signal handler was connected.

Since 0.17.5

### The `"streams-removed"` signal

    void                user_function                      (TpCallContent     *self,
                                                            GPtrArray         *streams,
                                                            TpCallStateReason *reason,
                                                            gpointer           user_data)      : Run Last

The ::streams-removed signal is emitted whenever TpCallStreams are removed from `self`.

It is NOT guaranteed that `TP_CALL_STREAM_FEATURE_CORE` is prepared on stream objects.

`self` : | the TpCallContent
`streams` : | a GPtrArray of newly removed TpCallStream. [type GLib.PtrArray][element-type TelepathyGLib.CallStream]
`reason` : | a TpCallStateReason
`user_data` : | user data set when the signal handler was connected.

Since 0.17.5