MeeGo 1.2 Harmattan Developer Documentation Develop for the Nokia N9
   Home · All Classes · All Namespaces · Modules · Functions · Files

Tp::Client::ChannelInterfaceGroupInterface Class Reference
[Channel proxies]

#include <TelepathyQt4/Channel>

Inherits Tp::AbstractInterface.

List of all members.

Public Slots

Signals

Public Member Functions

Static Public Member Functions

Protected Member Functions


Detailed Description

Proxy class providing a 1:1 mapping of the D-Bus interface "org.freedesktop.Telepathy.Channel.Interface.Group."


Constructor & Destructor Documentation

Tp::Client::ChannelInterfaceGroupInterface::ChannelInterfaceGroupInterface ( const QString busName,
const QString objectPath,
QObject parent = 0  
)

Creates a ChannelInterfaceGroupInterface associated with the given object on the session bus.

Parameters:
busName  Name of the service the object is on.
objectPath  Path to the object on the service.
parent  Passed to the parent class constructor.
Tp::Client::ChannelInterfaceGroupInterface::ChannelInterfaceGroupInterface ( const QDBusConnection connection,
const QString busName,
const QString objectPath,
QObject parent = 0  
)

Creates a ChannelInterfaceGroupInterface associated with the given object on the given bus.

Parameters:
connection  The bus via which the object can be reached.
busName  Name of the service the object is on.
objectPath  Path to the object on the service.
parent  Passed to the parent class constructor.
Tp::Client::ChannelInterfaceGroupInterface::ChannelInterfaceGroupInterface ( Tp::DBusProxy proxy  ) 

Creates a ChannelInterfaceGroupInterface associated with the same object as the given proxy.

Parameters:
proxy  The proxy to use. It will also be the QObject::parent() for this object.
Tp::Client::ChannelInterfaceGroupInterface::ChannelInterfaceGroupInterface ( const Tp::Client::ChannelInterface mainInterface  )  [explicit]

Creates a ChannelInterfaceGroupInterface associated with the same object as the given proxy. Additionally, the created proxy will have the same parent as the given proxy.

Parameters:
mainInterface  The proxy to use.
Tp::Client::ChannelInterfaceGroupInterface::ChannelInterfaceGroupInterface ( const Tp::Client::ChannelInterface mainInterface,
QObject parent  
)

Creates a ChannelInterfaceGroupInterface associated with the same object as the given proxy. However, a different parent object can be specified.

Parameters:
mainInterface  The proxy to use.
parent  Passed to the parent class constructor.

Member Function Documentation

static QLatin1String Tp::Client::ChannelInterfaceGroupInterface::staticInterfaceName (  )  [inline, static]

Returns the name of the interface "org.freedesktop.Telepathy.Channel.Interface.Group", which this class represents.

Returns:
The D-Bus interface name.
Tp::PendingVariant* Tp::Client::ChannelInterfaceGroupInterface::requestPropertyGroupFlags (  )  const [inline]

Asynchronous getter for the remote object property GroupFlags of type uint.

An integer representing the bitwise-OR of flags on this channel. The user interface can use this to present information about which operations are currently valid. Change notification is via the GroupFlagsChanged signal.

Returns:
A pending variant which will emit finished when the property has been retrieved.
Tp::PendingVariant* Tp::Client::ChannelInterfaceGroupInterface::requestPropertyHandleOwners (  )  const [inline]

Asynchronous getter for the remote object property HandleOwners of type Tp::HandleOwnerMap.

A map from channel-specific handles to their owners, including at least all of the channel-specific handles in this channel's members, local-pending or remote-pending sets as keys. Any handle not in the keys of this mapping is not channel-specific in this channel. Handles which are channel-specific, but for which the owner is unknown, MUST appear in this mapping with 0 as owner. Change notification is via the HandleOwnersChanged signal.

Returns:
A pending variant which will emit finished when the property has been retrieved.
Tp::PendingVariant* Tp::Client::ChannelInterfaceGroupInterface::requestPropertyLocalPendingMembers (  )  const [inline]

Asynchronous getter for the remote object property LocalPendingMembers of type Tp::LocalPendingInfoList.

An array of structs containing handles representing contacts requesting channel membership and awaiting local approval with AddMembers.

Returns:
A pending variant which will emit finished when the property has been retrieved.
Tp::PendingVariant* Tp::Client::ChannelInterfaceGroupInterface::requestPropertyMembers (  )  const [inline]

Asynchronous getter for the remote object property Members of type Tp::UIntList.

The members of this channel.

Returns:
A pending variant which will emit finished when the property has been retrieved.
Tp::PendingVariant* Tp::Client::ChannelInterfaceGroupInterface::requestPropertyRemotePendingMembers (  )  const [inline]

Asynchronous getter for the remote object property RemotePendingMembers of type Tp::UIntList.

An array of handles representing contacts who have been invited to the channel and are awaiting remote approval.

Returns:
A pending variant which will emit finished when the property has been retrieved.
Tp::PendingVariant* Tp::Client::ChannelInterfaceGroupInterface::requestPropertySelfHandle (  )  const [inline]

Asynchronous getter for the remote object property SelfHandle of type uint.

The handle for the user on this channel (which can also be a local or remote pending member), or 0 if the user is not a member at all (which is likely to be the case, for instance, on ContactList channels). Note that this is different from the result of Connection.GetSelfHandle on some protocols, so the value of this handle should always be used with the methods of this interface.

Returns:
A pending variant which will emit finished when the property has been retrieved.
Tp::PendingVariantMap* Tp::Client::ChannelInterfaceGroupInterface::requestAllProperties (  )  const [inline]

Request all of the DBus properties on the interface.

Returns:
A pending variant map which will emit finished when the properties have been retrieved.
QDBusPendingReply Tp::Client::ChannelInterfaceGroupInterface::AddMembers ( const Tp::UIntList contacts,
const QString message,
int  timeout = -1  
) [inline, slot]

Begins a call to the D-Bus method AddMembers on the remote object.

Invite all the given contacts into the channel, or accept requests for channel membership for contacts on the pending local list.

A message may be provided along with the request, which will be sent to the server if supported. See the CHANNEL_GROUP_FLAG_MESSAGE_ADD and CHANNEL_GROUP_FLAG_MESSAGE_ACCEPT GroupFlags to see in which cases this message should be provided.

Attempting to add contacts who are already members is allowed; connection managers must silently accept this, without error.

Note that timeout is ignored as of now. It will be used once http://bugreports.qt.nokia.com/browse/QTBUG-11775 is fixed.

Parameters:
contacts  An array of contact handles to invite to the channel
message  A string message, which can be blank if desired
timeout  The timeout in milliseconds.
QDBusPendingReply<Tp::UIntList, Tp::UIntList, Tp::UIntList> Tp::Client::ChannelInterfaceGroupInterface::GetAllMembers ( int  timeout = -1  )  [inline, slot]

Begins a call to the D-Bus method GetAllMembers on the remote object.

Returns arrays of all current, local and remote pending channel members.

Note that timeout is ignored as of now. It will be used once http://bugreports.qt.nokia.com/browse/QTBUG-11775 is fixed.

Parameters:
timeout  The timeout in milliseconds.
Returns:

array of handles of current members

Returns:

array of handles of local pending members

Returns:

array of handles of remote pending members

QDBusPendingReply<uint> Tp::Client::ChannelInterfaceGroupInterface::GetGroupFlags ( int  timeout = -1  )  [inline, slot]

Begins a call to the D-Bus method GetGroupFlags on the remote object.

Returns the value of the GroupFlags property.

Note that timeout is ignored as of now. It will be used once http://bugreports.qt.nokia.com/browse/QTBUG-11775 is fixed.

Parameters:
timeout  The timeout in milliseconds.
Returns:

The value of the GroupFlags property

QDBusPendingReply<Tp::UIntList> Tp::Client::ChannelInterfaceGroupInterface::GetHandleOwners ( const Tp::UIntList handles,
int  timeout = -1  
) [inline, slot]

Begins a call to the D-Bus method GetHandleOwners on the remote object.

If the CHANNEL_GROUP_FLAG_CHANNEL_SPECIFIC_HANDLES flag is set on the channel, then the handles of the group members are specific to this channel, and are not meaningful in a connection-wide context such as contact lists. This method allows you to find the owner of the handle if it can be discovered in this channel, or 0 if the owner is not available.

Note that timeout is ignored as of now. It will be used once http://bugreports.qt.nokia.com/browse/QTBUG-11775 is fixed.

Parameters:
handles  A list of integer handles representing members of the channel
timeout  The timeout in milliseconds.
Returns:

An array of integer handles representing the owner handles of the given room members, in the same order, or 0 if the owner is not available

QDBusPendingReply<Tp::UIntList> Tp::Client::ChannelInterfaceGroupInterface::GetLocalPendingMembers ( int  timeout = -1  )  [inline, slot]

Begins a call to the D-Bus method GetLocalPendingMembers on the remote object.

Returns the To_Be_Added handle (only) for each structure in the LocalPendingMembers property.

Note that timeout is ignored as of now. It will be used once http://bugreports.qt.nokia.com/browse/QTBUG-11775 is fixed.

Parameters:
timeout  The timeout in milliseconds.
QDBusPendingReply<Tp::LocalPendingInfoList> Tp::Client::ChannelInterfaceGroupInterface::GetLocalPendingMembersWithInfo ( int  timeout = -1  )  [inline, slot]

Begins a call to the D-Bus method GetLocalPendingMembersWithInfo on the remote object.

Returns the LocalPendingMembers property.

Note that timeout is ignored as of now. It will be used once http://bugreports.qt.nokia.com/browse/QTBUG-11775 is fixed.

Parameters:
timeout  The timeout in milliseconds.
Returns:

An array of structs containing: A handle representing the contact requesting channel membership A handle representing the contact making the request, or 0 if unknown The reason for the request: one of the values of Channel_Group_Change_Reason A string message containing the reason for the request if any (or blank if none)

QDBusPendingReply<Tp::UIntList> Tp::Client::ChannelInterfaceGroupInterface::GetMembers ( int  timeout = -1  )  [inline, slot]

Begins a call to the D-Bus method GetMembers on the remote object.

Returns the Members property.

Note that timeout is ignored as of now. It will be used once http://bugreports.qt.nokia.com/browse/QTBUG-11775 is fixed.

Parameters:
timeout  The timeout in milliseconds.
QDBusPendingReply<Tp::UIntList> Tp::Client::ChannelInterfaceGroupInterface::GetRemotePendingMembers ( int  timeout = -1  )  [inline, slot]

Begins a call to the D-Bus method GetRemotePendingMembers on the remote object.

Returns an array of handles representing contacts who have been invited to the channel and are awaiting remote approval.

Note that timeout is ignored as of now. It will be used once http://bugreports.qt.nokia.com/browse/QTBUG-11775 is fixed.

Parameters:
timeout  The timeout in milliseconds.
QDBusPendingReply<uint> Tp::Client::ChannelInterfaceGroupInterface::GetSelfHandle ( int  timeout = -1  )  [inline, slot]

Begins a call to the D-Bus method GetSelfHandle on the remote object.

Returns the value of the SelfHandle property.

Note that timeout is ignored as of now. It will be used once http://bugreports.qt.nokia.com/browse/QTBUG-11775 is fixed.

Parameters:
timeout  The timeout in milliseconds.
QDBusPendingReply Tp::Client::ChannelInterfaceGroupInterface::RemoveMembers ( const Tp::UIntList contacts,
const QString message,
int  timeout = -1  
) [inline, slot]

Begins a call to the D-Bus method RemoveMembers on the remote object.

Requests the removal of contacts from a channel, reject their request for channel membership on the pending local list, or rescind their invitation on the pending remote list.

If the SelfHandle is in a Group, it can be removed via this method, in order to leave the group gracefully. This is the recommended way to leave a chatroom, close or reject a ChannelTypeStreamedMediaInterface call, and so on.

Accordingly, connection managers SHOULD support doing this, regardless of the value of GroupFlags . If doing so fails with PermissionDenied, this is considered to a bug in the connection manager, but clients MUST recover by falling back to closing the channel with the ChannelInterface::Close() method.

Removing any contact from the local pending list is always allowed. Removing contacts other than the SelfHandle from the channel's members is allowed if and only if Channel_Group_Flag_Can_Remove is in the GroupFlags , while removing contacts other than the SelfHandle from the remote pending list is allowed if and only if Channel_Group_Flag_Can_Rescind is in the GroupFlags .

A message may be provided along with the request, which will be sent to the server if supported. See the Channel_Group_Flag_Message_Remove, Channel_Group_Flag_Message_Depart, Channel_Group_Flag_Message_Reject and Channel_Group_Flag_Message_Rescind GroupFlags to see in which cases this message should be provided.

Note that timeout is ignored as of now. It will be used once http://bugreports.qt.nokia.com/browse/QTBUG-11775 is fixed.

Parameters:
contacts  An array of contact handles to remove from the channel
message  A string message, which can be blank if desired
timeout  The timeout in milliseconds.
QDBusPendingReply Tp::Client::ChannelInterfaceGroupInterface::RemoveMembersWithReason ( const Tp::UIntList contacts,
const QString message,
uint  reason,
int  timeout = -1  
) [inline, slot]

Begins a call to the D-Bus method RemoveMembersWithReason on the remote object.

As RemoveMembers, but a reason code may be provided where appropriate. The reason code may be ignored if the underlying protocol is unable to represent the given reason.

Note that timeout is ignored as of now. It will be used once http://bugreports.qt.nokia.com/browse/QTBUG-11775 is fixed.

Parameters:
contacts  An array of contact handles to remove from the channel
message  A string message, which can be blank if desired
reason  A reason for the change
timeout  The timeout in milliseconds.
void Tp::Client::ChannelInterfaceGroupInterface::HandleOwnersChanged ( const Tp::HandleOwnerMap added,
const Tp::UIntList removed  
) [signal]

Represents the signal HandleOwnersChanged on the remote object.

Emitted whenever the HandleOwners property changes.

Parameters:
added  A map from channel-specific handles to their owners, in which the keys include all the handles that were added to the keys of the HandleOwners property, and all the handles in that property whose owner has changed
removed  The channel-specific handles that were removed from the keys of the HandleOwners property, as a result of the contact leaving this group in a previous MembersChanged signal
void Tp::Client::ChannelInterfaceGroupInterface::SelfHandleChanged ( uint  selfHandle  )  [signal]

Represents the signal SelfHandleChanged on the remote object.

Emitted whenever the SelfHandle property changes.

Parameters:
selfHandle  The new value of the SelfHandle property.
void Tp::Client::ChannelInterfaceGroupInterface::GroupFlagsChanged ( uint  added,
uint  removed  
) [signal]

Represents the signal GroupFlagsChanged on the remote object.

Emitted when the flags as returned by GetGroupFlags are changed. The user interface should be updated as appropriate.

Parameters:
added  A bitwise OR of the flags which have been set
removed  A bitwise OR of the flags which have been cleared
void Tp::Client::ChannelInterfaceGroupInterface::MembersChanged ( const QString message,
const Tp::UIntList added,
const Tp::UIntList removed,
const Tp::UIntList localPending,
const Tp::UIntList remotePending,
uint  actor,
uint  reason  
) [signal]

Represents the signal MembersChanged on the remote object.

Emitted when contacts join any of the three lists (members, local pending or remote pending) or when they leave any of the three lists. There may also be a message from the server regarding this change, which may be displayed to the user if desired.

All channel-specific handles that are mentioned in this signal MUST be represented in the value of the HandleOwners property. In practice, this will mean that HandleOwnersChanged() is emitted before emitting a MembersChanged signal in which channel-specific handles are added, but that it is emitted after emitting a MembersChanged signal in which channel-specific handles are removed.

See ChannelTypeStreamedMediaInterface for an overview of how group state changes are used to indicate the progress of a call.

Parameters:
message  A string message from the server, or blank if not
added  A list of members added to the channel
removed  A list of members removed from the channel
localPending  A list of members who are pending local approval
remotePending  A list of members who are pending remote approval
actor  The contact handle of the person who made the change, or 0 if not known
reason  A reason for the change
void Tp::Client::ChannelInterfaceGroupInterface::MembersChangedDetailed ( const Tp::UIntList added,
const Tp::UIntList removed,
const Tp::UIntList localPending,
const Tp::UIntList remotePending,
const QVariantMap &  details  
) [signal]

Represents the signal MembersChangedDetailed on the remote object.

Emitted when contacts join any of the three lists (members, local pending or remote pending) or when they leave any of the three lists. This signal provides a superset of the information provided by MembersChanged() ; if the channel's GroupFlags contains Members_Changed_Detailed, then clients may listen exclusively to this signal in preference to that signal.

All channel-specific handles that are mentioned in this signal MUST be represented in the value of the HandleOwners property. In practice, this will mean that HandleOwnersChanged() is emitted before emitting a MembersChangedDetailed signal in which channel-specific handles are added, but that it is emitted after emitting a MembersChangedDetailed signal in which channel-specific handles are removed.

See ChannelTypeStreamedMediaInterface for an overview of how group state changes are used to indicate the progress of a call.

Parameters:
added  A list of members added to the channel
removed  A list of members removed from the channel
localPending  A list of members who are pending local approval
remotePending  A list of members who are pending remote approval
details 

Information about the change, which may include the following well-known keys:

actor (u — Contact_Handle)
The contact handle of the person who made the change; 0 or omitted if unknown or not applicable.
change-reason (u — Channel_Group_Change_Reason)
A reason for the change.
contact-ids (a{us} — Handle_Identifier_Map)

The string identifiers for handles mentioned in this signal, to give clients the minimal information necessary to react to the event without waiting for round-trips. Connection managers SHOULD include the identifiers for members added to the group and for the actor (if any); they MAY omit the identifiers for handles which have been removed from the group.

On IRC, an event such as a netsplit could cause the vast majority of a channel to leave. Given that clients should already know the identifiers of a channel's members, including potentially hundreds of strings in the netsplit signal is unnecessary.

Clients MUST NOT assume that the presence or absence of a handle in this mapping is meaningful. This mapping is merely an optimization for round-trip reduction, and connection managers MAY add additional handles, omit some handles, or omit the mapping completely.

message (s)
A string message from the server regarding the change
error (s — DBus_Error_Name)
A (possibly implementation-specific) DBus error describing the change, providing more specific information than the Channel_Group_Change_Reason enum allows. This MUST only be present if it is strictly more informative than 'change-reason'; if present, 'change-reason' MUST be set to the closest available reason.
A SIP connection manager might want to signal "402 Payment required" as something more specific than Error or Permission_Denied so that a SIP-aware UI could handle it specially; including a namespaced error permits this to be done without Channel_Group_Change_Reason being extended to encompass every error any CM ever wants to report.
debug-message (s)
Debugging information on the change. SHOULD NOT be shown to users in normal circumstances.
void Tp::Client::ChannelInterfaceGroupInterface::invalidate ( Tp::DBusProxy proxy,
const QString error,
const QString message  
) [protected, virtual]

Reimplemented from Tp::AbstractInterface.


Copyright © 2008-2011 Collabora Ltd. and Nokia Corporation
Telepathy-Qt4 0.6.5