TpObserveChannelsContext: telepathy-glib API Reference Manual

## TpObserveChannelsContext TpObserveChannelsContext — context of a Observer.ObserveChannels() call |

## Functions

void | tp_observe_channels_context_accept ()
void | tp_observe_channels_context_delay ()
void | tp_observe_channels_context_fail ()
gboolean | tp_observe_channels_context_is_recovering ()
GList * | tp_observe_channels_context_get_requests ()

## Properties

TpAccount * | account | Read / Write / Construct Only
GPtrArray * | channels | Read / Write / Construct Only
TpConnection * | connection | Read / Write / Construct Only
gpointer | dbus-context | Write / Construct Only
TpChannelDispatchOperation * | dispatch-operation | Read / Write / Construct Only
GHashTable_gchararray+GValue_* | observer-info | Read / Write / Construct Only
GPtrArray * | requests | Read / Write / Construct Only

## Types and Values

| TpObserveChannelsContext

## Object Hierarchy

        GObject
        ╰── TpObserveChannelsContext

## Includes

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

## Description

Object used to represent the context of a Observer.ObserveChannels() D-Bus call on a TpBaseClient.

## Functions

### tp_observe_channels_context_accept ()

    void
    tp_observe_channels_context_accept (TpObserveChannelsContext *self);

Called by TpBaseClientClassObserveChannelsImpl when it's done so the D-Bus method can return.

#### Parameters

self | a TpObserveChannelsContext |

Since: 0.11.5

### tp_observe_channels_context_delay ()

    void
    tp_observe_channels_context_delay (TpObserveChannelsContext *self);

Called by TpBaseClientClassObserveChannelsImpl to indicate that it implements the method in an async way. The caller must take a reference to the TpObserveChannelsContext before calling this function, and is responsible for calling either `tp_observe_channels_context_accept()` or `tp_observe_channels_context_fail()` later.

#### Parameters

self | a TpObserveChannelsContext |

Since: 0.11.5

### tp_observe_channels_context_fail ()

    void
    tp_observe_channels_context_fail (TpObserveChannelsContext *self,
                                      const GError *error);

Called by TpBaseClientClassObserveChannelsImpl to raise a D-Bus error.

#### Parameters

self | a TpObserveChannelsContext |
error | the error to return from the method |

Since: 0.11.5

### tp_observe_channels_context_is_recovering ()

    gboolean
    tp_observe_channels_context_is_recovering
                                   (TpObserveChannelsContext *self);

If this call to ObserveChannels is for channels that already existed before this observer started (because the observer used `tp_base_client_set_observer_recover()`), return `TRUE`.

In most cases, the result is `FALSE`.

#### Parameters

self | a TpObserveChannelsContext |

#### Returns

`TRUE` for pre-existing channels, `FALSE` for new channels

Since: 0.11.5

### tp_observe_channels_context_get_requests ()

    GList *
    tp_observe_channels_context_get_requests
                                   (TpObserveChannelsContext *self);

Return a list of the TpChannelRequest which have been satisfied by the channels associated with self.

#### Parameters

self | a TpObserveChannelsContext |

#### Returns

a newly allocated GList of reffed TpChannelRequest.

[transfer full][element-type TelepathyGLib.ChannelRequest]

Since: 0.13.14

## Types and Values

### TpObserveChannelsContext

    typedef struct _TpObserveChannelsContext TpObserveChannelsContext;

Data structure representing the context of a Observer.ObserveChannels() call.

Since: 0.11.5

## Property Details

### The `“account”` property

      “account”                  TpAccount *

A TpAccount object representing the Account that has been passed to ObserveChannels. Read-only except during construction.

This property can't be `NULL`.

Owner: TpObserveChannelsContext

Flags: Read / Write / Construct Only

Since: 0.11.5

### The `“channels”` property

      “channels”                 GPtrArray *

A GPtrArray containing TpChannel objects representing the channels that have been passed to ObserveChannels. Read-only except during construction.

This property can't be `NULL`.

Owner: TpObserveChannelsContext

Flags: Read / Write / Construct Only

Since: 0.11.5

### The `“connection”` property

      “connection”               TpConnection *

A TpConnection object representing the Connection that has been passed to ObserveChannels. Read-only except during construction.

This property can't be `NULL`.

Owner: TpObserveChannelsContext

Flags: Read / Write / Construct Only

Since: 0.11.5

### The `“dbus-context”` property

      “dbus-context”             gpointer

The DBusGMethodInvocation representing the D-Bus context of the ObserveChannels call. Can only be written during construction.

[skip]

Owner: TpObserveChannelsContext

Flags: Write / Construct Only

Since: 0.11.5

### The `“dispatch-operation”` property

      “dispatch-operation”       TpChannelDispatchOperation *

A TpChannelDispatchOperation object representing the ChannelDispatchOperation that has been passed to ObserveChannels, or `NULL` if none has been passed. Read-only except during construction.

Owner: TpObserveChannelsContext

Flags: Read / Write / Construct Only

Since: 0.11.5

### The `“observer-info”` property

      “observer-info”            GHashTable_gchararray+GValue_*

A GHashTable where the keys are string and values are GValue instances. It represents the Observer_Info hash table that has been passed to ObserveChannels. It's recommended to use high-level method such as `tp_observe_channels_context_is_recovering()` to access to its content.

This property can't be `NULL`.

Owner: TpObserveChannelsContext

Flags: Read / Write / Construct Only

Since: 0.11.5

### The `“requests”` property

      “requests”                 GPtrArray *

A GPtrArray containing TpChannelRequest objects representing the requests that have been passed to ObserveChannels. Read-only except during construction.

This property can't be `NULL`.

Owner: TpObserveChannelsContext

Flags: Read / Write / Construct Only

Since: 0.11.5