@forge/util

2.0.12.0.1-experimental-7890858
packages/ari/chunk-J4HYZOLA.mjs
+packages/ari/chunk-J4HYZOLA.mjsNew file
+73
Index: package/packages/ari/chunk-J4HYZOLA.mjs
===================================================================
--- package/packages/ari/chunk-J4HYZOLA.mjs
+++ package/packages/ari/chunk-J4HYZOLA.mjs
@@ -0,0 +1,73 @@
+import {
+  GraphIncidentHistoryAriResourceOwner,
+  GraphIncidentHistoryAriResourceType
+} from "./chunk-NTBEFMSE.mjs";
+import {
+  RegisteredAri
+} from "./chunk-AB4PPISI.mjs";
+import {
+  AriParser
+} from "./chunk-S7RIZVFI.mjs";
+
+// src/graph/incident-history/manifest.ts
+var graphIncidentHistoryAriStaticOpts = {
+  qualifier: "ari",
+  platformQualifier: "cloud",
+  cloudId: new RegExp("^$"),
+  resourceOwner: GraphIncidentHistoryAriResourceOwner,
+  resourceType: GraphIncidentHistoryAriResourceType,
+  resourceIdSlug: "activation/{activationId}/{incidentId}/{updateSequenceNumber}",
+  resourceIdSegmentFormats: {
+    activationId: /[a-zA-Z0-9\-]+/,
+    // eslint-disable-line no-useless-escape
+    incidentId: /[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}/,
+    updateSequenceNumber: /\d+/
+  }
+};
+
+// src/graph/incident-history/index.ts
+var GraphIncidentHistoryAri = class _GraphIncidentHistoryAri extends RegisteredAri {
+  constructor(opts) {
+    super(opts), this._activationId = opts.resourceIdSegmentValues.activationId, this._incidentId = opts.resourceIdSegmentValues.incidentId, this._updateSequenceNumber = opts.resourceIdSegmentValues.updateSequenceNumber;
+  }
+  get activationId() {
+    return this._activationId;
+  }
+  get incidentId() {
+    return this._incidentId;
+  }
+  get updateSequenceNumber() {
+    return this._updateSequenceNumber;
+  }
+  static create(opts) {
+    let derivedOpts = {
+      qualifier: graphIncidentHistoryAriStaticOpts.qualifier,
+      platformQualifier: graphIncidentHistoryAriStaticOpts.platformQualifier,
+      cloudId: void 0,
+      resourceOwner: graphIncidentHistoryAriStaticOpts.resourceOwner,
+      resourceType: graphIncidentHistoryAriStaticOpts.resourceType,
+      resourceId: `activation/${opts.activationId}/${opts.incidentId}/${opts.updateSequenceNumber}`,
+      resourceIdSegmentValues: {
+        activationId: opts.activationId,
+        incidentId: opts.incidentId,
+        updateSequenceNumber: opts.updateSequenceNumber
+      }
+    }, ariOpts = AriParser.fromOpts(derivedOpts, graphIncidentHistoryAriStaticOpts);
+    return new _GraphIncidentHistoryAri(ariOpts);
+  }
+  static parse(maybeAri) {
+    let opts = AriParser.fromString(maybeAri, graphIncidentHistoryAriStaticOpts);
+    return new _GraphIncidentHistoryAri(opts);
+  }
+  getVariables() {
+    return {
+      activationId: this.activationId,
+      incidentId: this.incidentId,
+      updateSequenceNumber: this.updateSequenceNumber
+    };
+  }
+};
+
+export {
+  GraphIncidentHistoryAri
+};