Home > Class Reference > ENSLIB namespace > EnsLib.PushNotifications.IdentityManager.DeviceTracking

EnsLib.PushNotifications.IdentityManager.DeviceTracking

persistent class EnsLib.PushNotifications.IdentityManager.DeviceTracking extends %Library.Persistent, %XML.Adaptor

SQL Table Name: EnsLib_PushNotifications_IdentityManager.DeviceTracking

Zen Mobile Cloud Messaging Device Tracking

Property Inventory (Including Private)

Method Inventory (Including Private)

Properties (Including Private)

property AppIdentifier as %String (MAXLEN = 512) [ Required ];
App Identifier
Property methods: AppIdentifierDisplayToLogical(), AppIdentifierGet(), AppIdentifierGetStored(), AppIdentifierIndexExists(), AppIdentifierIsValid(), AppIdentifierLogicalToDisplay(), AppIdentifierLogicalToOdbc(), AppIdentifierNormalize(), AppIdentifierSet()
property AssociatedAppTokens as list of %String (MAXLEN = 512) [ Required ];
Associated Application Token
Property methods: AssociatedAppTokensBuildValueArray(), AssociatedAppTokensCollectionToDisplay(), AssociatedAppTokensCollectionToOdbc(), AssociatedAppTokensDisplayToCollection(), AssociatedAppTokensDisplayToLogical(), AssociatedAppTokensGet(), AssociatedAppTokensGetObject(), AssociatedAppTokensGetObjectId(), AssociatedAppTokensGetStored(), AssociatedAppTokensGetSwizzled(), AssociatedAppTokensIsValid(), AssociatedAppTokensLogicalToDisplay(), AssociatedAppTokensLogicalToOdbc(), AssociatedAppTokensNormalize(), AssociatedAppTokensOdbcToCollection(), AssociatedAppTokensSet(), AssociatedAppTokensSetObject(), AssociatedAppTokensSetObjectId()
property Identifier as %String (MAXLEN = 512) [ Required ];
Device Identifier (i.e. DeviceToken, or Registration Id)
Property methods: IdentifierDisplayToLogical(), IdentifierGet(), IdentifierGetStored(), IdentifierIndexExists(), IdentifierIsValid(), IdentifierLogicalToDisplay(), IdentifierLogicalToOdbc(), IdentifierNormalize(), IdentifierSet()
property LastUpdatedUTC as %TimeStamp [ InitialExpression = $ZDT($system.Util.LocalWithZTIMEZONEtoUTC($H),3) , Required ];
Last updated-at timestamp
Property methods: LastUpdatedUTCDisplayToLogical(), LastUpdatedUTCGet(), LastUpdatedUTCGetStored(), LastUpdatedUTCIsValid(), LastUpdatedUTCLogicalToDisplay(), LastUpdatedUTCLogicalToXSD(), LastUpdatedUTCNormalize(), LastUpdatedUTCOdbcToLogical(), LastUpdatedUTCSet(), LastUpdatedUTCXSDToLogical()
property Service as %String (DISPLAYLIST = ",Apple Push Notification Service,Google Cloud Messaging", VALUELIST = ",APNS,GCM") [ Required ];
Service type descriptor
Property methods: ServiceDisplayToLogical(), ServiceGet(), ServiceGetStored(), ServiceIndexExists(), ServiceIsValid(), ServiceLogicalToDisplay(), ServiceLogicalToOdbc(), ServiceNormalize(), ServiceSet()

Methods (Including Private)

classmethod AssociateDeviceWithAppToken(pIdentifier As %String, pAppId As %String, pService As %String, pAppToken As %String) as %Status
Associate an application token with a deviceid/appid
classmethod DisassociateDeviceWithAppToken(pIdentifier As %String, pAppId As %String, pService As %String, pAppToken As %String) as %Status
Disassociate an application token with a identifier/appid
classmethod FindDeviceByAppToken(pAppToken As %String, ByRef pDevice As EnsLib.PushNotifications.IdentityManager.DeviceTracking) as %Status
Locate a device tracking object by an app token
classmethod FindDeviceByDeviceAndAppIds(pIdentifier As %String, pAppId As %String, pService As %String, ByRef pDevice As EnsLib.PushNotifications.IdentityManager.DeviceTracking, pCreate As %Boolean = 0) as %Status
Helper to locate and/or create a device tracking object from a deviceid/appid pair

Queries

query DeviceSearchByAppToken(pAppToken As %String)
SQL Query:
SELECT %ID, Service, Identifier, LastUpdatedUTC FROM DeviceTracking WHERE FOR SOME %ELEMENT(AssociatedAppTokens) (%Value = :pAppToken)
Search for devices matching the associated app token

Indexes

index (AppIdentifierIndex on AppIdentifier);
Index the app identifier
Index methods: AppIdentifierIndexExists()
index (AssociatedAppTokensIndex on AssociatedAppTokens(ELEMENTS));
Index the associated app tokens (all of them) with this object
index (IdentifierIndex on Identifier);
Index the device identifier
Index methods: IdentifierIndexExists()
index (ServiceIndex on Service);
Index the service
Index methods: ServiceIndexExists()

Inherited Members

Inherited Methods (Including Private)