Show / Hide Table of Contents

Class NSPocketNotificationMessage

Describes behavior and content for a push notification message.

Syntax

Constructors

NSPocketNotificationMessage()

Initializes a new instance of the NSPocketNotificationMessage class.

Declaration
NSPocketNotificationMessage

Methods

GetDate()

Describes behavior and content for a push notification message.

Declaration
DateTime GetDate()
Returns
Type Description
DateTime

If the message is about some event happening at a specific date and time.

Examples
NSPocketNotificationMessage thing;
DateTime date = thing.GetDate();

GetDuration()

Describes behavior and content for a push notification message.

Declaration
TimeSpan GetDuration()
Returns
Type Description
TimeSpan

Specify duration of the event.

Examples
NSPocketNotificationMessage thing;
TimeSpan duration = thing.GetDuration();

GetExtraValues()

Describes behavior and content for a push notification message.

Declaration
Map GetExtraValues()
Returns
Type Description
Map

Additional key/value properties to include in the message.

Examples
NSPocketNotificationMessage thing;
Map extraValues = thing.GetExtraValues();

GetMessage()

Describes behavior and content for a push notification message.

Declaration
String GetMessage()
Returns
Type Description
String

The notification message body.

Examples
NSPocketNotificationMessage thing;
String message = thing.GetMessage();

GetRecordId()

Describes behavior and content for a push notification message.

Declaration
Integer GetRecordId()
Returns
Type Description
Integer

If the message is about some specific database record, this could be its primary key.

Examples
NSPocketNotificationMessage thing;
Integer recordId = thing.GetRecordId();

GetSilent()

Describes behavior and content for a push notification message.

Declaration
Bool GetSilent()
Returns
Type Description
Bool

Indicates wether or not the message will vibrate/play a sound when delivered.

Examples
NSPocketNotificationMessage thing;
Bool silent = thing.GetSilent();

GetTimeToLive()

Describes behavior and content for a push notification message.

Declaration
Integer GetTimeToLive()
Returns
Type Description
Integer

Specifies how many minutes the message should be valid.

Examples
NSPocketNotificationMessage thing;
Integer timeToLive = thing.GetTimeToLive();

GetTitle()

Describes behavior and content for a push notification message.

Declaration
String GetTitle()
Returns
Type Description
String

Title for the notification.

Examples
NSPocketNotificationMessage thing;
String title = thing.GetTitle();

GetType()

Describes behavior and content for a push notification message.

Declaration
Integer GetType()
Returns
Type Description
Integer

The type of notification this is. See NotificationMessageType.

Examples
NSPocketNotificationMessage thing;
Integer type = thing.GetType();

GetUrl()

Describes behavior and content for a push notification message.

Declaration
String GetUrl()
Returns
Type Description
String

A URL associated with the notification that will be handled by Pocket.

Examples
NSPocketNotificationMessage thing;
String url = thing.GetUrl();

SetDate(DateTime)

Describes behavior and content for a push notification message.

Declaration
Void SetDate(DateTime date)
Parameters
Type Name Description
DateTime date

If the message is about some event happening at a specific date and time.

Returns
Type Description
Void
Examples
NSPocketNotificationMessage thing;
DateTime date;
thing.SetDate(date);

SetDuration(TimeSpan)

Describes behavior and content for a push notification message.

Declaration
Void SetDuration(TimeSpan duration)
Parameters
Type Name Description
TimeSpan duration

Specify duration of the event.

Returns
Type Description
Void
Examples
NSPocketNotificationMessage thing;
TimeSpan duration;
thing.SetDuration(duration);

SetExtraValues(Map)

Describes behavior and content for a push notification message.

Declaration
Void SetExtraValues(Map extraValues)
Parameters
Type Name Description
Map extraValues

Additional key/value properties to include in the message.

Returns
Type Description
Void
Examples
NSPocketNotificationMessage thing;
Map extraValues;
thing.SetExtraValues(extraValues);

SetMessage(String)

Describes behavior and content for a push notification message.

Declaration
Void SetMessage(String message)
Parameters
Type Name Description
String message

The notification message body.

Returns
Type Description
Void
Examples
NSPocketNotificationMessage thing;
String message;
thing.SetMessage(message);

SetRecordId(Integer)

Describes behavior and content for a push notification message.

Declaration
Void SetRecordId(Integer recordId)
Parameters
Type Name Description
Integer recordId

If the message is about some specific database record, this could be its primary key.

Returns
Type Description
Void
Examples
NSPocketNotificationMessage thing;
Integer recordId;
thing.SetRecordId(recordId);

SetSilent(Bool)

Describes behavior and content for a push notification message.

Declaration
Void SetSilent(Bool silent)
Parameters
Type Name Description
Bool silent

Indicates wether or not the message will vibrate/play a sound when delivered.

Returns
Type Description
Void
Examples
NSPocketNotificationMessage thing;
Bool silent;
thing.SetSilent(silent);

SetTimeToLive(Integer)

Describes behavior and content for a push notification message.

Declaration
Void SetTimeToLive(Integer timeToLive)
Parameters
Type Name Description
Integer timeToLive

Specifies how many minutes the message should be valid.

Returns
Type Description
Void
Examples
NSPocketNotificationMessage thing;
Integer timeToLive;
thing.SetTimeToLive(timeToLive);

SetTitle(String)

Describes behavior and content for a push notification message.

Declaration
Void SetTitle(String title)
Parameters
Type Name Description
String title

Title for the notification.

Returns
Type Description
Void
Examples
NSPocketNotificationMessage thing;
String title;
thing.SetTitle(title);

SetType(Integer)

Describes behavior and content for a push notification message.

Declaration
Void SetType(Integer type)
Parameters
Type Name Description
Integer type

The type of notification this is. See NotificationMessageType.

Returns
Type Description
Void
Examples
NSPocketNotificationMessage thing;
Integer type;
thing.SetType(type);

SetUrl(String)

Describes behavior and content for a push notification message.

Declaration
Void SetUrl(String url)
Parameters
Type Name Description
String url

A URL associated with the notification that will be handled by Pocket.

Returns
Type Description
Void
Examples
NSPocketNotificationMessage thing;
String url;
thing.SetUrl(url);
In This Article
© SuperOffice. All rights reserved.
SuperOffice |  Community |  Release Notes |  Privacy |  Site feedback |  Search Docs |  About Docs |  Contribute |  Back to top