@fraym/proto 0.11.1 → 0.11.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -17,6 +17,7 @@ export interface Event {
17
17
  payload: {
18
18
  [key: string]: EventPayload;
19
19
  };
20
+ raisedAt: string;
20
21
  }
21
22
  export interface Event_PayloadEntry {
22
23
  key: string;
@@ -4,6 +4,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.EventGdprValue = exports.EventPayload = exports.EventMetadata = exports.EventOptions = exports.Event_PayloadEntry = exports.Event = exports.GetEventRequest = exports.protobufPackage = void 0;
7
+ const long_1 = __importDefault(require("long"));
7
8
  const minimal_1 = __importDefault(require("protobufjs/minimal"));
8
9
  exports.protobufPackage = "freym.streams.management";
9
10
  function createBaseGetEventRequest() {
@@ -98,6 +99,7 @@ function createBaseEvent() {
98
99
  options: undefined,
99
100
  metadata: undefined,
100
101
  payload: {},
102
+ raisedAt: "0",
101
103
  };
102
104
  }
103
105
  exports.Event = {
@@ -129,6 +131,9 @@ exports.Event = {
129
131
  Object.entries(message.payload).forEach(([key, value]) => {
130
132
  exports.Event_PayloadEntry.encode({ key: key, value }, writer.uint32(74).fork()).ldelim();
131
133
  });
134
+ if (message.raisedAt !== "0") {
135
+ writer.uint32(80).int64(message.raisedAt);
136
+ }
132
137
  return writer;
133
138
  },
134
139
  decode(input, length) {
@@ -195,6 +200,12 @@ exports.Event = {
195
200
  message.payload[entry9.key] = entry9.value;
196
201
  }
197
202
  continue;
203
+ case 10:
204
+ if (tag !== 80) {
205
+ break;
206
+ }
207
+ message.raisedAt = longToString(reader.int64());
208
+ continue;
198
209
  }
199
210
  if ((tag & 7) === 4 || tag === 0) {
200
211
  break;
@@ -219,6 +230,7 @@ exports.Event = {
219
230
  return acc;
220
231
  }, {})
221
232
  : {},
233
+ raisedAt: isSet(object.raisedAt) ? globalThis.String(object.raisedAt) : "0",
222
234
  };
223
235
  },
224
236
  toJSON(message) {
@@ -256,13 +268,16 @@ exports.Event = {
256
268
  });
257
269
  }
258
270
  }
271
+ if (message.raisedAt !== "0") {
272
+ obj.raisedAt = message.raisedAt;
273
+ }
259
274
  return obj;
260
275
  },
261
276
  create(base) {
262
277
  return exports.Event.fromPartial(base !== null && base !== void 0 ? base : {});
263
278
  },
264
279
  fromPartial(object) {
265
- var _a, _b, _c, _d, _e, _f, _g;
280
+ var _a, _b, _c, _d, _e, _f, _g, _h;
266
281
  const message = createBaseEvent();
267
282
  message.tenantId = (_a = object.tenantId) !== null && _a !== void 0 ? _a : "";
268
283
  message.topic = (_b = object.topic) !== null && _b !== void 0 ? _b : "";
@@ -282,6 +297,7 @@ exports.Event = {
282
297
  }
283
298
  return acc;
284
299
  }, {});
300
+ message.raisedAt = (_h = object.raisedAt) !== null && _h !== void 0 ? _h : "0";
285
301
  return message;
286
302
  },
287
303
  };
@@ -622,6 +638,13 @@ exports.EventGdprValue = {
622
638
  return message;
623
639
  },
624
640
  };
641
+ function longToString(long) {
642
+ return long.toString();
643
+ }
644
+ if (minimal_1.default.util.Long !== long_1.default) {
645
+ minimal_1.default.util.Long = long_1.default;
646
+ minimal_1.default.configure();
647
+ }
625
648
  function isObject(value) {
626
649
  return typeof value === "object" && value !== null;
627
650
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fraym/proto",
3
- "version": "0.11.1",
3
+ "version": "0.11.3",
4
4
  "license": "MIT",
5
5
  "homepage": "https://github.com/fraym/proto",
6
6
  "repository": {