naijarea-ts 1.0.2
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/account.d.ts +229 -0
- package/dist/account.js +2211 -0
- package/dist/admin.d.ts +49 -0
- package/dist/admin.js +164 -0
- package/dist/auth.d.ts +242 -0
- package/dist/auth.js +1750 -0
- package/dist/chat.d.ts +49 -0
- package/dist/chat.js +163 -0
- package/dist/common.d.ts +60 -0
- package/dist/common.js +543 -0
- package/dist/google/api/annotations.d.ts +1 -0
- package/dist/google/api/annotations.js +10 -0
- package/dist/google/api/field_behavior.d.ts +76 -0
- package/dist/google/api/field_behavior.js +146 -0
- package/dist/google/api/http.d.ts +379 -0
- package/dist/google/api/http.js +360 -0
- package/dist/google/api/httpbody.d.ts +78 -0
- package/dist/google/api/httpbody.js +127 -0
- package/dist/google/protobuf/any.d.ts +144 -0
- package/dist/google/protobuf/any.js +108 -0
- package/dist/google/protobuf/descriptor.d.ts +1338 -0
- package/dist/google/protobuf/descriptor.js +5427 -0
- package/dist/index.d.ts +11 -0
- package/dist/index.js +190 -0
- package/dist/lookup.d.ts +876 -0
- package/dist/lookup.js +6841 -0
- package/dist/posts.d.ts +374 -0
- package/dist/posts.js +2784 -0
- package/package.json +43 -0
package/dist/posts.js
ADDED
|
@@ -0,0 +1,2784 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
3
|
+
// versions:
|
|
4
|
+
// protoc-gen-ts_proto v2.10.0
|
|
5
|
+
// protoc v6.33.2
|
|
6
|
+
// source: posts.proto
|
|
7
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
+
exports.PostServiceDefinition = exports.PostUserStatus = exports.PostEngagement = exports.Creator = exports.Post = exports.UnapproveEyewitnessReportRequest = exports.ApproveEyewitnessReportResponse = exports.ApproveEyewitnessReportRequest = exports.UnsignPetitionRequest = exports.SignPetitionResponse = exports.SignPetitionRequest = exports.SearchPostsRequest = exports.UnrepostRequest = exports.RepostResponse = exports.RepostRequest = exports.UnbookmarkPostRequest = exports.BookmarkPostResponse = exports.BookmarkPostRequest = exports.UnlikePostRequest = exports.LikePostResponse = exports.LikePostRequest = exports.UpdatePostResponse = exports.UpdatePostRequest = exports.ListPostsResponse = exports.ListPostsRequest = exports.GetPostResponse = exports.CreatePostResponse = exports.CreatePostRequest = exports.protobufPackage = void 0;
|
|
9
|
+
/* eslint-disable */
|
|
10
|
+
const wire_1 = require("@bufbuild/protobuf/wire");
|
|
11
|
+
const common_1 = require("./common");
|
|
12
|
+
exports.protobufPackage = "pb";
|
|
13
|
+
function createBaseCreatePostRequest() {
|
|
14
|
+
return { postType: "", title: "", context: "", media: [], targetSignatures: 0, category: "" };
|
|
15
|
+
}
|
|
16
|
+
exports.CreatePostRequest = {
|
|
17
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
18
|
+
if (message.postType !== "") {
|
|
19
|
+
writer.uint32(10).string(message.postType);
|
|
20
|
+
}
|
|
21
|
+
if (message.title !== "") {
|
|
22
|
+
writer.uint32(18).string(message.title);
|
|
23
|
+
}
|
|
24
|
+
if (message.context !== "") {
|
|
25
|
+
writer.uint32(26).string(message.context);
|
|
26
|
+
}
|
|
27
|
+
for (const v of message.media) {
|
|
28
|
+
writer.uint32(34).string(v);
|
|
29
|
+
}
|
|
30
|
+
if (message.targetSignatures !== 0) {
|
|
31
|
+
writer.uint32(40).int32(message.targetSignatures);
|
|
32
|
+
}
|
|
33
|
+
if (message.category !== "") {
|
|
34
|
+
writer.uint32(50).string(message.category);
|
|
35
|
+
}
|
|
36
|
+
return writer;
|
|
37
|
+
},
|
|
38
|
+
decode(input, length) {
|
|
39
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
40
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
41
|
+
const message = createBaseCreatePostRequest();
|
|
42
|
+
while (reader.pos < end) {
|
|
43
|
+
const tag = reader.uint32();
|
|
44
|
+
switch (tag >>> 3) {
|
|
45
|
+
case 1: {
|
|
46
|
+
if (tag !== 10) {
|
|
47
|
+
break;
|
|
48
|
+
}
|
|
49
|
+
message.postType = reader.string();
|
|
50
|
+
continue;
|
|
51
|
+
}
|
|
52
|
+
case 2: {
|
|
53
|
+
if (tag !== 18) {
|
|
54
|
+
break;
|
|
55
|
+
}
|
|
56
|
+
message.title = reader.string();
|
|
57
|
+
continue;
|
|
58
|
+
}
|
|
59
|
+
case 3: {
|
|
60
|
+
if (tag !== 26) {
|
|
61
|
+
break;
|
|
62
|
+
}
|
|
63
|
+
message.context = reader.string();
|
|
64
|
+
continue;
|
|
65
|
+
}
|
|
66
|
+
case 4: {
|
|
67
|
+
if (tag !== 34) {
|
|
68
|
+
break;
|
|
69
|
+
}
|
|
70
|
+
message.media.push(reader.string());
|
|
71
|
+
continue;
|
|
72
|
+
}
|
|
73
|
+
case 5: {
|
|
74
|
+
if (tag !== 40) {
|
|
75
|
+
break;
|
|
76
|
+
}
|
|
77
|
+
message.targetSignatures = reader.int32();
|
|
78
|
+
continue;
|
|
79
|
+
}
|
|
80
|
+
case 6: {
|
|
81
|
+
if (tag !== 50) {
|
|
82
|
+
break;
|
|
83
|
+
}
|
|
84
|
+
message.category = reader.string();
|
|
85
|
+
continue;
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
89
|
+
break;
|
|
90
|
+
}
|
|
91
|
+
reader.skip(tag & 7);
|
|
92
|
+
}
|
|
93
|
+
return message;
|
|
94
|
+
},
|
|
95
|
+
fromJSON(object) {
|
|
96
|
+
return {
|
|
97
|
+
postType: isSet(object.postType) ? globalThis.String(object.postType) : "",
|
|
98
|
+
title: isSet(object.title) ? globalThis.String(object.title) : "",
|
|
99
|
+
context: isSet(object.context) ? globalThis.String(object.context) : "",
|
|
100
|
+
media: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.media) ? object.media.map((e) => globalThis.String(e)) : [],
|
|
101
|
+
targetSignatures: isSet(object.targetSignatures) ? globalThis.Number(object.targetSignatures) : 0,
|
|
102
|
+
category: isSet(object.category) ? globalThis.String(object.category) : "",
|
|
103
|
+
};
|
|
104
|
+
},
|
|
105
|
+
toJSON(message) {
|
|
106
|
+
var _a;
|
|
107
|
+
const obj = {};
|
|
108
|
+
if (message.postType !== "") {
|
|
109
|
+
obj.postType = message.postType;
|
|
110
|
+
}
|
|
111
|
+
if (message.title !== "") {
|
|
112
|
+
obj.title = message.title;
|
|
113
|
+
}
|
|
114
|
+
if (message.context !== "") {
|
|
115
|
+
obj.context = message.context;
|
|
116
|
+
}
|
|
117
|
+
if ((_a = message.media) === null || _a === void 0 ? void 0 : _a.length) {
|
|
118
|
+
obj.media = message.media;
|
|
119
|
+
}
|
|
120
|
+
if (message.targetSignatures !== 0) {
|
|
121
|
+
obj.targetSignatures = Math.round(message.targetSignatures);
|
|
122
|
+
}
|
|
123
|
+
if (message.category !== "") {
|
|
124
|
+
obj.category = message.category;
|
|
125
|
+
}
|
|
126
|
+
return obj;
|
|
127
|
+
},
|
|
128
|
+
create(base) {
|
|
129
|
+
return exports.CreatePostRequest.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
130
|
+
},
|
|
131
|
+
fromPartial(object) {
|
|
132
|
+
var _a, _b, _c, _d, _e, _f;
|
|
133
|
+
const message = createBaseCreatePostRequest();
|
|
134
|
+
message.postType = (_a = object.postType) !== null && _a !== void 0 ? _a : "";
|
|
135
|
+
message.title = (_b = object.title) !== null && _b !== void 0 ? _b : "";
|
|
136
|
+
message.context = (_c = object.context) !== null && _c !== void 0 ? _c : "";
|
|
137
|
+
message.media = ((_d = object.media) === null || _d === void 0 ? void 0 : _d.map((e) => e)) || [];
|
|
138
|
+
message.targetSignatures = (_e = object.targetSignatures) !== null && _e !== void 0 ? _e : 0;
|
|
139
|
+
message.category = (_f = object.category) !== null && _f !== void 0 ? _f : "";
|
|
140
|
+
return message;
|
|
141
|
+
},
|
|
142
|
+
};
|
|
143
|
+
function createBaseCreatePostResponse() {
|
|
144
|
+
return { post: undefined };
|
|
145
|
+
}
|
|
146
|
+
exports.CreatePostResponse = {
|
|
147
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
148
|
+
if (message.post !== undefined) {
|
|
149
|
+
exports.Post.encode(message.post, writer.uint32(10).fork()).join();
|
|
150
|
+
}
|
|
151
|
+
return writer;
|
|
152
|
+
},
|
|
153
|
+
decode(input, length) {
|
|
154
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
155
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
156
|
+
const message = createBaseCreatePostResponse();
|
|
157
|
+
while (reader.pos < end) {
|
|
158
|
+
const tag = reader.uint32();
|
|
159
|
+
switch (tag >>> 3) {
|
|
160
|
+
case 1: {
|
|
161
|
+
if (tag !== 10) {
|
|
162
|
+
break;
|
|
163
|
+
}
|
|
164
|
+
message.post = exports.Post.decode(reader, reader.uint32());
|
|
165
|
+
continue;
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
169
|
+
break;
|
|
170
|
+
}
|
|
171
|
+
reader.skip(tag & 7);
|
|
172
|
+
}
|
|
173
|
+
return message;
|
|
174
|
+
},
|
|
175
|
+
fromJSON(object) {
|
|
176
|
+
return { post: isSet(object.post) ? exports.Post.fromJSON(object.post) : undefined };
|
|
177
|
+
},
|
|
178
|
+
toJSON(message) {
|
|
179
|
+
const obj = {};
|
|
180
|
+
if (message.post !== undefined) {
|
|
181
|
+
obj.post = exports.Post.toJSON(message.post);
|
|
182
|
+
}
|
|
183
|
+
return obj;
|
|
184
|
+
},
|
|
185
|
+
create(base) {
|
|
186
|
+
return exports.CreatePostResponse.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
187
|
+
},
|
|
188
|
+
fromPartial(object) {
|
|
189
|
+
const message = createBaseCreatePostResponse();
|
|
190
|
+
message.post = (object.post !== undefined && object.post !== null) ? exports.Post.fromPartial(object.post) : undefined;
|
|
191
|
+
return message;
|
|
192
|
+
},
|
|
193
|
+
};
|
|
194
|
+
function createBaseGetPostResponse() {
|
|
195
|
+
return { post: undefined };
|
|
196
|
+
}
|
|
197
|
+
exports.GetPostResponse = {
|
|
198
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
199
|
+
if (message.post !== undefined) {
|
|
200
|
+
exports.Post.encode(message.post, writer.uint32(10).fork()).join();
|
|
201
|
+
}
|
|
202
|
+
return writer;
|
|
203
|
+
},
|
|
204
|
+
decode(input, length) {
|
|
205
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
206
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
207
|
+
const message = createBaseGetPostResponse();
|
|
208
|
+
while (reader.pos < end) {
|
|
209
|
+
const tag = reader.uint32();
|
|
210
|
+
switch (tag >>> 3) {
|
|
211
|
+
case 1: {
|
|
212
|
+
if (tag !== 10) {
|
|
213
|
+
break;
|
|
214
|
+
}
|
|
215
|
+
message.post = exports.Post.decode(reader, reader.uint32());
|
|
216
|
+
continue;
|
|
217
|
+
}
|
|
218
|
+
}
|
|
219
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
220
|
+
break;
|
|
221
|
+
}
|
|
222
|
+
reader.skip(tag & 7);
|
|
223
|
+
}
|
|
224
|
+
return message;
|
|
225
|
+
},
|
|
226
|
+
fromJSON(object) {
|
|
227
|
+
return { post: isSet(object.post) ? exports.Post.fromJSON(object.post) : undefined };
|
|
228
|
+
},
|
|
229
|
+
toJSON(message) {
|
|
230
|
+
const obj = {};
|
|
231
|
+
if (message.post !== undefined) {
|
|
232
|
+
obj.post = exports.Post.toJSON(message.post);
|
|
233
|
+
}
|
|
234
|
+
return obj;
|
|
235
|
+
},
|
|
236
|
+
create(base) {
|
|
237
|
+
return exports.GetPostResponse.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
238
|
+
},
|
|
239
|
+
fromPartial(object) {
|
|
240
|
+
const message = createBaseGetPostResponse();
|
|
241
|
+
message.post = (object.post !== undefined && object.post !== null) ? exports.Post.fromPartial(object.post) : undefined;
|
|
242
|
+
return message;
|
|
243
|
+
},
|
|
244
|
+
};
|
|
245
|
+
function createBaseListPostsRequest() {
|
|
246
|
+
return { base: undefined, postType: "" };
|
|
247
|
+
}
|
|
248
|
+
exports.ListPostsRequest = {
|
|
249
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
250
|
+
if (message.base !== undefined) {
|
|
251
|
+
common_1.BaseListRequest.encode(message.base, writer.uint32(10).fork()).join();
|
|
252
|
+
}
|
|
253
|
+
if (message.postType !== "") {
|
|
254
|
+
writer.uint32(18).string(message.postType);
|
|
255
|
+
}
|
|
256
|
+
return writer;
|
|
257
|
+
},
|
|
258
|
+
decode(input, length) {
|
|
259
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
260
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
261
|
+
const message = createBaseListPostsRequest();
|
|
262
|
+
while (reader.pos < end) {
|
|
263
|
+
const tag = reader.uint32();
|
|
264
|
+
switch (tag >>> 3) {
|
|
265
|
+
case 1: {
|
|
266
|
+
if (tag !== 10) {
|
|
267
|
+
break;
|
|
268
|
+
}
|
|
269
|
+
message.base = common_1.BaseListRequest.decode(reader, reader.uint32());
|
|
270
|
+
continue;
|
|
271
|
+
}
|
|
272
|
+
case 2: {
|
|
273
|
+
if (tag !== 18) {
|
|
274
|
+
break;
|
|
275
|
+
}
|
|
276
|
+
message.postType = reader.string();
|
|
277
|
+
continue;
|
|
278
|
+
}
|
|
279
|
+
}
|
|
280
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
281
|
+
break;
|
|
282
|
+
}
|
|
283
|
+
reader.skip(tag & 7);
|
|
284
|
+
}
|
|
285
|
+
return message;
|
|
286
|
+
},
|
|
287
|
+
fromJSON(object) {
|
|
288
|
+
return {
|
|
289
|
+
base: isSet(object.base) ? common_1.BaseListRequest.fromJSON(object.base) : undefined,
|
|
290
|
+
postType: isSet(object.postType) ? globalThis.String(object.postType) : "",
|
|
291
|
+
};
|
|
292
|
+
},
|
|
293
|
+
toJSON(message) {
|
|
294
|
+
const obj = {};
|
|
295
|
+
if (message.base !== undefined) {
|
|
296
|
+
obj.base = common_1.BaseListRequest.toJSON(message.base);
|
|
297
|
+
}
|
|
298
|
+
if (message.postType !== "") {
|
|
299
|
+
obj.postType = message.postType;
|
|
300
|
+
}
|
|
301
|
+
return obj;
|
|
302
|
+
},
|
|
303
|
+
create(base) {
|
|
304
|
+
return exports.ListPostsRequest.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
305
|
+
},
|
|
306
|
+
fromPartial(object) {
|
|
307
|
+
var _a;
|
|
308
|
+
const message = createBaseListPostsRequest();
|
|
309
|
+
message.base = (object.base !== undefined && object.base !== null)
|
|
310
|
+
? common_1.BaseListRequest.fromPartial(object.base)
|
|
311
|
+
: undefined;
|
|
312
|
+
message.postType = (_a = object.postType) !== null && _a !== void 0 ? _a : "";
|
|
313
|
+
return message;
|
|
314
|
+
},
|
|
315
|
+
};
|
|
316
|
+
function createBaseListPostsResponse() {
|
|
317
|
+
return { posts: [], metadata: undefined };
|
|
318
|
+
}
|
|
319
|
+
exports.ListPostsResponse = {
|
|
320
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
321
|
+
for (const v of message.posts) {
|
|
322
|
+
exports.Post.encode(v, writer.uint32(10).fork()).join();
|
|
323
|
+
}
|
|
324
|
+
if (message.metadata !== undefined) {
|
|
325
|
+
common_1.Metadata.encode(message.metadata, writer.uint32(18).fork()).join();
|
|
326
|
+
}
|
|
327
|
+
return writer;
|
|
328
|
+
},
|
|
329
|
+
decode(input, length) {
|
|
330
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
331
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
332
|
+
const message = createBaseListPostsResponse();
|
|
333
|
+
while (reader.pos < end) {
|
|
334
|
+
const tag = reader.uint32();
|
|
335
|
+
switch (tag >>> 3) {
|
|
336
|
+
case 1: {
|
|
337
|
+
if (tag !== 10) {
|
|
338
|
+
break;
|
|
339
|
+
}
|
|
340
|
+
message.posts.push(exports.Post.decode(reader, reader.uint32()));
|
|
341
|
+
continue;
|
|
342
|
+
}
|
|
343
|
+
case 2: {
|
|
344
|
+
if (tag !== 18) {
|
|
345
|
+
break;
|
|
346
|
+
}
|
|
347
|
+
message.metadata = common_1.Metadata.decode(reader, reader.uint32());
|
|
348
|
+
continue;
|
|
349
|
+
}
|
|
350
|
+
}
|
|
351
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
352
|
+
break;
|
|
353
|
+
}
|
|
354
|
+
reader.skip(tag & 7);
|
|
355
|
+
}
|
|
356
|
+
return message;
|
|
357
|
+
},
|
|
358
|
+
fromJSON(object) {
|
|
359
|
+
return {
|
|
360
|
+
posts: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.posts) ? object.posts.map((e) => exports.Post.fromJSON(e)) : [],
|
|
361
|
+
metadata: isSet(object.metadata) ? common_1.Metadata.fromJSON(object.metadata) : undefined,
|
|
362
|
+
};
|
|
363
|
+
},
|
|
364
|
+
toJSON(message) {
|
|
365
|
+
var _a;
|
|
366
|
+
const obj = {};
|
|
367
|
+
if ((_a = message.posts) === null || _a === void 0 ? void 0 : _a.length) {
|
|
368
|
+
obj.posts = message.posts.map((e) => exports.Post.toJSON(e));
|
|
369
|
+
}
|
|
370
|
+
if (message.metadata !== undefined) {
|
|
371
|
+
obj.metadata = common_1.Metadata.toJSON(message.metadata);
|
|
372
|
+
}
|
|
373
|
+
return obj;
|
|
374
|
+
},
|
|
375
|
+
create(base) {
|
|
376
|
+
return exports.ListPostsResponse.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
377
|
+
},
|
|
378
|
+
fromPartial(object) {
|
|
379
|
+
var _a;
|
|
380
|
+
const message = createBaseListPostsResponse();
|
|
381
|
+
message.posts = ((_a = object.posts) === null || _a === void 0 ? void 0 : _a.map((e) => exports.Post.fromPartial(e))) || [];
|
|
382
|
+
message.metadata = (object.metadata !== undefined && object.metadata !== null)
|
|
383
|
+
? common_1.Metadata.fromPartial(object.metadata)
|
|
384
|
+
: undefined;
|
|
385
|
+
return message;
|
|
386
|
+
},
|
|
387
|
+
};
|
|
388
|
+
function createBaseUpdatePostRequest() {
|
|
389
|
+
return { id: "", title: "", context: "", media: [], status: "" };
|
|
390
|
+
}
|
|
391
|
+
exports.UpdatePostRequest = {
|
|
392
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
393
|
+
if (message.id !== "") {
|
|
394
|
+
writer.uint32(10).string(message.id);
|
|
395
|
+
}
|
|
396
|
+
if (message.title !== "") {
|
|
397
|
+
writer.uint32(18).string(message.title);
|
|
398
|
+
}
|
|
399
|
+
if (message.context !== "") {
|
|
400
|
+
writer.uint32(26).string(message.context);
|
|
401
|
+
}
|
|
402
|
+
for (const v of message.media) {
|
|
403
|
+
writer.uint32(34).string(v);
|
|
404
|
+
}
|
|
405
|
+
if (message.status !== "") {
|
|
406
|
+
writer.uint32(42).string(message.status);
|
|
407
|
+
}
|
|
408
|
+
return writer;
|
|
409
|
+
},
|
|
410
|
+
decode(input, length) {
|
|
411
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
412
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
413
|
+
const message = createBaseUpdatePostRequest();
|
|
414
|
+
while (reader.pos < end) {
|
|
415
|
+
const tag = reader.uint32();
|
|
416
|
+
switch (tag >>> 3) {
|
|
417
|
+
case 1: {
|
|
418
|
+
if (tag !== 10) {
|
|
419
|
+
break;
|
|
420
|
+
}
|
|
421
|
+
message.id = reader.string();
|
|
422
|
+
continue;
|
|
423
|
+
}
|
|
424
|
+
case 2: {
|
|
425
|
+
if (tag !== 18) {
|
|
426
|
+
break;
|
|
427
|
+
}
|
|
428
|
+
message.title = reader.string();
|
|
429
|
+
continue;
|
|
430
|
+
}
|
|
431
|
+
case 3: {
|
|
432
|
+
if (tag !== 26) {
|
|
433
|
+
break;
|
|
434
|
+
}
|
|
435
|
+
message.context = reader.string();
|
|
436
|
+
continue;
|
|
437
|
+
}
|
|
438
|
+
case 4: {
|
|
439
|
+
if (tag !== 34) {
|
|
440
|
+
break;
|
|
441
|
+
}
|
|
442
|
+
message.media.push(reader.string());
|
|
443
|
+
continue;
|
|
444
|
+
}
|
|
445
|
+
case 5: {
|
|
446
|
+
if (tag !== 42) {
|
|
447
|
+
break;
|
|
448
|
+
}
|
|
449
|
+
message.status = reader.string();
|
|
450
|
+
continue;
|
|
451
|
+
}
|
|
452
|
+
}
|
|
453
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
454
|
+
break;
|
|
455
|
+
}
|
|
456
|
+
reader.skip(tag & 7);
|
|
457
|
+
}
|
|
458
|
+
return message;
|
|
459
|
+
},
|
|
460
|
+
fromJSON(object) {
|
|
461
|
+
return {
|
|
462
|
+
id: isSet(object.id) ? globalThis.String(object.id) : "",
|
|
463
|
+
title: isSet(object.title) ? globalThis.String(object.title) : "",
|
|
464
|
+
context: isSet(object.context) ? globalThis.String(object.context) : "",
|
|
465
|
+
media: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.media) ? object.media.map((e) => globalThis.String(e)) : [],
|
|
466
|
+
status: isSet(object.status) ? globalThis.String(object.status) : "",
|
|
467
|
+
};
|
|
468
|
+
},
|
|
469
|
+
toJSON(message) {
|
|
470
|
+
var _a;
|
|
471
|
+
const obj = {};
|
|
472
|
+
if (message.id !== "") {
|
|
473
|
+
obj.id = message.id;
|
|
474
|
+
}
|
|
475
|
+
if (message.title !== "") {
|
|
476
|
+
obj.title = message.title;
|
|
477
|
+
}
|
|
478
|
+
if (message.context !== "") {
|
|
479
|
+
obj.context = message.context;
|
|
480
|
+
}
|
|
481
|
+
if ((_a = message.media) === null || _a === void 0 ? void 0 : _a.length) {
|
|
482
|
+
obj.media = message.media;
|
|
483
|
+
}
|
|
484
|
+
if (message.status !== "") {
|
|
485
|
+
obj.status = message.status;
|
|
486
|
+
}
|
|
487
|
+
return obj;
|
|
488
|
+
},
|
|
489
|
+
create(base) {
|
|
490
|
+
return exports.UpdatePostRequest.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
491
|
+
},
|
|
492
|
+
fromPartial(object) {
|
|
493
|
+
var _a, _b, _c, _d, _e;
|
|
494
|
+
const message = createBaseUpdatePostRequest();
|
|
495
|
+
message.id = (_a = object.id) !== null && _a !== void 0 ? _a : "";
|
|
496
|
+
message.title = (_b = object.title) !== null && _b !== void 0 ? _b : "";
|
|
497
|
+
message.context = (_c = object.context) !== null && _c !== void 0 ? _c : "";
|
|
498
|
+
message.media = ((_d = object.media) === null || _d === void 0 ? void 0 : _d.map((e) => e)) || [];
|
|
499
|
+
message.status = (_e = object.status) !== null && _e !== void 0 ? _e : "";
|
|
500
|
+
return message;
|
|
501
|
+
},
|
|
502
|
+
};
|
|
503
|
+
function createBaseUpdatePostResponse() {
|
|
504
|
+
return { post: undefined };
|
|
505
|
+
}
|
|
506
|
+
exports.UpdatePostResponse = {
|
|
507
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
508
|
+
if (message.post !== undefined) {
|
|
509
|
+
exports.Post.encode(message.post, writer.uint32(10).fork()).join();
|
|
510
|
+
}
|
|
511
|
+
return writer;
|
|
512
|
+
},
|
|
513
|
+
decode(input, length) {
|
|
514
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
515
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
516
|
+
const message = createBaseUpdatePostResponse();
|
|
517
|
+
while (reader.pos < end) {
|
|
518
|
+
const tag = reader.uint32();
|
|
519
|
+
switch (tag >>> 3) {
|
|
520
|
+
case 1: {
|
|
521
|
+
if (tag !== 10) {
|
|
522
|
+
break;
|
|
523
|
+
}
|
|
524
|
+
message.post = exports.Post.decode(reader, reader.uint32());
|
|
525
|
+
continue;
|
|
526
|
+
}
|
|
527
|
+
}
|
|
528
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
529
|
+
break;
|
|
530
|
+
}
|
|
531
|
+
reader.skip(tag & 7);
|
|
532
|
+
}
|
|
533
|
+
return message;
|
|
534
|
+
},
|
|
535
|
+
fromJSON(object) {
|
|
536
|
+
return { post: isSet(object.post) ? exports.Post.fromJSON(object.post) : undefined };
|
|
537
|
+
},
|
|
538
|
+
toJSON(message) {
|
|
539
|
+
const obj = {};
|
|
540
|
+
if (message.post !== undefined) {
|
|
541
|
+
obj.post = exports.Post.toJSON(message.post);
|
|
542
|
+
}
|
|
543
|
+
return obj;
|
|
544
|
+
},
|
|
545
|
+
create(base) {
|
|
546
|
+
return exports.UpdatePostResponse.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
547
|
+
},
|
|
548
|
+
fromPartial(object) {
|
|
549
|
+
const message = createBaseUpdatePostResponse();
|
|
550
|
+
message.post = (object.post !== undefined && object.post !== null) ? exports.Post.fromPartial(object.post) : undefined;
|
|
551
|
+
return message;
|
|
552
|
+
},
|
|
553
|
+
};
|
|
554
|
+
function createBaseLikePostRequest() {
|
|
555
|
+
return { postId: "" };
|
|
556
|
+
}
|
|
557
|
+
exports.LikePostRequest = {
|
|
558
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
559
|
+
if (message.postId !== "") {
|
|
560
|
+
writer.uint32(10).string(message.postId);
|
|
561
|
+
}
|
|
562
|
+
return writer;
|
|
563
|
+
},
|
|
564
|
+
decode(input, length) {
|
|
565
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
566
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
567
|
+
const message = createBaseLikePostRequest();
|
|
568
|
+
while (reader.pos < end) {
|
|
569
|
+
const tag = reader.uint32();
|
|
570
|
+
switch (tag >>> 3) {
|
|
571
|
+
case 1: {
|
|
572
|
+
if (tag !== 10) {
|
|
573
|
+
break;
|
|
574
|
+
}
|
|
575
|
+
message.postId = reader.string();
|
|
576
|
+
continue;
|
|
577
|
+
}
|
|
578
|
+
}
|
|
579
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
580
|
+
break;
|
|
581
|
+
}
|
|
582
|
+
reader.skip(tag & 7);
|
|
583
|
+
}
|
|
584
|
+
return message;
|
|
585
|
+
},
|
|
586
|
+
fromJSON(object) {
|
|
587
|
+
return { postId: isSet(object.postId) ? globalThis.String(object.postId) : "" };
|
|
588
|
+
},
|
|
589
|
+
toJSON(message) {
|
|
590
|
+
const obj = {};
|
|
591
|
+
if (message.postId !== "") {
|
|
592
|
+
obj.postId = message.postId;
|
|
593
|
+
}
|
|
594
|
+
return obj;
|
|
595
|
+
},
|
|
596
|
+
create(base) {
|
|
597
|
+
return exports.LikePostRequest.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
598
|
+
},
|
|
599
|
+
fromPartial(object) {
|
|
600
|
+
var _a;
|
|
601
|
+
const message = createBaseLikePostRequest();
|
|
602
|
+
message.postId = (_a = object.postId) !== null && _a !== void 0 ? _a : "";
|
|
603
|
+
return message;
|
|
604
|
+
},
|
|
605
|
+
};
|
|
606
|
+
function createBaseLikePostResponse() {
|
|
607
|
+
return { liked: false, likesCount: 0 };
|
|
608
|
+
}
|
|
609
|
+
exports.LikePostResponse = {
|
|
610
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
611
|
+
if (message.liked !== false) {
|
|
612
|
+
writer.uint32(8).bool(message.liked);
|
|
613
|
+
}
|
|
614
|
+
if (message.likesCount !== 0) {
|
|
615
|
+
writer.uint32(16).int64(message.likesCount);
|
|
616
|
+
}
|
|
617
|
+
return writer;
|
|
618
|
+
},
|
|
619
|
+
decode(input, length) {
|
|
620
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
621
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
622
|
+
const message = createBaseLikePostResponse();
|
|
623
|
+
while (reader.pos < end) {
|
|
624
|
+
const tag = reader.uint32();
|
|
625
|
+
switch (tag >>> 3) {
|
|
626
|
+
case 1: {
|
|
627
|
+
if (tag !== 8) {
|
|
628
|
+
break;
|
|
629
|
+
}
|
|
630
|
+
message.liked = reader.bool();
|
|
631
|
+
continue;
|
|
632
|
+
}
|
|
633
|
+
case 2: {
|
|
634
|
+
if (tag !== 16) {
|
|
635
|
+
break;
|
|
636
|
+
}
|
|
637
|
+
message.likesCount = longToNumber(reader.int64());
|
|
638
|
+
continue;
|
|
639
|
+
}
|
|
640
|
+
}
|
|
641
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
642
|
+
break;
|
|
643
|
+
}
|
|
644
|
+
reader.skip(tag & 7);
|
|
645
|
+
}
|
|
646
|
+
return message;
|
|
647
|
+
},
|
|
648
|
+
fromJSON(object) {
|
|
649
|
+
return {
|
|
650
|
+
liked: isSet(object.liked) ? globalThis.Boolean(object.liked) : false,
|
|
651
|
+
likesCount: isSet(object.likesCount) ? globalThis.Number(object.likesCount) : 0,
|
|
652
|
+
};
|
|
653
|
+
},
|
|
654
|
+
toJSON(message) {
|
|
655
|
+
const obj = {};
|
|
656
|
+
if (message.liked !== false) {
|
|
657
|
+
obj.liked = message.liked;
|
|
658
|
+
}
|
|
659
|
+
if (message.likesCount !== 0) {
|
|
660
|
+
obj.likesCount = Math.round(message.likesCount);
|
|
661
|
+
}
|
|
662
|
+
return obj;
|
|
663
|
+
},
|
|
664
|
+
create(base) {
|
|
665
|
+
return exports.LikePostResponse.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
666
|
+
},
|
|
667
|
+
fromPartial(object) {
|
|
668
|
+
var _a, _b;
|
|
669
|
+
const message = createBaseLikePostResponse();
|
|
670
|
+
message.liked = (_a = object.liked) !== null && _a !== void 0 ? _a : false;
|
|
671
|
+
message.likesCount = (_b = object.likesCount) !== null && _b !== void 0 ? _b : 0;
|
|
672
|
+
return message;
|
|
673
|
+
},
|
|
674
|
+
};
|
|
675
|
+
function createBaseUnlikePostRequest() {
|
|
676
|
+
return { postId: "" };
|
|
677
|
+
}
|
|
678
|
+
exports.UnlikePostRequest = {
|
|
679
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
680
|
+
if (message.postId !== "") {
|
|
681
|
+
writer.uint32(10).string(message.postId);
|
|
682
|
+
}
|
|
683
|
+
return writer;
|
|
684
|
+
},
|
|
685
|
+
decode(input, length) {
|
|
686
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
687
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
688
|
+
const message = createBaseUnlikePostRequest();
|
|
689
|
+
while (reader.pos < end) {
|
|
690
|
+
const tag = reader.uint32();
|
|
691
|
+
switch (tag >>> 3) {
|
|
692
|
+
case 1: {
|
|
693
|
+
if (tag !== 10) {
|
|
694
|
+
break;
|
|
695
|
+
}
|
|
696
|
+
message.postId = reader.string();
|
|
697
|
+
continue;
|
|
698
|
+
}
|
|
699
|
+
}
|
|
700
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
701
|
+
break;
|
|
702
|
+
}
|
|
703
|
+
reader.skip(tag & 7);
|
|
704
|
+
}
|
|
705
|
+
return message;
|
|
706
|
+
},
|
|
707
|
+
fromJSON(object) {
|
|
708
|
+
return { postId: isSet(object.postId) ? globalThis.String(object.postId) : "" };
|
|
709
|
+
},
|
|
710
|
+
toJSON(message) {
|
|
711
|
+
const obj = {};
|
|
712
|
+
if (message.postId !== "") {
|
|
713
|
+
obj.postId = message.postId;
|
|
714
|
+
}
|
|
715
|
+
return obj;
|
|
716
|
+
},
|
|
717
|
+
create(base) {
|
|
718
|
+
return exports.UnlikePostRequest.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
719
|
+
},
|
|
720
|
+
fromPartial(object) {
|
|
721
|
+
var _a;
|
|
722
|
+
const message = createBaseUnlikePostRequest();
|
|
723
|
+
message.postId = (_a = object.postId) !== null && _a !== void 0 ? _a : "";
|
|
724
|
+
return message;
|
|
725
|
+
},
|
|
726
|
+
};
|
|
727
|
+
function createBaseBookmarkPostRequest() {
|
|
728
|
+
return { postId: "" };
|
|
729
|
+
}
|
|
730
|
+
exports.BookmarkPostRequest = {
|
|
731
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
732
|
+
if (message.postId !== "") {
|
|
733
|
+
writer.uint32(10).string(message.postId);
|
|
734
|
+
}
|
|
735
|
+
return writer;
|
|
736
|
+
},
|
|
737
|
+
decode(input, length) {
|
|
738
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
739
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
740
|
+
const message = createBaseBookmarkPostRequest();
|
|
741
|
+
while (reader.pos < end) {
|
|
742
|
+
const tag = reader.uint32();
|
|
743
|
+
switch (tag >>> 3) {
|
|
744
|
+
case 1: {
|
|
745
|
+
if (tag !== 10) {
|
|
746
|
+
break;
|
|
747
|
+
}
|
|
748
|
+
message.postId = reader.string();
|
|
749
|
+
continue;
|
|
750
|
+
}
|
|
751
|
+
}
|
|
752
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
753
|
+
break;
|
|
754
|
+
}
|
|
755
|
+
reader.skip(tag & 7);
|
|
756
|
+
}
|
|
757
|
+
return message;
|
|
758
|
+
},
|
|
759
|
+
fromJSON(object) {
|
|
760
|
+
return { postId: isSet(object.postId) ? globalThis.String(object.postId) : "" };
|
|
761
|
+
},
|
|
762
|
+
toJSON(message) {
|
|
763
|
+
const obj = {};
|
|
764
|
+
if (message.postId !== "") {
|
|
765
|
+
obj.postId = message.postId;
|
|
766
|
+
}
|
|
767
|
+
return obj;
|
|
768
|
+
},
|
|
769
|
+
create(base) {
|
|
770
|
+
return exports.BookmarkPostRequest.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
771
|
+
},
|
|
772
|
+
fromPartial(object) {
|
|
773
|
+
var _a;
|
|
774
|
+
const message = createBaseBookmarkPostRequest();
|
|
775
|
+
message.postId = (_a = object.postId) !== null && _a !== void 0 ? _a : "";
|
|
776
|
+
return message;
|
|
777
|
+
},
|
|
778
|
+
};
|
|
779
|
+
function createBaseBookmarkPostResponse() {
|
|
780
|
+
return { bookmarked: false, bookmarksCount: 0 };
|
|
781
|
+
}
|
|
782
|
+
exports.BookmarkPostResponse = {
|
|
783
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
784
|
+
if (message.bookmarked !== false) {
|
|
785
|
+
writer.uint32(8).bool(message.bookmarked);
|
|
786
|
+
}
|
|
787
|
+
if (message.bookmarksCount !== 0) {
|
|
788
|
+
writer.uint32(16).int64(message.bookmarksCount);
|
|
789
|
+
}
|
|
790
|
+
return writer;
|
|
791
|
+
},
|
|
792
|
+
decode(input, length) {
|
|
793
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
794
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
795
|
+
const message = createBaseBookmarkPostResponse();
|
|
796
|
+
while (reader.pos < end) {
|
|
797
|
+
const tag = reader.uint32();
|
|
798
|
+
switch (tag >>> 3) {
|
|
799
|
+
case 1: {
|
|
800
|
+
if (tag !== 8) {
|
|
801
|
+
break;
|
|
802
|
+
}
|
|
803
|
+
message.bookmarked = reader.bool();
|
|
804
|
+
continue;
|
|
805
|
+
}
|
|
806
|
+
case 2: {
|
|
807
|
+
if (tag !== 16) {
|
|
808
|
+
break;
|
|
809
|
+
}
|
|
810
|
+
message.bookmarksCount = longToNumber(reader.int64());
|
|
811
|
+
continue;
|
|
812
|
+
}
|
|
813
|
+
}
|
|
814
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
815
|
+
break;
|
|
816
|
+
}
|
|
817
|
+
reader.skip(tag & 7);
|
|
818
|
+
}
|
|
819
|
+
return message;
|
|
820
|
+
},
|
|
821
|
+
fromJSON(object) {
|
|
822
|
+
return {
|
|
823
|
+
bookmarked: isSet(object.bookmarked) ? globalThis.Boolean(object.bookmarked) : false,
|
|
824
|
+
bookmarksCount: isSet(object.bookmarksCount) ? globalThis.Number(object.bookmarksCount) : 0,
|
|
825
|
+
};
|
|
826
|
+
},
|
|
827
|
+
toJSON(message) {
|
|
828
|
+
const obj = {};
|
|
829
|
+
if (message.bookmarked !== false) {
|
|
830
|
+
obj.bookmarked = message.bookmarked;
|
|
831
|
+
}
|
|
832
|
+
if (message.bookmarksCount !== 0) {
|
|
833
|
+
obj.bookmarksCount = Math.round(message.bookmarksCount);
|
|
834
|
+
}
|
|
835
|
+
return obj;
|
|
836
|
+
},
|
|
837
|
+
create(base) {
|
|
838
|
+
return exports.BookmarkPostResponse.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
839
|
+
},
|
|
840
|
+
fromPartial(object) {
|
|
841
|
+
var _a, _b;
|
|
842
|
+
const message = createBaseBookmarkPostResponse();
|
|
843
|
+
message.bookmarked = (_a = object.bookmarked) !== null && _a !== void 0 ? _a : false;
|
|
844
|
+
message.bookmarksCount = (_b = object.bookmarksCount) !== null && _b !== void 0 ? _b : 0;
|
|
845
|
+
return message;
|
|
846
|
+
},
|
|
847
|
+
};
|
|
848
|
+
function createBaseUnbookmarkPostRequest() {
|
|
849
|
+
return { postId: "" };
|
|
850
|
+
}
|
|
851
|
+
exports.UnbookmarkPostRequest = {
|
|
852
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
853
|
+
if (message.postId !== "") {
|
|
854
|
+
writer.uint32(10).string(message.postId);
|
|
855
|
+
}
|
|
856
|
+
return writer;
|
|
857
|
+
},
|
|
858
|
+
decode(input, length) {
|
|
859
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
860
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
861
|
+
const message = createBaseUnbookmarkPostRequest();
|
|
862
|
+
while (reader.pos < end) {
|
|
863
|
+
const tag = reader.uint32();
|
|
864
|
+
switch (tag >>> 3) {
|
|
865
|
+
case 1: {
|
|
866
|
+
if (tag !== 10) {
|
|
867
|
+
break;
|
|
868
|
+
}
|
|
869
|
+
message.postId = reader.string();
|
|
870
|
+
continue;
|
|
871
|
+
}
|
|
872
|
+
}
|
|
873
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
874
|
+
break;
|
|
875
|
+
}
|
|
876
|
+
reader.skip(tag & 7);
|
|
877
|
+
}
|
|
878
|
+
return message;
|
|
879
|
+
},
|
|
880
|
+
fromJSON(object) {
|
|
881
|
+
return { postId: isSet(object.postId) ? globalThis.String(object.postId) : "" };
|
|
882
|
+
},
|
|
883
|
+
toJSON(message) {
|
|
884
|
+
const obj = {};
|
|
885
|
+
if (message.postId !== "") {
|
|
886
|
+
obj.postId = message.postId;
|
|
887
|
+
}
|
|
888
|
+
return obj;
|
|
889
|
+
},
|
|
890
|
+
create(base) {
|
|
891
|
+
return exports.UnbookmarkPostRequest.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
892
|
+
},
|
|
893
|
+
fromPartial(object) {
|
|
894
|
+
var _a;
|
|
895
|
+
const message = createBaseUnbookmarkPostRequest();
|
|
896
|
+
message.postId = (_a = object.postId) !== null && _a !== void 0 ? _a : "";
|
|
897
|
+
return message;
|
|
898
|
+
},
|
|
899
|
+
};
|
|
900
|
+
function createBaseRepostRequest() {
|
|
901
|
+
return { postId: "" };
|
|
902
|
+
}
|
|
903
|
+
exports.RepostRequest = {
|
|
904
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
905
|
+
if (message.postId !== "") {
|
|
906
|
+
writer.uint32(10).string(message.postId);
|
|
907
|
+
}
|
|
908
|
+
return writer;
|
|
909
|
+
},
|
|
910
|
+
decode(input, length) {
|
|
911
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
912
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
913
|
+
const message = createBaseRepostRequest();
|
|
914
|
+
while (reader.pos < end) {
|
|
915
|
+
const tag = reader.uint32();
|
|
916
|
+
switch (tag >>> 3) {
|
|
917
|
+
case 1: {
|
|
918
|
+
if (tag !== 10) {
|
|
919
|
+
break;
|
|
920
|
+
}
|
|
921
|
+
message.postId = reader.string();
|
|
922
|
+
continue;
|
|
923
|
+
}
|
|
924
|
+
}
|
|
925
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
926
|
+
break;
|
|
927
|
+
}
|
|
928
|
+
reader.skip(tag & 7);
|
|
929
|
+
}
|
|
930
|
+
return message;
|
|
931
|
+
},
|
|
932
|
+
fromJSON(object) {
|
|
933
|
+
return { postId: isSet(object.postId) ? globalThis.String(object.postId) : "" };
|
|
934
|
+
},
|
|
935
|
+
toJSON(message) {
|
|
936
|
+
const obj = {};
|
|
937
|
+
if (message.postId !== "") {
|
|
938
|
+
obj.postId = message.postId;
|
|
939
|
+
}
|
|
940
|
+
return obj;
|
|
941
|
+
},
|
|
942
|
+
create(base) {
|
|
943
|
+
return exports.RepostRequest.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
944
|
+
},
|
|
945
|
+
fromPartial(object) {
|
|
946
|
+
var _a;
|
|
947
|
+
const message = createBaseRepostRequest();
|
|
948
|
+
message.postId = (_a = object.postId) !== null && _a !== void 0 ? _a : "";
|
|
949
|
+
return message;
|
|
950
|
+
},
|
|
951
|
+
};
|
|
952
|
+
function createBaseRepostResponse() {
|
|
953
|
+
return { reposted: false, repostsCount: 0 };
|
|
954
|
+
}
|
|
955
|
+
exports.RepostResponse = {
|
|
956
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
957
|
+
if (message.reposted !== false) {
|
|
958
|
+
writer.uint32(8).bool(message.reposted);
|
|
959
|
+
}
|
|
960
|
+
if (message.repostsCount !== 0) {
|
|
961
|
+
writer.uint32(16).int64(message.repostsCount);
|
|
962
|
+
}
|
|
963
|
+
return writer;
|
|
964
|
+
},
|
|
965
|
+
decode(input, length) {
|
|
966
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
967
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
968
|
+
const message = createBaseRepostResponse();
|
|
969
|
+
while (reader.pos < end) {
|
|
970
|
+
const tag = reader.uint32();
|
|
971
|
+
switch (tag >>> 3) {
|
|
972
|
+
case 1: {
|
|
973
|
+
if (tag !== 8) {
|
|
974
|
+
break;
|
|
975
|
+
}
|
|
976
|
+
message.reposted = reader.bool();
|
|
977
|
+
continue;
|
|
978
|
+
}
|
|
979
|
+
case 2: {
|
|
980
|
+
if (tag !== 16) {
|
|
981
|
+
break;
|
|
982
|
+
}
|
|
983
|
+
message.repostsCount = longToNumber(reader.int64());
|
|
984
|
+
continue;
|
|
985
|
+
}
|
|
986
|
+
}
|
|
987
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
988
|
+
break;
|
|
989
|
+
}
|
|
990
|
+
reader.skip(tag & 7);
|
|
991
|
+
}
|
|
992
|
+
return message;
|
|
993
|
+
},
|
|
994
|
+
fromJSON(object) {
|
|
995
|
+
return {
|
|
996
|
+
reposted: isSet(object.reposted) ? globalThis.Boolean(object.reposted) : false,
|
|
997
|
+
repostsCount: isSet(object.repostsCount) ? globalThis.Number(object.repostsCount) : 0,
|
|
998
|
+
};
|
|
999
|
+
},
|
|
1000
|
+
toJSON(message) {
|
|
1001
|
+
const obj = {};
|
|
1002
|
+
if (message.reposted !== false) {
|
|
1003
|
+
obj.reposted = message.reposted;
|
|
1004
|
+
}
|
|
1005
|
+
if (message.repostsCount !== 0) {
|
|
1006
|
+
obj.repostsCount = Math.round(message.repostsCount);
|
|
1007
|
+
}
|
|
1008
|
+
return obj;
|
|
1009
|
+
},
|
|
1010
|
+
create(base) {
|
|
1011
|
+
return exports.RepostResponse.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
1012
|
+
},
|
|
1013
|
+
fromPartial(object) {
|
|
1014
|
+
var _a, _b;
|
|
1015
|
+
const message = createBaseRepostResponse();
|
|
1016
|
+
message.reposted = (_a = object.reposted) !== null && _a !== void 0 ? _a : false;
|
|
1017
|
+
message.repostsCount = (_b = object.repostsCount) !== null && _b !== void 0 ? _b : 0;
|
|
1018
|
+
return message;
|
|
1019
|
+
},
|
|
1020
|
+
};
|
|
1021
|
+
function createBaseUnrepostRequest() {
|
|
1022
|
+
return { postId: "" };
|
|
1023
|
+
}
|
|
1024
|
+
exports.UnrepostRequest = {
|
|
1025
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
1026
|
+
if (message.postId !== "") {
|
|
1027
|
+
writer.uint32(10).string(message.postId);
|
|
1028
|
+
}
|
|
1029
|
+
return writer;
|
|
1030
|
+
},
|
|
1031
|
+
decode(input, length) {
|
|
1032
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
1033
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1034
|
+
const message = createBaseUnrepostRequest();
|
|
1035
|
+
while (reader.pos < end) {
|
|
1036
|
+
const tag = reader.uint32();
|
|
1037
|
+
switch (tag >>> 3) {
|
|
1038
|
+
case 1: {
|
|
1039
|
+
if (tag !== 10) {
|
|
1040
|
+
break;
|
|
1041
|
+
}
|
|
1042
|
+
message.postId = reader.string();
|
|
1043
|
+
continue;
|
|
1044
|
+
}
|
|
1045
|
+
}
|
|
1046
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1047
|
+
break;
|
|
1048
|
+
}
|
|
1049
|
+
reader.skip(tag & 7);
|
|
1050
|
+
}
|
|
1051
|
+
return message;
|
|
1052
|
+
},
|
|
1053
|
+
fromJSON(object) {
|
|
1054
|
+
return { postId: isSet(object.postId) ? globalThis.String(object.postId) : "" };
|
|
1055
|
+
},
|
|
1056
|
+
toJSON(message) {
|
|
1057
|
+
const obj = {};
|
|
1058
|
+
if (message.postId !== "") {
|
|
1059
|
+
obj.postId = message.postId;
|
|
1060
|
+
}
|
|
1061
|
+
return obj;
|
|
1062
|
+
},
|
|
1063
|
+
create(base) {
|
|
1064
|
+
return exports.UnrepostRequest.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
1065
|
+
},
|
|
1066
|
+
fromPartial(object) {
|
|
1067
|
+
var _a;
|
|
1068
|
+
const message = createBaseUnrepostRequest();
|
|
1069
|
+
message.postId = (_a = object.postId) !== null && _a !== void 0 ? _a : "";
|
|
1070
|
+
return message;
|
|
1071
|
+
},
|
|
1072
|
+
};
|
|
1073
|
+
function createBaseSearchPostsRequest() {
|
|
1074
|
+
return { base: undefined, query: "", postType: "", limit: 0 };
|
|
1075
|
+
}
|
|
1076
|
+
exports.SearchPostsRequest = {
|
|
1077
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
1078
|
+
if (message.base !== undefined) {
|
|
1079
|
+
common_1.BaseListRequest.encode(message.base, writer.uint32(10).fork()).join();
|
|
1080
|
+
}
|
|
1081
|
+
if (message.query !== "") {
|
|
1082
|
+
writer.uint32(18).string(message.query);
|
|
1083
|
+
}
|
|
1084
|
+
if (message.postType !== "") {
|
|
1085
|
+
writer.uint32(26).string(message.postType);
|
|
1086
|
+
}
|
|
1087
|
+
if (message.limit !== 0) {
|
|
1088
|
+
writer.uint32(32).int32(message.limit);
|
|
1089
|
+
}
|
|
1090
|
+
return writer;
|
|
1091
|
+
},
|
|
1092
|
+
decode(input, length) {
|
|
1093
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
1094
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1095
|
+
const message = createBaseSearchPostsRequest();
|
|
1096
|
+
while (reader.pos < end) {
|
|
1097
|
+
const tag = reader.uint32();
|
|
1098
|
+
switch (tag >>> 3) {
|
|
1099
|
+
case 1: {
|
|
1100
|
+
if (tag !== 10) {
|
|
1101
|
+
break;
|
|
1102
|
+
}
|
|
1103
|
+
message.base = common_1.BaseListRequest.decode(reader, reader.uint32());
|
|
1104
|
+
continue;
|
|
1105
|
+
}
|
|
1106
|
+
case 2: {
|
|
1107
|
+
if (tag !== 18) {
|
|
1108
|
+
break;
|
|
1109
|
+
}
|
|
1110
|
+
message.query = reader.string();
|
|
1111
|
+
continue;
|
|
1112
|
+
}
|
|
1113
|
+
case 3: {
|
|
1114
|
+
if (tag !== 26) {
|
|
1115
|
+
break;
|
|
1116
|
+
}
|
|
1117
|
+
message.postType = reader.string();
|
|
1118
|
+
continue;
|
|
1119
|
+
}
|
|
1120
|
+
case 4: {
|
|
1121
|
+
if (tag !== 32) {
|
|
1122
|
+
break;
|
|
1123
|
+
}
|
|
1124
|
+
message.limit = reader.int32();
|
|
1125
|
+
continue;
|
|
1126
|
+
}
|
|
1127
|
+
}
|
|
1128
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1129
|
+
break;
|
|
1130
|
+
}
|
|
1131
|
+
reader.skip(tag & 7);
|
|
1132
|
+
}
|
|
1133
|
+
return message;
|
|
1134
|
+
},
|
|
1135
|
+
fromJSON(object) {
|
|
1136
|
+
return {
|
|
1137
|
+
base: isSet(object.base) ? common_1.BaseListRequest.fromJSON(object.base) : undefined,
|
|
1138
|
+
query: isSet(object.query) ? globalThis.String(object.query) : "",
|
|
1139
|
+
postType: isSet(object.postType) ? globalThis.String(object.postType) : "",
|
|
1140
|
+
limit: isSet(object.limit) ? globalThis.Number(object.limit) : 0,
|
|
1141
|
+
};
|
|
1142
|
+
},
|
|
1143
|
+
toJSON(message) {
|
|
1144
|
+
const obj = {};
|
|
1145
|
+
if (message.base !== undefined) {
|
|
1146
|
+
obj.base = common_1.BaseListRequest.toJSON(message.base);
|
|
1147
|
+
}
|
|
1148
|
+
if (message.query !== "") {
|
|
1149
|
+
obj.query = message.query;
|
|
1150
|
+
}
|
|
1151
|
+
if (message.postType !== "") {
|
|
1152
|
+
obj.postType = message.postType;
|
|
1153
|
+
}
|
|
1154
|
+
if (message.limit !== 0) {
|
|
1155
|
+
obj.limit = Math.round(message.limit);
|
|
1156
|
+
}
|
|
1157
|
+
return obj;
|
|
1158
|
+
},
|
|
1159
|
+
create(base) {
|
|
1160
|
+
return exports.SearchPostsRequest.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
1161
|
+
},
|
|
1162
|
+
fromPartial(object) {
|
|
1163
|
+
var _a, _b, _c;
|
|
1164
|
+
const message = createBaseSearchPostsRequest();
|
|
1165
|
+
message.base = (object.base !== undefined && object.base !== null)
|
|
1166
|
+
? common_1.BaseListRequest.fromPartial(object.base)
|
|
1167
|
+
: undefined;
|
|
1168
|
+
message.query = (_a = object.query) !== null && _a !== void 0 ? _a : "";
|
|
1169
|
+
message.postType = (_b = object.postType) !== null && _b !== void 0 ? _b : "";
|
|
1170
|
+
message.limit = (_c = object.limit) !== null && _c !== void 0 ? _c : 0;
|
|
1171
|
+
return message;
|
|
1172
|
+
},
|
|
1173
|
+
};
|
|
1174
|
+
function createBaseSignPetitionRequest() {
|
|
1175
|
+
return { postId: "" };
|
|
1176
|
+
}
|
|
1177
|
+
exports.SignPetitionRequest = {
|
|
1178
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
1179
|
+
if (message.postId !== "") {
|
|
1180
|
+
writer.uint32(10).string(message.postId);
|
|
1181
|
+
}
|
|
1182
|
+
return writer;
|
|
1183
|
+
},
|
|
1184
|
+
decode(input, length) {
|
|
1185
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
1186
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1187
|
+
const message = createBaseSignPetitionRequest();
|
|
1188
|
+
while (reader.pos < end) {
|
|
1189
|
+
const tag = reader.uint32();
|
|
1190
|
+
switch (tag >>> 3) {
|
|
1191
|
+
case 1: {
|
|
1192
|
+
if (tag !== 10) {
|
|
1193
|
+
break;
|
|
1194
|
+
}
|
|
1195
|
+
message.postId = reader.string();
|
|
1196
|
+
continue;
|
|
1197
|
+
}
|
|
1198
|
+
}
|
|
1199
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1200
|
+
break;
|
|
1201
|
+
}
|
|
1202
|
+
reader.skip(tag & 7);
|
|
1203
|
+
}
|
|
1204
|
+
return message;
|
|
1205
|
+
},
|
|
1206
|
+
fromJSON(object) {
|
|
1207
|
+
return { postId: isSet(object.postId) ? globalThis.String(object.postId) : "" };
|
|
1208
|
+
},
|
|
1209
|
+
toJSON(message) {
|
|
1210
|
+
const obj = {};
|
|
1211
|
+
if (message.postId !== "") {
|
|
1212
|
+
obj.postId = message.postId;
|
|
1213
|
+
}
|
|
1214
|
+
return obj;
|
|
1215
|
+
},
|
|
1216
|
+
create(base) {
|
|
1217
|
+
return exports.SignPetitionRequest.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
1218
|
+
},
|
|
1219
|
+
fromPartial(object) {
|
|
1220
|
+
var _a;
|
|
1221
|
+
const message = createBaseSignPetitionRequest();
|
|
1222
|
+
message.postId = (_a = object.postId) !== null && _a !== void 0 ? _a : "";
|
|
1223
|
+
return message;
|
|
1224
|
+
},
|
|
1225
|
+
};
|
|
1226
|
+
function createBaseSignPetitionResponse() {
|
|
1227
|
+
return { signed: false, signaturesCount: 0 };
|
|
1228
|
+
}
|
|
1229
|
+
exports.SignPetitionResponse = {
|
|
1230
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
1231
|
+
if (message.signed !== false) {
|
|
1232
|
+
writer.uint32(8).bool(message.signed);
|
|
1233
|
+
}
|
|
1234
|
+
if (message.signaturesCount !== 0) {
|
|
1235
|
+
writer.uint32(16).int64(message.signaturesCount);
|
|
1236
|
+
}
|
|
1237
|
+
return writer;
|
|
1238
|
+
},
|
|
1239
|
+
decode(input, length) {
|
|
1240
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
1241
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1242
|
+
const message = createBaseSignPetitionResponse();
|
|
1243
|
+
while (reader.pos < end) {
|
|
1244
|
+
const tag = reader.uint32();
|
|
1245
|
+
switch (tag >>> 3) {
|
|
1246
|
+
case 1: {
|
|
1247
|
+
if (tag !== 8) {
|
|
1248
|
+
break;
|
|
1249
|
+
}
|
|
1250
|
+
message.signed = reader.bool();
|
|
1251
|
+
continue;
|
|
1252
|
+
}
|
|
1253
|
+
case 2: {
|
|
1254
|
+
if (tag !== 16) {
|
|
1255
|
+
break;
|
|
1256
|
+
}
|
|
1257
|
+
message.signaturesCount = longToNumber(reader.int64());
|
|
1258
|
+
continue;
|
|
1259
|
+
}
|
|
1260
|
+
}
|
|
1261
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1262
|
+
break;
|
|
1263
|
+
}
|
|
1264
|
+
reader.skip(tag & 7);
|
|
1265
|
+
}
|
|
1266
|
+
return message;
|
|
1267
|
+
},
|
|
1268
|
+
fromJSON(object) {
|
|
1269
|
+
return {
|
|
1270
|
+
signed: isSet(object.signed) ? globalThis.Boolean(object.signed) : false,
|
|
1271
|
+
signaturesCount: isSet(object.signaturesCount) ? globalThis.Number(object.signaturesCount) : 0,
|
|
1272
|
+
};
|
|
1273
|
+
},
|
|
1274
|
+
toJSON(message) {
|
|
1275
|
+
const obj = {};
|
|
1276
|
+
if (message.signed !== false) {
|
|
1277
|
+
obj.signed = message.signed;
|
|
1278
|
+
}
|
|
1279
|
+
if (message.signaturesCount !== 0) {
|
|
1280
|
+
obj.signaturesCount = Math.round(message.signaturesCount);
|
|
1281
|
+
}
|
|
1282
|
+
return obj;
|
|
1283
|
+
},
|
|
1284
|
+
create(base) {
|
|
1285
|
+
return exports.SignPetitionResponse.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
1286
|
+
},
|
|
1287
|
+
fromPartial(object) {
|
|
1288
|
+
var _a, _b;
|
|
1289
|
+
const message = createBaseSignPetitionResponse();
|
|
1290
|
+
message.signed = (_a = object.signed) !== null && _a !== void 0 ? _a : false;
|
|
1291
|
+
message.signaturesCount = (_b = object.signaturesCount) !== null && _b !== void 0 ? _b : 0;
|
|
1292
|
+
return message;
|
|
1293
|
+
},
|
|
1294
|
+
};
|
|
1295
|
+
function createBaseUnsignPetitionRequest() {
|
|
1296
|
+
return { postId: "" };
|
|
1297
|
+
}
|
|
1298
|
+
exports.UnsignPetitionRequest = {
|
|
1299
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
1300
|
+
if (message.postId !== "") {
|
|
1301
|
+
writer.uint32(10).string(message.postId);
|
|
1302
|
+
}
|
|
1303
|
+
return writer;
|
|
1304
|
+
},
|
|
1305
|
+
decode(input, length) {
|
|
1306
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
1307
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1308
|
+
const message = createBaseUnsignPetitionRequest();
|
|
1309
|
+
while (reader.pos < end) {
|
|
1310
|
+
const tag = reader.uint32();
|
|
1311
|
+
switch (tag >>> 3) {
|
|
1312
|
+
case 1: {
|
|
1313
|
+
if (tag !== 10) {
|
|
1314
|
+
break;
|
|
1315
|
+
}
|
|
1316
|
+
message.postId = reader.string();
|
|
1317
|
+
continue;
|
|
1318
|
+
}
|
|
1319
|
+
}
|
|
1320
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1321
|
+
break;
|
|
1322
|
+
}
|
|
1323
|
+
reader.skip(tag & 7);
|
|
1324
|
+
}
|
|
1325
|
+
return message;
|
|
1326
|
+
},
|
|
1327
|
+
fromJSON(object) {
|
|
1328
|
+
return { postId: isSet(object.postId) ? globalThis.String(object.postId) : "" };
|
|
1329
|
+
},
|
|
1330
|
+
toJSON(message) {
|
|
1331
|
+
const obj = {};
|
|
1332
|
+
if (message.postId !== "") {
|
|
1333
|
+
obj.postId = message.postId;
|
|
1334
|
+
}
|
|
1335
|
+
return obj;
|
|
1336
|
+
},
|
|
1337
|
+
create(base) {
|
|
1338
|
+
return exports.UnsignPetitionRequest.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
1339
|
+
},
|
|
1340
|
+
fromPartial(object) {
|
|
1341
|
+
var _a;
|
|
1342
|
+
const message = createBaseUnsignPetitionRequest();
|
|
1343
|
+
message.postId = (_a = object.postId) !== null && _a !== void 0 ? _a : "";
|
|
1344
|
+
return message;
|
|
1345
|
+
},
|
|
1346
|
+
};
|
|
1347
|
+
function createBaseApproveEyewitnessReportRequest() {
|
|
1348
|
+
return { postId: "" };
|
|
1349
|
+
}
|
|
1350
|
+
exports.ApproveEyewitnessReportRequest = {
|
|
1351
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
1352
|
+
if (message.postId !== "") {
|
|
1353
|
+
writer.uint32(10).string(message.postId);
|
|
1354
|
+
}
|
|
1355
|
+
return writer;
|
|
1356
|
+
},
|
|
1357
|
+
decode(input, length) {
|
|
1358
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
1359
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1360
|
+
const message = createBaseApproveEyewitnessReportRequest();
|
|
1361
|
+
while (reader.pos < end) {
|
|
1362
|
+
const tag = reader.uint32();
|
|
1363
|
+
switch (tag >>> 3) {
|
|
1364
|
+
case 1: {
|
|
1365
|
+
if (tag !== 10) {
|
|
1366
|
+
break;
|
|
1367
|
+
}
|
|
1368
|
+
message.postId = reader.string();
|
|
1369
|
+
continue;
|
|
1370
|
+
}
|
|
1371
|
+
}
|
|
1372
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1373
|
+
break;
|
|
1374
|
+
}
|
|
1375
|
+
reader.skip(tag & 7);
|
|
1376
|
+
}
|
|
1377
|
+
return message;
|
|
1378
|
+
},
|
|
1379
|
+
fromJSON(object) {
|
|
1380
|
+
return { postId: isSet(object.postId) ? globalThis.String(object.postId) : "" };
|
|
1381
|
+
},
|
|
1382
|
+
toJSON(message) {
|
|
1383
|
+
const obj = {};
|
|
1384
|
+
if (message.postId !== "") {
|
|
1385
|
+
obj.postId = message.postId;
|
|
1386
|
+
}
|
|
1387
|
+
return obj;
|
|
1388
|
+
},
|
|
1389
|
+
create(base) {
|
|
1390
|
+
return exports.ApproveEyewitnessReportRequest.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
1391
|
+
},
|
|
1392
|
+
fromPartial(object) {
|
|
1393
|
+
var _a;
|
|
1394
|
+
const message = createBaseApproveEyewitnessReportRequest();
|
|
1395
|
+
message.postId = (_a = object.postId) !== null && _a !== void 0 ? _a : "";
|
|
1396
|
+
return message;
|
|
1397
|
+
},
|
|
1398
|
+
};
|
|
1399
|
+
function createBaseApproveEyewitnessReportResponse() {
|
|
1400
|
+
return { approved: false, approvalsCount: 0 };
|
|
1401
|
+
}
|
|
1402
|
+
exports.ApproveEyewitnessReportResponse = {
|
|
1403
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
1404
|
+
if (message.approved !== false) {
|
|
1405
|
+
writer.uint32(8).bool(message.approved);
|
|
1406
|
+
}
|
|
1407
|
+
if (message.approvalsCount !== 0) {
|
|
1408
|
+
writer.uint32(16).int64(message.approvalsCount);
|
|
1409
|
+
}
|
|
1410
|
+
return writer;
|
|
1411
|
+
},
|
|
1412
|
+
decode(input, length) {
|
|
1413
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
1414
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1415
|
+
const message = createBaseApproveEyewitnessReportResponse();
|
|
1416
|
+
while (reader.pos < end) {
|
|
1417
|
+
const tag = reader.uint32();
|
|
1418
|
+
switch (tag >>> 3) {
|
|
1419
|
+
case 1: {
|
|
1420
|
+
if (tag !== 8) {
|
|
1421
|
+
break;
|
|
1422
|
+
}
|
|
1423
|
+
message.approved = reader.bool();
|
|
1424
|
+
continue;
|
|
1425
|
+
}
|
|
1426
|
+
case 2: {
|
|
1427
|
+
if (tag !== 16) {
|
|
1428
|
+
break;
|
|
1429
|
+
}
|
|
1430
|
+
message.approvalsCount = longToNumber(reader.int64());
|
|
1431
|
+
continue;
|
|
1432
|
+
}
|
|
1433
|
+
}
|
|
1434
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1435
|
+
break;
|
|
1436
|
+
}
|
|
1437
|
+
reader.skip(tag & 7);
|
|
1438
|
+
}
|
|
1439
|
+
return message;
|
|
1440
|
+
},
|
|
1441
|
+
fromJSON(object) {
|
|
1442
|
+
return {
|
|
1443
|
+
approved: isSet(object.approved) ? globalThis.Boolean(object.approved) : false,
|
|
1444
|
+
approvalsCount: isSet(object.approvalsCount) ? globalThis.Number(object.approvalsCount) : 0,
|
|
1445
|
+
};
|
|
1446
|
+
},
|
|
1447
|
+
toJSON(message) {
|
|
1448
|
+
const obj = {};
|
|
1449
|
+
if (message.approved !== false) {
|
|
1450
|
+
obj.approved = message.approved;
|
|
1451
|
+
}
|
|
1452
|
+
if (message.approvalsCount !== 0) {
|
|
1453
|
+
obj.approvalsCount = Math.round(message.approvalsCount);
|
|
1454
|
+
}
|
|
1455
|
+
return obj;
|
|
1456
|
+
},
|
|
1457
|
+
create(base) {
|
|
1458
|
+
return exports.ApproveEyewitnessReportResponse.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
1459
|
+
},
|
|
1460
|
+
fromPartial(object) {
|
|
1461
|
+
var _a, _b;
|
|
1462
|
+
const message = createBaseApproveEyewitnessReportResponse();
|
|
1463
|
+
message.approved = (_a = object.approved) !== null && _a !== void 0 ? _a : false;
|
|
1464
|
+
message.approvalsCount = (_b = object.approvalsCount) !== null && _b !== void 0 ? _b : 0;
|
|
1465
|
+
return message;
|
|
1466
|
+
},
|
|
1467
|
+
};
|
|
1468
|
+
function createBaseUnapproveEyewitnessReportRequest() {
|
|
1469
|
+
return { postId: "" };
|
|
1470
|
+
}
|
|
1471
|
+
exports.UnapproveEyewitnessReportRequest = {
|
|
1472
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
1473
|
+
if (message.postId !== "") {
|
|
1474
|
+
writer.uint32(10).string(message.postId);
|
|
1475
|
+
}
|
|
1476
|
+
return writer;
|
|
1477
|
+
},
|
|
1478
|
+
decode(input, length) {
|
|
1479
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
1480
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1481
|
+
const message = createBaseUnapproveEyewitnessReportRequest();
|
|
1482
|
+
while (reader.pos < end) {
|
|
1483
|
+
const tag = reader.uint32();
|
|
1484
|
+
switch (tag >>> 3) {
|
|
1485
|
+
case 1: {
|
|
1486
|
+
if (tag !== 10) {
|
|
1487
|
+
break;
|
|
1488
|
+
}
|
|
1489
|
+
message.postId = reader.string();
|
|
1490
|
+
continue;
|
|
1491
|
+
}
|
|
1492
|
+
}
|
|
1493
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1494
|
+
break;
|
|
1495
|
+
}
|
|
1496
|
+
reader.skip(tag & 7);
|
|
1497
|
+
}
|
|
1498
|
+
return message;
|
|
1499
|
+
},
|
|
1500
|
+
fromJSON(object) {
|
|
1501
|
+
return { postId: isSet(object.postId) ? globalThis.String(object.postId) : "" };
|
|
1502
|
+
},
|
|
1503
|
+
toJSON(message) {
|
|
1504
|
+
const obj = {};
|
|
1505
|
+
if (message.postId !== "") {
|
|
1506
|
+
obj.postId = message.postId;
|
|
1507
|
+
}
|
|
1508
|
+
return obj;
|
|
1509
|
+
},
|
|
1510
|
+
create(base) {
|
|
1511
|
+
return exports.UnapproveEyewitnessReportRequest.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
1512
|
+
},
|
|
1513
|
+
fromPartial(object) {
|
|
1514
|
+
var _a;
|
|
1515
|
+
const message = createBaseUnapproveEyewitnessReportRequest();
|
|
1516
|
+
message.postId = (_a = object.postId) !== null && _a !== void 0 ? _a : "";
|
|
1517
|
+
return message;
|
|
1518
|
+
},
|
|
1519
|
+
};
|
|
1520
|
+
function createBasePost() {
|
|
1521
|
+
return {
|
|
1522
|
+
id: "",
|
|
1523
|
+
postType: "",
|
|
1524
|
+
title: "",
|
|
1525
|
+
context: "",
|
|
1526
|
+
media: [],
|
|
1527
|
+
creatorId: "",
|
|
1528
|
+
creator: undefined,
|
|
1529
|
+
status: "",
|
|
1530
|
+
createdAt: "",
|
|
1531
|
+
updatedAt: "",
|
|
1532
|
+
engagement: undefined,
|
|
1533
|
+
userStatus: undefined,
|
|
1534
|
+
};
|
|
1535
|
+
}
|
|
1536
|
+
exports.Post = {
|
|
1537
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
1538
|
+
if (message.id !== "") {
|
|
1539
|
+
writer.uint32(10).string(message.id);
|
|
1540
|
+
}
|
|
1541
|
+
if (message.postType !== "") {
|
|
1542
|
+
writer.uint32(18).string(message.postType);
|
|
1543
|
+
}
|
|
1544
|
+
if (message.title !== "") {
|
|
1545
|
+
writer.uint32(26).string(message.title);
|
|
1546
|
+
}
|
|
1547
|
+
if (message.context !== "") {
|
|
1548
|
+
writer.uint32(34).string(message.context);
|
|
1549
|
+
}
|
|
1550
|
+
for (const v of message.media) {
|
|
1551
|
+
writer.uint32(42).string(v);
|
|
1552
|
+
}
|
|
1553
|
+
if (message.creatorId !== "") {
|
|
1554
|
+
writer.uint32(50).string(message.creatorId);
|
|
1555
|
+
}
|
|
1556
|
+
if (message.creator !== undefined) {
|
|
1557
|
+
exports.Creator.encode(message.creator, writer.uint32(58).fork()).join();
|
|
1558
|
+
}
|
|
1559
|
+
if (message.status !== "") {
|
|
1560
|
+
writer.uint32(66).string(message.status);
|
|
1561
|
+
}
|
|
1562
|
+
if (message.createdAt !== "") {
|
|
1563
|
+
writer.uint32(74).string(message.createdAt);
|
|
1564
|
+
}
|
|
1565
|
+
if (message.updatedAt !== "") {
|
|
1566
|
+
writer.uint32(82).string(message.updatedAt);
|
|
1567
|
+
}
|
|
1568
|
+
if (message.engagement !== undefined) {
|
|
1569
|
+
exports.PostEngagement.encode(message.engagement, writer.uint32(90).fork()).join();
|
|
1570
|
+
}
|
|
1571
|
+
if (message.userStatus !== undefined) {
|
|
1572
|
+
exports.PostUserStatus.encode(message.userStatus, writer.uint32(98).fork()).join();
|
|
1573
|
+
}
|
|
1574
|
+
return writer;
|
|
1575
|
+
},
|
|
1576
|
+
decode(input, length) {
|
|
1577
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
1578
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1579
|
+
const message = createBasePost();
|
|
1580
|
+
while (reader.pos < end) {
|
|
1581
|
+
const tag = reader.uint32();
|
|
1582
|
+
switch (tag >>> 3) {
|
|
1583
|
+
case 1: {
|
|
1584
|
+
if (tag !== 10) {
|
|
1585
|
+
break;
|
|
1586
|
+
}
|
|
1587
|
+
message.id = reader.string();
|
|
1588
|
+
continue;
|
|
1589
|
+
}
|
|
1590
|
+
case 2: {
|
|
1591
|
+
if (tag !== 18) {
|
|
1592
|
+
break;
|
|
1593
|
+
}
|
|
1594
|
+
message.postType = reader.string();
|
|
1595
|
+
continue;
|
|
1596
|
+
}
|
|
1597
|
+
case 3: {
|
|
1598
|
+
if (tag !== 26) {
|
|
1599
|
+
break;
|
|
1600
|
+
}
|
|
1601
|
+
message.title = reader.string();
|
|
1602
|
+
continue;
|
|
1603
|
+
}
|
|
1604
|
+
case 4: {
|
|
1605
|
+
if (tag !== 34) {
|
|
1606
|
+
break;
|
|
1607
|
+
}
|
|
1608
|
+
message.context = reader.string();
|
|
1609
|
+
continue;
|
|
1610
|
+
}
|
|
1611
|
+
case 5: {
|
|
1612
|
+
if (tag !== 42) {
|
|
1613
|
+
break;
|
|
1614
|
+
}
|
|
1615
|
+
message.media.push(reader.string());
|
|
1616
|
+
continue;
|
|
1617
|
+
}
|
|
1618
|
+
case 6: {
|
|
1619
|
+
if (tag !== 50) {
|
|
1620
|
+
break;
|
|
1621
|
+
}
|
|
1622
|
+
message.creatorId = reader.string();
|
|
1623
|
+
continue;
|
|
1624
|
+
}
|
|
1625
|
+
case 7: {
|
|
1626
|
+
if (tag !== 58) {
|
|
1627
|
+
break;
|
|
1628
|
+
}
|
|
1629
|
+
message.creator = exports.Creator.decode(reader, reader.uint32());
|
|
1630
|
+
continue;
|
|
1631
|
+
}
|
|
1632
|
+
case 8: {
|
|
1633
|
+
if (tag !== 66) {
|
|
1634
|
+
break;
|
|
1635
|
+
}
|
|
1636
|
+
message.status = reader.string();
|
|
1637
|
+
continue;
|
|
1638
|
+
}
|
|
1639
|
+
case 9: {
|
|
1640
|
+
if (tag !== 74) {
|
|
1641
|
+
break;
|
|
1642
|
+
}
|
|
1643
|
+
message.createdAt = reader.string();
|
|
1644
|
+
continue;
|
|
1645
|
+
}
|
|
1646
|
+
case 10: {
|
|
1647
|
+
if (tag !== 82) {
|
|
1648
|
+
break;
|
|
1649
|
+
}
|
|
1650
|
+
message.updatedAt = reader.string();
|
|
1651
|
+
continue;
|
|
1652
|
+
}
|
|
1653
|
+
case 11: {
|
|
1654
|
+
if (tag !== 90) {
|
|
1655
|
+
break;
|
|
1656
|
+
}
|
|
1657
|
+
message.engagement = exports.PostEngagement.decode(reader, reader.uint32());
|
|
1658
|
+
continue;
|
|
1659
|
+
}
|
|
1660
|
+
case 12: {
|
|
1661
|
+
if (tag !== 98) {
|
|
1662
|
+
break;
|
|
1663
|
+
}
|
|
1664
|
+
message.userStatus = exports.PostUserStatus.decode(reader, reader.uint32());
|
|
1665
|
+
continue;
|
|
1666
|
+
}
|
|
1667
|
+
}
|
|
1668
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1669
|
+
break;
|
|
1670
|
+
}
|
|
1671
|
+
reader.skip(tag & 7);
|
|
1672
|
+
}
|
|
1673
|
+
return message;
|
|
1674
|
+
},
|
|
1675
|
+
fromJSON(object) {
|
|
1676
|
+
return {
|
|
1677
|
+
id: isSet(object.id) ? globalThis.String(object.id) : "",
|
|
1678
|
+
postType: isSet(object.postType) ? globalThis.String(object.postType) : "",
|
|
1679
|
+
title: isSet(object.title) ? globalThis.String(object.title) : "",
|
|
1680
|
+
context: isSet(object.context) ? globalThis.String(object.context) : "",
|
|
1681
|
+
media: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.media) ? object.media.map((e) => globalThis.String(e)) : [],
|
|
1682
|
+
creatorId: isSet(object.creatorId) ? globalThis.String(object.creatorId) : "",
|
|
1683
|
+
creator: isSet(object.creator) ? exports.Creator.fromJSON(object.creator) : undefined,
|
|
1684
|
+
status: isSet(object.status) ? globalThis.String(object.status) : "",
|
|
1685
|
+
createdAt: isSet(object.createdAt) ? globalThis.String(object.createdAt) : "",
|
|
1686
|
+
updatedAt: isSet(object.updatedAt) ? globalThis.String(object.updatedAt) : "",
|
|
1687
|
+
engagement: isSet(object.engagement) ? exports.PostEngagement.fromJSON(object.engagement) : undefined,
|
|
1688
|
+
userStatus: isSet(object.userStatus) ? exports.PostUserStatus.fromJSON(object.userStatus) : undefined,
|
|
1689
|
+
};
|
|
1690
|
+
},
|
|
1691
|
+
toJSON(message) {
|
|
1692
|
+
var _a;
|
|
1693
|
+
const obj = {};
|
|
1694
|
+
if (message.id !== "") {
|
|
1695
|
+
obj.id = message.id;
|
|
1696
|
+
}
|
|
1697
|
+
if (message.postType !== "") {
|
|
1698
|
+
obj.postType = message.postType;
|
|
1699
|
+
}
|
|
1700
|
+
if (message.title !== "") {
|
|
1701
|
+
obj.title = message.title;
|
|
1702
|
+
}
|
|
1703
|
+
if (message.context !== "") {
|
|
1704
|
+
obj.context = message.context;
|
|
1705
|
+
}
|
|
1706
|
+
if ((_a = message.media) === null || _a === void 0 ? void 0 : _a.length) {
|
|
1707
|
+
obj.media = message.media;
|
|
1708
|
+
}
|
|
1709
|
+
if (message.creatorId !== "") {
|
|
1710
|
+
obj.creatorId = message.creatorId;
|
|
1711
|
+
}
|
|
1712
|
+
if (message.creator !== undefined) {
|
|
1713
|
+
obj.creator = exports.Creator.toJSON(message.creator);
|
|
1714
|
+
}
|
|
1715
|
+
if (message.status !== "") {
|
|
1716
|
+
obj.status = message.status;
|
|
1717
|
+
}
|
|
1718
|
+
if (message.createdAt !== "") {
|
|
1719
|
+
obj.createdAt = message.createdAt;
|
|
1720
|
+
}
|
|
1721
|
+
if (message.updatedAt !== "") {
|
|
1722
|
+
obj.updatedAt = message.updatedAt;
|
|
1723
|
+
}
|
|
1724
|
+
if (message.engagement !== undefined) {
|
|
1725
|
+
obj.engagement = exports.PostEngagement.toJSON(message.engagement);
|
|
1726
|
+
}
|
|
1727
|
+
if (message.userStatus !== undefined) {
|
|
1728
|
+
obj.userStatus = exports.PostUserStatus.toJSON(message.userStatus);
|
|
1729
|
+
}
|
|
1730
|
+
return obj;
|
|
1731
|
+
},
|
|
1732
|
+
create(base) {
|
|
1733
|
+
return exports.Post.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
1734
|
+
},
|
|
1735
|
+
fromPartial(object) {
|
|
1736
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
1737
|
+
const message = createBasePost();
|
|
1738
|
+
message.id = (_a = object.id) !== null && _a !== void 0 ? _a : "";
|
|
1739
|
+
message.postType = (_b = object.postType) !== null && _b !== void 0 ? _b : "";
|
|
1740
|
+
message.title = (_c = object.title) !== null && _c !== void 0 ? _c : "";
|
|
1741
|
+
message.context = (_d = object.context) !== null && _d !== void 0 ? _d : "";
|
|
1742
|
+
message.media = ((_e = object.media) === null || _e === void 0 ? void 0 : _e.map((e) => e)) || [];
|
|
1743
|
+
message.creatorId = (_f = object.creatorId) !== null && _f !== void 0 ? _f : "";
|
|
1744
|
+
message.creator = (object.creator !== undefined && object.creator !== null)
|
|
1745
|
+
? exports.Creator.fromPartial(object.creator)
|
|
1746
|
+
: undefined;
|
|
1747
|
+
message.status = (_g = object.status) !== null && _g !== void 0 ? _g : "";
|
|
1748
|
+
message.createdAt = (_h = object.createdAt) !== null && _h !== void 0 ? _h : "";
|
|
1749
|
+
message.updatedAt = (_j = object.updatedAt) !== null && _j !== void 0 ? _j : "";
|
|
1750
|
+
message.engagement = (object.engagement !== undefined && object.engagement !== null)
|
|
1751
|
+
? exports.PostEngagement.fromPartial(object.engagement)
|
|
1752
|
+
: undefined;
|
|
1753
|
+
message.userStatus = (object.userStatus !== undefined && object.userStatus !== null)
|
|
1754
|
+
? exports.PostUserStatus.fromPartial(object.userStatus)
|
|
1755
|
+
: undefined;
|
|
1756
|
+
return message;
|
|
1757
|
+
},
|
|
1758
|
+
};
|
|
1759
|
+
function createBaseCreator() {
|
|
1760
|
+
return { id: "", name: "", email: "", photoUrl: "" };
|
|
1761
|
+
}
|
|
1762
|
+
exports.Creator = {
|
|
1763
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
1764
|
+
if (message.id !== "") {
|
|
1765
|
+
writer.uint32(10).string(message.id);
|
|
1766
|
+
}
|
|
1767
|
+
if (message.name !== "") {
|
|
1768
|
+
writer.uint32(18).string(message.name);
|
|
1769
|
+
}
|
|
1770
|
+
if (message.email !== "") {
|
|
1771
|
+
writer.uint32(26).string(message.email);
|
|
1772
|
+
}
|
|
1773
|
+
if (message.photoUrl !== "") {
|
|
1774
|
+
writer.uint32(34).string(message.photoUrl);
|
|
1775
|
+
}
|
|
1776
|
+
return writer;
|
|
1777
|
+
},
|
|
1778
|
+
decode(input, length) {
|
|
1779
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
1780
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1781
|
+
const message = createBaseCreator();
|
|
1782
|
+
while (reader.pos < end) {
|
|
1783
|
+
const tag = reader.uint32();
|
|
1784
|
+
switch (tag >>> 3) {
|
|
1785
|
+
case 1: {
|
|
1786
|
+
if (tag !== 10) {
|
|
1787
|
+
break;
|
|
1788
|
+
}
|
|
1789
|
+
message.id = reader.string();
|
|
1790
|
+
continue;
|
|
1791
|
+
}
|
|
1792
|
+
case 2: {
|
|
1793
|
+
if (tag !== 18) {
|
|
1794
|
+
break;
|
|
1795
|
+
}
|
|
1796
|
+
message.name = reader.string();
|
|
1797
|
+
continue;
|
|
1798
|
+
}
|
|
1799
|
+
case 3: {
|
|
1800
|
+
if (tag !== 26) {
|
|
1801
|
+
break;
|
|
1802
|
+
}
|
|
1803
|
+
message.email = reader.string();
|
|
1804
|
+
continue;
|
|
1805
|
+
}
|
|
1806
|
+
case 4: {
|
|
1807
|
+
if (tag !== 34) {
|
|
1808
|
+
break;
|
|
1809
|
+
}
|
|
1810
|
+
message.photoUrl = reader.string();
|
|
1811
|
+
continue;
|
|
1812
|
+
}
|
|
1813
|
+
}
|
|
1814
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1815
|
+
break;
|
|
1816
|
+
}
|
|
1817
|
+
reader.skip(tag & 7);
|
|
1818
|
+
}
|
|
1819
|
+
return message;
|
|
1820
|
+
},
|
|
1821
|
+
fromJSON(object) {
|
|
1822
|
+
return {
|
|
1823
|
+
id: isSet(object.id) ? globalThis.String(object.id) : "",
|
|
1824
|
+
name: isSet(object.name) ? globalThis.String(object.name) : "",
|
|
1825
|
+
email: isSet(object.email) ? globalThis.String(object.email) : "",
|
|
1826
|
+
photoUrl: isSet(object.photoUrl) ? globalThis.String(object.photoUrl) : "",
|
|
1827
|
+
};
|
|
1828
|
+
},
|
|
1829
|
+
toJSON(message) {
|
|
1830
|
+
const obj = {};
|
|
1831
|
+
if (message.id !== "") {
|
|
1832
|
+
obj.id = message.id;
|
|
1833
|
+
}
|
|
1834
|
+
if (message.name !== "") {
|
|
1835
|
+
obj.name = message.name;
|
|
1836
|
+
}
|
|
1837
|
+
if (message.email !== "") {
|
|
1838
|
+
obj.email = message.email;
|
|
1839
|
+
}
|
|
1840
|
+
if (message.photoUrl !== "") {
|
|
1841
|
+
obj.photoUrl = message.photoUrl;
|
|
1842
|
+
}
|
|
1843
|
+
return obj;
|
|
1844
|
+
},
|
|
1845
|
+
create(base) {
|
|
1846
|
+
return exports.Creator.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
1847
|
+
},
|
|
1848
|
+
fromPartial(object) {
|
|
1849
|
+
var _a, _b, _c, _d;
|
|
1850
|
+
const message = createBaseCreator();
|
|
1851
|
+
message.id = (_a = object.id) !== null && _a !== void 0 ? _a : "";
|
|
1852
|
+
message.name = (_b = object.name) !== null && _b !== void 0 ? _b : "";
|
|
1853
|
+
message.email = (_c = object.email) !== null && _c !== void 0 ? _c : "";
|
|
1854
|
+
message.photoUrl = (_d = object.photoUrl) !== null && _d !== void 0 ? _d : "";
|
|
1855
|
+
return message;
|
|
1856
|
+
},
|
|
1857
|
+
};
|
|
1858
|
+
function createBasePostEngagement() {
|
|
1859
|
+
return {
|
|
1860
|
+
likesCount: 0,
|
|
1861
|
+
commentsCount: 0,
|
|
1862
|
+
repostsCount: 0,
|
|
1863
|
+
bookmarksCount: 0,
|
|
1864
|
+
signaturesCount: undefined,
|
|
1865
|
+
approvalsCount: undefined,
|
|
1866
|
+
};
|
|
1867
|
+
}
|
|
1868
|
+
exports.PostEngagement = {
|
|
1869
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
1870
|
+
if (message.likesCount !== 0) {
|
|
1871
|
+
writer.uint32(8).int64(message.likesCount);
|
|
1872
|
+
}
|
|
1873
|
+
if (message.commentsCount !== 0) {
|
|
1874
|
+
writer.uint32(16).int64(message.commentsCount);
|
|
1875
|
+
}
|
|
1876
|
+
if (message.repostsCount !== 0) {
|
|
1877
|
+
writer.uint32(24).int64(message.repostsCount);
|
|
1878
|
+
}
|
|
1879
|
+
if (message.bookmarksCount !== 0) {
|
|
1880
|
+
writer.uint32(32).int64(message.bookmarksCount);
|
|
1881
|
+
}
|
|
1882
|
+
if (message.signaturesCount !== undefined) {
|
|
1883
|
+
writer.uint32(40).int64(message.signaturesCount);
|
|
1884
|
+
}
|
|
1885
|
+
if (message.approvalsCount !== undefined) {
|
|
1886
|
+
writer.uint32(48).int64(message.approvalsCount);
|
|
1887
|
+
}
|
|
1888
|
+
return writer;
|
|
1889
|
+
},
|
|
1890
|
+
decode(input, length) {
|
|
1891
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
1892
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
1893
|
+
const message = createBasePostEngagement();
|
|
1894
|
+
while (reader.pos < end) {
|
|
1895
|
+
const tag = reader.uint32();
|
|
1896
|
+
switch (tag >>> 3) {
|
|
1897
|
+
case 1: {
|
|
1898
|
+
if (tag !== 8) {
|
|
1899
|
+
break;
|
|
1900
|
+
}
|
|
1901
|
+
message.likesCount = longToNumber(reader.int64());
|
|
1902
|
+
continue;
|
|
1903
|
+
}
|
|
1904
|
+
case 2: {
|
|
1905
|
+
if (tag !== 16) {
|
|
1906
|
+
break;
|
|
1907
|
+
}
|
|
1908
|
+
message.commentsCount = longToNumber(reader.int64());
|
|
1909
|
+
continue;
|
|
1910
|
+
}
|
|
1911
|
+
case 3: {
|
|
1912
|
+
if (tag !== 24) {
|
|
1913
|
+
break;
|
|
1914
|
+
}
|
|
1915
|
+
message.repostsCount = longToNumber(reader.int64());
|
|
1916
|
+
continue;
|
|
1917
|
+
}
|
|
1918
|
+
case 4: {
|
|
1919
|
+
if (tag !== 32) {
|
|
1920
|
+
break;
|
|
1921
|
+
}
|
|
1922
|
+
message.bookmarksCount = longToNumber(reader.int64());
|
|
1923
|
+
continue;
|
|
1924
|
+
}
|
|
1925
|
+
case 5: {
|
|
1926
|
+
if (tag !== 40) {
|
|
1927
|
+
break;
|
|
1928
|
+
}
|
|
1929
|
+
message.signaturesCount = longToNumber(reader.int64());
|
|
1930
|
+
continue;
|
|
1931
|
+
}
|
|
1932
|
+
case 6: {
|
|
1933
|
+
if (tag !== 48) {
|
|
1934
|
+
break;
|
|
1935
|
+
}
|
|
1936
|
+
message.approvalsCount = longToNumber(reader.int64());
|
|
1937
|
+
continue;
|
|
1938
|
+
}
|
|
1939
|
+
}
|
|
1940
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
1941
|
+
break;
|
|
1942
|
+
}
|
|
1943
|
+
reader.skip(tag & 7);
|
|
1944
|
+
}
|
|
1945
|
+
return message;
|
|
1946
|
+
},
|
|
1947
|
+
fromJSON(object) {
|
|
1948
|
+
return {
|
|
1949
|
+
likesCount: isSet(object.likesCount) ? globalThis.Number(object.likesCount) : 0,
|
|
1950
|
+
commentsCount: isSet(object.commentsCount) ? globalThis.Number(object.commentsCount) : 0,
|
|
1951
|
+
repostsCount: isSet(object.repostsCount) ? globalThis.Number(object.repostsCount) : 0,
|
|
1952
|
+
bookmarksCount: isSet(object.bookmarksCount) ? globalThis.Number(object.bookmarksCount) : 0,
|
|
1953
|
+
signaturesCount: isSet(object.signaturesCount) ? globalThis.Number(object.signaturesCount) : undefined,
|
|
1954
|
+
approvalsCount: isSet(object.approvalsCount) ? globalThis.Number(object.approvalsCount) : undefined,
|
|
1955
|
+
};
|
|
1956
|
+
},
|
|
1957
|
+
toJSON(message) {
|
|
1958
|
+
const obj = {};
|
|
1959
|
+
if (message.likesCount !== 0) {
|
|
1960
|
+
obj.likesCount = Math.round(message.likesCount);
|
|
1961
|
+
}
|
|
1962
|
+
if (message.commentsCount !== 0) {
|
|
1963
|
+
obj.commentsCount = Math.round(message.commentsCount);
|
|
1964
|
+
}
|
|
1965
|
+
if (message.repostsCount !== 0) {
|
|
1966
|
+
obj.repostsCount = Math.round(message.repostsCount);
|
|
1967
|
+
}
|
|
1968
|
+
if (message.bookmarksCount !== 0) {
|
|
1969
|
+
obj.bookmarksCount = Math.round(message.bookmarksCount);
|
|
1970
|
+
}
|
|
1971
|
+
if (message.signaturesCount !== undefined) {
|
|
1972
|
+
obj.signaturesCount = Math.round(message.signaturesCount);
|
|
1973
|
+
}
|
|
1974
|
+
if (message.approvalsCount !== undefined) {
|
|
1975
|
+
obj.approvalsCount = Math.round(message.approvalsCount);
|
|
1976
|
+
}
|
|
1977
|
+
return obj;
|
|
1978
|
+
},
|
|
1979
|
+
create(base) {
|
|
1980
|
+
return exports.PostEngagement.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
1981
|
+
},
|
|
1982
|
+
fromPartial(object) {
|
|
1983
|
+
var _a, _b, _c, _d, _e, _f;
|
|
1984
|
+
const message = createBasePostEngagement();
|
|
1985
|
+
message.likesCount = (_a = object.likesCount) !== null && _a !== void 0 ? _a : 0;
|
|
1986
|
+
message.commentsCount = (_b = object.commentsCount) !== null && _b !== void 0 ? _b : 0;
|
|
1987
|
+
message.repostsCount = (_c = object.repostsCount) !== null && _c !== void 0 ? _c : 0;
|
|
1988
|
+
message.bookmarksCount = (_d = object.bookmarksCount) !== null && _d !== void 0 ? _d : 0;
|
|
1989
|
+
message.signaturesCount = (_e = object.signaturesCount) !== null && _e !== void 0 ? _e : undefined;
|
|
1990
|
+
message.approvalsCount = (_f = object.approvalsCount) !== null && _f !== void 0 ? _f : undefined;
|
|
1991
|
+
return message;
|
|
1992
|
+
},
|
|
1993
|
+
};
|
|
1994
|
+
function createBasePostUserStatus() {
|
|
1995
|
+
return { isLiked: false, isBookmarked: false, isReposted: false, isSigned: undefined, isApproved: undefined };
|
|
1996
|
+
}
|
|
1997
|
+
exports.PostUserStatus = {
|
|
1998
|
+
encode(message, writer = new wire_1.BinaryWriter()) {
|
|
1999
|
+
if (message.isLiked !== false) {
|
|
2000
|
+
writer.uint32(8).bool(message.isLiked);
|
|
2001
|
+
}
|
|
2002
|
+
if (message.isBookmarked !== false) {
|
|
2003
|
+
writer.uint32(16).bool(message.isBookmarked);
|
|
2004
|
+
}
|
|
2005
|
+
if (message.isReposted !== false) {
|
|
2006
|
+
writer.uint32(24).bool(message.isReposted);
|
|
2007
|
+
}
|
|
2008
|
+
if (message.isSigned !== undefined) {
|
|
2009
|
+
writer.uint32(32).bool(message.isSigned);
|
|
2010
|
+
}
|
|
2011
|
+
if (message.isApproved !== undefined) {
|
|
2012
|
+
writer.uint32(40).bool(message.isApproved);
|
|
2013
|
+
}
|
|
2014
|
+
return writer;
|
|
2015
|
+
},
|
|
2016
|
+
decode(input, length) {
|
|
2017
|
+
const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
|
|
2018
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
|
2019
|
+
const message = createBasePostUserStatus();
|
|
2020
|
+
while (reader.pos < end) {
|
|
2021
|
+
const tag = reader.uint32();
|
|
2022
|
+
switch (tag >>> 3) {
|
|
2023
|
+
case 1: {
|
|
2024
|
+
if (tag !== 8) {
|
|
2025
|
+
break;
|
|
2026
|
+
}
|
|
2027
|
+
message.isLiked = reader.bool();
|
|
2028
|
+
continue;
|
|
2029
|
+
}
|
|
2030
|
+
case 2: {
|
|
2031
|
+
if (tag !== 16) {
|
|
2032
|
+
break;
|
|
2033
|
+
}
|
|
2034
|
+
message.isBookmarked = reader.bool();
|
|
2035
|
+
continue;
|
|
2036
|
+
}
|
|
2037
|
+
case 3: {
|
|
2038
|
+
if (tag !== 24) {
|
|
2039
|
+
break;
|
|
2040
|
+
}
|
|
2041
|
+
message.isReposted = reader.bool();
|
|
2042
|
+
continue;
|
|
2043
|
+
}
|
|
2044
|
+
case 4: {
|
|
2045
|
+
if (tag !== 32) {
|
|
2046
|
+
break;
|
|
2047
|
+
}
|
|
2048
|
+
message.isSigned = reader.bool();
|
|
2049
|
+
continue;
|
|
2050
|
+
}
|
|
2051
|
+
case 5: {
|
|
2052
|
+
if (tag !== 40) {
|
|
2053
|
+
break;
|
|
2054
|
+
}
|
|
2055
|
+
message.isApproved = reader.bool();
|
|
2056
|
+
continue;
|
|
2057
|
+
}
|
|
2058
|
+
}
|
|
2059
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
2060
|
+
break;
|
|
2061
|
+
}
|
|
2062
|
+
reader.skip(tag & 7);
|
|
2063
|
+
}
|
|
2064
|
+
return message;
|
|
2065
|
+
},
|
|
2066
|
+
fromJSON(object) {
|
|
2067
|
+
return {
|
|
2068
|
+
isLiked: isSet(object.isLiked) ? globalThis.Boolean(object.isLiked) : false,
|
|
2069
|
+
isBookmarked: isSet(object.isBookmarked) ? globalThis.Boolean(object.isBookmarked) : false,
|
|
2070
|
+
isReposted: isSet(object.isReposted) ? globalThis.Boolean(object.isReposted) : false,
|
|
2071
|
+
isSigned: isSet(object.isSigned) ? globalThis.Boolean(object.isSigned) : undefined,
|
|
2072
|
+
isApproved: isSet(object.isApproved) ? globalThis.Boolean(object.isApproved) : undefined,
|
|
2073
|
+
};
|
|
2074
|
+
},
|
|
2075
|
+
toJSON(message) {
|
|
2076
|
+
const obj = {};
|
|
2077
|
+
if (message.isLiked !== false) {
|
|
2078
|
+
obj.isLiked = message.isLiked;
|
|
2079
|
+
}
|
|
2080
|
+
if (message.isBookmarked !== false) {
|
|
2081
|
+
obj.isBookmarked = message.isBookmarked;
|
|
2082
|
+
}
|
|
2083
|
+
if (message.isReposted !== false) {
|
|
2084
|
+
obj.isReposted = message.isReposted;
|
|
2085
|
+
}
|
|
2086
|
+
if (message.isSigned !== undefined) {
|
|
2087
|
+
obj.isSigned = message.isSigned;
|
|
2088
|
+
}
|
|
2089
|
+
if (message.isApproved !== undefined) {
|
|
2090
|
+
obj.isApproved = message.isApproved;
|
|
2091
|
+
}
|
|
2092
|
+
return obj;
|
|
2093
|
+
},
|
|
2094
|
+
create(base) {
|
|
2095
|
+
return exports.PostUserStatus.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
2096
|
+
},
|
|
2097
|
+
fromPartial(object) {
|
|
2098
|
+
var _a, _b, _c, _d, _e;
|
|
2099
|
+
const message = createBasePostUserStatus();
|
|
2100
|
+
message.isLiked = (_a = object.isLiked) !== null && _a !== void 0 ? _a : false;
|
|
2101
|
+
message.isBookmarked = (_b = object.isBookmarked) !== null && _b !== void 0 ? _b : false;
|
|
2102
|
+
message.isReposted = (_c = object.isReposted) !== null && _c !== void 0 ? _c : false;
|
|
2103
|
+
message.isSigned = (_d = object.isSigned) !== null && _d !== void 0 ? _d : undefined;
|
|
2104
|
+
message.isApproved = (_e = object.isApproved) !== null && _e !== void 0 ? _e : undefined;
|
|
2105
|
+
return message;
|
|
2106
|
+
},
|
|
2107
|
+
};
|
|
2108
|
+
exports.PostServiceDefinition = {
|
|
2109
|
+
name: "PostService",
|
|
2110
|
+
fullName: "pb.PostService",
|
|
2111
|
+
methods: {
|
|
2112
|
+
createPost: {
|
|
2113
|
+
name: "CreatePost",
|
|
2114
|
+
requestType: exports.CreatePostRequest,
|
|
2115
|
+
requestStream: false,
|
|
2116
|
+
responseType: exports.CreatePostResponse,
|
|
2117
|
+
responseStream: false,
|
|
2118
|
+
options: {
|
|
2119
|
+
_unknownFields: {
|
|
2120
|
+
578365826: [
|
|
2121
|
+
new Uint8Array([18, 34, 13, 47, 97, 112, 105, 47, 118, 49, 47, 112, 111, 115, 116, 115, 58, 1, 42]),
|
|
2122
|
+
],
|
|
2123
|
+
},
|
|
2124
|
+
},
|
|
2125
|
+
},
|
|
2126
|
+
getPost: {
|
|
2127
|
+
name: "GetPost",
|
|
2128
|
+
requestType: common_1.GetIDRequest,
|
|
2129
|
+
requestStream: false,
|
|
2130
|
+
responseType: exports.GetPostResponse,
|
|
2131
|
+
responseStream: false,
|
|
2132
|
+
options: {
|
|
2133
|
+
_unknownFields: {
|
|
2134
|
+
578365826: [
|
|
2135
|
+
new Uint8Array([
|
|
2136
|
+
20,
|
|
2137
|
+
18,
|
|
2138
|
+
18,
|
|
2139
|
+
47,
|
|
2140
|
+
97,
|
|
2141
|
+
112,
|
|
2142
|
+
105,
|
|
2143
|
+
47,
|
|
2144
|
+
118,
|
|
2145
|
+
49,
|
|
2146
|
+
47,
|
|
2147
|
+
112,
|
|
2148
|
+
111,
|
|
2149
|
+
115,
|
|
2150
|
+
116,
|
|
2151
|
+
115,
|
|
2152
|
+
47,
|
|
2153
|
+
123,
|
|
2154
|
+
105,
|
|
2155
|
+
100,
|
|
2156
|
+
125,
|
|
2157
|
+
]),
|
|
2158
|
+
],
|
|
2159
|
+
},
|
|
2160
|
+
},
|
|
2161
|
+
},
|
|
2162
|
+
listPosts: {
|
|
2163
|
+
name: "ListPosts",
|
|
2164
|
+
requestType: exports.ListPostsRequest,
|
|
2165
|
+
requestStream: false,
|
|
2166
|
+
responseType: exports.ListPostsResponse,
|
|
2167
|
+
responseStream: false,
|
|
2168
|
+
options: {
|
|
2169
|
+
_unknownFields: {
|
|
2170
|
+
578365826: [new Uint8Array([15, 18, 13, 47, 97, 112, 105, 47, 118, 49, 47, 112, 111, 115, 116, 115])],
|
|
2171
|
+
},
|
|
2172
|
+
},
|
|
2173
|
+
},
|
|
2174
|
+
updatePost: {
|
|
2175
|
+
name: "UpdatePost",
|
|
2176
|
+
requestType: exports.UpdatePostRequest,
|
|
2177
|
+
requestStream: false,
|
|
2178
|
+
responseType: exports.UpdatePostResponse,
|
|
2179
|
+
responseStream: false,
|
|
2180
|
+
options: {
|
|
2181
|
+
_unknownFields: {
|
|
2182
|
+
578365826: [
|
|
2183
|
+
new Uint8Array([
|
|
2184
|
+
23,
|
|
2185
|
+
26,
|
|
2186
|
+
18,
|
|
2187
|
+
47,
|
|
2188
|
+
97,
|
|
2189
|
+
112,
|
|
2190
|
+
105,
|
|
2191
|
+
47,
|
|
2192
|
+
118,
|
|
2193
|
+
49,
|
|
2194
|
+
47,
|
|
2195
|
+
112,
|
|
2196
|
+
111,
|
|
2197
|
+
115,
|
|
2198
|
+
116,
|
|
2199
|
+
115,
|
|
2200
|
+
47,
|
|
2201
|
+
123,
|
|
2202
|
+
105,
|
|
2203
|
+
100,
|
|
2204
|
+
125,
|
|
2205
|
+
58,
|
|
2206
|
+
1,
|
|
2207
|
+
42,
|
|
2208
|
+
]),
|
|
2209
|
+
],
|
|
2210
|
+
},
|
|
2211
|
+
},
|
|
2212
|
+
},
|
|
2213
|
+
deletePost: {
|
|
2214
|
+
name: "DeletePost",
|
|
2215
|
+
requestType: common_1.GetIDRequest,
|
|
2216
|
+
requestStream: false,
|
|
2217
|
+
responseType: common_1.DeleteResponse,
|
|
2218
|
+
responseStream: false,
|
|
2219
|
+
options: {
|
|
2220
|
+
_unknownFields: {
|
|
2221
|
+
578365826: [
|
|
2222
|
+
new Uint8Array([
|
|
2223
|
+
20,
|
|
2224
|
+
42,
|
|
2225
|
+
18,
|
|
2226
|
+
47,
|
|
2227
|
+
97,
|
|
2228
|
+
112,
|
|
2229
|
+
105,
|
|
2230
|
+
47,
|
|
2231
|
+
118,
|
|
2232
|
+
49,
|
|
2233
|
+
47,
|
|
2234
|
+
112,
|
|
2235
|
+
111,
|
|
2236
|
+
115,
|
|
2237
|
+
116,
|
|
2238
|
+
115,
|
|
2239
|
+
47,
|
|
2240
|
+
123,
|
|
2241
|
+
105,
|
|
2242
|
+
100,
|
|
2243
|
+
125,
|
|
2244
|
+
]),
|
|
2245
|
+
],
|
|
2246
|
+
},
|
|
2247
|
+
},
|
|
2248
|
+
},
|
|
2249
|
+
likePost: {
|
|
2250
|
+
name: "LikePost",
|
|
2251
|
+
requestType: exports.LikePostRequest,
|
|
2252
|
+
requestStream: false,
|
|
2253
|
+
responseType: exports.LikePostResponse,
|
|
2254
|
+
responseStream: false,
|
|
2255
|
+
options: {
|
|
2256
|
+
_unknownFields: {
|
|
2257
|
+
578365826: [
|
|
2258
|
+
new Uint8Array([
|
|
2259
|
+
32,
|
|
2260
|
+
34,
|
|
2261
|
+
27,
|
|
2262
|
+
47,
|
|
2263
|
+
97,
|
|
2264
|
+
112,
|
|
2265
|
+
105,
|
|
2266
|
+
47,
|
|
2267
|
+
118,
|
|
2268
|
+
49,
|
|
2269
|
+
47,
|
|
2270
|
+
112,
|
|
2271
|
+
111,
|
|
2272
|
+
115,
|
|
2273
|
+
116,
|
|
2274
|
+
115,
|
|
2275
|
+
47,
|
|
2276
|
+
123,
|
|
2277
|
+
112,
|
|
2278
|
+
111,
|
|
2279
|
+
115,
|
|
2280
|
+
116,
|
|
2281
|
+
73,
|
|
2282
|
+
100,
|
|
2283
|
+
125,
|
|
2284
|
+
47,
|
|
2285
|
+
108,
|
|
2286
|
+
105,
|
|
2287
|
+
107,
|
|
2288
|
+
101,
|
|
2289
|
+
58,
|
|
2290
|
+
1,
|
|
2291
|
+
42,
|
|
2292
|
+
]),
|
|
2293
|
+
],
|
|
2294
|
+
},
|
|
2295
|
+
},
|
|
2296
|
+
},
|
|
2297
|
+
unlikePost: {
|
|
2298
|
+
name: "UnlikePost",
|
|
2299
|
+
requestType: exports.UnlikePostRequest,
|
|
2300
|
+
requestStream: false,
|
|
2301
|
+
responseType: common_1.DeleteResponse,
|
|
2302
|
+
responseStream: false,
|
|
2303
|
+
options: {
|
|
2304
|
+
_unknownFields: {
|
|
2305
|
+
578365826: [
|
|
2306
|
+
new Uint8Array([
|
|
2307
|
+
29,
|
|
2308
|
+
42,
|
|
2309
|
+
27,
|
|
2310
|
+
47,
|
|
2311
|
+
97,
|
|
2312
|
+
112,
|
|
2313
|
+
105,
|
|
2314
|
+
47,
|
|
2315
|
+
118,
|
|
2316
|
+
49,
|
|
2317
|
+
47,
|
|
2318
|
+
112,
|
|
2319
|
+
111,
|
|
2320
|
+
115,
|
|
2321
|
+
116,
|
|
2322
|
+
115,
|
|
2323
|
+
47,
|
|
2324
|
+
123,
|
|
2325
|
+
112,
|
|
2326
|
+
111,
|
|
2327
|
+
115,
|
|
2328
|
+
116,
|
|
2329
|
+
73,
|
|
2330
|
+
100,
|
|
2331
|
+
125,
|
|
2332
|
+
47,
|
|
2333
|
+
108,
|
|
2334
|
+
105,
|
|
2335
|
+
107,
|
|
2336
|
+
101,
|
|
2337
|
+
]),
|
|
2338
|
+
],
|
|
2339
|
+
},
|
|
2340
|
+
},
|
|
2341
|
+
},
|
|
2342
|
+
bookmarkPost: {
|
|
2343
|
+
name: "BookmarkPost",
|
|
2344
|
+
requestType: exports.BookmarkPostRequest,
|
|
2345
|
+
requestStream: false,
|
|
2346
|
+
responseType: exports.BookmarkPostResponse,
|
|
2347
|
+
responseStream: false,
|
|
2348
|
+
options: {
|
|
2349
|
+
_unknownFields: {
|
|
2350
|
+
578365826: [
|
|
2351
|
+
new Uint8Array([
|
|
2352
|
+
36,
|
|
2353
|
+
34,
|
|
2354
|
+
31,
|
|
2355
|
+
47,
|
|
2356
|
+
97,
|
|
2357
|
+
112,
|
|
2358
|
+
105,
|
|
2359
|
+
47,
|
|
2360
|
+
118,
|
|
2361
|
+
49,
|
|
2362
|
+
47,
|
|
2363
|
+
112,
|
|
2364
|
+
111,
|
|
2365
|
+
115,
|
|
2366
|
+
116,
|
|
2367
|
+
115,
|
|
2368
|
+
47,
|
|
2369
|
+
123,
|
|
2370
|
+
112,
|
|
2371
|
+
111,
|
|
2372
|
+
115,
|
|
2373
|
+
116,
|
|
2374
|
+
73,
|
|
2375
|
+
100,
|
|
2376
|
+
125,
|
|
2377
|
+
47,
|
|
2378
|
+
98,
|
|
2379
|
+
111,
|
|
2380
|
+
111,
|
|
2381
|
+
107,
|
|
2382
|
+
109,
|
|
2383
|
+
97,
|
|
2384
|
+
114,
|
|
2385
|
+
107,
|
|
2386
|
+
58,
|
|
2387
|
+
1,
|
|
2388
|
+
42,
|
|
2389
|
+
]),
|
|
2390
|
+
],
|
|
2391
|
+
},
|
|
2392
|
+
},
|
|
2393
|
+
},
|
|
2394
|
+
unbookmarkPost: {
|
|
2395
|
+
name: "UnbookmarkPost",
|
|
2396
|
+
requestType: exports.UnbookmarkPostRequest,
|
|
2397
|
+
requestStream: false,
|
|
2398
|
+
responseType: common_1.DeleteResponse,
|
|
2399
|
+
responseStream: false,
|
|
2400
|
+
options: {
|
|
2401
|
+
_unknownFields: {
|
|
2402
|
+
578365826: [
|
|
2403
|
+
new Uint8Array([
|
|
2404
|
+
33,
|
|
2405
|
+
42,
|
|
2406
|
+
31,
|
|
2407
|
+
47,
|
|
2408
|
+
97,
|
|
2409
|
+
112,
|
|
2410
|
+
105,
|
|
2411
|
+
47,
|
|
2412
|
+
118,
|
|
2413
|
+
49,
|
|
2414
|
+
47,
|
|
2415
|
+
112,
|
|
2416
|
+
111,
|
|
2417
|
+
115,
|
|
2418
|
+
116,
|
|
2419
|
+
115,
|
|
2420
|
+
47,
|
|
2421
|
+
123,
|
|
2422
|
+
112,
|
|
2423
|
+
111,
|
|
2424
|
+
115,
|
|
2425
|
+
116,
|
|
2426
|
+
73,
|
|
2427
|
+
100,
|
|
2428
|
+
125,
|
|
2429
|
+
47,
|
|
2430
|
+
98,
|
|
2431
|
+
111,
|
|
2432
|
+
111,
|
|
2433
|
+
107,
|
|
2434
|
+
109,
|
|
2435
|
+
97,
|
|
2436
|
+
114,
|
|
2437
|
+
107,
|
|
2438
|
+
]),
|
|
2439
|
+
],
|
|
2440
|
+
},
|
|
2441
|
+
},
|
|
2442
|
+
},
|
|
2443
|
+
repost: {
|
|
2444
|
+
name: "Repost",
|
|
2445
|
+
requestType: exports.RepostRequest,
|
|
2446
|
+
requestStream: false,
|
|
2447
|
+
responseType: exports.RepostResponse,
|
|
2448
|
+
responseStream: false,
|
|
2449
|
+
options: {
|
|
2450
|
+
_unknownFields: {
|
|
2451
|
+
578365826: [
|
|
2452
|
+
new Uint8Array([
|
|
2453
|
+
34,
|
|
2454
|
+
34,
|
|
2455
|
+
29,
|
|
2456
|
+
47,
|
|
2457
|
+
97,
|
|
2458
|
+
112,
|
|
2459
|
+
105,
|
|
2460
|
+
47,
|
|
2461
|
+
118,
|
|
2462
|
+
49,
|
|
2463
|
+
47,
|
|
2464
|
+
112,
|
|
2465
|
+
111,
|
|
2466
|
+
115,
|
|
2467
|
+
116,
|
|
2468
|
+
115,
|
|
2469
|
+
47,
|
|
2470
|
+
123,
|
|
2471
|
+
112,
|
|
2472
|
+
111,
|
|
2473
|
+
115,
|
|
2474
|
+
116,
|
|
2475
|
+
73,
|
|
2476
|
+
100,
|
|
2477
|
+
125,
|
|
2478
|
+
47,
|
|
2479
|
+
114,
|
|
2480
|
+
101,
|
|
2481
|
+
112,
|
|
2482
|
+
111,
|
|
2483
|
+
115,
|
|
2484
|
+
116,
|
|
2485
|
+
58,
|
|
2486
|
+
1,
|
|
2487
|
+
42,
|
|
2488
|
+
]),
|
|
2489
|
+
],
|
|
2490
|
+
},
|
|
2491
|
+
},
|
|
2492
|
+
},
|
|
2493
|
+
unrepost: {
|
|
2494
|
+
name: "Unrepost",
|
|
2495
|
+
requestType: exports.UnrepostRequest,
|
|
2496
|
+
requestStream: false,
|
|
2497
|
+
responseType: common_1.DeleteResponse,
|
|
2498
|
+
responseStream: false,
|
|
2499
|
+
options: {
|
|
2500
|
+
_unknownFields: {
|
|
2501
|
+
578365826: [
|
|
2502
|
+
new Uint8Array([
|
|
2503
|
+
31,
|
|
2504
|
+
42,
|
|
2505
|
+
29,
|
|
2506
|
+
47,
|
|
2507
|
+
97,
|
|
2508
|
+
112,
|
|
2509
|
+
105,
|
|
2510
|
+
47,
|
|
2511
|
+
118,
|
|
2512
|
+
49,
|
|
2513
|
+
47,
|
|
2514
|
+
112,
|
|
2515
|
+
111,
|
|
2516
|
+
115,
|
|
2517
|
+
116,
|
|
2518
|
+
115,
|
|
2519
|
+
47,
|
|
2520
|
+
123,
|
|
2521
|
+
112,
|
|
2522
|
+
111,
|
|
2523
|
+
115,
|
|
2524
|
+
116,
|
|
2525
|
+
73,
|
|
2526
|
+
100,
|
|
2527
|
+
125,
|
|
2528
|
+
47,
|
|
2529
|
+
114,
|
|
2530
|
+
101,
|
|
2531
|
+
112,
|
|
2532
|
+
111,
|
|
2533
|
+
115,
|
|
2534
|
+
116,
|
|
2535
|
+
]),
|
|
2536
|
+
],
|
|
2537
|
+
},
|
|
2538
|
+
},
|
|
2539
|
+
},
|
|
2540
|
+
searchPosts: {
|
|
2541
|
+
name: "SearchPosts",
|
|
2542
|
+
requestType: exports.SearchPostsRequest,
|
|
2543
|
+
requestStream: false,
|
|
2544
|
+
responseType: exports.ListPostsResponse,
|
|
2545
|
+
responseStream: false,
|
|
2546
|
+
options: {
|
|
2547
|
+
_unknownFields: {
|
|
2548
|
+
578365826: [
|
|
2549
|
+
new Uint8Array([
|
|
2550
|
+
22,
|
|
2551
|
+
18,
|
|
2552
|
+
20,
|
|
2553
|
+
47,
|
|
2554
|
+
97,
|
|
2555
|
+
112,
|
|
2556
|
+
105,
|
|
2557
|
+
47,
|
|
2558
|
+
118,
|
|
2559
|
+
49,
|
|
2560
|
+
47,
|
|
2561
|
+
112,
|
|
2562
|
+
111,
|
|
2563
|
+
115,
|
|
2564
|
+
116,
|
|
2565
|
+
115,
|
|
2566
|
+
47,
|
|
2567
|
+
115,
|
|
2568
|
+
101,
|
|
2569
|
+
97,
|
|
2570
|
+
114,
|
|
2571
|
+
99,
|
|
2572
|
+
104,
|
|
2573
|
+
]),
|
|
2574
|
+
],
|
|
2575
|
+
},
|
|
2576
|
+
},
|
|
2577
|
+
},
|
|
2578
|
+
signPetition: {
|
|
2579
|
+
name: "SignPetition",
|
|
2580
|
+
requestType: exports.SignPetitionRequest,
|
|
2581
|
+
requestStream: false,
|
|
2582
|
+
responseType: exports.SignPetitionResponse,
|
|
2583
|
+
responseStream: false,
|
|
2584
|
+
options: {
|
|
2585
|
+
_unknownFields: {
|
|
2586
|
+
578365826: [
|
|
2587
|
+
new Uint8Array([
|
|
2588
|
+
32,
|
|
2589
|
+
34,
|
|
2590
|
+
27,
|
|
2591
|
+
47,
|
|
2592
|
+
97,
|
|
2593
|
+
112,
|
|
2594
|
+
105,
|
|
2595
|
+
47,
|
|
2596
|
+
118,
|
|
2597
|
+
49,
|
|
2598
|
+
47,
|
|
2599
|
+
112,
|
|
2600
|
+
111,
|
|
2601
|
+
115,
|
|
2602
|
+
116,
|
|
2603
|
+
115,
|
|
2604
|
+
47,
|
|
2605
|
+
123,
|
|
2606
|
+
112,
|
|
2607
|
+
111,
|
|
2608
|
+
115,
|
|
2609
|
+
116,
|
|
2610
|
+
73,
|
|
2611
|
+
100,
|
|
2612
|
+
125,
|
|
2613
|
+
47,
|
|
2614
|
+
115,
|
|
2615
|
+
105,
|
|
2616
|
+
103,
|
|
2617
|
+
110,
|
|
2618
|
+
58,
|
|
2619
|
+
1,
|
|
2620
|
+
42,
|
|
2621
|
+
]),
|
|
2622
|
+
],
|
|
2623
|
+
},
|
|
2624
|
+
},
|
|
2625
|
+
},
|
|
2626
|
+
unsignPetition: {
|
|
2627
|
+
name: "UnsignPetition",
|
|
2628
|
+
requestType: exports.UnsignPetitionRequest,
|
|
2629
|
+
requestStream: false,
|
|
2630
|
+
responseType: common_1.DeleteResponse,
|
|
2631
|
+
responseStream: false,
|
|
2632
|
+
options: {
|
|
2633
|
+
_unknownFields: {
|
|
2634
|
+
578365826: [
|
|
2635
|
+
new Uint8Array([
|
|
2636
|
+
29,
|
|
2637
|
+
42,
|
|
2638
|
+
27,
|
|
2639
|
+
47,
|
|
2640
|
+
97,
|
|
2641
|
+
112,
|
|
2642
|
+
105,
|
|
2643
|
+
47,
|
|
2644
|
+
118,
|
|
2645
|
+
49,
|
|
2646
|
+
47,
|
|
2647
|
+
112,
|
|
2648
|
+
111,
|
|
2649
|
+
115,
|
|
2650
|
+
116,
|
|
2651
|
+
115,
|
|
2652
|
+
47,
|
|
2653
|
+
123,
|
|
2654
|
+
112,
|
|
2655
|
+
111,
|
|
2656
|
+
115,
|
|
2657
|
+
116,
|
|
2658
|
+
73,
|
|
2659
|
+
100,
|
|
2660
|
+
125,
|
|
2661
|
+
47,
|
|
2662
|
+
115,
|
|
2663
|
+
105,
|
|
2664
|
+
103,
|
|
2665
|
+
110,
|
|
2666
|
+
]),
|
|
2667
|
+
],
|
|
2668
|
+
},
|
|
2669
|
+
},
|
|
2670
|
+
},
|
|
2671
|
+
approveEyewitnessReport: {
|
|
2672
|
+
name: "ApproveEyewitnessReport",
|
|
2673
|
+
requestType: exports.ApproveEyewitnessReportRequest,
|
|
2674
|
+
requestStream: false,
|
|
2675
|
+
responseType: exports.ApproveEyewitnessReportResponse,
|
|
2676
|
+
responseStream: false,
|
|
2677
|
+
options: {
|
|
2678
|
+
_unknownFields: {
|
|
2679
|
+
578365826: [
|
|
2680
|
+
new Uint8Array([
|
|
2681
|
+
35,
|
|
2682
|
+
34,
|
|
2683
|
+
30,
|
|
2684
|
+
47,
|
|
2685
|
+
97,
|
|
2686
|
+
112,
|
|
2687
|
+
105,
|
|
2688
|
+
47,
|
|
2689
|
+
118,
|
|
2690
|
+
49,
|
|
2691
|
+
47,
|
|
2692
|
+
112,
|
|
2693
|
+
111,
|
|
2694
|
+
115,
|
|
2695
|
+
116,
|
|
2696
|
+
115,
|
|
2697
|
+
47,
|
|
2698
|
+
123,
|
|
2699
|
+
112,
|
|
2700
|
+
111,
|
|
2701
|
+
115,
|
|
2702
|
+
116,
|
|
2703
|
+
73,
|
|
2704
|
+
100,
|
|
2705
|
+
125,
|
|
2706
|
+
47,
|
|
2707
|
+
97,
|
|
2708
|
+
112,
|
|
2709
|
+
112,
|
|
2710
|
+
114,
|
|
2711
|
+
111,
|
|
2712
|
+
118,
|
|
2713
|
+
101,
|
|
2714
|
+
58,
|
|
2715
|
+
1,
|
|
2716
|
+
42,
|
|
2717
|
+
]),
|
|
2718
|
+
],
|
|
2719
|
+
},
|
|
2720
|
+
},
|
|
2721
|
+
},
|
|
2722
|
+
unapproveEyewitnessReport: {
|
|
2723
|
+
name: "UnapproveEyewitnessReport",
|
|
2724
|
+
requestType: exports.UnapproveEyewitnessReportRequest,
|
|
2725
|
+
requestStream: false,
|
|
2726
|
+
responseType: common_1.DeleteResponse,
|
|
2727
|
+
responseStream: false,
|
|
2728
|
+
options: {
|
|
2729
|
+
_unknownFields: {
|
|
2730
|
+
578365826: [
|
|
2731
|
+
new Uint8Array([
|
|
2732
|
+
32,
|
|
2733
|
+
42,
|
|
2734
|
+
30,
|
|
2735
|
+
47,
|
|
2736
|
+
97,
|
|
2737
|
+
112,
|
|
2738
|
+
105,
|
|
2739
|
+
47,
|
|
2740
|
+
118,
|
|
2741
|
+
49,
|
|
2742
|
+
47,
|
|
2743
|
+
112,
|
|
2744
|
+
111,
|
|
2745
|
+
115,
|
|
2746
|
+
116,
|
|
2747
|
+
115,
|
|
2748
|
+
47,
|
|
2749
|
+
123,
|
|
2750
|
+
112,
|
|
2751
|
+
111,
|
|
2752
|
+
115,
|
|
2753
|
+
116,
|
|
2754
|
+
73,
|
|
2755
|
+
100,
|
|
2756
|
+
125,
|
|
2757
|
+
47,
|
|
2758
|
+
97,
|
|
2759
|
+
112,
|
|
2760
|
+
112,
|
|
2761
|
+
114,
|
|
2762
|
+
111,
|
|
2763
|
+
118,
|
|
2764
|
+
101,
|
|
2765
|
+
]),
|
|
2766
|
+
],
|
|
2767
|
+
},
|
|
2768
|
+
},
|
|
2769
|
+
},
|
|
2770
|
+
},
|
|
2771
|
+
};
|
|
2772
|
+
function longToNumber(int64) {
|
|
2773
|
+
const num = globalThis.Number(int64.toString());
|
|
2774
|
+
if (num > globalThis.Number.MAX_SAFE_INTEGER) {
|
|
2775
|
+
throw new globalThis.Error("Value is larger than Number.MAX_SAFE_INTEGER");
|
|
2776
|
+
}
|
|
2777
|
+
if (num < globalThis.Number.MIN_SAFE_INTEGER) {
|
|
2778
|
+
throw new globalThis.Error("Value is smaller than Number.MIN_SAFE_INTEGER");
|
|
2779
|
+
}
|
|
2780
|
+
return num;
|
|
2781
|
+
}
|
|
2782
|
+
function isSet(value) {
|
|
2783
|
+
return value !== null && value !== undefined;
|
|
2784
|
+
}
|