@forge/util
2.0.12.0.1-experimental-7890858
packages/ari/chunk-Z633MAPC.mjs+
packages/ari/chunk-Z633MAPC.mjsNew file+66
Index: package/packages/ari/chunk-Z633MAPC.mjs
===================================================================
--- package/packages/ari/chunk-Z633MAPC.mjs
+++ package/packages/ari/chunk-Z633MAPC.mjs
@@ -0,0 +1,66 @@
+import {
+ BitbucketPullrequestCommentAriResourceOwner,
+ BitbucketPullrequestCommentAriResourceType
+} from "./chunk-CCH7QET7.mjs";
+import {
+ RegisteredAri
+} from "./chunk-AB4PPISI.mjs";
+import {
+ AriParser
+} from "./chunk-S7RIZVFI.mjs";
+
+// src/bitbucket/pullrequest-comment/manifest.ts
+var bitbucketPullrequestCommentAriStaticOpts = {
+ qualifier: "ari",
+ platformQualifier: "cloud",
+ cloudId: new RegExp("^$"),
+ resourceOwner: BitbucketPullrequestCommentAriResourceOwner,
+ resourceType: BitbucketPullrequestCommentAriResourceType,
+ resourceIdSlug: "{pullRequestId}/{commentId}",
+ resourceIdSegmentFormats: {
+ pullRequestId: /[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}:[0-9]+/,
+ commentId: /[0-9]+/
+ }
+};
+
+// src/bitbucket/pullrequest-comment/index.ts
+var BitbucketPullrequestCommentAri = class _BitbucketPullrequestCommentAri extends RegisteredAri {
+ constructor(opts) {
+ super(opts), this._pullRequestId = opts.resourceIdSegmentValues.pullRequestId, this._commentId = opts.resourceIdSegmentValues.commentId;
+ }
+ get pullRequestId() {
+ return this._pullRequestId;
+ }
+ get commentId() {
+ return this._commentId;
+ }
+ static create(opts) {
+ let derivedOpts = {
+ qualifier: bitbucketPullrequestCommentAriStaticOpts.qualifier,
+ platformQualifier: bitbucketPullrequestCommentAriStaticOpts.platformQualifier,
+ cloudId: void 0,
+ resourceOwner: bitbucketPullrequestCommentAriStaticOpts.resourceOwner,
+ resourceType: bitbucketPullrequestCommentAriStaticOpts.resourceType,
+ resourceId: `${opts.pullRequestId}/${opts.commentId}`,
+ resourceIdSegmentValues: {
+ pullRequestId: opts.pullRequestId,
+ commentId: opts.commentId
+ }
+ }, ariOpts = AriParser.fromOpts(derivedOpts, bitbucketPullrequestCommentAriStaticOpts);
+ return new _BitbucketPullrequestCommentAri(ariOpts);
+ }
+ static parse(maybeAri) {
+ let opts = AriParser.fromString(maybeAri, bitbucketPullrequestCommentAriStaticOpts);
+ return new _BitbucketPullrequestCommentAri(opts);
+ }
+ getVariables() {
+ return {
+ pullRequestId: this.pullRequestId,
+ commentId: this.commentId
+ };
+ }
+};
+
+export {
+ BitbucketPullrequestCommentAri
+};