@fivenet-app/gen 2025.5.2 → 2025.9.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 (169) hide show
  1. package/buf/validate/validate.ts +11301 -0
  2. package/clients.ts +157 -154
  3. package/codegen/dbscanner/dbscanner.ts +91 -0
  4. package/codegen/perms/perms.ts +208 -0
  5. package/codegen/sanitizer/sanitizer.ts +80 -0
  6. package/google/protobuf/any.ts +4 -3
  7. package/google/protobuf/descriptor.ts +393 -239
  8. package/google/protobuf/duration.ts +4 -3
  9. package/google/protobuf/struct.ts +485 -0
  10. package/google/protobuf/timestamp.ts +4 -3
  11. package/package.json +3 -3
  12. package/perms.ts +85 -159
  13. package/resources/accounts/accounts.ts +26 -25
  14. package/resources/accounts/oauth2.ts +30 -29
  15. package/resources/audit/audit.ts +36 -35
  16. package/resources/calendar/access.ts +49 -48
  17. package/resources/calendar/calendar.ts +122 -126
  18. package/resources/centrum/access.ts +345 -0
  19. package/resources/centrum/attributes.ts +8 -11
  20. package/resources/centrum/dispatchers.ts +149 -0
  21. package/resources/centrum/dispatches.ts +252 -115
  22. package/resources/centrum/settings.ts +384 -34
  23. package/resources/centrum/units.ts +112 -92
  24. package/resources/centrum/units_access.ts +54 -55
  25. package/resources/clientconfig/clientconfig.ts +890 -0
  26. package/resources/collab/collab.ts +817 -0
  27. package/resources/common/content/content.ts +113 -30
  28. package/resources/common/cron/cron.ts +43 -31
  29. package/resources/common/database/database.ts +92 -35
  30. package/resources/common/error.ts +17 -16
  31. package/resources/common/grpcws/grpcws.ts +24 -23
  32. package/resources/common/i18n.ts +20 -24
  33. package/resources/common/id_mapping.ts +69 -0
  34. package/resources/common/tests/objects.ts +4 -3
  35. package/resources/common/uuid.ts +4 -3
  36. package/resources/discord/discord.ts +209 -0
  37. package/resources/documents/access.ts +52 -53
  38. package/resources/documents/activity.ts +235 -58
  39. package/resources/documents/category.ts +20 -27
  40. package/resources/documents/comment.ts +26 -25
  41. package/resources/documents/documents.ts +335 -262
  42. package/resources/documents/pins.ts +127 -0
  43. package/resources/documents/requests.ts +31 -30
  44. package/resources/documents/signoff.ts +55 -0
  45. package/resources/documents/state.ts +69 -0
  46. package/resources/documents/templates.ts +119 -136
  47. package/resources/documents/workflow.ts +35 -24
  48. package/resources/file/file.ts +152 -0
  49. package/{services/settings → resources/file}/filestore.ts +179 -165
  50. package/resources/file/meta.ts +148 -0
  51. package/resources/jobs/activity.ts +39 -42
  52. package/resources/jobs/colleagues.ts +67 -60
  53. package/resources/jobs/conduct.ts +29 -30
  54. package/resources/jobs/job_props.ts +46 -48
  55. package/resources/jobs/job_settings.ts +45 -52
  56. package/resources/jobs/jobs.ts +14 -13
  57. package/resources/jobs/labels.ts +21 -22
  58. package/resources/jobs/timeclock.ts +26 -25
  59. package/resources/laws/laws.ts +40 -49
  60. package/resources/livemap/coords.ts +81 -0
  61. package/resources/livemap/heatmap.ts +93 -0
  62. package/resources/livemap/{livemap.ts → marker_marker.ts} +43 -310
  63. package/resources/livemap/user_marker.ts +298 -0
  64. package/resources/mailer/access.ts +75 -74
  65. package/resources/mailer/email.ts +24 -27
  66. package/resources/mailer/events.ts +25 -24
  67. package/resources/mailer/message.ts +45 -50
  68. package/resources/mailer/settings.ts +12 -15
  69. package/resources/mailer/template.ts +25 -28
  70. package/resources/mailer/thread.ts +70 -71
  71. package/resources/notifications/client_view.ts +239 -0
  72. package/resources/notifications/events.ts +50 -101
  73. package/resources/notifications/notifications.ts +52 -57
  74. package/resources/permissions/attributes.ts +63 -206
  75. package/resources/permissions/events.ts +149 -0
  76. package/resources/permissions/permissions.ts +103 -34
  77. package/resources/qualifications/access.ts +27 -26
  78. package/resources/qualifications/exam.ts +188 -126
  79. package/resources/qualifications/qualifications.ts +370 -303
  80. package/resources/settings/banner.ts +14 -21
  81. package/resources/settings/config.ts +163 -79
  82. package/resources/settings/perms.ts +151 -0
  83. package/resources/settings/status.ts +533 -0
  84. package/resources/stats/stats.ts +3 -2
  85. package/resources/sync/activity.ts +24 -23
  86. package/resources/sync/data.ts +94 -26
  87. package/resources/timestamp/timestamp.ts +3 -2
  88. package/resources/{centrum/user_unit.ts → tracker/mapping.ts} +44 -44
  89. package/resources/userinfo/user_info.ts +464 -0
  90. package/resources/users/activity.ts +80 -85
  91. package/resources/users/labels.ts +18 -21
  92. package/resources/users/licenses.ts +9 -8
  93. package/resources/users/props.ts +61 -51
  94. package/resources/users/users.ts +100 -78
  95. package/resources/vehicles/activity.ts +231 -0
  96. package/resources/vehicles/props.ts +103 -0
  97. package/resources/vehicles/vehicles.ts +28 -15
  98. package/resources/wiki/access.ts +49 -48
  99. package/resources/wiki/activity.ts +133 -51
  100. package/resources/wiki/page.ts +134 -87
  101. package/services/auth/auth.client.ts +24 -27
  102. package/services/auth/auth.ts +222 -195
  103. package/services/calendar/calendar.client.ts +32 -91
  104. package/services/calendar/calendar.ts +110 -109
  105. package/services/centrum/centrum.client.ts +97 -137
  106. package/services/centrum/centrum.ts +701 -298
  107. package/services/citizens/citizens.client.ts +70 -39
  108. package/services/citizens/citizens.ts +183 -93
  109. package/services/completor/completor.client.ts +16 -35
  110. package/services/completor/completor.ts +65 -44
  111. package/services/documents/collab.client.ts +46 -0
  112. package/services/documents/collab.ts +13 -0
  113. package/services/documents/documents.client.ts +88 -217
  114. package/services/documents/documents.ts +490 -508
  115. package/services/filestore/filestore.client.ts +86 -0
  116. package/services/filestore/filestore.ts +262 -0
  117. package/services/jobs/conduct.client.ts +10 -25
  118. package/services/jobs/conduct.ts +36 -35
  119. package/services/jobs/jobs.client.ts +22 -61
  120. package/services/jobs/jobs.ts +108 -91
  121. package/services/jobs/timeclock.client.ts +8 -19
  122. package/services/jobs/timeclock.ts +47 -46
  123. package/services/livemap/livemap.client.ts +8 -19
  124. package/services/livemap/livemap.ts +290 -119
  125. package/services/mailer/mailer.client.ts +44 -127
  126. package/services/mailer/mailer.ts +213 -216
  127. package/services/notifications/notifications.client.ts +65 -0
  128. package/services/{notificator/notificator.ts → notifications/notifications.ts} +117 -74
  129. package/services/qualifications/qualifications.client.ts +46 -91
  130. package/services/qualifications/qualifications.ts +181 -175
  131. package/services/settings/accounts.client.ts +10 -25
  132. package/services/settings/accounts.ts +64 -41
  133. package/services/settings/config.client.ts +6 -13
  134. package/services/settings/config.ts +8 -7
  135. package/services/settings/cron.client.ts +4 -7
  136. package/services/settings/cron.ts +4 -3
  137. package/services/settings/laws.client.ts +10 -25
  138. package/services/settings/laws.ts +29 -28
  139. package/services/settings/settings.client.ts +57 -103
  140. package/services/settings/settings.ts +190 -607
  141. package/services/settings/system.client.ts +90 -0
  142. package/services/settings/system.ts +618 -0
  143. package/services/stats/stats.client.ts +4 -3
  144. package/services/stats/stats.ts +4 -3
  145. package/services/sync/sync.client.ts +16 -15
  146. package/services/sync/sync.ts +82 -52
  147. package/services/vehicles/vehicles.client.ts +17 -7
  148. package/services/vehicles/vehicles.ts +169 -24
  149. package/services/wiki/collab.client.ts +46 -0
  150. package/services/wiki/collab.ts +13 -0
  151. package/services/wiki/wiki.client.ts +28 -37
  152. package/services/wiki/wiki.ts +93 -63
  153. package/svcs.ts +79 -103
  154. package/resources/centrum/disponents.ts +0 -81
  155. package/resources/filestore/file.ts +0 -204
  156. package/resources/internet/access.ts +0 -358
  157. package/resources/internet/ads.ts +0 -257
  158. package/resources/internet/domain.ts +0 -328
  159. package/resources/internet/page.ts +0 -428
  160. package/resources/internet/search.ts +0 -128
  161. package/resources/livemap/tracker.ts +0 -81
  162. package/services/internet/ads.client.ts +0 -41
  163. package/services/internet/ads.ts +0 -145
  164. package/services/internet/domain.client.ts +0 -109
  165. package/services/internet/domain.ts +0 -658
  166. package/services/internet/internet.client.ts +0 -58
  167. package/services/internet/internet.ts +0 -268
  168. package/services/notificator/notificator.client.ts +0 -76
  169. package/services/settings/filestore.client.ts +0 -75
package/clients.ts CHANGED
@@ -1,156 +1,159 @@
1
1
  // Code generated by protoc-gen-fronthelper. DO NOT EDIT.
2
2
 
3
- import type { RpcTransport } from '@protobuf-ts/runtime-rpc';
4
- import { AuthServiceClient } from '~~/gen/ts/services/auth/auth.client';
5
- import { CalendarServiceClient } from '~~/gen/ts/services/calendar/calendar.client';
6
- import { CentrumServiceClient } from '~~/gen/ts/services/centrum/centrum.client';
7
- import { CitizensServiceClient } from '~~/gen/ts/services/citizens/citizens.client';
8
- import { CompletorServiceClient } from '~~/gen/ts/services/completor/completor.client';
9
- import { DocumentsServiceClient } from '~~/gen/ts/services/documents/documents.client';
10
- import { AdsServiceClient } from '~~/gen/ts/services/internet/ads.client';
11
- import { DomainServiceClient } from '~~/gen/ts/services/internet/domain.client';
12
- import { InternetServiceClient } from '~~/gen/ts/services/internet/internet.client';
13
- import { ConductServiceClient } from '~~/gen/ts/services/jobs/conduct.client';
14
- import { JobsServiceClient } from '~~/gen/ts/services/jobs/jobs.client';
15
- import { TimeclockServiceClient } from '~~/gen/ts/services/jobs/timeclock.client';
16
- import { LivemapServiceClient } from '~~/gen/ts/services/livemap/livemap.client';
17
- import { MailerServiceClient } from '~~/gen/ts/services/mailer/mailer.client';
18
- import { NotificatorServiceClient } from '~~/gen/ts/services/notificator/notificator.client';
19
- import { QualificationsServiceClient } from '~~/gen/ts/services/qualifications/qualifications.client';
20
- import { AccountsServiceClient } from '~~/gen/ts/services/settings/accounts.client';
21
- import { ConfigServiceClient } from '~~/gen/ts/services/settings/config.client';
22
- import { CronServiceClient } from '~~/gen/ts/services/settings/cron.client';
23
- import { FilestoreServiceClient } from '~~/gen/ts/services/settings/filestore.client';
24
- import { LawsServiceClient } from '~~/gen/ts/services/settings/laws.client';
25
- import { SettingsServiceClient } from '~~/gen/ts/services/settings/settings.client';
26
- import { StatsServiceClient } from '~~/gen/ts/services/stats/stats.client';
27
- import { SyncServiceClient } from '~~/gen/ts/services/sync/sync.client';
28
- import { VehiclesServiceClient } from '~~/gen/ts/services/vehicles/vehicles.client';
29
- import { WikiServiceClient } from '~~/gen/ts/services/wiki/wiki.client';
30
-
31
- export class GRPCClients {
32
-
33
- public auth: {
34
- auth: AuthServiceClient;
35
- };
36
- public calendar: {
37
- calendar: CalendarServiceClient;
38
- };
39
- public centrum: {
40
- centrum: CentrumServiceClient;
41
- };
42
- public citizens: {
43
- citizens: CitizensServiceClient;
44
- };
45
- public completor: {
46
- completor: CompletorServiceClient;
47
- };
48
- public documents: {
49
- documents: DocumentsServiceClient;
50
- };
51
- public internet: {
52
- ads: AdsServiceClient;
53
- domain: DomainServiceClient;
54
- internet: InternetServiceClient;
55
- };
56
- public jobs: {
57
- conduct: ConductServiceClient;
58
- jobs: JobsServiceClient;
59
- timeclock: TimeclockServiceClient;
60
- };
61
- public livemap: {
62
- livemap: LivemapServiceClient;
63
- };
64
- public mailer: {
65
- mailer: MailerServiceClient;
66
- };
67
- public notificator: {
68
- notificator: NotificatorServiceClient;
69
- };
70
- public qualifications: {
71
- qualifications: QualificationsServiceClient;
72
- };
73
- public settings: {
74
- accounts: AccountsServiceClient;
75
- config: ConfigServiceClient;
76
- cron: CronServiceClient;
77
- filestore: FilestoreServiceClient;
78
- laws: LawsServiceClient;
79
- settings: SettingsServiceClient;
80
- };
81
- public stats: {
82
- stats: StatsServiceClient;
83
- };
84
- public sync: {
85
- sync: SyncServiceClient;
86
- };
87
- public vehicles: {
88
- vehicles: VehiclesServiceClient;
89
- };
90
- public wiki: {
91
- wiki: WikiServiceClient;
92
- };
93
-
94
- constructor(transport: RpcTransport) {
95
- this.auth = {
96
- auth: new AuthServiceClient(transport),
97
- };
98
- this.calendar = {
99
- calendar: new CalendarServiceClient(transport),
100
- };
101
- this.centrum = {
102
- centrum: new CentrumServiceClient(transport),
103
- };
104
- this.citizens = {
105
- citizens: new CitizensServiceClient(transport),
106
- };
107
- this.completor = {
108
- completor: new CompletorServiceClient(transport),
109
- };
110
- this.documents = {
111
- documents: new DocumentsServiceClient(transport),
112
- };
113
- this.internet = {
114
- ads: new AdsServiceClient(transport),
115
- domain: new DomainServiceClient(transport),
116
- internet: new InternetServiceClient(transport),
117
- };
118
- this.jobs = {
119
- conduct: new ConductServiceClient(transport),
120
- jobs: new JobsServiceClient(transport),
121
- timeclock: new TimeclockServiceClient(transport),
122
- };
123
- this.livemap = {
124
- livemap: new LivemapServiceClient(transport),
125
- };
126
- this.mailer = {
127
- mailer: new MailerServiceClient(transport),
128
- };
129
- this.notificator = {
130
- notificator: new NotificatorServiceClient(transport),
131
- };
132
- this.qualifications = {
133
- qualifications: new QualificationsServiceClient(transport),
134
- };
135
- this.settings = {
136
- accounts: new AccountsServiceClient(transport),
137
- config: new ConfigServiceClient(transport),
138
- cron: new CronServiceClient(transport),
139
- filestore: new FilestoreServiceClient(transport),
140
- laws: new LawsServiceClient(transport),
141
- settings: new SettingsServiceClient(transport),
142
- };
143
- this.stats = {
144
- stats: new StatsServiceClient(transport),
145
- };
146
- this.sync = {
147
- sync: new SyncServiceClient(transport),
148
- };
149
- this.vehicles = {
150
- vehicles: new VehiclesServiceClient(transport),
151
- };
152
- this.wiki = {
153
- wiki: new WikiServiceClient(transport),
154
- };
155
- }
156
- };
3
+ import { useGRPCTransport } from '~/composables/useGRPCTransport';
4
+
5
+ // Factory for auth.auth client.
6
+ export async function getAuthAuthClient() {
7
+ const { AuthServiceClient } = await import('~~/gen/ts/services/auth/auth.client');
8
+ return new AuthServiceClient(useGRPCTransport());
9
+ }
10
+
11
+ // Factory for calendar.calendar client.
12
+ export async function getCalendarCalendarClient() {
13
+ const { CalendarServiceClient } = await import('~~/gen/ts/services/calendar/calendar.client');
14
+ return new CalendarServiceClient(useGRPCTransport());
15
+ }
16
+
17
+ // Factory for centrum.centrum client.
18
+ export async function getCentrumCentrumClient() {
19
+ const { CentrumServiceClient } = await import('~~/gen/ts/services/centrum/centrum.client');
20
+ return new CentrumServiceClient(useGRPCTransport());
21
+ }
22
+
23
+ // Factory for citizens.citizens client.
24
+ export async function getCitizensCitizensClient() {
25
+ const { CitizensServiceClient } = await import('~~/gen/ts/services/citizens/citizens.client');
26
+ return new CitizensServiceClient(useGRPCTransport());
27
+ }
28
+
29
+ // Factory for completor.completor client.
30
+ export async function getCompletorCompletorClient() {
31
+ const { CompletorServiceClient } = await import('~~/gen/ts/services/completor/completor.client');
32
+ return new CompletorServiceClient(useGRPCTransport());
33
+ }
34
+
35
+ // Factory for documents.collab client.
36
+ export async function getDocumentsCollabClient() {
37
+ const { CollabServiceClient } = await import('~~/gen/ts/services/documents/collab.client');
38
+ return new CollabServiceClient(useGRPCTransport());
39
+ }
40
+
41
+ // Factory for documents.documents client.
42
+ export async function getDocumentsDocumentsClient() {
43
+ const { DocumentsServiceClient } = await import('~~/gen/ts/services/documents/documents.client');
44
+ return new DocumentsServiceClient(useGRPCTransport());
45
+ }
46
+
47
+ // Factory for filestore.filestore client.
48
+ export async function getFilestoreFilestoreClient() {
49
+ const { FilestoreServiceClient } = await import('~~/gen/ts/services/filestore/filestore.client');
50
+ return new FilestoreServiceClient(useGRPCTransport());
51
+ }
52
+
53
+ // Factory for jobs.conduct client.
54
+ export async function getJobsConductClient() {
55
+ const { ConductServiceClient } = await import('~~/gen/ts/services/jobs/conduct.client');
56
+ return new ConductServiceClient(useGRPCTransport());
57
+ }
58
+
59
+ // Factory for jobs.jobs client.
60
+ export async function getJobsJobsClient() {
61
+ const { JobsServiceClient } = await import('~~/gen/ts/services/jobs/jobs.client');
62
+ return new JobsServiceClient(useGRPCTransport());
63
+ }
64
+
65
+ // Factory for jobs.timeclock client.
66
+ export async function getJobsTimeclockClient() {
67
+ const { TimeclockServiceClient } = await import('~~/gen/ts/services/jobs/timeclock.client');
68
+ return new TimeclockServiceClient(useGRPCTransport());
69
+ }
70
+
71
+ // Factory for livemap.livemap client.
72
+ export async function getLivemapLivemapClient() {
73
+ const { LivemapServiceClient } = await import('~~/gen/ts/services/livemap/livemap.client');
74
+ return new LivemapServiceClient(useGRPCTransport());
75
+ }
76
+
77
+ // Factory for mailer.mailer client.
78
+ export async function getMailerMailerClient() {
79
+ const { MailerServiceClient } = await import('~~/gen/ts/services/mailer/mailer.client');
80
+ return new MailerServiceClient(useGRPCTransport());
81
+ }
82
+
83
+ // Factory for notifications.notifications client.
84
+ export async function getNotificationsNotificationsClient() {
85
+ const { NotificationsServiceClient } = await import('~~/gen/ts/services/notifications/notifications.client');
86
+ return new NotificationsServiceClient(useGRPCTransport());
87
+ }
88
+
89
+ // Factory for qualifications.qualifications client.
90
+ export async function getQualificationsQualificationsClient() {
91
+ const { QualificationsServiceClient } = await import('~~/gen/ts/services/qualifications/qualifications.client');
92
+ return new QualificationsServiceClient(useGRPCTransport());
93
+ }
94
+
95
+ // Factory for settings.accounts client.
96
+ export async function getSettingsAccountsClient() {
97
+ const { AccountsServiceClient } = await import('~~/gen/ts/services/settings/accounts.client');
98
+ return new AccountsServiceClient(useGRPCTransport());
99
+ }
100
+
101
+ // Factory for settings.config client.
102
+ export async function getSettingsConfigClient() {
103
+ const { ConfigServiceClient } = await import('~~/gen/ts/services/settings/config.client');
104
+ return new ConfigServiceClient(useGRPCTransport());
105
+ }
106
+
107
+ // Factory for settings.cron client.
108
+ export async function getSettingsCronClient() {
109
+ const { CronServiceClient } = await import('~~/gen/ts/services/settings/cron.client');
110
+ return new CronServiceClient(useGRPCTransport());
111
+ }
112
+
113
+ // Factory for settings.laws client.
114
+ export async function getSettingsLawsClient() {
115
+ const { LawsServiceClient } = await import('~~/gen/ts/services/settings/laws.client');
116
+ return new LawsServiceClient(useGRPCTransport());
117
+ }
118
+
119
+ // Factory for settings.settings client.
120
+ export async function getSettingsSettingsClient() {
121
+ const { SettingsServiceClient } = await import('~~/gen/ts/services/settings/settings.client');
122
+ return new SettingsServiceClient(useGRPCTransport());
123
+ }
124
+
125
+ // Factory for settings.system client.
126
+ export async function getSettingsSystemClient() {
127
+ const { SystemServiceClient } = await import('~~/gen/ts/services/settings/system.client');
128
+ return new SystemServiceClient(useGRPCTransport());
129
+ }
130
+
131
+ // Factory for stats.stats client.
132
+ export async function getStatsStatsClient() {
133
+ const { StatsServiceClient } = await import('~~/gen/ts/services/stats/stats.client');
134
+ return new StatsServiceClient(useGRPCTransport());
135
+ }
136
+
137
+ // Factory for sync.sync client.
138
+ export async function getSyncSyncClient() {
139
+ const { SyncServiceClient } = await import('~~/gen/ts/services/sync/sync.client');
140
+ return new SyncServiceClient(useGRPCTransport());
141
+ }
142
+
143
+ // Factory for vehicles.vehicles client.
144
+ export async function getVehiclesVehiclesClient() {
145
+ const { VehiclesServiceClient } = await import('~~/gen/ts/services/vehicles/vehicles.client');
146
+ return new VehiclesServiceClient(useGRPCTransport());
147
+ }
148
+
149
+ // Factory for wiki.collab client.
150
+ export async function getWikiCollabClient() {
151
+ const { CollabServiceClient } = await import('~~/gen/ts/services/wiki/collab.client');
152
+ return new CollabServiceClient(useGRPCTransport());
153
+ }
154
+
155
+ // Factory for wiki.wiki client.
156
+ export async function getWikiWikiClient() {
157
+ const { WikiServiceClient } = await import('~~/gen/ts/services/wiki/wiki.client');
158
+ return new WikiServiceClient(useGRPCTransport());
159
+ }
@@ -0,0 +1,91 @@
1
+ // @generated by protobuf-ts 2.11.1 with parameter force_server_none,long_type_number,optimize_speed,ts_nocheck
2
+ // @generated from protobuf file "codegen/dbscanner/dbscanner.proto" (package "codegen.dbscanner", syntax proto3)
3
+ // tslint:disable
4
+ // @ts-nocheck
5
+ import type { BinaryWriteOptions } from "@protobuf-ts/runtime";
6
+ import type { IBinaryWriter } from "@protobuf-ts/runtime";
7
+ import { WireType } from "@protobuf-ts/runtime";
8
+ import type { BinaryReadOptions } from "@protobuf-ts/runtime";
9
+ import type { IBinaryReader } from "@protobuf-ts/runtime";
10
+ import { UnknownFieldHandler } from "@protobuf-ts/runtime";
11
+ import type { PartialMessage } from "@protobuf-ts/runtime";
12
+ import { reflectionMergePartial } from "@protobuf-ts/runtime";
13
+ import { MessageType } from "@protobuf-ts/runtime";
14
+ /**
15
+ * @generated from protobuf message codegen.dbscanner.MessageOptions
16
+ */
17
+ export interface MessageOptions {
18
+ /**
19
+ * @generated from protobuf field: bool enabled = 1
20
+ */
21
+ enabled: boolean;
22
+ /**
23
+ * @generated from protobuf field: optional bool not_json = 2
24
+ */
25
+ notJson?: boolean;
26
+ /**
27
+ * @generated from protobuf field: optional bool partial = 3
28
+ */
29
+ partial?: boolean;
30
+ }
31
+ // @generated message type with reflection information, may provide speed optimized methods
32
+ class MessageOptions$Type extends MessageType<MessageOptions> {
33
+ constructor() {
34
+ super("codegen.dbscanner.MessageOptions", [
35
+ { no: 1, name: "enabled", kind: "scalar", T: 8 /*ScalarType.BOOL*/ },
36
+ { no: 2, name: "not_json", kind: "scalar", opt: true, T: 8 /*ScalarType.BOOL*/ },
37
+ { no: 3, name: "partial", kind: "scalar", opt: true, T: 8 /*ScalarType.BOOL*/ }
38
+ ]);
39
+ }
40
+ create(value?: PartialMessage<MessageOptions>): MessageOptions {
41
+ const message = globalThis.Object.create((this.messagePrototype!));
42
+ message.enabled = false;
43
+ if (value !== undefined)
44
+ reflectionMergePartial<MessageOptions>(this, message, value);
45
+ return message;
46
+ }
47
+ internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: MessageOptions): MessageOptions {
48
+ let message = target ?? this.create(), end = reader.pos + length;
49
+ while (reader.pos < end) {
50
+ let [fieldNo, wireType] = reader.tag();
51
+ switch (fieldNo) {
52
+ case /* bool enabled */ 1:
53
+ message.enabled = reader.bool();
54
+ break;
55
+ case /* optional bool not_json */ 2:
56
+ message.notJson = reader.bool();
57
+ break;
58
+ case /* optional bool partial */ 3:
59
+ message.partial = reader.bool();
60
+ break;
61
+ default:
62
+ let u = options.readUnknownField;
63
+ if (u === "throw")
64
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
65
+ let d = reader.skip(wireType);
66
+ if (u !== false)
67
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
68
+ }
69
+ }
70
+ return message;
71
+ }
72
+ internalBinaryWrite(message: MessageOptions, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
73
+ /* bool enabled = 1; */
74
+ if (message.enabled !== false)
75
+ writer.tag(1, WireType.Varint).bool(message.enabled);
76
+ /* optional bool not_json = 2; */
77
+ if (message.notJson !== undefined)
78
+ writer.tag(2, WireType.Varint).bool(message.notJson);
79
+ /* optional bool partial = 3; */
80
+ if (message.partial !== undefined)
81
+ writer.tag(3, WireType.Varint).bool(message.partial);
82
+ let u = options.writeUnknownFields;
83
+ if (u !== false)
84
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
85
+ return writer;
86
+ }
87
+ }
88
+ /**
89
+ * @generated MessageType for protobuf message codegen.dbscanner.MessageOptions
90
+ */
91
+ export const MessageOptions = new MessageOptions$Type();
@@ -0,0 +1,208 @@
1
+ // @generated by protobuf-ts 2.11.1 with parameter force_server_none,long_type_number,optimize_speed,ts_nocheck
2
+ // @generated from protobuf file "codegen/perms/perms.proto" (package "codegen.perms", syntax proto3)
3
+ // tslint:disable
4
+ // @ts-nocheck
5
+ import type { BinaryWriteOptions } from "@protobuf-ts/runtime";
6
+ import type { IBinaryWriter } from "@protobuf-ts/runtime";
7
+ import { WireType } from "@protobuf-ts/runtime";
8
+ import type { BinaryReadOptions } from "@protobuf-ts/runtime";
9
+ import type { IBinaryReader } from "@protobuf-ts/runtime";
10
+ import { UnknownFieldHandler } from "@protobuf-ts/runtime";
11
+ import type { PartialMessage } from "@protobuf-ts/runtime";
12
+ import { reflectionMergePartial } from "@protobuf-ts/runtime";
13
+ import { MessageType } from "@protobuf-ts/runtime";
14
+ import { AttributeType } from "../../resources/permissions/attributes";
15
+ /**
16
+ * @generated from protobuf message codegen.perms.FieldOptions
17
+ */
18
+ export interface FieldOptions {
19
+ /**
20
+ * @generated from protobuf field: bool enabled = 1
21
+ */
22
+ enabled: boolean;
23
+ /**
24
+ * @generated from protobuf field: optional string service = 2
25
+ */
26
+ service?: string;
27
+ /**
28
+ * @generated from protobuf field: optional string name = 3
29
+ */
30
+ name?: string;
31
+ /**
32
+ * @generated from protobuf field: int32 order = 4
33
+ */
34
+ order: number;
35
+ /**
36
+ * @generated from protobuf field: repeated codegen.perms.Attr attrs = 5
37
+ */
38
+ attrs: Attr[];
39
+ }
40
+ /**
41
+ * @generated from protobuf message codegen.perms.Attr
42
+ */
43
+ export interface Attr {
44
+ /**
45
+ * @generated from protobuf field: string key = 1
46
+ */
47
+ key: string;
48
+ /**
49
+ * @generated from protobuf field: string value = 2
50
+ */
51
+ value: string;
52
+ /**
53
+ * @generated from protobuf field: resources.permissions.AttributeType type = 3
54
+ */
55
+ type: AttributeType;
56
+ /**
57
+ * @generated from protobuf field: repeated string valid_string_list = 4
58
+ */
59
+ validStringList: string[];
60
+ }
61
+ // @generated message type with reflection information, may provide speed optimized methods
62
+ class FieldOptions$Type extends MessageType<FieldOptions> {
63
+ constructor() {
64
+ super("codegen.perms.FieldOptions", [
65
+ { no: 1, name: "enabled", kind: "scalar", T: 8 /*ScalarType.BOOL*/ },
66
+ { no: 2, name: "service", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
67
+ { no: 3, name: "name", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/ },
68
+ { no: 4, name: "order", kind: "scalar", T: 5 /*ScalarType.INT32*/ },
69
+ { no: 5, name: "attrs", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Attr }
70
+ ]);
71
+ }
72
+ create(value?: PartialMessage<FieldOptions>): FieldOptions {
73
+ const message = globalThis.Object.create((this.messagePrototype!));
74
+ message.enabled = false;
75
+ message.order = 0;
76
+ message.attrs = [];
77
+ if (value !== undefined)
78
+ reflectionMergePartial<FieldOptions>(this, message, value);
79
+ return message;
80
+ }
81
+ internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: FieldOptions): FieldOptions {
82
+ let message = target ?? this.create(), end = reader.pos + length;
83
+ while (reader.pos < end) {
84
+ let [fieldNo, wireType] = reader.tag();
85
+ switch (fieldNo) {
86
+ case /* bool enabled */ 1:
87
+ message.enabled = reader.bool();
88
+ break;
89
+ case /* optional string service */ 2:
90
+ message.service = reader.string();
91
+ break;
92
+ case /* optional string name */ 3:
93
+ message.name = reader.string();
94
+ break;
95
+ case /* int32 order */ 4:
96
+ message.order = reader.int32();
97
+ break;
98
+ case /* repeated codegen.perms.Attr attrs */ 5:
99
+ message.attrs.push(Attr.internalBinaryRead(reader, reader.uint32(), options));
100
+ break;
101
+ default:
102
+ let u = options.readUnknownField;
103
+ if (u === "throw")
104
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
105
+ let d = reader.skip(wireType);
106
+ if (u !== false)
107
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
108
+ }
109
+ }
110
+ return message;
111
+ }
112
+ internalBinaryWrite(message: FieldOptions, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
113
+ /* bool enabled = 1; */
114
+ if (message.enabled !== false)
115
+ writer.tag(1, WireType.Varint).bool(message.enabled);
116
+ /* optional string service = 2; */
117
+ if (message.service !== undefined)
118
+ writer.tag(2, WireType.LengthDelimited).string(message.service);
119
+ /* optional string name = 3; */
120
+ if (message.name !== undefined)
121
+ writer.tag(3, WireType.LengthDelimited).string(message.name);
122
+ /* int32 order = 4; */
123
+ if (message.order !== 0)
124
+ writer.tag(4, WireType.Varint).int32(message.order);
125
+ /* repeated codegen.perms.Attr attrs = 5; */
126
+ for (let i = 0; i < message.attrs.length; i++)
127
+ Attr.internalBinaryWrite(message.attrs[i], writer.tag(5, WireType.LengthDelimited).fork(), options).join();
128
+ let u = options.writeUnknownFields;
129
+ if (u !== false)
130
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
131
+ return writer;
132
+ }
133
+ }
134
+ /**
135
+ * @generated MessageType for protobuf message codegen.perms.FieldOptions
136
+ */
137
+ export const FieldOptions = new FieldOptions$Type();
138
+ // @generated message type with reflection information, may provide speed optimized methods
139
+ class Attr$Type extends MessageType<Attr> {
140
+ constructor() {
141
+ super("codegen.perms.Attr", [
142
+ { no: 1, name: "key", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
143
+ { no: 2, name: "value", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
144
+ { no: 3, name: "type", kind: "enum", T: () => ["resources.permissions.AttributeType", AttributeType, "ATTRIBUTE_TYPE_"] },
145
+ { no: 4, name: "valid_string_list", kind: "scalar", repeat: 2 /*RepeatType.UNPACKED*/, T: 9 /*ScalarType.STRING*/ }
146
+ ]);
147
+ }
148
+ create(value?: PartialMessage<Attr>): Attr {
149
+ const message = globalThis.Object.create((this.messagePrototype!));
150
+ message.key = "";
151
+ message.value = "";
152
+ message.type = 0;
153
+ message.validStringList = [];
154
+ if (value !== undefined)
155
+ reflectionMergePartial<Attr>(this, message, value);
156
+ return message;
157
+ }
158
+ internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: Attr): Attr {
159
+ let message = target ?? this.create(), end = reader.pos + length;
160
+ while (reader.pos < end) {
161
+ let [fieldNo, wireType] = reader.tag();
162
+ switch (fieldNo) {
163
+ case /* string key */ 1:
164
+ message.key = reader.string();
165
+ break;
166
+ case /* string value */ 2:
167
+ message.value = reader.string();
168
+ break;
169
+ case /* resources.permissions.AttributeType type */ 3:
170
+ message.type = reader.int32();
171
+ break;
172
+ case /* repeated string valid_string_list */ 4:
173
+ message.validStringList.push(reader.string());
174
+ break;
175
+ default:
176
+ let u = options.readUnknownField;
177
+ if (u === "throw")
178
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
179
+ let d = reader.skip(wireType);
180
+ if (u !== false)
181
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
182
+ }
183
+ }
184
+ return message;
185
+ }
186
+ internalBinaryWrite(message: Attr, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
187
+ /* string key = 1; */
188
+ if (message.key !== "")
189
+ writer.tag(1, WireType.LengthDelimited).string(message.key);
190
+ /* string value = 2; */
191
+ if (message.value !== "")
192
+ writer.tag(2, WireType.LengthDelimited).string(message.value);
193
+ /* resources.permissions.AttributeType type = 3; */
194
+ if (message.type !== 0)
195
+ writer.tag(3, WireType.Varint).int32(message.type);
196
+ /* repeated string valid_string_list = 4; */
197
+ for (let i = 0; i < message.validStringList.length; i++)
198
+ writer.tag(4, WireType.LengthDelimited).string(message.validStringList[i]);
199
+ let u = options.writeUnknownFields;
200
+ if (u !== false)
201
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
202
+ return writer;
203
+ }
204
+ }
205
+ /**
206
+ * @generated MessageType for protobuf message codegen.perms.Attr
207
+ */
208
+ export const Attr = new Attr$Type();