@acequants/aegis-contracts 0.1.22 → 0.1.24

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.
@@ -0,0 +1,108 @@
1
+ // Code generated by protoc-gen-ts_proto. DO NOT EDIT.
2
+ // versions:
3
+ // protoc-gen-ts_proto v1.181.2
4
+ // protoc v6.32.0
5
+ // source: analytics/v1/analytics.proto
6
+ import { GrpcMethod, GrpcStreamMethod } from "@nestjs/microservices";
7
+ import _m0 from "protobufjs/minimal";
8
+ export const protobufPackage = "aegis.analytics.v1";
9
+ export const AEGIS_ANALYTICS_V1_PACKAGE_NAME = "aegis.analytics.v1";
10
+ function createBaseStatsRequest() {
11
+ return { id: "" };
12
+ }
13
+ export const StatsRequest = {
14
+ encode(message, writer = _m0.Writer.create()) {
15
+ if (message.id !== "") {
16
+ writer.uint32(10).string(message.id);
17
+ }
18
+ return writer;
19
+ },
20
+ decode(input, length) {
21
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
22
+ let end = length === undefined ? reader.len : reader.pos + length;
23
+ const message = createBaseStatsRequest();
24
+ while (reader.pos < end) {
25
+ const tag = reader.uint32();
26
+ switch (tag >>> 3) {
27
+ case 1:
28
+ if (tag !== 10) {
29
+ break;
30
+ }
31
+ message.id = reader.string();
32
+ continue;
33
+ }
34
+ if ((tag & 7) === 4 || tag === 0) {
35
+ break;
36
+ }
37
+ reader.skipType(tag & 7);
38
+ }
39
+ return message;
40
+ },
41
+ };
42
+ function createBaseStatsResponse() {
43
+ return { id: "", name: "" };
44
+ }
45
+ export const StatsResponse = {
46
+ encode(message, writer = _m0.Writer.create()) {
47
+ if (message.id !== "") {
48
+ writer.uint32(10).string(message.id);
49
+ }
50
+ if (message.name !== "") {
51
+ writer.uint32(18).string(message.name);
52
+ }
53
+ return writer;
54
+ },
55
+ decode(input, length) {
56
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
57
+ let end = length === undefined ? reader.len : reader.pos + length;
58
+ const message = createBaseStatsResponse();
59
+ while (reader.pos < end) {
60
+ const tag = reader.uint32();
61
+ switch (tag >>> 3) {
62
+ case 1:
63
+ if (tag !== 10) {
64
+ break;
65
+ }
66
+ message.id = reader.string();
67
+ continue;
68
+ case 2:
69
+ if (tag !== 18) {
70
+ break;
71
+ }
72
+ message.name = reader.string();
73
+ continue;
74
+ }
75
+ if ((tag & 7) === 4 || tag === 0) {
76
+ break;
77
+ }
78
+ reader.skipType(tag & 7);
79
+ }
80
+ return message;
81
+ },
82
+ };
83
+ export function AnalyticsServiceControllerMethods() {
84
+ return function (constructor) {
85
+ const grpcMethods = ["getStats"];
86
+ for (const method of grpcMethods) {
87
+ const descriptor = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
88
+ GrpcMethod("AnalyticsService", method)(constructor.prototype[method], method, descriptor);
89
+ }
90
+ const grpcStreamMethods = [];
91
+ for (const method of grpcStreamMethods) {
92
+ const descriptor = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
93
+ GrpcStreamMethod("AnalyticsService", method)(constructor.prototype[method], method, descriptor);
94
+ }
95
+ };
96
+ }
97
+ export const ANALYTICS_SERVICE_NAME = "AnalyticsService";
98
+ export const AnalyticsServiceService = {
99
+ getStats: {
100
+ path: "/aegis.analytics.v1.AnalyticsService/GetStats",
101
+ requestStream: false,
102
+ responseStream: false,
103
+ requestSerialize: (value) => Buffer.from(StatsRequest.encode(value).finish()),
104
+ requestDeserialize: (value) => StatsRequest.decode(value),
105
+ responseSerialize: (value) => Buffer.from(StatsResponse.encode(value).finish()),
106
+ responseDeserialize: (value) => StatsResponse.decode(value),
107
+ },
108
+ };