Horde_Alarm_Handler_Desktop
extends Horde_Alarm_Handler
in package
The Horde_Alarm_Handler_Desktop class is a Horde_Alarm handler that notifies of active alarms by desktop notification through webkit browsers.
Tags
Table of Contents
- $alarm : mixed
- The alarm object to that this handler is attached.
- $_icon : string
- An icon URL.
- $_jsNotify : callable
- A notification callback.
- __construct() : mixed
- Constructor.
- getDescription() : string
- Returns a human readable description of the handler.
- getParameters() : array<string|int, mixed>
- Returns a hash of user-configurable parameters for the handler.
- notify() : mixed
- Notifies about an alarm through javascript.
- reset() : mixed
- Resets the internal status of the handler, so that alarm notifications are sent again.
Properties
$alarm
The alarm object to that this handler is attached.
public
mixed
$alarm
Horde_Alarm
$_icon
An icon URL.
protected
string
$_icon
$_jsNotify
A notification callback.
protected
callable
$_jsNotify
Methods
__construct()
Constructor.
public
__construct([array<string|int, mixed> $params = null ]) : mixed
Parameters
- $params : array<string|int, mixed> = null
-
Any parameters that the handler might need. Required parameter:
- js_notify: A Horde_Notification_Handler instance. Optional parameter:
- icon: URL of an icon to display.
Return values
mixed —getDescription()
Returns a human readable description of the handler.
public
getDescription() : string
Return values
string —getParameters()
Returns a hash of user-configurable parameters for the handler.
public
getParameters() : array<string|int, mixed>
The parameters are hashes with parameter names as keys and parameter information as values. The parameter information is a hash with the following keys:
- type: the parameter type as a preference type.
- desc: a parameter description.
- required: whether this parameter is required.
Return values
array<string|int, mixed> —notify()
Notifies about an alarm through javascript.
public
notify(array<string|int, mixed> $alarm) : mixed
Parameters
- $alarm : array<string|int, mixed>
-
An alarm hash.
Return values
mixed —reset()
Resets the internal status of the handler, so that alarm notifications are sent again.
public
reset(array<string|int, mixed> $alarm) : mixed
Parameters
- $alarm : array<string|int, mixed>
-
An alarm hash.