org.freedesktop.Telepathy.Channel.Interface.ChatState

# Interface org.freedesktop.Telepathy.Channel.Interface.ChatState

Interface Index (Compact) | Summary | Description | Methods | Signals | Types

### Methods

SetChatState | (u: State) | → | nothing |

### Signals

ChatStateChanged | (u: Contact, u: State) |

### Types

Channel_Chat_State | Enum | u |

Objects implementing this interface must also implement:

- org.freedesktop.Telepathy.Channel.Type.Text

### Description

An interface for channels for receiving notifications of remote contacts' state, and for notifying remote contacts of the local state.

Clients should assume that a contact's state is Channel_Chat_State_Inactive unless they receive a notification otherwise.

The Channel_Chat_State_Gone state is treated differently to other states:

- It may not be used for multi-user chats
- It may not be explicitly sent
- It should be automatically sent when the channel is closed
- It must not be sent to the peer if a channel is closed without being used
- Receiving it must not cause a new channel to be opened

The different states are defined by XEP-0085, but may be applied to any suitable protocol.

# Methods

(Permalink)

## SetChatState (u: State) → nothing

### Parameters

- State — u (Channel_Chat_State)
The new state.

Set the local state and notify other members of the channel that it has changed.

### Possible Errors

- Network Error
Raised when there is an error reading from or writing to the network.
- Not Available
Raised when the requested functionality is temporarily unavailable.
- Invalid Argument
Raised when one of the provided arguments is invalid.

# Signals

(Permalink)

## ChatStateChanged (u: Contact, u: State)

### Parameters

- Contact — u (Contact_Handle)
An integer handle for the contact.
- State — u (Channel_Chat_State)
The new state of this contact.

Emitted when the state of a member of the channel has changed. This includes local state.

# Types

Enum (Permalink)

## Channel_Chat_State — u

- Gone (0)
The contact has effectively ceased participating in the chat.
- Inactive (1)
The contact has not been active for some time.
- Active (2)
The contact is actively participating in the chat.
- Paused (3)
The contact has paused composing a message.
- Composing (4)
The contact is composing a message to be sent to the chat.