jsdoc comments for mpns notifications
This commit is contained in:
Родитель
344c3e8f4a
Коммит
8f229fee6d
|
@ -34,6 +34,11 @@ var templateSpecs = [ 'Toast', 'Tile', 'FlipTile', 'Raw' ];
|
|||
* Creates a new MpnsService object.
|
||||
*
|
||||
* @constructor
|
||||
* __Note__: An instance of this object is created automatically when a {@link NotificationHubService}
|
||||
* object is created. See {@link NotificationHubService#gcm}.
|
||||
* @class
|
||||
* The MpnsService class is used to send notifications using the [Microsoft Push Notification Service](http://msdn.microsoft.com/en-us/library/windowsphone/develop/ff402558).
|
||||
* @constructor
|
||||
*
|
||||
* @param {NotificationHubService} notificationHubService The notification hub service.
|
||||
*/
|
||||
|
@ -168,8 +173,8 @@ function MpnsService(notificationHubService) {
|
|||
*
|
||||
* @param {string} channel The device channel uri.
|
||||
* @param {string|array} tags The tags.
|
||||
* @param {object|function} [optionsOrCallback] The request options or callback function.
|
||||
* @param {function(error, response)} callback The callback function.
|
||||
* @param {object} [options] The request options.
|
||||
* @param {Function(error, response)} callback The callback function.
|
||||
* @return {undefined}
|
||||
*/
|
||||
MpnsService.prototype.createNativeRegistration = function (channel, tags, optionsOrCallback, callback) {
|
||||
|
@ -193,10 +198,10 @@ MpnsService.prototype.createNativeRegistration = function (channel, tags, option
|
|||
* @param {string} channel The device channel uri.
|
||||
* @param {string|array} tags The tags.
|
||||
* @param {json} template The template for the registration.
|
||||
* @param {object|function} [optionsOrCallback] The request options or callback function.
|
||||
* @param {object|function} [optionsOrCallback.pnsCredentialName] The pns credentials to use.
|
||||
* @param {object|function} [optionsOrCallback.headers] The mpns headers to include.
|
||||
* @param {function(error, response)} callback The callback function.
|
||||
* @param {object} [options] The request options.
|
||||
* @param {object} [options.pnsCredentialName] The pns credentials to use.
|
||||
* @param {object} [options.headers] The mpns headers to include.
|
||||
* @param {Function(error, response)} callback The callback function.
|
||||
* @return {undefined}
|
||||
*/
|
||||
MpnsService.prototype.createRawTemplateRegistration = function (channel, tags, template, optionsOrCallback, callback) {
|
||||
|
@ -221,11 +226,11 @@ MpnsService.prototype.createRawTemplateRegistration = function (channel, tags, t
|
|||
* @param {string} channel The device channel uri.
|
||||
* @param {string|array} tags The tags.
|
||||
* @param {json} template The template for the registration.
|
||||
* @param {object|function} [optionsOrCallback] The request options or callback function.
|
||||
* @param {object|function} [optionsOrCallback.pnsCredentialName] The pns credentials to use.
|
||||
* @param {object|function} [optionsOrCallback.headers] The mpns headers to include.
|
||||
* @param {object|function} [optionsOrCallback.etag] The etag to include.
|
||||
* @param {function(error, response)} callback The callback function.
|
||||
* @param {object} [options] The request options.
|
||||
* @param {object} [options.pnsCredentialName] The pns credentials to use.
|
||||
* @param {object} [options.headers] The mpns headers to include.
|
||||
* @param {object} [options.etag] The etag to include.
|
||||
* @param {Function(error, response)} callback The callback function.
|
||||
* @return {undefined}
|
||||
*/
|
||||
MpnsService.prototype.updatesRawTemplateRegistration = function (registrationId, channel, tags, template, optionsOrCallback, callback) {
|
||||
|
@ -253,10 +258,10 @@ MpnsService.prototype.updatesRawTemplateRegistration = function (registrationId,
|
|||
* Retrieves a registration by channel.
|
||||
*
|
||||
* @param {string} channel The registration identifier.
|
||||
* @param {object|function} [optionsOrCallback] The request options or callback function. Additional properties will be passed as headers.
|
||||
* @param {object|function} [optionsOrCallback.top] Specifies the maximum number of registration to obtain from the call.
|
||||
* @param {object|function} [optionsOrCallback.skip] Specifies the number of registrations to skip in the call.
|
||||
* @param {function(error, response)} callback The callback function.
|
||||
* @param {object} [options] The request options. Additional properties will be passed as headers.
|
||||
* @param {object} [options.top] Specifies the maximum number of registration to obtain from the call.
|
||||
* @param {object} [options.skip] Specifies the number of registrations to skip in the call.
|
||||
* @param {Function(error, response)} callback The callback function.
|
||||
* @return {undefined}
|
||||
*/
|
||||
MpnsService.prototype.listRegistrationsByChannel = function (channel, optionsOrCallback, callback) {
|
||||
|
@ -288,9 +293,9 @@ MpnsService.prototype.listRegistrationsByChannel = function (channel, optionsOrC
|
|||
* @param {string} payload The message's XML payload.
|
||||
* @param {string} targetName The target name.
|
||||
* @param {string} notificationClass The notification class.
|
||||
* @param {object|function} [optionsOrCallback] The request options or callback function.
|
||||
* @param {object|function} [optionsOrCallback.headers] The mpns headers.
|
||||
* @param {function(error, response)} callback The callback function.
|
||||
* @param {object} [options] The request options.
|
||||
* @param {object} [options.headers] The mpns headers.
|
||||
* @param {Function(error, response)} callback The callback function.
|
||||
* @return {undefined}
|
||||
*/
|
||||
MpnsService.prototype.send = function (tags, payload, targetName, notificationClass, optionsOrCallback, callback) {
|
||||
|
@ -335,9 +340,9 @@ MpnsService.prototype.send = function (tags, payload, targetName, notificationCl
|
|||
* @param {string} channel The device channel uri.
|
||||
* @param {string|array} tags The tags.
|
||||
* @param {json} template The template for the registration.
|
||||
* @param {object|function} [options] The request options or callback function.
|
||||
* @param {object|function} [options.pnsCredentialName] The pns credentials to use.
|
||||
* @param {object|function} [options.headers] The mpns headers to include.
|
||||
* @param {object} [options] The request options.
|
||||
* @param {object} [options.pnsCredentialName] The pns credentials to use.
|
||||
* @param {object} [options.headers] The mpns headers to include.
|
||||
* @return {undefined}
|
||||
*/
|
||||
MpnsService.prototype._createBody = function (elementName, channel, tags, template, options) {
|
||||
|
@ -390,9 +395,9 @@ MpnsService.prototype._createBody = function (elementName, channel, tags, templa
|
|||
* @param {string} channel The device channel uri.
|
||||
* @param {string|array} tags The tags.
|
||||
* @param {json} template The template for the registration.
|
||||
* @param {object|function} [options] The request options or callback function.
|
||||
* @param {object|function} [options.pnsCredentialName] The pns credentials to use.
|
||||
* @param {object|function} [options.headers] The mpns headers to include.
|
||||
* @param {object} [options] The request options.
|
||||
* @param {object} [options.pnsCredentialName] The pns credentials to use.
|
||||
* @param {object} [options.headers] The mpns headers to include.
|
||||
* @return {undefined}
|
||||
*/
|
||||
MpnsService.prototype._createTemplateBody = function (channel, tags, template, options) {
|
||||
|
|
|
@ -78,6 +78,11 @@ function NotificationHubService(hubName, endpointOrConnectionString, sharedAcces
|
|||
*
|
||||
*/
|
||||
this.gcm = new GcmService(this);
|
||||
/**
|
||||
* Provides access to a MpnsService object created using the NotificationHubService.
|
||||
* @type {GcmService}
|
||||
*
|
||||
*/
|
||||
this.mpns = new MpnsService(this);
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче