@fivenet-app/gen 0.9.3-1

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.
Files changed (123) hide show
  1. package/README.md +1 -0
  2. package/google/protobuf/any.ts +322 -0
  3. package/google/protobuf/descriptor.ts +3475 -0
  4. package/google/protobuf/duration.ts +231 -0
  5. package/google/protobuf/timestamp.ts +290 -0
  6. package/package.json +15 -0
  7. package/perms.ts +178 -0
  8. package/resources/accounts/accounts.ts +195 -0
  9. package/resources/accounts/oauth2.ts +230 -0
  10. package/resources/calendar/access.ts +362 -0
  11. package/resources/calendar/calendar.ts +955 -0
  12. package/resources/centrum/access.ts +380 -0
  13. package/resources/centrum/dispatches.ts +854 -0
  14. package/resources/centrum/general.ts +231 -0
  15. package/resources/centrum/settings.ts +303 -0
  16. package/resources/centrum/units.ts +620 -0
  17. package/resources/common/access/dummy.ts +309 -0
  18. package/resources/common/content/content.ts +252 -0
  19. package/resources/common/cron/cron.ts +536 -0
  20. package/resources/common/database/database.ts +306 -0
  21. package/resources/common/error.ts +79 -0
  22. package/resources/common/grpcws/grpcws.ts +615 -0
  23. package/resources/common/i18n.ts +102 -0
  24. package/resources/common/uuid.ts +68 -0
  25. package/resources/documents/access.ts +388 -0
  26. package/resources/documents/activity.ts +803 -0
  27. package/resources/documents/category.ts +132 -0
  28. package/resources/documents/comment.ts +161 -0
  29. package/resources/documents/documents.ts +1124 -0
  30. package/resources/documents/requests.ts +196 -0
  31. package/resources/documents/templates.ts +949 -0
  32. package/resources/documents/workflow.ts +349 -0
  33. package/resources/filestore/file.ts +204 -0
  34. package/resources/internet/ads.ts +257 -0
  35. package/resources/internet/domain.ts +136 -0
  36. package/resources/internet/internet.ts +344 -0
  37. package/resources/internet/page.ts +236 -0
  38. package/resources/internet/search.ts +104 -0
  39. package/resources/jobs/activity.ts +600 -0
  40. package/resources/jobs/colleagues.ts +346 -0
  41. package/resources/jobs/conduct.ts +220 -0
  42. package/resources/jobs/labels.ts +240 -0
  43. package/resources/jobs/timeclock.ts +372 -0
  44. package/resources/laws/laws.ts +293 -0
  45. package/resources/livemap/livemap.ts +728 -0
  46. package/resources/livemap/tracker.ts +81 -0
  47. package/resources/mailer/access.ts +485 -0
  48. package/resources/mailer/email.ts +222 -0
  49. package/resources/mailer/events.ts +196 -0
  50. package/resources/mailer/message.ts +285 -0
  51. package/resources/mailer/settings.ts +95 -0
  52. package/resources/mailer/template.ts +164 -0
  53. package/resources/mailer/thread.ts +422 -0
  54. package/resources/mailer/user.ts +93 -0
  55. package/resources/notifications/events.ts +287 -0
  56. package/resources/notifications/notifications.ts +444 -0
  57. package/resources/permissions/permissions.ts +829 -0
  58. package/resources/qualifications/access.ts +275 -0
  59. package/resources/qualifications/exam.ts +1421 -0
  60. package/resources/qualifications/qualifications.ts +1289 -0
  61. package/resources/rector/audit.ts +226 -0
  62. package/resources/rector/config.ts +922 -0
  63. package/resources/stats/stats.ts +67 -0
  64. package/resources/sync/activity.ts +356 -0
  65. package/resources/sync/data.ts +455 -0
  66. package/resources/timestamp/timestamp.ts +78 -0
  67. package/resources/users/activity.ts +211 -0
  68. package/resources/users/job_props.ts +992 -0
  69. package/resources/users/jobs.ts +171 -0
  70. package/resources/users/labels.ts +161 -0
  71. package/resources/users/props.ts +207 -0
  72. package/resources/users/users.ts +570 -0
  73. package/resources/vehicles/vehicles.ts +114 -0
  74. package/resources/wiki/access.ts +362 -0
  75. package/resources/wiki/activity.ts +591 -0
  76. package/resources/wiki/page.ts +548 -0
  77. package/services/auth/auth.client.ts +171 -0
  78. package/services/auth/auth.ts +1331 -0
  79. package/services/calendar/calendar.client.ts +262 -0
  80. package/services/calendar/calendar.ts +1733 -0
  81. package/services/centrum/centrum.client.ts +365 -0
  82. package/services/centrum/centrum.ts +2619 -0
  83. package/services/citizenstore/citizenstore.client.ts +126 -0
  84. package/services/citizenstore/citizenstore.ts +847 -0
  85. package/services/completor/completor.client.ts +109 -0
  86. package/services/completor/completor.ts +616 -0
  87. package/services/dmv/vehicles.client.ts +41 -0
  88. package/services/dmv/vehicles.ts +191 -0
  89. package/services/docstore/docstore.client.ts +653 -0
  90. package/services/docstore/docstore.ts +4571 -0
  91. package/services/internet/ads.client.ts +41 -0
  92. package/services/internet/ads.ts +145 -0
  93. package/services/internet/internet.client.ts +58 -0
  94. package/services/internet/internet.ts +257 -0
  95. package/services/jobs/conduct.client.ts +92 -0
  96. package/services/jobs/conduct.ts +541 -0
  97. package/services/jobs/jobs.client.ts +194 -0
  98. package/services/jobs/jobs.ts +1301 -0
  99. package/services/jobs/timeclock.client.ts +75 -0
  100. package/services/jobs/timeclock.ts +808 -0
  101. package/services/livemapper/livemap.client.ts +76 -0
  102. package/services/livemapper/livemap.ts +552 -0
  103. package/services/mailer/mailer.client.ts +381 -0
  104. package/services/mailer/mailer.ts +2590 -0
  105. package/services/notificator/notificator.client.ts +76 -0
  106. package/services/notificator/notificator.ts +510 -0
  107. package/services/qualifications/qualifications.client.ts +279 -0
  108. package/services/qualifications/qualifications.ts +2142 -0
  109. package/services/rector/config.client.ts +58 -0
  110. package/services/rector/config.ts +216 -0
  111. package/services/rector/filestore.client.ts +75 -0
  112. package/services/rector/filestore.ts +378 -0
  113. package/services/rector/laws.client.ts +92 -0
  114. package/services/rector/laws.ts +416 -0
  115. package/services/rector/rector.client.ts +211 -0
  116. package/services/rector/rector.ts +1540 -0
  117. package/services/stats/stats.client.ts +37 -0
  118. package/services/stats/stats.ts +128 -0
  119. package/services/sync/sync.client.ts +110 -0
  120. package/services/sync/sync.ts +831 -0
  121. package/services/wiki/wiki.client.ts +126 -0
  122. package/services/wiki/wiki.ts +749 -0
  123. package/svcs.ts +307 -0
@@ -0,0 +1,380 @@
1
+ // @generated by protobuf-ts 2.9.4 with parameter optimize_speed,long_type_number,force_server_none
2
+ // @generated from protobuf file "resources/centrum/access.proto" (package "resources.centrum", syntax proto3)
3
+ // @ts-nocheck
4
+ import type { BinaryWriteOptions } from "@protobuf-ts/runtime";
5
+ import type { IBinaryWriter } from "@protobuf-ts/runtime";
6
+ import { WireType } from "@protobuf-ts/runtime";
7
+ import type { BinaryReadOptions } from "@protobuf-ts/runtime";
8
+ import type { IBinaryReader } from "@protobuf-ts/runtime";
9
+ import { UnknownFieldHandler } from "@protobuf-ts/runtime";
10
+ import type { PartialMessage } from "@protobuf-ts/runtime";
11
+ import { reflectionMergePartial } from "@protobuf-ts/runtime";
12
+ import { MessageType } from "@protobuf-ts/runtime";
13
+ import { QualificationShort } from "../qualifications/qualifications";
14
+ import { Timestamp } from "../timestamp/timestamp";
15
+ /**
16
+ * @generated from protobuf message resources.centrum.UnitAccess
17
+ */
18
+ export interface UnitAccess {
19
+ /**
20
+ * @generated from protobuf field: repeated resources.centrum.UnitJobAccess jobs = 1;
21
+ */
22
+ jobs: UnitJobAccess[]; // @gotags: alias:"job_access"
23
+ /**
24
+ * @generated from protobuf field: repeated resources.centrum.UnitQualificationAccess qualifications = 3;
25
+ */
26
+ qualifications: UnitQualificationAccess[]; // @gotags: alias:"qualification_access"
27
+ }
28
+ /**
29
+ * @generated from protobuf message resources.centrum.UnitJobAccess
30
+ */
31
+ export interface UnitJobAccess {
32
+ /**
33
+ * @generated from protobuf field: uint64 id = 1 [jstype = JS_STRING];
34
+ */
35
+ id: string;
36
+ /**
37
+ * @generated from protobuf field: optional resources.timestamp.Timestamp created_at = 2;
38
+ */
39
+ createdAt?: Timestamp;
40
+ /**
41
+ * @generated from protobuf field: uint64 target_id = 3 [jstype = JS_STRING];
42
+ */
43
+ targetId: string; // @gotags: alias:"calendar_id"
44
+ /**
45
+ * @generated from protobuf field: string job = 4;
46
+ */
47
+ job: string;
48
+ /**
49
+ * @generated from protobuf field: optional string job_label = 5;
50
+ */
51
+ jobLabel?: string;
52
+ /**
53
+ * @generated from protobuf field: int32 minimum_grade = 6;
54
+ */
55
+ minimumGrade: number;
56
+ /**
57
+ * @generated from protobuf field: optional string job_grade_label = 7;
58
+ */
59
+ jobGradeLabel?: string;
60
+ /**
61
+ * @generated from protobuf field: resources.centrum.UnitAccessLevel access = 8;
62
+ */
63
+ access: UnitAccessLevel;
64
+ }
65
+ /**
66
+ * @generated from protobuf message resources.centrum.UnitUserAccess
67
+ */
68
+ export interface UnitUserAccess {
69
+ }
70
+ /**
71
+ * @generated from protobuf message resources.centrum.UnitQualificationAccess
72
+ */
73
+ export interface UnitQualificationAccess {
74
+ /**
75
+ * @generated from protobuf field: uint64 id = 1 [jstype = JS_STRING];
76
+ */
77
+ id: string;
78
+ /**
79
+ * @generated from protobuf field: optional resources.timestamp.Timestamp created_at = 2;
80
+ */
81
+ createdAt?: Timestamp;
82
+ /**
83
+ * @generated from protobuf field: uint64 target_id = 3 [jstype = JS_STRING];
84
+ */
85
+ targetId: string; // @gotags: alias:"thread_id"
86
+ /**
87
+ * @generated from protobuf field: uint64 qualification_id = 4 [jstype = JS_STRING];
88
+ */
89
+ qualificationId: string;
90
+ /**
91
+ * @generated from protobuf field: optional resources.qualifications.QualificationShort qualification = 5;
92
+ */
93
+ qualification?: QualificationShort;
94
+ /**
95
+ * @generated from protobuf field: resources.centrum.UnitAccessLevel access = 6;
96
+ */
97
+ access: UnitAccessLevel;
98
+ }
99
+ /**
100
+ * @generated from protobuf enum resources.centrum.UnitAccessLevel
101
+ */
102
+ export enum UnitAccessLevel {
103
+ /**
104
+ * @generated from protobuf enum value: UNIT_ACCESS_LEVEL_UNSPECIFIED = 0;
105
+ */
106
+ UNSPECIFIED = 0,
107
+ /**
108
+ * @generated from protobuf enum value: UNIT_ACCESS_LEVEL_BLOCKED = 1;
109
+ */
110
+ BLOCKED = 1,
111
+ /**
112
+ * @generated from protobuf enum value: UNIT_ACCESS_LEVEL_JOIN = 2;
113
+ */
114
+ JOIN = 2
115
+ }
116
+ // @generated message type with reflection information, may provide speed optimized methods
117
+ class UnitAccess$Type extends MessageType<UnitAccess> {
118
+ constructor() {
119
+ super("resources.centrum.UnitAccess", [
120
+ { no: 1, name: "jobs", kind: "message", repeat: 1 /*RepeatType.PACKED*/, T: () => UnitJobAccess, options: { "validate.rules": { repeated: { maxItems: "20" } } } },
121
+ { no: 3, name: "qualifications", kind: "message", repeat: 1 /*RepeatType.PACKED*/, T: () => UnitQualificationAccess, options: { "validate.rules": { repeated: { maxItems: "20" } } } }
122
+ ]);
123
+ }
124
+ create(value?: PartialMessage<UnitAccess>): UnitAccess {
125
+ const message = globalThis.Object.create((this.messagePrototype!));
126
+ message.jobs = [];
127
+ message.qualifications = [];
128
+ if (value !== undefined)
129
+ reflectionMergePartial<UnitAccess>(this, message, value);
130
+ return message;
131
+ }
132
+ internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: UnitAccess): UnitAccess {
133
+ let message = target ?? this.create(), end = reader.pos + length;
134
+ while (reader.pos < end) {
135
+ let [fieldNo, wireType] = reader.tag();
136
+ switch (fieldNo) {
137
+ case /* repeated resources.centrum.UnitJobAccess jobs */ 1:
138
+ message.jobs.push(UnitJobAccess.internalBinaryRead(reader, reader.uint32(), options));
139
+ break;
140
+ case /* repeated resources.centrum.UnitQualificationAccess qualifications */ 3:
141
+ message.qualifications.push(UnitQualificationAccess.internalBinaryRead(reader, reader.uint32(), options));
142
+ break;
143
+ default:
144
+ let u = options.readUnknownField;
145
+ if (u === "throw")
146
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
147
+ let d = reader.skip(wireType);
148
+ if (u !== false)
149
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
150
+ }
151
+ }
152
+ return message;
153
+ }
154
+ internalBinaryWrite(message: UnitAccess, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
155
+ /* repeated resources.centrum.UnitJobAccess jobs = 1; */
156
+ for (let i = 0; i < message.jobs.length; i++)
157
+ UnitJobAccess.internalBinaryWrite(message.jobs[i], writer.tag(1, WireType.LengthDelimited).fork(), options).join();
158
+ /* repeated resources.centrum.UnitQualificationAccess qualifications = 3; */
159
+ for (let i = 0; i < message.qualifications.length; i++)
160
+ UnitQualificationAccess.internalBinaryWrite(message.qualifications[i], writer.tag(3, WireType.LengthDelimited).fork(), options).join();
161
+ let u = options.writeUnknownFields;
162
+ if (u !== false)
163
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
164
+ return writer;
165
+ }
166
+ }
167
+ /**
168
+ * @generated MessageType for protobuf message resources.centrum.UnitAccess
169
+ */
170
+ export const UnitAccess = new UnitAccess$Type();
171
+ // @generated message type with reflection information, may provide speed optimized methods
172
+ class UnitJobAccess$Type extends MessageType<UnitJobAccess> {
173
+ constructor() {
174
+ super("resources.centrum.UnitJobAccess", [
175
+ { no: 1, name: "id", kind: "scalar", T: 4 /*ScalarType.UINT64*/ },
176
+ { no: 2, name: "created_at", kind: "message", T: () => Timestamp },
177
+ { no: 3, name: "target_id", kind: "scalar", T: 4 /*ScalarType.UINT64*/ },
178
+ { no: 4, name: "job", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { maxLen: "20" } } } },
179
+ { no: 5, name: "job_label", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { maxLen: "50" } } } },
180
+ { no: 6, name: "minimum_grade", kind: "scalar", T: 5 /*ScalarType.INT32*/, options: { "validate.rules": { int32: { gte: 0 } } } },
181
+ { no: 7, name: "job_grade_label", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { maxLen: "50" } } } },
182
+ { no: 8, name: "access", kind: "enum", T: () => ["resources.centrum.UnitAccessLevel", UnitAccessLevel, "UNIT_ACCESS_LEVEL_"], options: { "validate.rules": { enum: { definedOnly: true } } } }
183
+ ]);
184
+ }
185
+ create(value?: PartialMessage<UnitJobAccess>): UnitJobAccess {
186
+ const message = globalThis.Object.create((this.messagePrototype!));
187
+ message.id = "0";
188
+ message.targetId = "0";
189
+ message.job = "";
190
+ message.minimumGrade = 0;
191
+ message.access = 0;
192
+ if (value !== undefined)
193
+ reflectionMergePartial<UnitJobAccess>(this, message, value);
194
+ return message;
195
+ }
196
+ internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: UnitJobAccess): UnitJobAccess {
197
+ let message = target ?? this.create(), end = reader.pos + length;
198
+ while (reader.pos < end) {
199
+ let [fieldNo, wireType] = reader.tag();
200
+ switch (fieldNo) {
201
+ case /* uint64 id = 1 [jstype = JS_STRING];*/ 1:
202
+ message.id = reader.uint64().toString();
203
+ break;
204
+ case /* optional resources.timestamp.Timestamp created_at */ 2:
205
+ message.createdAt = Timestamp.internalBinaryRead(reader, reader.uint32(), options, message.createdAt);
206
+ break;
207
+ case /* uint64 target_id = 3 [jstype = JS_STRING];*/ 3:
208
+ message.targetId = reader.uint64().toString();
209
+ break;
210
+ case /* string job */ 4:
211
+ message.job = reader.string();
212
+ break;
213
+ case /* optional string job_label */ 5:
214
+ message.jobLabel = reader.string();
215
+ break;
216
+ case /* int32 minimum_grade */ 6:
217
+ message.minimumGrade = reader.int32();
218
+ break;
219
+ case /* optional string job_grade_label */ 7:
220
+ message.jobGradeLabel = reader.string();
221
+ break;
222
+ case /* resources.centrum.UnitAccessLevel access */ 8:
223
+ message.access = reader.int32();
224
+ break;
225
+ default:
226
+ let u = options.readUnknownField;
227
+ if (u === "throw")
228
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
229
+ let d = reader.skip(wireType);
230
+ if (u !== false)
231
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
232
+ }
233
+ }
234
+ return message;
235
+ }
236
+ internalBinaryWrite(message: UnitJobAccess, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
237
+ /* uint64 id = 1 [jstype = JS_STRING]; */
238
+ if (message.id !== "0")
239
+ writer.tag(1, WireType.Varint).uint64(message.id);
240
+ /* optional resources.timestamp.Timestamp created_at = 2; */
241
+ if (message.createdAt)
242
+ Timestamp.internalBinaryWrite(message.createdAt, writer.tag(2, WireType.LengthDelimited).fork(), options).join();
243
+ /* uint64 target_id = 3 [jstype = JS_STRING]; */
244
+ if (message.targetId !== "0")
245
+ writer.tag(3, WireType.Varint).uint64(message.targetId);
246
+ /* string job = 4; */
247
+ if (message.job !== "")
248
+ writer.tag(4, WireType.LengthDelimited).string(message.job);
249
+ /* optional string job_label = 5; */
250
+ if (message.jobLabel !== undefined)
251
+ writer.tag(5, WireType.LengthDelimited).string(message.jobLabel);
252
+ /* int32 minimum_grade = 6; */
253
+ if (message.minimumGrade !== 0)
254
+ writer.tag(6, WireType.Varint).int32(message.minimumGrade);
255
+ /* optional string job_grade_label = 7; */
256
+ if (message.jobGradeLabel !== undefined)
257
+ writer.tag(7, WireType.LengthDelimited).string(message.jobGradeLabel);
258
+ /* resources.centrum.UnitAccessLevel access = 8; */
259
+ if (message.access !== 0)
260
+ writer.tag(8, WireType.Varint).int32(message.access);
261
+ let u = options.writeUnknownFields;
262
+ if (u !== false)
263
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
264
+ return writer;
265
+ }
266
+ }
267
+ /**
268
+ * @generated MessageType for protobuf message resources.centrum.UnitJobAccess
269
+ */
270
+ export const UnitJobAccess = new UnitJobAccess$Type();
271
+ // @generated message type with reflection information, may provide speed optimized methods
272
+ class UnitUserAccess$Type extends MessageType<UnitUserAccess> {
273
+ constructor() {
274
+ super("resources.centrum.UnitUserAccess", []);
275
+ }
276
+ create(value?: PartialMessage<UnitUserAccess>): UnitUserAccess {
277
+ const message = globalThis.Object.create((this.messagePrototype!));
278
+ if (value !== undefined)
279
+ reflectionMergePartial<UnitUserAccess>(this, message, value);
280
+ return message;
281
+ }
282
+ internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: UnitUserAccess): UnitUserAccess {
283
+ return target ?? this.create();
284
+ }
285
+ internalBinaryWrite(message: UnitUserAccess, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
286
+ let u = options.writeUnknownFields;
287
+ if (u !== false)
288
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
289
+ return writer;
290
+ }
291
+ }
292
+ /**
293
+ * @generated MessageType for protobuf message resources.centrum.UnitUserAccess
294
+ */
295
+ export const UnitUserAccess = new UnitUserAccess$Type();
296
+ // @generated message type with reflection information, may provide speed optimized methods
297
+ class UnitQualificationAccess$Type extends MessageType<UnitQualificationAccess> {
298
+ constructor() {
299
+ super("resources.centrum.UnitQualificationAccess", [
300
+ { no: 1, name: "id", kind: "scalar", T: 4 /*ScalarType.UINT64*/ },
301
+ { no: 2, name: "created_at", kind: "message", T: () => Timestamp },
302
+ { no: 3, name: "target_id", kind: "scalar", T: 4 /*ScalarType.UINT64*/ },
303
+ { no: 4, name: "qualification_id", kind: "scalar", T: 4 /*ScalarType.UINT64*/ },
304
+ { no: 5, name: "qualification", kind: "message", T: () => QualificationShort },
305
+ { no: 6, name: "access", kind: "enum", T: () => ["resources.centrum.UnitAccessLevel", UnitAccessLevel, "UNIT_ACCESS_LEVEL_"], options: { "validate.rules": { enum: { definedOnly: true } } } }
306
+ ]);
307
+ }
308
+ create(value?: PartialMessage<UnitQualificationAccess>): UnitQualificationAccess {
309
+ const message = globalThis.Object.create((this.messagePrototype!));
310
+ message.id = "0";
311
+ message.targetId = "0";
312
+ message.qualificationId = "0";
313
+ message.access = 0;
314
+ if (value !== undefined)
315
+ reflectionMergePartial<UnitQualificationAccess>(this, message, value);
316
+ return message;
317
+ }
318
+ internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: UnitQualificationAccess): UnitQualificationAccess {
319
+ let message = target ?? this.create(), end = reader.pos + length;
320
+ while (reader.pos < end) {
321
+ let [fieldNo, wireType] = reader.tag();
322
+ switch (fieldNo) {
323
+ case /* uint64 id = 1 [jstype = JS_STRING];*/ 1:
324
+ message.id = reader.uint64().toString();
325
+ break;
326
+ case /* optional resources.timestamp.Timestamp created_at */ 2:
327
+ message.createdAt = Timestamp.internalBinaryRead(reader, reader.uint32(), options, message.createdAt);
328
+ break;
329
+ case /* uint64 target_id = 3 [jstype = JS_STRING];*/ 3:
330
+ message.targetId = reader.uint64().toString();
331
+ break;
332
+ case /* uint64 qualification_id = 4 [jstype = JS_STRING];*/ 4:
333
+ message.qualificationId = reader.uint64().toString();
334
+ break;
335
+ case /* optional resources.qualifications.QualificationShort qualification */ 5:
336
+ message.qualification = QualificationShort.internalBinaryRead(reader, reader.uint32(), options, message.qualification);
337
+ break;
338
+ case /* resources.centrum.UnitAccessLevel access */ 6:
339
+ message.access = reader.int32();
340
+ break;
341
+ default:
342
+ let u = options.readUnknownField;
343
+ if (u === "throw")
344
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
345
+ let d = reader.skip(wireType);
346
+ if (u !== false)
347
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
348
+ }
349
+ }
350
+ return message;
351
+ }
352
+ internalBinaryWrite(message: UnitQualificationAccess, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
353
+ /* uint64 id = 1 [jstype = JS_STRING]; */
354
+ if (message.id !== "0")
355
+ writer.tag(1, WireType.Varint).uint64(message.id);
356
+ /* optional resources.timestamp.Timestamp created_at = 2; */
357
+ if (message.createdAt)
358
+ Timestamp.internalBinaryWrite(message.createdAt, writer.tag(2, WireType.LengthDelimited).fork(), options).join();
359
+ /* uint64 target_id = 3 [jstype = JS_STRING]; */
360
+ if (message.targetId !== "0")
361
+ writer.tag(3, WireType.Varint).uint64(message.targetId);
362
+ /* uint64 qualification_id = 4 [jstype = JS_STRING]; */
363
+ if (message.qualificationId !== "0")
364
+ writer.tag(4, WireType.Varint).uint64(message.qualificationId);
365
+ /* optional resources.qualifications.QualificationShort qualification = 5; */
366
+ if (message.qualification)
367
+ QualificationShort.internalBinaryWrite(message.qualification, writer.tag(5, WireType.LengthDelimited).fork(), options).join();
368
+ /* resources.centrum.UnitAccessLevel access = 6; */
369
+ if (message.access !== 0)
370
+ writer.tag(6, WireType.Varint).int32(message.access);
371
+ let u = options.writeUnknownFields;
372
+ if (u !== false)
373
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
374
+ return writer;
375
+ }
376
+ }
377
+ /**
378
+ * @generated MessageType for protobuf message resources.centrum.UnitQualificationAccess
379
+ */
380
+ export const UnitQualificationAccess = new UnitQualificationAccess$Type();