@cratis/chronicle.contracts 19.6.0 → 19.7.0
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.
- package/dist/cjs/generated/descriptorSet.js +1 -1
- package/dist/cjs/generated/descriptorSet.js.map +1 -1
- package/dist/cjs/generated/index.d.ts +2 -0
- package/dist/cjs/generated/index.d.ts.map +1 -1
- package/dist/cjs/generated/projections.d.ts +3 -0
- package/dist/cjs/generated/projections.d.ts.map +1 -1
- package/dist/cjs/generated/projections.js +28 -1
- package/dist/cjs/generated/projections.js.map +1 -1
- package/dist/cjs/generated/statistics.d.ts +94 -0
- package/dist/cjs/generated/statistics.d.ts.map +1 -0
- package/dist/cjs/generated/statistics.js +665 -0
- package/dist/cjs/generated/statistics.js.map +1 -0
- package/dist/cjs/index.js +7 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/generated/descriptorSet.js +1 -1
- package/dist/esm/generated/descriptorSet.js.map +1 -1
- package/dist/esm/generated/index.d.ts +2 -0
- package/dist/esm/generated/index.d.ts.map +1 -1
- package/dist/esm/generated/projections.d.ts +3 -0
- package/dist/esm/generated/projections.d.ts.map +1 -1
- package/dist/esm/generated/projections.js +28 -1
- package/dist/esm/generated/projections.js.map +1 -1
- package/dist/esm/generated/statistics.d.ts +94 -0
- package/dist/esm/generated/statistics.d.ts.map +1 -0
- package/dist/esm/generated/statistics.js +655 -0
- package/dist/esm/generated/statistics.js.map +1 -0
- package/dist/esm/index.js +1 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/generated/descriptorSet.js +1 -1
- package/dist/generated/descriptorSet.js.map +1 -1
- package/dist/generated/index.d.ts +2 -0
- package/dist/generated/index.d.ts.map +1 -1
- package/dist/generated/index.js +1 -0
- package/dist/generated/index.js.map +1 -1
- package/dist/generated/projections.d.ts +3 -0
- package/dist/generated/projections.d.ts.map +1 -1
- package/dist/generated/projections.js +28 -1
- package/dist/generated/projections.js.map +1 -1
- package/dist/generated/statistics.d.ts +94 -0
- package/dist/generated/statistics.d.ts.map +1 -0
- package/dist/generated/statistics.js +653 -0
- package/dist/generated/statistics.js.map +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/generated/descriptorSet.ts +1 -1
- package/generated/index.ts +3 -0
- package/generated/projections.ts +30 -1
- package/generated/statistics.ts +791 -0
- package/package.json +1 -1
|
@@ -0,0 +1,655 @@
|
|
|
1
|
+
import { BinaryWriter, BinaryReader } from '@bufbuild/protobuf/wire';
|
|
2
|
+
import { Guid } from './protobuf-net/bcl.js';
|
|
3
|
+
|
|
4
|
+
var ValidationResultSeverity;
|
|
5
|
+
(function (ValidationResultSeverity) {
|
|
6
|
+
ValidationResultSeverity[ValidationResultSeverity["Unknown"] = 0] = "Unknown";
|
|
7
|
+
ValidationResultSeverity[ValidationResultSeverity["Information"] = 1] = "Information";
|
|
8
|
+
ValidationResultSeverity[ValidationResultSeverity["Warning"] = 2] = "Warning";
|
|
9
|
+
ValidationResultSeverity[ValidationResultSeverity["Error"] = 3] = "Error";
|
|
10
|
+
ValidationResultSeverity[ValidationResultSeverity["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
11
|
+
})(ValidationResultSeverity || (ValidationResultSeverity = {}));
|
|
12
|
+
function validationResultSeverityFromJSON(object) {
|
|
13
|
+
switch (object) {
|
|
14
|
+
case 0:
|
|
15
|
+
case "Unknown":
|
|
16
|
+
return ValidationResultSeverity.Unknown;
|
|
17
|
+
case 1:
|
|
18
|
+
case "Information":
|
|
19
|
+
return ValidationResultSeverity.Information;
|
|
20
|
+
case 2:
|
|
21
|
+
case "Warning":
|
|
22
|
+
return ValidationResultSeverity.Warning;
|
|
23
|
+
case 3:
|
|
24
|
+
case "Error":
|
|
25
|
+
return ValidationResultSeverity.Error;
|
|
26
|
+
case -1:
|
|
27
|
+
case "UNRECOGNIZED":
|
|
28
|
+
default:
|
|
29
|
+
return ValidationResultSeverity.UNRECOGNIZED;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
function validationResultSeverityToJSON(object) {
|
|
33
|
+
switch (object) {
|
|
34
|
+
case ValidationResultSeverity.Unknown:
|
|
35
|
+
return "Unknown";
|
|
36
|
+
case ValidationResultSeverity.Information:
|
|
37
|
+
return "Information";
|
|
38
|
+
case ValidationResultSeverity.Warning:
|
|
39
|
+
return "Warning";
|
|
40
|
+
case ValidationResultSeverity.Error:
|
|
41
|
+
return "Error";
|
|
42
|
+
case ValidationResultSeverity.UNRECOGNIZED:
|
|
43
|
+
default:
|
|
44
|
+
return "UNRECOGNIZED";
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
function createBaseEventStatisticsResponse() {
|
|
48
|
+
return { TotalEvents: 0n, EventTypes: 0, Namespaces: 0, PerEventType: [] };
|
|
49
|
+
}
|
|
50
|
+
const EventStatisticsResponse = {
|
|
51
|
+
encode(message, writer = new BinaryWriter()) {
|
|
52
|
+
if (message.TotalEvents !== 0n) {
|
|
53
|
+
if (BigInt.asIntN(64, message.TotalEvents) !== message.TotalEvents) {
|
|
54
|
+
throw new globalThis.Error("value provided for field message.TotalEvents of type int64 too large");
|
|
55
|
+
}
|
|
56
|
+
writer.uint32(8).int64(message.TotalEvents);
|
|
57
|
+
}
|
|
58
|
+
if (message.EventTypes !== 0) {
|
|
59
|
+
writer.uint32(16).int32(message.EventTypes);
|
|
60
|
+
}
|
|
61
|
+
if (message.Namespaces !== 0) {
|
|
62
|
+
writer.uint32(24).int32(message.Namespaces);
|
|
63
|
+
}
|
|
64
|
+
for (const v of message.PerEventType) {
|
|
65
|
+
EventTypeCount.encode(v, writer.uint32(34).fork()).join();
|
|
66
|
+
}
|
|
67
|
+
return writer;
|
|
68
|
+
},
|
|
69
|
+
decode(input, length) {
|
|
70
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
71
|
+
const previousRecursionDepth = reader.__tsProtoDecodeDepth ?? 0;
|
|
72
|
+
if (previousRecursionDepth >= 100) {
|
|
73
|
+
throw new globalThis.Error("protobuf decode recursion limit exceeded");
|
|
74
|
+
}
|
|
75
|
+
reader.__tsProtoDecodeDepth = previousRecursionDepth + 1;
|
|
76
|
+
try {
|
|
77
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
78
|
+
const message = createBaseEventStatisticsResponse();
|
|
79
|
+
while (reader.pos < end) {
|
|
80
|
+
const tag = reader.uint32();
|
|
81
|
+
switch (tag >>> 3) {
|
|
82
|
+
case 1: {
|
|
83
|
+
if (tag !== 8) {
|
|
84
|
+
break;
|
|
85
|
+
}
|
|
86
|
+
message.TotalEvents = reader.int64();
|
|
87
|
+
continue;
|
|
88
|
+
}
|
|
89
|
+
case 2: {
|
|
90
|
+
if (tag !== 16) {
|
|
91
|
+
break;
|
|
92
|
+
}
|
|
93
|
+
message.EventTypes = reader.int32();
|
|
94
|
+
continue;
|
|
95
|
+
}
|
|
96
|
+
case 3: {
|
|
97
|
+
if (tag !== 24) {
|
|
98
|
+
break;
|
|
99
|
+
}
|
|
100
|
+
message.Namespaces = reader.int32();
|
|
101
|
+
continue;
|
|
102
|
+
}
|
|
103
|
+
case 4: {
|
|
104
|
+
if (tag !== 34) {
|
|
105
|
+
break;
|
|
106
|
+
}
|
|
107
|
+
message.PerEventType.push(EventTypeCount.decode(reader, reader.uint32()));
|
|
108
|
+
continue;
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
112
|
+
break;
|
|
113
|
+
}
|
|
114
|
+
reader.skip(tag & 7);
|
|
115
|
+
}
|
|
116
|
+
return message;
|
|
117
|
+
}
|
|
118
|
+
finally {
|
|
119
|
+
reader.__tsProtoDecodeDepth = previousRecursionDepth;
|
|
120
|
+
}
|
|
121
|
+
},
|
|
122
|
+
fromJSON(object) {
|
|
123
|
+
return {
|
|
124
|
+
TotalEvents: isSet(object.TotalEvents) ? BigInt(object.TotalEvents) : 0n,
|
|
125
|
+
EventTypes: isSet(object.EventTypes) ? globalThis.Number(object.EventTypes) : 0,
|
|
126
|
+
Namespaces: isSet(object.Namespaces) ? globalThis.Number(object.Namespaces) : 0,
|
|
127
|
+
PerEventType: globalThis.Array.isArray(object?.PerEventType)
|
|
128
|
+
? object.PerEventType.map((e) => EventTypeCount.fromJSON(e))
|
|
129
|
+
: [],
|
|
130
|
+
};
|
|
131
|
+
},
|
|
132
|
+
toJSON(message) {
|
|
133
|
+
const obj = {};
|
|
134
|
+
if (message.TotalEvents !== 0n) {
|
|
135
|
+
obj.TotalEvents = message.TotalEvents.toString();
|
|
136
|
+
}
|
|
137
|
+
if (message.EventTypes !== 0) {
|
|
138
|
+
obj.EventTypes = Math.round(message.EventTypes);
|
|
139
|
+
}
|
|
140
|
+
if (message.Namespaces !== 0) {
|
|
141
|
+
obj.Namespaces = Math.round(message.Namespaces);
|
|
142
|
+
}
|
|
143
|
+
if (message.PerEventType?.length) {
|
|
144
|
+
obj.PerEventType = message.PerEventType.map((e) => EventTypeCount.toJSON(e));
|
|
145
|
+
}
|
|
146
|
+
return obj;
|
|
147
|
+
},
|
|
148
|
+
create(base) {
|
|
149
|
+
return EventStatisticsResponse.fromPartial(base ?? {});
|
|
150
|
+
},
|
|
151
|
+
fromPartial(object) {
|
|
152
|
+
const message = createBaseEventStatisticsResponse();
|
|
153
|
+
message.TotalEvents = (object.TotalEvents !== undefined && object.TotalEvents !== null)
|
|
154
|
+
? BigInt(object.TotalEvents)
|
|
155
|
+
: 0n;
|
|
156
|
+
message.EventTypes = object.EventTypes ?? 0;
|
|
157
|
+
message.Namespaces = object.Namespaces ?? 0;
|
|
158
|
+
message.PerEventType = object.PerEventType?.map((e) => EventTypeCount.fromPartial(e)) || [];
|
|
159
|
+
return message;
|
|
160
|
+
},
|
|
161
|
+
};
|
|
162
|
+
function createBaseEventTypeCount() {
|
|
163
|
+
return { EventType: "", Count: 0n };
|
|
164
|
+
}
|
|
165
|
+
const EventTypeCount = {
|
|
166
|
+
encode(message, writer = new BinaryWriter()) {
|
|
167
|
+
if (message.EventType !== "") {
|
|
168
|
+
writer.uint32(10).string(message.EventType);
|
|
169
|
+
}
|
|
170
|
+
if (message.Count !== 0n) {
|
|
171
|
+
if (BigInt.asIntN(64, message.Count) !== message.Count) {
|
|
172
|
+
throw new globalThis.Error("value provided for field message.Count of type int64 too large");
|
|
173
|
+
}
|
|
174
|
+
writer.uint32(16).int64(message.Count);
|
|
175
|
+
}
|
|
176
|
+
return writer;
|
|
177
|
+
},
|
|
178
|
+
decode(input, length) {
|
|
179
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
180
|
+
const previousRecursionDepth = reader.__tsProtoDecodeDepth ?? 0;
|
|
181
|
+
if (previousRecursionDepth >= 100) {
|
|
182
|
+
throw new globalThis.Error("protobuf decode recursion limit exceeded");
|
|
183
|
+
}
|
|
184
|
+
reader.__tsProtoDecodeDepth = previousRecursionDepth + 1;
|
|
185
|
+
try {
|
|
186
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
187
|
+
const message = createBaseEventTypeCount();
|
|
188
|
+
while (reader.pos < end) {
|
|
189
|
+
const tag = reader.uint32();
|
|
190
|
+
switch (tag >>> 3) {
|
|
191
|
+
case 1: {
|
|
192
|
+
if (tag !== 10) {
|
|
193
|
+
break;
|
|
194
|
+
}
|
|
195
|
+
message.EventType = reader.string();
|
|
196
|
+
continue;
|
|
197
|
+
}
|
|
198
|
+
case 2: {
|
|
199
|
+
if (tag !== 16) {
|
|
200
|
+
break;
|
|
201
|
+
}
|
|
202
|
+
message.Count = reader.int64();
|
|
203
|
+
continue;
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
207
|
+
break;
|
|
208
|
+
}
|
|
209
|
+
reader.skip(tag & 7);
|
|
210
|
+
}
|
|
211
|
+
return message;
|
|
212
|
+
}
|
|
213
|
+
finally {
|
|
214
|
+
reader.__tsProtoDecodeDepth = previousRecursionDepth;
|
|
215
|
+
}
|
|
216
|
+
},
|
|
217
|
+
fromJSON(object) {
|
|
218
|
+
return {
|
|
219
|
+
EventType: isSet(object.EventType) ? globalThis.String(object.EventType) : "",
|
|
220
|
+
Count: isSet(object.Count) ? BigInt(object.Count) : 0n,
|
|
221
|
+
};
|
|
222
|
+
},
|
|
223
|
+
toJSON(message) {
|
|
224
|
+
const obj = {};
|
|
225
|
+
if (message.EventType !== "") {
|
|
226
|
+
obj.EventType = message.EventType;
|
|
227
|
+
}
|
|
228
|
+
if (message.Count !== 0n) {
|
|
229
|
+
obj.Count = message.Count.toString();
|
|
230
|
+
}
|
|
231
|
+
return obj;
|
|
232
|
+
},
|
|
233
|
+
create(base) {
|
|
234
|
+
return EventTypeCount.fromPartial(base ?? {});
|
|
235
|
+
},
|
|
236
|
+
fromPartial(object) {
|
|
237
|
+
const message = createBaseEventTypeCount();
|
|
238
|
+
message.EventType = object.EventType ?? "";
|
|
239
|
+
message.Count = (object.Count !== undefined && object.Count !== null) ? BigInt(object.Count) : 0n;
|
|
240
|
+
return message;
|
|
241
|
+
},
|
|
242
|
+
};
|
|
243
|
+
function createBaseQueryResultEventStatisticsResponse() {
|
|
244
|
+
return {
|
|
245
|
+
CorrelationId: undefined,
|
|
246
|
+
IsAuthorized: false,
|
|
247
|
+
ValidationResults: [],
|
|
248
|
+
ExceptionMessages: [],
|
|
249
|
+
ExceptionStackTrace: "",
|
|
250
|
+
Data: undefined,
|
|
251
|
+
};
|
|
252
|
+
}
|
|
253
|
+
const QueryResultEventStatisticsResponse = {
|
|
254
|
+
encode(message, writer = new BinaryWriter()) {
|
|
255
|
+
if (message.CorrelationId !== undefined) {
|
|
256
|
+
Guid.encode(message.CorrelationId, writer.uint32(10).fork()).join();
|
|
257
|
+
}
|
|
258
|
+
if (message.IsAuthorized !== false) {
|
|
259
|
+
writer.uint32(16).bool(message.IsAuthorized);
|
|
260
|
+
}
|
|
261
|
+
for (const v of message.ValidationResults) {
|
|
262
|
+
ValidationResult.encode(v, writer.uint32(26).fork()).join();
|
|
263
|
+
}
|
|
264
|
+
for (const v of message.ExceptionMessages) {
|
|
265
|
+
writer.uint32(34).string(v);
|
|
266
|
+
}
|
|
267
|
+
if (message.ExceptionStackTrace !== "") {
|
|
268
|
+
writer.uint32(42).string(message.ExceptionStackTrace);
|
|
269
|
+
}
|
|
270
|
+
if (message.Data !== undefined) {
|
|
271
|
+
EventStatisticsResponse.encode(message.Data, writer.uint32(50).fork()).join();
|
|
272
|
+
}
|
|
273
|
+
return writer;
|
|
274
|
+
},
|
|
275
|
+
decode(input, length) {
|
|
276
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
277
|
+
const previousRecursionDepth = reader.__tsProtoDecodeDepth ?? 0;
|
|
278
|
+
if (previousRecursionDepth >= 100) {
|
|
279
|
+
throw new globalThis.Error("protobuf decode recursion limit exceeded");
|
|
280
|
+
}
|
|
281
|
+
reader.__tsProtoDecodeDepth = previousRecursionDepth + 1;
|
|
282
|
+
try {
|
|
283
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
284
|
+
const message = createBaseQueryResultEventStatisticsResponse();
|
|
285
|
+
while (reader.pos < end) {
|
|
286
|
+
const tag = reader.uint32();
|
|
287
|
+
switch (tag >>> 3) {
|
|
288
|
+
case 1: {
|
|
289
|
+
if (tag !== 10) {
|
|
290
|
+
break;
|
|
291
|
+
}
|
|
292
|
+
message.CorrelationId = Guid.decode(reader, reader.uint32());
|
|
293
|
+
continue;
|
|
294
|
+
}
|
|
295
|
+
case 2: {
|
|
296
|
+
if (tag !== 16) {
|
|
297
|
+
break;
|
|
298
|
+
}
|
|
299
|
+
message.IsAuthorized = reader.bool();
|
|
300
|
+
continue;
|
|
301
|
+
}
|
|
302
|
+
case 3: {
|
|
303
|
+
if (tag !== 26) {
|
|
304
|
+
break;
|
|
305
|
+
}
|
|
306
|
+
message.ValidationResults.push(ValidationResult.decode(reader, reader.uint32()));
|
|
307
|
+
continue;
|
|
308
|
+
}
|
|
309
|
+
case 4: {
|
|
310
|
+
if (tag !== 34) {
|
|
311
|
+
break;
|
|
312
|
+
}
|
|
313
|
+
message.ExceptionMessages.push(reader.string());
|
|
314
|
+
continue;
|
|
315
|
+
}
|
|
316
|
+
case 5: {
|
|
317
|
+
if (tag !== 42) {
|
|
318
|
+
break;
|
|
319
|
+
}
|
|
320
|
+
message.ExceptionStackTrace = reader.string();
|
|
321
|
+
continue;
|
|
322
|
+
}
|
|
323
|
+
case 6: {
|
|
324
|
+
if (tag !== 50) {
|
|
325
|
+
break;
|
|
326
|
+
}
|
|
327
|
+
message.Data = EventStatisticsResponse.decode(reader, reader.uint32());
|
|
328
|
+
continue;
|
|
329
|
+
}
|
|
330
|
+
}
|
|
331
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
332
|
+
break;
|
|
333
|
+
}
|
|
334
|
+
reader.skip(tag & 7);
|
|
335
|
+
}
|
|
336
|
+
return message;
|
|
337
|
+
}
|
|
338
|
+
finally {
|
|
339
|
+
reader.__tsProtoDecodeDepth = previousRecursionDepth;
|
|
340
|
+
}
|
|
341
|
+
},
|
|
342
|
+
fromJSON(object) {
|
|
343
|
+
return {
|
|
344
|
+
CorrelationId: isSet(object.CorrelationId) ? Guid.fromJSON(object.CorrelationId) : undefined,
|
|
345
|
+
IsAuthorized: isSet(object.IsAuthorized) ? globalThis.Boolean(object.IsAuthorized) : false,
|
|
346
|
+
ValidationResults: globalThis.Array.isArray(object?.ValidationResults)
|
|
347
|
+
? object.ValidationResults.map((e) => ValidationResult.fromJSON(e))
|
|
348
|
+
: [],
|
|
349
|
+
ExceptionMessages: globalThis.Array.isArray(object?.ExceptionMessages)
|
|
350
|
+
? object.ExceptionMessages.map((e) => globalThis.String(e))
|
|
351
|
+
: [],
|
|
352
|
+
ExceptionStackTrace: isSet(object.ExceptionStackTrace) ? globalThis.String(object.ExceptionStackTrace) : "",
|
|
353
|
+
Data: isSet(object.Data) ? EventStatisticsResponse.fromJSON(object.Data) : undefined,
|
|
354
|
+
};
|
|
355
|
+
},
|
|
356
|
+
toJSON(message) {
|
|
357
|
+
const obj = {};
|
|
358
|
+
if (message.CorrelationId !== undefined) {
|
|
359
|
+
obj.CorrelationId = Guid.toJSON(message.CorrelationId);
|
|
360
|
+
}
|
|
361
|
+
if (message.IsAuthorized !== false) {
|
|
362
|
+
obj.IsAuthorized = message.IsAuthorized;
|
|
363
|
+
}
|
|
364
|
+
if (message.ValidationResults?.length) {
|
|
365
|
+
obj.ValidationResults = message.ValidationResults.map((e) => ValidationResult.toJSON(e));
|
|
366
|
+
}
|
|
367
|
+
if (message.ExceptionMessages?.length) {
|
|
368
|
+
obj.ExceptionMessages = message.ExceptionMessages;
|
|
369
|
+
}
|
|
370
|
+
if (message.ExceptionStackTrace !== "") {
|
|
371
|
+
obj.ExceptionStackTrace = message.ExceptionStackTrace;
|
|
372
|
+
}
|
|
373
|
+
if (message.Data !== undefined) {
|
|
374
|
+
obj.Data = EventStatisticsResponse.toJSON(message.Data);
|
|
375
|
+
}
|
|
376
|
+
return obj;
|
|
377
|
+
},
|
|
378
|
+
create(base) {
|
|
379
|
+
return QueryResultEventStatisticsResponse.fromPartial(base ?? {});
|
|
380
|
+
},
|
|
381
|
+
fromPartial(object) {
|
|
382
|
+
const message = createBaseQueryResultEventStatisticsResponse();
|
|
383
|
+
message.CorrelationId = (object.CorrelationId !== undefined && object.CorrelationId !== null)
|
|
384
|
+
? Guid.fromPartial(object.CorrelationId)
|
|
385
|
+
: undefined;
|
|
386
|
+
message.IsAuthorized = object.IsAuthorized ?? false;
|
|
387
|
+
message.ValidationResults = object.ValidationResults?.map((e) => ValidationResult.fromPartial(e)) || [];
|
|
388
|
+
message.ExceptionMessages = object.ExceptionMessages?.map((e) => e) || [];
|
|
389
|
+
message.ExceptionStackTrace = object.ExceptionStackTrace ?? "";
|
|
390
|
+
message.Data = (object.Data !== undefined && object.Data !== null)
|
|
391
|
+
? EventStatisticsResponse.fromPartial(object.Data)
|
|
392
|
+
: undefined;
|
|
393
|
+
return message;
|
|
394
|
+
},
|
|
395
|
+
};
|
|
396
|
+
function createBaseStatisticsForEventStoreRequest() {
|
|
397
|
+
return { EventStore: "" };
|
|
398
|
+
}
|
|
399
|
+
const StatisticsForEventStoreRequest = {
|
|
400
|
+
encode(message, writer = new BinaryWriter()) {
|
|
401
|
+
if (message.EventStore !== "") {
|
|
402
|
+
writer.uint32(10).string(message.EventStore);
|
|
403
|
+
}
|
|
404
|
+
return writer;
|
|
405
|
+
},
|
|
406
|
+
decode(input, length) {
|
|
407
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
408
|
+
const previousRecursionDepth = reader.__tsProtoDecodeDepth ?? 0;
|
|
409
|
+
if (previousRecursionDepth >= 100) {
|
|
410
|
+
throw new globalThis.Error("protobuf decode recursion limit exceeded");
|
|
411
|
+
}
|
|
412
|
+
reader.__tsProtoDecodeDepth = previousRecursionDepth + 1;
|
|
413
|
+
try {
|
|
414
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
415
|
+
const message = createBaseStatisticsForEventStoreRequest();
|
|
416
|
+
while (reader.pos < end) {
|
|
417
|
+
const tag = reader.uint32();
|
|
418
|
+
switch (tag >>> 3) {
|
|
419
|
+
case 1: {
|
|
420
|
+
if (tag !== 10) {
|
|
421
|
+
break;
|
|
422
|
+
}
|
|
423
|
+
message.EventStore = reader.string();
|
|
424
|
+
continue;
|
|
425
|
+
}
|
|
426
|
+
}
|
|
427
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
428
|
+
break;
|
|
429
|
+
}
|
|
430
|
+
reader.skip(tag & 7);
|
|
431
|
+
}
|
|
432
|
+
return message;
|
|
433
|
+
}
|
|
434
|
+
finally {
|
|
435
|
+
reader.__tsProtoDecodeDepth = previousRecursionDepth;
|
|
436
|
+
}
|
|
437
|
+
},
|
|
438
|
+
fromJSON(object) {
|
|
439
|
+
return { EventStore: isSet(object.EventStore) ? globalThis.String(object.EventStore) : "" };
|
|
440
|
+
},
|
|
441
|
+
toJSON(message) {
|
|
442
|
+
const obj = {};
|
|
443
|
+
if (message.EventStore !== "") {
|
|
444
|
+
obj.EventStore = message.EventStore;
|
|
445
|
+
}
|
|
446
|
+
return obj;
|
|
447
|
+
},
|
|
448
|
+
create(base) {
|
|
449
|
+
return StatisticsForEventStoreRequest.fromPartial(base ?? {});
|
|
450
|
+
},
|
|
451
|
+
fromPartial(object) {
|
|
452
|
+
const message = createBaseStatisticsForEventStoreRequest();
|
|
453
|
+
message.EventStore = object.EventStore ?? "";
|
|
454
|
+
return message;
|
|
455
|
+
},
|
|
456
|
+
};
|
|
457
|
+
function createBaseStatisticsForNamespaceRequest() {
|
|
458
|
+
return { EventStore: "", Namespace: "" };
|
|
459
|
+
}
|
|
460
|
+
const StatisticsForNamespaceRequest = {
|
|
461
|
+
encode(message, writer = new BinaryWriter()) {
|
|
462
|
+
if (message.EventStore !== "") {
|
|
463
|
+
writer.uint32(10).string(message.EventStore);
|
|
464
|
+
}
|
|
465
|
+
if (message.Namespace !== "") {
|
|
466
|
+
writer.uint32(18).string(message.Namespace);
|
|
467
|
+
}
|
|
468
|
+
return writer;
|
|
469
|
+
},
|
|
470
|
+
decode(input, length) {
|
|
471
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
472
|
+
const previousRecursionDepth = reader.__tsProtoDecodeDepth ?? 0;
|
|
473
|
+
if (previousRecursionDepth >= 100) {
|
|
474
|
+
throw new globalThis.Error("protobuf decode recursion limit exceeded");
|
|
475
|
+
}
|
|
476
|
+
reader.__tsProtoDecodeDepth = previousRecursionDepth + 1;
|
|
477
|
+
try {
|
|
478
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
479
|
+
const message = createBaseStatisticsForNamespaceRequest();
|
|
480
|
+
while (reader.pos < end) {
|
|
481
|
+
const tag = reader.uint32();
|
|
482
|
+
switch (tag >>> 3) {
|
|
483
|
+
case 1: {
|
|
484
|
+
if (tag !== 10) {
|
|
485
|
+
break;
|
|
486
|
+
}
|
|
487
|
+
message.EventStore = reader.string();
|
|
488
|
+
continue;
|
|
489
|
+
}
|
|
490
|
+
case 2: {
|
|
491
|
+
if (tag !== 18) {
|
|
492
|
+
break;
|
|
493
|
+
}
|
|
494
|
+
message.Namespace = reader.string();
|
|
495
|
+
continue;
|
|
496
|
+
}
|
|
497
|
+
}
|
|
498
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
499
|
+
break;
|
|
500
|
+
}
|
|
501
|
+
reader.skip(tag & 7);
|
|
502
|
+
}
|
|
503
|
+
return message;
|
|
504
|
+
}
|
|
505
|
+
finally {
|
|
506
|
+
reader.__tsProtoDecodeDepth = previousRecursionDepth;
|
|
507
|
+
}
|
|
508
|
+
},
|
|
509
|
+
fromJSON(object) {
|
|
510
|
+
return {
|
|
511
|
+
EventStore: isSet(object.EventStore) ? globalThis.String(object.EventStore) : "",
|
|
512
|
+
Namespace: isSet(object.Namespace) ? globalThis.String(object.Namespace) : "",
|
|
513
|
+
};
|
|
514
|
+
},
|
|
515
|
+
toJSON(message) {
|
|
516
|
+
const obj = {};
|
|
517
|
+
if (message.EventStore !== "") {
|
|
518
|
+
obj.EventStore = message.EventStore;
|
|
519
|
+
}
|
|
520
|
+
if (message.Namespace !== "") {
|
|
521
|
+
obj.Namespace = message.Namespace;
|
|
522
|
+
}
|
|
523
|
+
return obj;
|
|
524
|
+
},
|
|
525
|
+
create(base) {
|
|
526
|
+
return StatisticsForNamespaceRequest.fromPartial(base ?? {});
|
|
527
|
+
},
|
|
528
|
+
fromPartial(object) {
|
|
529
|
+
const message = createBaseStatisticsForNamespaceRequest();
|
|
530
|
+
message.EventStore = object.EventStore ?? "";
|
|
531
|
+
message.Namespace = object.Namespace ?? "";
|
|
532
|
+
return message;
|
|
533
|
+
},
|
|
534
|
+
};
|
|
535
|
+
function createBaseValidationResult() {
|
|
536
|
+
return { Severity: 0, Message: "", Members: [] };
|
|
537
|
+
}
|
|
538
|
+
const ValidationResult = {
|
|
539
|
+
encode(message, writer = new BinaryWriter()) {
|
|
540
|
+
if (message.Severity !== 0) {
|
|
541
|
+
writer.uint32(8).int32(message.Severity);
|
|
542
|
+
}
|
|
543
|
+
if (message.Message !== "") {
|
|
544
|
+
writer.uint32(18).string(message.Message);
|
|
545
|
+
}
|
|
546
|
+
for (const v of message.Members) {
|
|
547
|
+
writer.uint32(26).string(v);
|
|
548
|
+
}
|
|
549
|
+
return writer;
|
|
550
|
+
},
|
|
551
|
+
decode(input, length) {
|
|
552
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
553
|
+
const previousRecursionDepth = reader.__tsProtoDecodeDepth ?? 0;
|
|
554
|
+
if (previousRecursionDepth >= 100) {
|
|
555
|
+
throw new globalThis.Error("protobuf decode recursion limit exceeded");
|
|
556
|
+
}
|
|
557
|
+
reader.__tsProtoDecodeDepth = previousRecursionDepth + 1;
|
|
558
|
+
try {
|
|
559
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
560
|
+
const message = createBaseValidationResult();
|
|
561
|
+
while (reader.pos < end) {
|
|
562
|
+
const tag = reader.uint32();
|
|
563
|
+
switch (tag >>> 3) {
|
|
564
|
+
case 1: {
|
|
565
|
+
if (tag !== 8) {
|
|
566
|
+
break;
|
|
567
|
+
}
|
|
568
|
+
message.Severity = reader.int32();
|
|
569
|
+
continue;
|
|
570
|
+
}
|
|
571
|
+
case 2: {
|
|
572
|
+
if (tag !== 18) {
|
|
573
|
+
break;
|
|
574
|
+
}
|
|
575
|
+
message.Message = reader.string();
|
|
576
|
+
continue;
|
|
577
|
+
}
|
|
578
|
+
case 3: {
|
|
579
|
+
if (tag !== 26) {
|
|
580
|
+
break;
|
|
581
|
+
}
|
|
582
|
+
message.Members.push(reader.string());
|
|
583
|
+
continue;
|
|
584
|
+
}
|
|
585
|
+
}
|
|
586
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
587
|
+
break;
|
|
588
|
+
}
|
|
589
|
+
reader.skip(tag & 7);
|
|
590
|
+
}
|
|
591
|
+
return message;
|
|
592
|
+
}
|
|
593
|
+
finally {
|
|
594
|
+
reader.__tsProtoDecodeDepth = previousRecursionDepth;
|
|
595
|
+
}
|
|
596
|
+
},
|
|
597
|
+
fromJSON(object) {
|
|
598
|
+
return {
|
|
599
|
+
Severity: isSet(object.Severity) ? validationResultSeverityFromJSON(object.Severity) : 0,
|
|
600
|
+
Message: isSet(object.Message) ? globalThis.String(object.Message) : "",
|
|
601
|
+
Members: globalThis.Array.isArray(object?.Members) ? object.Members.map((e) => globalThis.String(e)) : [],
|
|
602
|
+
};
|
|
603
|
+
},
|
|
604
|
+
toJSON(message) {
|
|
605
|
+
const obj = {};
|
|
606
|
+
if (message.Severity !== 0) {
|
|
607
|
+
obj.Severity = validationResultSeverityToJSON(message.Severity);
|
|
608
|
+
}
|
|
609
|
+
if (message.Message !== "") {
|
|
610
|
+
obj.Message = message.Message;
|
|
611
|
+
}
|
|
612
|
+
if (message.Members?.length) {
|
|
613
|
+
obj.Members = message.Members;
|
|
614
|
+
}
|
|
615
|
+
return obj;
|
|
616
|
+
},
|
|
617
|
+
create(base) {
|
|
618
|
+
return ValidationResult.fromPartial(base ?? {});
|
|
619
|
+
},
|
|
620
|
+
fromPartial(object) {
|
|
621
|
+
const message = createBaseValidationResult();
|
|
622
|
+
message.Severity = object.Severity ?? 0;
|
|
623
|
+
message.Message = object.Message ?? "";
|
|
624
|
+
message.Members = object.Members?.map((e) => e) || [];
|
|
625
|
+
return message;
|
|
626
|
+
},
|
|
627
|
+
};
|
|
628
|
+
const StatisticsDefinition = {
|
|
629
|
+
name: "Statistics",
|
|
630
|
+
fullName: "Cratis.Chronicle.Contracts.Statistics.Statistics",
|
|
631
|
+
methods: {
|
|
632
|
+
statisticsForEventStore: {
|
|
633
|
+
name: "StatisticsForEventStore",
|
|
634
|
+
requestType: StatisticsForEventStoreRequest,
|
|
635
|
+
requestStream: false,
|
|
636
|
+
responseType: QueryResultEventStatisticsResponse,
|
|
637
|
+
responseStream: false,
|
|
638
|
+
options: {},
|
|
639
|
+
},
|
|
640
|
+
statisticsForNamespace: {
|
|
641
|
+
name: "StatisticsForNamespace",
|
|
642
|
+
requestType: StatisticsForNamespaceRequest,
|
|
643
|
+
requestStream: false,
|
|
644
|
+
responseType: QueryResultEventStatisticsResponse,
|
|
645
|
+
responseStream: false,
|
|
646
|
+
options: {},
|
|
647
|
+
},
|
|
648
|
+
},
|
|
649
|
+
};
|
|
650
|
+
function isSet(value) {
|
|
651
|
+
return value !== null && value !== undefined;
|
|
652
|
+
}
|
|
653
|
+
|
|
654
|
+
export { EventStatisticsResponse, EventTypeCount, QueryResultEventStatisticsResponse, StatisticsDefinition, StatisticsForEventStoreRequest, StatisticsForNamespaceRequest, ValidationResult, ValidationResultSeverity, validationResultSeverityFromJSON, validationResultSeverityToJSON };
|
|
655
|
+
//# sourceMappingURL=statistics.js.map
|