InvokeTimerRequest
Since: BlackBerry 10.3.0
#include <bb/system/InvokeTimerRequest>
To link against this class, add the following line to your .pro file: LIBS += -lbbsystem
Encapsulates a request to register a timer with the invocation service.
The register timer trigger request message is sent to the invocation service to register a new invocation timer trigger.
Overview
Public Types Index
enum TypeUnknown 0, SpecificTime 1, RecurrentRule 2 |
Public Functions Index
InvokeTimerRequest () | |
InvokeTimerRequest (const QString &timerId, const InvokeDateTime &specificTime, const QString &target) | |
InvokeTimerRequest (const QString &timerId, const InvokeRecurrenceRule &recurrenceRule, const QString &target) | |
InvokeTimerRequest (const InvokeTimerRequest &other) | |
virtual | ~InvokeTimerRequest () |
bool | isValid () const |
InvokeTimerRequest & | operator= (const InvokeTimerRequest &other) |
bb::system::InvokeRecurrenceRule | recurrenceRule () const |
void | set (const QString &timerId, const InvokeDateTime &specificTime, const QString &target) |
void | set (const QString &timerId, const InvokeRecurrenceRule &recurrenceRule, const QString &target) |
bb::system::InvokeDateTime | specificTime () const |
QString | target () const |
QString | timerId () const |
InvokeTimerRequest::Type | type () const |
Public Types
The kinds of timer requests.
BlackBerry 10.0.0
- Unknown 0
Unknown type.
- SpecificTime 1
Type of timer request that allows you to specify an InvokeDateTime.
Since:BlackBerry 10.0.0
- RecurrentRule 2
Type of timer request that allows you to specify an InvokeRecurrenceRule.
Since:BlackBerry 10.0.0
Public Functions
Creates an InvokeTimerRequest object.
The timer request parameters need to be set by calling set().
BlackBerry 10.3.0
Creates an InvokeTimerRequest object.
Parameters | |
---|---|
timerId |
The ID for this request. A timer must have a timer ID attribute. The timer ID is used to uniquely identify and deregister the timer within an application package. |
specificTime |
The InvokeDateTime representing the specific time for the timer. If the specificTime is of type InvokeDateTime::Anchored, the assigned time zone may or may not be recognized. If the assigned time zone is not recognized, the timer registration request will fail. |
target |
The target to invoke |
BlackBerry 10.3.0
Creates an InvokeTimerRequest object.
Parameters | |
---|---|
timerId |
The ID for this request. A timer must have a timer ID attribute. The timer ID is used to uniquely identify and deregister the timer within an application package. Recurrence rules have to be explicitly deregistered unlike specific timers (that is, timers with type InvokeTimerRequest::SpecificTime), which expire on completion. You must save the timerId to be used later for deregistering the recurrence rule. Otherwise, the timer stays registered and active forever. |
recurrenceRule |
A recurrence rule that specifies the interval at which to trigger a headless application |
target |
The target to invoke |
BlackBerry 10.3.0
Creates a copy of an existing InvokeTimerRequest object.
Parameters | |
---|---|
other |
The source InvokeTimerRequest object to copy. |
BlackBerry 10.3.0
virtual
Destructor.
BlackBerry 10.3.0
bool
Returns true if this InvokeTimerRequest object is valid.
The method returns true if the target and the timerId representing this InvokeTimerRequest object are not empty and the specificTime is valid or recurrenceRule is valid depending on the type of the request.
true if valid, false otherwise.
BlackBerry 10.3.0
InvokeTimerRequest &
Copies the data of an existing InvokeTimerRequest object to this object.
Parameters | |
---|---|
other |
The source InvokeTimerRequest object to copy. |
The InvokeTimerRequest instance.
BlackBerry 10.3.0
bb::system::InvokeRecurrenceRule
Returns the assigned recurrence rule.
The recurrence rule that was previously set.
BlackBerry 10.3.0
void
Sets the parameters for the timer request of InvokeTimerRequest::SpecificTime type.
Parameters | |
---|---|
timerId |
The ID for this request. A timer must have a timer ID attribute. The timer ID is used to uniquely identify and deregister the timer within an application package. |
specificTime |
The InvokeDateTime representing the specific time for the timer. If the specificTime is of type InvokeDateTime::Anchored, the assigned time zone may or may not be recognized. If the assigned time zone is not recognized, the timer registration request will fail. |
target |
The target to invoke. |
BlackBerry 10.3.0
void
Sets the parameters for the timer request of InvokeTimerRequest::RecurrentRule type.
Parameters | |
---|---|
timerId |
The ID for this request. A timer must have a timer ID attribute. The timer ID is used to uniquely identify and deregister the timer within an application package. Recurrence rules have to be explicitly deregistered unlike specific timers (that is, timers with type InvokeTimerRequest::SpecificTime), which expire on completion. You must save the timerId to be used later for deregistering the recurrence rule. Otherwise, the timer would stay registered and active forever. |
recurrenceRule |
A recurrence rule that specifies the interval at which to trigger a headless application |
target |
The target to invoke |
BlackBerry 10.3.0
bb::system::InvokeDateTime
Returns the assigned specific time.
The specific time that was previously set.
BlackBerry 10.3.0
QString
Returns the assigned target.
The target that was previously set or an empty string.
BlackBerry 10.3.0
QString
Returns the assigned timer ID.
Recurrence rules have to be explicitly deregistered unlike specific timers, which expire on completion. You must save the timerId to be used later for deregistering the recurrence rule. Otherwise, the timer would stay registered and active forever.
The timer ID that was previously set or an empty string.
BlackBerry 10.3.0
InvokeTimerRequest::Type
Returns the timer type.
One of the timer types defined in InvokeTimerRequest::Type.
BlackBerry 10.3.0