From 35d9efe1fa71985f7368a3e66ba6a265fb1a4d9d Mon Sep 17 00:00:00 2001
From: Simon McVittie
Channel handlers are the eventual handler for a channel or a - channel bundle; a typical channel handler is a user interface - process handling channels of a particular type.
+Handlers are the user interface for a channel. They turn an abstract + Telepathy channel into something the user wants to see, like a text + message stream or an audio and/or video call.
+ +For its entire lifetime, each channel on a connection known to the + channel dispatcher is either being processed by the channel dispatcher, + or being handled by precisely one Handler.
+ +Because each channel is only handled by one Handler, handlers may
+ perform actions that only make sense to do once, such as acknowledging
+
When a new incoming channel (one with
This property works in exactly the same way as the
-
In the .client file, it is represented in the same way as ObserverChannelFilter, but the group has the same name as this interface and the keys start with HandlerChannelFilter instead of ObserverChannelFilter.
@@ -105,13 +123,14 @@ paths. -This method can raise any D-Bus error. If it does, or if the - handler loses its bus name before all the channels have closed, the +
This method can raise any D-Bus error. If it does, the handler is assumed to have failed or crashed, and the channel - dispatcher MUST recover in an implementation-specific way.
+ dispatcher MUST recover in an implementation-specific way; it MAY + attempt to dispatch the channels to another handler, or close the + channels. -It is RECOMMENDED that the channel dispatcher attempts to - close the channels using +
If closing the channels, it is RECOMMENDED that the channel
+ dispatcher attempts to close the channels using
After HandleChannels returns successfully, the client process is + considered to be responsible for the channel until it its unique + name disappears from the bus.
+ +If a process has multiple Client bus names - some temporary and + some long-lived - and drops one of the temporary bus names in order + to reduce the set of channels that it will handle, any channels + that it is already handling should remain unaffected.
+The requests satisfied by these channels.
If the handler implements Requests, this tells it
+ that these channels match previous
There can be more than one, if they were EnsureChannel + requests.
Called by the ChannelDispatcher to indicate that channels have been - requested, and that if the request is successful, they will be - handled by this Handler.
- -This allows the UI to start preparing to handle the channels - in advance (e.g. render a window with an "in progress" message), - improving perceived responsiveness.
-(FIXME: how do we know the returned channels will be handled by - this handler? Do we just assume that they'll match the - HandlerChannelFilter iff the request does?)
-Some of the properties of the ChannelRequest. To avoid race - conditions, this dictionary MUST NOT include properties whose - values could subsequently change. It SHOULD include as many - properties as possible, given that constraint.
- -In particular, the properties
Called by the ChannelDispatcher to indicate that a request
- previously passed to
The name of the D-Bus error with which the request failed.
+Additional information about these channels. No keys are + currently defined.
-If this is org.freedesktop.Telepathy.Error.NotYours
,
- this indicates that the request succeeded, but all the resulting
- channels were given to some other handler.
If keys are defined for this dictionary, all will be optional; + handlers MAY safely ignore any entry in this dictionary.
A list of the channels that this Handler is currently handling. -
+A list of the channels that this process is currently handling.
There is no change notification.
@@ -272,6 +235,17 @@ the user is that unhandled channels that they have already approved might be sent back to Approvers. + +The value of this property SHOULD be the same for all Client + instances that share a unique bus name, and SHOULD include all + channels that are being handled, even if they were conceptually + handled by a different Client instance.
+ +Otherwise, when a process released a temporary Client name, + channels that it handled because of that Client name would no + longer be state-recoverable.
+