UNPKG

baasic-sdk-javascript

Version:

JavaScript SDK provides core functionality for building web and mobile applications on [Baasic](http://www.baasic.com/).

57 lines (56 loc) 3.14 kB
"use strict"; /* globals module */ /** * @module articleSubscriptionsCommentReportedRoute * @description Baasic Article Subscriptions Comment Reported Route Definition provides Baasic route templates which can be expanded to Baasic REST URIs. Various services can use Baasic Article Subscriptions Comment Reported Route Definition to obtain needed routes while other routes will be obtained through HAL. By convention, all route services use the same function names as their corresponding services. */ Object.defineProperty(exports, "__esModule", { value: true }); var tslib_1 = require("tslib"); var inversify_1 = require("inversify"); var common_1 = require("../../../common"); var contracts_1 = require("../../../core/contracts"); var ArticleSubscriptionsCommentReportedRoute = /** @class */ (function (_super) { tslib_1.__extends(ArticleSubscriptionsCommentReportedRoute, _super); function ArticleSubscriptionsCommentReportedRoute(appOptions) { var _this = _super.call(this, appOptions) || this; _this.appOptions = appOptions; _this.subscribeRoute = 'articles/subscriptions/comment-reported'; _this.isSubscribedRoute = 'articles/subscriptions/comment-reported/{subscriberId}'; _this.unSubscribeRoute = 'articles/subscriptions/comment-reported'; return _this; } /** * Parses commentReported subscribe route which doesn't support any additional options. * @method * @param data The subscribe information. * @example articleSubscriptionsCommentReportedRoute.subscribe(data); **/ ArticleSubscriptionsCommentReportedRoute.prototype.subscribe = function (data) { return _super.prototype.baseCreate.call(this, this.subscribeRoute, data); }; /** * Parses commentReported isSubscribed route which must be expanded with subscriber Id. * @method * @param data The subscribe information. * @example articleSubscriptionsCommentReportedRoute.isSubscribed({subscriberId: '<subscriber-id>'}); **/ ArticleSubscriptionsCommentReportedRoute.prototype.isSubscribed = function (data) { return _super.prototype.baseCreate.call(this, this.isSubscribedRoute, data); }; /** * Parses commentReported unSubscribe route which doesn't support any additional options. * @method * @param data The unsubscribe information. * @example articleSubscriptionsCommentReportedRoute.unSubscribe(data); **/ ArticleSubscriptionsCommentReportedRoute.prototype.unSubscribe = function (data) { return _super.prototype.baseCreate.call(this, this.unSubscribeRoute, data); }; ArticleSubscriptionsCommentReportedRoute = tslib_1.__decorate([ inversify_1.injectable(), tslib_1.__param(0, inversify_1.inject(contracts_1.TYPES.IAppOptions)), tslib_1.__metadata("design:paramtypes", [Object]) ], ArticleSubscriptionsCommentReportedRoute); return ArticleSubscriptionsCommentReportedRoute; }(common_1.BaseRoute)); exports.ArticleSubscriptionsCommentReportedRoute = ArticleSubscriptionsCommentReportedRoute;