@i4you/proto-files 1.0.5-beta.0 → 1.0.5-beta.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/user/v2/user.js
CHANGED
@@ -1,12 +1,213 @@
|
|
1
1
|
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
2
2
|
// versions:
|
3
|
-
// protoc-gen-ts_proto v2.7.
|
3
|
+
// protoc-gen-ts_proto v2.7.5
|
4
4
|
// protoc unknown
|
5
5
|
// source: user/v2/user.proto
|
6
6
|
/* eslint-disable */
|
7
7
|
import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
|
8
8
|
import { makeGenericClientConstructor, } from "@grpc/grpc-js";
|
9
9
|
export const protobufPackage = "user.v2";
|
10
|
+
function createBasePreferences() {
|
11
|
+
return { ageRange: [], distance: 0, showMe: "", lookingFor: "" };
|
12
|
+
}
|
13
|
+
export const Preferences = {
|
14
|
+
encode(message, writer = new BinaryWriter()) {
|
15
|
+
writer.uint32(10).fork();
|
16
|
+
for (const v of message.ageRange) {
|
17
|
+
writer.int32(v);
|
18
|
+
}
|
19
|
+
writer.join();
|
20
|
+
if (message.distance !== 0) {
|
21
|
+
writer.uint32(16).int32(message.distance);
|
22
|
+
}
|
23
|
+
if (message.showMe !== "") {
|
24
|
+
writer.uint32(26).string(message.showMe);
|
25
|
+
}
|
26
|
+
if (message.lookingFor !== "") {
|
27
|
+
writer.uint32(34).string(message.lookingFor);
|
28
|
+
}
|
29
|
+
return writer;
|
30
|
+
},
|
31
|
+
decode(input, length) {
|
32
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
33
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
34
|
+
const message = createBasePreferences();
|
35
|
+
while (reader.pos < end) {
|
36
|
+
const tag = reader.uint32();
|
37
|
+
switch (tag >>> 3) {
|
38
|
+
case 1: {
|
39
|
+
if (tag === 8) {
|
40
|
+
message.ageRange.push(reader.int32());
|
41
|
+
continue;
|
42
|
+
}
|
43
|
+
if (tag === 10) {
|
44
|
+
const end2 = reader.uint32() + reader.pos;
|
45
|
+
while (reader.pos < end2) {
|
46
|
+
message.ageRange.push(reader.int32());
|
47
|
+
}
|
48
|
+
continue;
|
49
|
+
}
|
50
|
+
break;
|
51
|
+
}
|
52
|
+
case 2: {
|
53
|
+
if (tag !== 16) {
|
54
|
+
break;
|
55
|
+
}
|
56
|
+
message.distance = reader.int32();
|
57
|
+
continue;
|
58
|
+
}
|
59
|
+
case 3: {
|
60
|
+
if (tag !== 26) {
|
61
|
+
break;
|
62
|
+
}
|
63
|
+
message.showMe = reader.string();
|
64
|
+
continue;
|
65
|
+
}
|
66
|
+
case 4: {
|
67
|
+
if (tag !== 34) {
|
68
|
+
break;
|
69
|
+
}
|
70
|
+
message.lookingFor = reader.string();
|
71
|
+
continue;
|
72
|
+
}
|
73
|
+
}
|
74
|
+
if ((tag & 7) === 4 || tag === 0) {
|
75
|
+
break;
|
76
|
+
}
|
77
|
+
reader.skip(tag & 7);
|
78
|
+
}
|
79
|
+
return message;
|
80
|
+
},
|
81
|
+
fromJSON(object) {
|
82
|
+
return {
|
83
|
+
ageRange: globalThis.Array.isArray(object?.ageRange) ? object.ageRange.map((e) => globalThis.Number(e)) : [],
|
84
|
+
distance: isSet(object.distance) ? globalThis.Number(object.distance) : 0,
|
85
|
+
showMe: isSet(object.showMe) ? globalThis.String(object.showMe) : "",
|
86
|
+
lookingFor: isSet(object.lookingFor) ? globalThis.String(object.lookingFor) : "",
|
87
|
+
};
|
88
|
+
},
|
89
|
+
toJSON(message) {
|
90
|
+
const obj = {};
|
91
|
+
if (message.ageRange?.length) {
|
92
|
+
obj.ageRange = message.ageRange.map((e) => Math.round(e));
|
93
|
+
}
|
94
|
+
if (message.distance !== 0) {
|
95
|
+
obj.distance = Math.round(message.distance);
|
96
|
+
}
|
97
|
+
if (message.showMe !== "") {
|
98
|
+
obj.showMe = message.showMe;
|
99
|
+
}
|
100
|
+
if (message.lookingFor !== "") {
|
101
|
+
obj.lookingFor = message.lookingFor;
|
102
|
+
}
|
103
|
+
return obj;
|
104
|
+
},
|
105
|
+
create(base) {
|
106
|
+
return Preferences.fromPartial(base ?? {});
|
107
|
+
},
|
108
|
+
fromPartial(object) {
|
109
|
+
const message = createBasePreferences();
|
110
|
+
message.ageRange = object.ageRange?.map((e) => e) || [];
|
111
|
+
message.distance = object.distance ?? 0;
|
112
|
+
message.showMe = object.showMe ?? "";
|
113
|
+
message.lookingFor = object.lookingFor ?? "";
|
114
|
+
return message;
|
115
|
+
},
|
116
|
+
};
|
117
|
+
function createBaseLocation() {
|
118
|
+
return { type: "", coordinates: [], displayName: "" };
|
119
|
+
}
|
120
|
+
export const Location = {
|
121
|
+
encode(message, writer = new BinaryWriter()) {
|
122
|
+
if (message.type !== "") {
|
123
|
+
writer.uint32(10).string(message.type);
|
124
|
+
}
|
125
|
+
writer.uint32(18).fork();
|
126
|
+
for (const v of message.coordinates) {
|
127
|
+
writer.double(v);
|
128
|
+
}
|
129
|
+
writer.join();
|
130
|
+
if (message.displayName !== "") {
|
131
|
+
writer.uint32(26).string(message.displayName);
|
132
|
+
}
|
133
|
+
return writer;
|
134
|
+
},
|
135
|
+
decode(input, length) {
|
136
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
137
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
138
|
+
const message = createBaseLocation();
|
139
|
+
while (reader.pos < end) {
|
140
|
+
const tag = reader.uint32();
|
141
|
+
switch (tag >>> 3) {
|
142
|
+
case 1: {
|
143
|
+
if (tag !== 10) {
|
144
|
+
break;
|
145
|
+
}
|
146
|
+
message.type = reader.string();
|
147
|
+
continue;
|
148
|
+
}
|
149
|
+
case 2: {
|
150
|
+
if (tag === 17) {
|
151
|
+
message.coordinates.push(reader.double());
|
152
|
+
continue;
|
153
|
+
}
|
154
|
+
if (tag === 18) {
|
155
|
+
const end2 = reader.uint32() + reader.pos;
|
156
|
+
while (reader.pos < end2) {
|
157
|
+
message.coordinates.push(reader.double());
|
158
|
+
}
|
159
|
+
continue;
|
160
|
+
}
|
161
|
+
break;
|
162
|
+
}
|
163
|
+
case 3: {
|
164
|
+
if (tag !== 26) {
|
165
|
+
break;
|
166
|
+
}
|
167
|
+
message.displayName = reader.string();
|
168
|
+
continue;
|
169
|
+
}
|
170
|
+
}
|
171
|
+
if ((tag & 7) === 4 || tag === 0) {
|
172
|
+
break;
|
173
|
+
}
|
174
|
+
reader.skip(tag & 7);
|
175
|
+
}
|
176
|
+
return message;
|
177
|
+
},
|
178
|
+
fromJSON(object) {
|
179
|
+
return {
|
180
|
+
type: isSet(object.type) ? globalThis.String(object.type) : "",
|
181
|
+
coordinates: globalThis.Array.isArray(object?.coordinates)
|
182
|
+
? object.coordinates.map((e) => globalThis.Number(e))
|
183
|
+
: [],
|
184
|
+
displayName: isSet(object.displayName) ? globalThis.String(object.displayName) : "",
|
185
|
+
};
|
186
|
+
},
|
187
|
+
toJSON(message) {
|
188
|
+
const obj = {};
|
189
|
+
if (message.type !== "") {
|
190
|
+
obj.type = message.type;
|
191
|
+
}
|
192
|
+
if (message.coordinates?.length) {
|
193
|
+
obj.coordinates = message.coordinates;
|
194
|
+
}
|
195
|
+
if (message.displayName !== "") {
|
196
|
+
obj.displayName = message.displayName;
|
197
|
+
}
|
198
|
+
return obj;
|
199
|
+
},
|
200
|
+
create(base) {
|
201
|
+
return Location.fromPartial(base ?? {});
|
202
|
+
},
|
203
|
+
fromPartial(object) {
|
204
|
+
const message = createBaseLocation();
|
205
|
+
message.type = object.type ?? "";
|
206
|
+
message.coordinates = object.coordinates?.map((e) => e) || [];
|
207
|
+
message.displayName = object.displayName ?? "";
|
208
|
+
return message;
|
209
|
+
},
|
210
|
+
};
|
10
211
|
function createBaseGetUserByIdRequest() {
|
11
212
|
return { id: "" };
|
12
213
|
}
|
@@ -19,7 +220,7 @@ export const GetUserByIdRequest = {
|
|
19
220
|
},
|
20
221
|
decode(input, length) {
|
21
222
|
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
22
|
-
|
223
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
23
224
|
const message = createBaseGetUserByIdRequest();
|
24
225
|
while (reader.pos < end) {
|
25
226
|
const tag = reader.uint32();
|
@@ -70,7 +271,7 @@ export const GetUserByEmailRequest = {
|
|
70
271
|
},
|
71
272
|
decode(input, length) {
|
72
273
|
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
73
|
-
|
274
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
74
275
|
const message = createBaseGetUserByEmailRequest();
|
75
276
|
while (reader.pos < end) {
|
76
277
|
const tag = reader.uint32();
|
@@ -158,7 +359,7 @@ export const GetUserByIdResponse = {
|
|
158
359
|
writer.uint32(74).string(v);
|
159
360
|
}
|
160
361
|
if (message.preferences !== undefined) {
|
161
|
-
|
362
|
+
Preferences.encode(message.preferences, writer.uint32(82).fork()).join();
|
162
363
|
}
|
163
364
|
if (message.location !== undefined) {
|
164
365
|
GetUserByIdResponse_Location.encode(message.location, writer.uint32(90).fork()).join();
|
@@ -179,7 +380,7 @@ export const GetUserByIdResponse = {
|
|
179
380
|
},
|
180
381
|
decode(input, length) {
|
181
382
|
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
182
|
-
|
383
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
183
384
|
const message = createBaseGetUserByIdResponse();
|
184
385
|
while (reader.pos < end) {
|
185
386
|
const tag = reader.uint32();
|
@@ -251,7 +452,7 @@ export const GetUserByIdResponse = {
|
|
251
452
|
if (tag !== 82) {
|
252
453
|
break;
|
253
454
|
}
|
254
|
-
message.preferences =
|
455
|
+
message.preferences = Preferences.decode(reader, reader.uint32());
|
255
456
|
continue;
|
256
457
|
}
|
257
458
|
case 11: {
|
@@ -310,7 +511,7 @@ export const GetUserByIdResponse = {
|
|
310
511
|
interests: globalThis.Array.isArray(object?.interests)
|
311
512
|
? object.interests.map((e) => globalThis.String(e))
|
312
513
|
: [],
|
313
|
-
preferences: isSet(object.preferences) ?
|
514
|
+
preferences: isSet(object.preferences) ? Preferences.fromJSON(object.preferences) : undefined,
|
314
515
|
location: isSet(object.location) ? GetUserByIdResponse_Location.fromJSON(object.location) : undefined,
|
315
516
|
onboardingCompleted: isSet(object.onboardingCompleted)
|
316
517
|
? globalThis.Boolean(object.onboardingCompleted)
|
@@ -350,7 +551,7 @@ export const GetUserByIdResponse = {
|
|
350
551
|
obj.interests = message.interests;
|
351
552
|
}
|
352
553
|
if (message.preferences !== undefined) {
|
353
|
-
obj.preferences =
|
554
|
+
obj.preferences = Preferences.toJSON(message.preferences);
|
354
555
|
}
|
355
556
|
if (message.location !== undefined) {
|
356
557
|
obj.location = GetUserByIdResponse_Location.toJSON(message.location);
|
@@ -384,7 +585,7 @@ export const GetUserByIdResponse = {
|
|
384
585
|
message.photos = object.photos?.map((e) => e) || [];
|
385
586
|
message.interests = object.interests?.map((e) => e) || [];
|
386
587
|
message.preferences = (object.preferences !== undefined && object.preferences !== null)
|
387
|
-
?
|
588
|
+
? Preferences.fromPartial(object.preferences)
|
388
589
|
: undefined;
|
389
590
|
message.location = (object.location !== undefined && object.location !== null)
|
390
591
|
? GetUserByIdResponse_Location.fromPartial(object.location)
|
@@ -396,164 +597,57 @@ export const GetUserByIdResponse = {
|
|
396
597
|
return message;
|
397
598
|
},
|
398
599
|
};
|
399
|
-
function
|
400
|
-
return {
|
600
|
+
function createBaseGetUserByIdResponse_Location() {
|
601
|
+
return { type: "", coordinates: [], displayName: "" };
|
401
602
|
}
|
402
|
-
export const
|
603
|
+
export const GetUserByIdResponse_Location = {
|
403
604
|
encode(message, writer = new BinaryWriter()) {
|
404
|
-
|
405
|
-
|
406
|
-
writer.int32(v);
|
407
|
-
}
|
408
|
-
writer.join();
|
409
|
-
if (message.distance !== 0) {
|
410
|
-
writer.uint32(16).int32(message.distance);
|
605
|
+
if (message.type !== "") {
|
606
|
+
writer.uint32(10).string(message.type);
|
411
607
|
}
|
412
|
-
|
413
|
-
|
608
|
+
writer.uint32(18).fork();
|
609
|
+
for (const v of message.coordinates) {
|
610
|
+
writer.double(v);
|
414
611
|
}
|
415
|
-
|
416
|
-
|
612
|
+
writer.join();
|
613
|
+
if (message.displayName !== "") {
|
614
|
+
writer.uint32(26).string(message.displayName);
|
417
615
|
}
|
418
616
|
return writer;
|
419
617
|
},
|
420
618
|
decode(input, length) {
|
421
619
|
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
422
|
-
|
423
|
-
const message =
|
620
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
621
|
+
const message = createBaseGetUserByIdResponse_Location();
|
424
622
|
while (reader.pos < end) {
|
425
623
|
const tag = reader.uint32();
|
426
624
|
switch (tag >>> 3) {
|
427
625
|
case 1: {
|
428
|
-
if (tag
|
429
|
-
|
626
|
+
if (tag !== 10) {
|
627
|
+
break;
|
628
|
+
}
|
629
|
+
message.type = reader.string();
|
630
|
+
continue;
|
631
|
+
}
|
632
|
+
case 2: {
|
633
|
+
if (tag === 17) {
|
634
|
+
message.coordinates.push(reader.double());
|
430
635
|
continue;
|
431
636
|
}
|
432
|
-
if (tag ===
|
637
|
+
if (tag === 18) {
|
433
638
|
const end2 = reader.uint32() + reader.pos;
|
434
639
|
while (reader.pos < end2) {
|
435
|
-
message.
|
640
|
+
message.coordinates.push(reader.double());
|
436
641
|
}
|
437
642
|
continue;
|
438
643
|
}
|
439
644
|
break;
|
440
645
|
}
|
441
|
-
case 2: {
|
442
|
-
if (tag !== 16) {
|
443
|
-
break;
|
444
|
-
}
|
445
|
-
message.distance = reader.int32();
|
446
|
-
continue;
|
447
|
-
}
|
448
646
|
case 3: {
|
449
647
|
if (tag !== 26) {
|
450
648
|
break;
|
451
649
|
}
|
452
|
-
message.
|
453
|
-
continue;
|
454
|
-
}
|
455
|
-
case 4: {
|
456
|
-
if (tag !== 34) {
|
457
|
-
break;
|
458
|
-
}
|
459
|
-
message.lookingFor = reader.string();
|
460
|
-
continue;
|
461
|
-
}
|
462
|
-
}
|
463
|
-
if ((tag & 7) === 4 || tag === 0) {
|
464
|
-
break;
|
465
|
-
}
|
466
|
-
reader.skip(tag & 7);
|
467
|
-
}
|
468
|
-
return message;
|
469
|
-
},
|
470
|
-
fromJSON(object) {
|
471
|
-
return {
|
472
|
-
ageRange: globalThis.Array.isArray(object?.ageRange) ? object.ageRange.map((e) => globalThis.Number(e)) : [],
|
473
|
-
distance: isSet(object.distance) ? globalThis.Number(object.distance) : 0,
|
474
|
-
showMe: isSet(object.showMe) ? globalThis.String(object.showMe) : "",
|
475
|
-
lookingFor: isSet(object.lookingFor) ? globalThis.String(object.lookingFor) : "",
|
476
|
-
};
|
477
|
-
},
|
478
|
-
toJSON(message) {
|
479
|
-
const obj = {};
|
480
|
-
if (message.ageRange?.length) {
|
481
|
-
obj.ageRange = message.ageRange.map((e) => Math.round(e));
|
482
|
-
}
|
483
|
-
if (message.distance !== 0) {
|
484
|
-
obj.distance = Math.round(message.distance);
|
485
|
-
}
|
486
|
-
if (message.showMe !== "") {
|
487
|
-
obj.showMe = message.showMe;
|
488
|
-
}
|
489
|
-
if (message.lookingFor !== "") {
|
490
|
-
obj.lookingFor = message.lookingFor;
|
491
|
-
}
|
492
|
-
return obj;
|
493
|
-
},
|
494
|
-
create(base) {
|
495
|
-
return GetUserByIdResponse_Preferences.fromPartial(base ?? {});
|
496
|
-
},
|
497
|
-
fromPartial(object) {
|
498
|
-
const message = createBaseGetUserByIdResponse_Preferences();
|
499
|
-
message.ageRange = object.ageRange?.map((e) => e) || [];
|
500
|
-
message.distance = object.distance ?? 0;
|
501
|
-
message.showMe = object.showMe ?? "";
|
502
|
-
message.lookingFor = object.lookingFor ?? "";
|
503
|
-
return message;
|
504
|
-
},
|
505
|
-
};
|
506
|
-
function createBaseGetUserByIdResponse_Location() {
|
507
|
-
return { type: "", coordinates: [], displayName: "" };
|
508
|
-
}
|
509
|
-
export const GetUserByIdResponse_Location = {
|
510
|
-
encode(message, writer = new BinaryWriter()) {
|
511
|
-
if (message.type !== "") {
|
512
|
-
writer.uint32(10).string(message.type);
|
513
|
-
}
|
514
|
-
writer.uint32(18).fork();
|
515
|
-
for (const v of message.coordinates) {
|
516
|
-
writer.double(v);
|
517
|
-
}
|
518
|
-
writer.join();
|
519
|
-
if (message.displayName !== "") {
|
520
|
-
writer.uint32(26).string(message.displayName);
|
521
|
-
}
|
522
|
-
return writer;
|
523
|
-
},
|
524
|
-
decode(input, length) {
|
525
|
-
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
526
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
527
|
-
const message = createBaseGetUserByIdResponse_Location();
|
528
|
-
while (reader.pos < end) {
|
529
|
-
const tag = reader.uint32();
|
530
|
-
switch (tag >>> 3) {
|
531
|
-
case 1: {
|
532
|
-
if (tag !== 10) {
|
533
|
-
break;
|
534
|
-
}
|
535
|
-
message.type = reader.string();
|
536
|
-
continue;
|
537
|
-
}
|
538
|
-
case 2: {
|
539
|
-
if (tag === 17) {
|
540
|
-
message.coordinates.push(reader.double());
|
541
|
-
continue;
|
542
|
-
}
|
543
|
-
if (tag === 18) {
|
544
|
-
const end2 = reader.uint32() + reader.pos;
|
545
|
-
while (reader.pos < end2) {
|
546
|
-
message.coordinates.push(reader.double());
|
547
|
-
}
|
548
|
-
continue;
|
549
|
-
}
|
550
|
-
break;
|
551
|
-
}
|
552
|
-
case 3: {
|
553
|
-
if (tag !== 26) {
|
554
|
-
break;
|
555
|
-
}
|
556
|
-
message.displayName = reader.string();
|
650
|
+
message.displayName = reader.string();
|
557
651
|
continue;
|
558
652
|
}
|
559
653
|
}
|
@@ -646,10 +740,10 @@ export const GetUserByEmailResponse = {
|
|
646
740
|
writer.uint32(74).string(v);
|
647
741
|
}
|
648
742
|
if (message.preferences !== undefined) {
|
649
|
-
|
743
|
+
Preferences.encode(message.preferences, writer.uint32(82).fork()).join();
|
650
744
|
}
|
651
745
|
if (message.location !== undefined) {
|
652
|
-
|
746
|
+
Location.encode(message.location, writer.uint32(90).fork()).join();
|
653
747
|
}
|
654
748
|
if (message.onboardingCompleted !== false) {
|
655
749
|
writer.uint32(96).bool(message.onboardingCompleted);
|
@@ -667,7 +761,7 @@ export const GetUserByEmailResponse = {
|
|
667
761
|
},
|
668
762
|
decode(input, length) {
|
669
763
|
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
670
|
-
|
764
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
671
765
|
const message = createBaseGetUserByEmailResponse();
|
672
766
|
while (reader.pos < end) {
|
673
767
|
const tag = reader.uint32();
|
@@ -739,14 +833,14 @@ export const GetUserByEmailResponse = {
|
|
739
833
|
if (tag !== 82) {
|
740
834
|
break;
|
741
835
|
}
|
742
|
-
message.preferences =
|
836
|
+
message.preferences = Preferences.decode(reader, reader.uint32());
|
743
837
|
continue;
|
744
838
|
}
|
745
839
|
case 11: {
|
746
840
|
if (tag !== 90) {
|
747
841
|
break;
|
748
842
|
}
|
749
|
-
message.location =
|
843
|
+
message.location = Location.decode(reader, reader.uint32());
|
750
844
|
continue;
|
751
845
|
}
|
752
846
|
case 12: {
|
@@ -798,10 +892,8 @@ export const GetUserByEmailResponse = {
|
|
798
892
|
interests: globalThis.Array.isArray(object?.interests)
|
799
893
|
? object.interests.map((e) => globalThis.String(e))
|
800
894
|
: [],
|
801
|
-
preferences: isSet(object.preferences)
|
802
|
-
|
803
|
-
: undefined,
|
804
|
-
location: isSet(object.location) ? GetUserByEmailResponse_Location.fromJSON(object.location) : undefined,
|
895
|
+
preferences: isSet(object.preferences) ? Preferences.fromJSON(object.preferences) : undefined,
|
896
|
+
location: isSet(object.location) ? Location.fromJSON(object.location) : undefined,
|
805
897
|
onboardingCompleted: isSet(object.onboardingCompleted) ? globalThis.Boolean(object.onboardingCompleted) : false,
|
806
898
|
status: isSet(object.status) ? globalThis.String(object.status) : "",
|
807
899
|
createdAt: isSet(object.createdAt) ? globalThis.String(object.createdAt) : "",
|
@@ -838,10 +930,10 @@ export const GetUserByEmailResponse = {
|
|
838
930
|
obj.interests = message.interests;
|
839
931
|
}
|
840
932
|
if (message.preferences !== undefined) {
|
841
|
-
obj.preferences =
|
933
|
+
obj.preferences = Preferences.toJSON(message.preferences);
|
842
934
|
}
|
843
935
|
if (message.location !== undefined) {
|
844
|
-
obj.location =
|
936
|
+
obj.location = Location.toJSON(message.location);
|
845
937
|
}
|
846
938
|
if (message.onboardingCompleted !== false) {
|
847
939
|
obj.onboardingCompleted = message.onboardingCompleted;
|
@@ -872,10 +964,10 @@ export const GetUserByEmailResponse = {
|
|
872
964
|
message.photos = object.photos?.map((e) => e) || [];
|
873
965
|
message.interests = object.interests?.map((e) => e) || [];
|
874
966
|
message.preferences = (object.preferences !== undefined && object.preferences !== null)
|
875
|
-
?
|
967
|
+
? Preferences.fromPartial(object.preferences)
|
876
968
|
: undefined;
|
877
969
|
message.location = (object.location !== undefined && object.location !== null)
|
878
|
-
?
|
970
|
+
? Location.fromPartial(object.location)
|
879
971
|
: undefined;
|
880
972
|
message.onboardingCompleted = object.onboardingCompleted ?? false;
|
881
973
|
message.status = object.status ?? "";
|
@@ -884,258 +976,48 @@ export const GetUserByEmailResponse = {
|
|
884
976
|
return message;
|
885
977
|
},
|
886
978
|
};
|
887
|
-
function
|
888
|
-
return {
|
979
|
+
function createBaseCreateUserRequest() {
|
980
|
+
return { name: "", email: "", password: "" };
|
889
981
|
}
|
890
|
-
export const
|
982
|
+
export const CreateUserRequest = {
|
891
983
|
encode(message, writer = new BinaryWriter()) {
|
892
|
-
|
893
|
-
|
894
|
-
writer.int32(v);
|
895
|
-
}
|
896
|
-
writer.join();
|
897
|
-
if (message.distance !== 0) {
|
898
|
-
writer.uint32(16).int32(message.distance);
|
984
|
+
if (message.name !== "") {
|
985
|
+
writer.uint32(18).string(message.name);
|
899
986
|
}
|
900
|
-
if (message.
|
901
|
-
writer.uint32(26).string(message.
|
987
|
+
if (message.email !== "") {
|
988
|
+
writer.uint32(26).string(message.email);
|
902
989
|
}
|
903
|
-
if (message.
|
904
|
-
writer.uint32(34).string(message.
|
990
|
+
if (message.password !== "") {
|
991
|
+
writer.uint32(34).string(message.password);
|
905
992
|
}
|
906
993
|
return writer;
|
907
994
|
},
|
908
995
|
decode(input, length) {
|
909
996
|
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
910
|
-
|
911
|
-
const message =
|
997
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
998
|
+
const message = createBaseCreateUserRequest();
|
912
999
|
while (reader.pos < end) {
|
913
1000
|
const tag = reader.uint32();
|
914
1001
|
switch (tag >>> 3) {
|
915
|
-
case 1: {
|
916
|
-
if (tag === 8) {
|
917
|
-
message.ageRange.push(reader.int32());
|
918
|
-
continue;
|
919
|
-
}
|
920
|
-
if (tag === 10) {
|
921
|
-
const end2 = reader.uint32() + reader.pos;
|
922
|
-
while (reader.pos < end2) {
|
923
|
-
message.ageRange.push(reader.int32());
|
924
|
-
}
|
925
|
-
continue;
|
926
|
-
}
|
927
|
-
break;
|
928
|
-
}
|
929
1002
|
case 2: {
|
930
|
-
if (tag !==
|
1003
|
+
if (tag !== 18) {
|
931
1004
|
break;
|
932
1005
|
}
|
933
|
-
message.
|
1006
|
+
message.name = reader.string();
|
934
1007
|
continue;
|
935
1008
|
}
|
936
1009
|
case 3: {
|
937
1010
|
if (tag !== 26) {
|
938
1011
|
break;
|
939
1012
|
}
|
940
|
-
message.
|
1013
|
+
message.email = reader.string();
|
941
1014
|
continue;
|
942
1015
|
}
|
943
1016
|
case 4: {
|
944
1017
|
if (tag !== 34) {
|
945
1018
|
break;
|
946
1019
|
}
|
947
|
-
message.
|
948
|
-
continue;
|
949
|
-
}
|
950
|
-
}
|
951
|
-
if ((tag & 7) === 4 || tag === 0) {
|
952
|
-
break;
|
953
|
-
}
|
954
|
-
reader.skip(tag & 7);
|
955
|
-
}
|
956
|
-
return message;
|
957
|
-
},
|
958
|
-
fromJSON(object) {
|
959
|
-
return {
|
960
|
-
ageRange: globalThis.Array.isArray(object?.ageRange) ? object.ageRange.map((e) => globalThis.Number(e)) : [],
|
961
|
-
distance: isSet(object.distance) ? globalThis.Number(object.distance) : 0,
|
962
|
-
showMe: isSet(object.showMe) ? globalThis.String(object.showMe) : "",
|
963
|
-
lookingFor: isSet(object.lookingFor) ? globalThis.String(object.lookingFor) : "",
|
964
|
-
};
|
965
|
-
},
|
966
|
-
toJSON(message) {
|
967
|
-
const obj = {};
|
968
|
-
if (message.ageRange?.length) {
|
969
|
-
obj.ageRange = message.ageRange.map((e) => Math.round(e));
|
970
|
-
}
|
971
|
-
if (message.distance !== 0) {
|
972
|
-
obj.distance = Math.round(message.distance);
|
973
|
-
}
|
974
|
-
if (message.showMe !== "") {
|
975
|
-
obj.showMe = message.showMe;
|
976
|
-
}
|
977
|
-
if (message.lookingFor !== "") {
|
978
|
-
obj.lookingFor = message.lookingFor;
|
979
|
-
}
|
980
|
-
return obj;
|
981
|
-
},
|
982
|
-
create(base) {
|
983
|
-
return GetUserByEmailResponse_Preferences.fromPartial(base ?? {});
|
984
|
-
},
|
985
|
-
fromPartial(object) {
|
986
|
-
const message = createBaseGetUserByEmailResponse_Preferences();
|
987
|
-
message.ageRange = object.ageRange?.map((e) => e) || [];
|
988
|
-
message.distance = object.distance ?? 0;
|
989
|
-
message.showMe = object.showMe ?? "";
|
990
|
-
message.lookingFor = object.lookingFor ?? "";
|
991
|
-
return message;
|
992
|
-
},
|
993
|
-
};
|
994
|
-
function createBaseGetUserByEmailResponse_Location() {
|
995
|
-
return { type: "", coordinates: [], displayName: "" };
|
996
|
-
}
|
997
|
-
export const GetUserByEmailResponse_Location = {
|
998
|
-
encode(message, writer = new BinaryWriter()) {
|
999
|
-
if (message.type !== "") {
|
1000
|
-
writer.uint32(10).string(message.type);
|
1001
|
-
}
|
1002
|
-
writer.uint32(18).fork();
|
1003
|
-
for (const v of message.coordinates) {
|
1004
|
-
writer.double(v);
|
1005
|
-
}
|
1006
|
-
writer.join();
|
1007
|
-
if (message.displayName !== "") {
|
1008
|
-
writer.uint32(26).string(message.displayName);
|
1009
|
-
}
|
1010
|
-
return writer;
|
1011
|
-
},
|
1012
|
-
decode(input, length) {
|
1013
|
-
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
1014
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
1015
|
-
const message = createBaseGetUserByEmailResponse_Location();
|
1016
|
-
while (reader.pos < end) {
|
1017
|
-
const tag = reader.uint32();
|
1018
|
-
switch (tag >>> 3) {
|
1019
|
-
case 1: {
|
1020
|
-
if (tag !== 10) {
|
1021
|
-
break;
|
1022
|
-
}
|
1023
|
-
message.type = reader.string();
|
1024
|
-
continue;
|
1025
|
-
}
|
1026
|
-
case 2: {
|
1027
|
-
if (tag === 17) {
|
1028
|
-
message.coordinates.push(reader.double());
|
1029
|
-
continue;
|
1030
|
-
}
|
1031
|
-
if (tag === 18) {
|
1032
|
-
const end2 = reader.uint32() + reader.pos;
|
1033
|
-
while (reader.pos < end2) {
|
1034
|
-
message.coordinates.push(reader.double());
|
1035
|
-
}
|
1036
|
-
continue;
|
1037
|
-
}
|
1038
|
-
break;
|
1039
|
-
}
|
1040
|
-
case 3: {
|
1041
|
-
if (tag !== 26) {
|
1042
|
-
break;
|
1043
|
-
}
|
1044
|
-
message.displayName = reader.string();
|
1045
|
-
continue;
|
1046
|
-
}
|
1047
|
-
}
|
1048
|
-
if ((tag & 7) === 4 || tag === 0) {
|
1049
|
-
break;
|
1050
|
-
}
|
1051
|
-
reader.skip(tag & 7);
|
1052
|
-
}
|
1053
|
-
return message;
|
1054
|
-
},
|
1055
|
-
fromJSON(object) {
|
1056
|
-
return {
|
1057
|
-
type: isSet(object.type) ? globalThis.String(object.type) : "",
|
1058
|
-
coordinates: globalThis.Array.isArray(object?.coordinates)
|
1059
|
-
? object.coordinates.map((e) => globalThis.Number(e))
|
1060
|
-
: [],
|
1061
|
-
displayName: isSet(object.displayName) ? globalThis.String(object.displayName) : "",
|
1062
|
-
};
|
1063
|
-
},
|
1064
|
-
toJSON(message) {
|
1065
|
-
const obj = {};
|
1066
|
-
if (message.type !== "") {
|
1067
|
-
obj.type = message.type;
|
1068
|
-
}
|
1069
|
-
if (message.coordinates?.length) {
|
1070
|
-
obj.coordinates = message.coordinates;
|
1071
|
-
}
|
1072
|
-
if (message.displayName !== "") {
|
1073
|
-
obj.displayName = message.displayName;
|
1074
|
-
}
|
1075
|
-
return obj;
|
1076
|
-
},
|
1077
|
-
create(base) {
|
1078
|
-
return GetUserByEmailResponse_Location.fromPartial(base ?? {});
|
1079
|
-
},
|
1080
|
-
fromPartial(object) {
|
1081
|
-
const message = createBaseGetUserByEmailResponse_Location();
|
1082
|
-
message.type = object.type ?? "";
|
1083
|
-
message.coordinates = object.coordinates?.map((e) => e) || [];
|
1084
|
-
message.displayName = object.displayName ?? "";
|
1085
|
-
return message;
|
1086
|
-
},
|
1087
|
-
};
|
1088
|
-
function createBaseLocation() {
|
1089
|
-
return { type: "", coordinates: [], displayName: "" };
|
1090
|
-
}
|
1091
|
-
export const Location = {
|
1092
|
-
encode(message, writer = new BinaryWriter()) {
|
1093
|
-
if (message.type !== "") {
|
1094
|
-
writer.uint32(10).string(message.type);
|
1095
|
-
}
|
1096
|
-
writer.uint32(18).fork();
|
1097
|
-
for (const v of message.coordinates) {
|
1098
|
-
writer.double(v);
|
1099
|
-
}
|
1100
|
-
writer.join();
|
1101
|
-
if (message.displayName !== "") {
|
1102
|
-
writer.uint32(26).string(message.displayName);
|
1103
|
-
}
|
1104
|
-
return writer;
|
1105
|
-
},
|
1106
|
-
decode(input, length) {
|
1107
|
-
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
1108
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
1109
|
-
const message = createBaseLocation();
|
1110
|
-
while (reader.pos < end) {
|
1111
|
-
const tag = reader.uint32();
|
1112
|
-
switch (tag >>> 3) {
|
1113
|
-
case 1: {
|
1114
|
-
if (tag !== 10) {
|
1115
|
-
break;
|
1116
|
-
}
|
1117
|
-
message.type = reader.string();
|
1118
|
-
continue;
|
1119
|
-
}
|
1120
|
-
case 2: {
|
1121
|
-
if (tag === 17) {
|
1122
|
-
message.coordinates.push(reader.double());
|
1123
|
-
continue;
|
1124
|
-
}
|
1125
|
-
if (tag === 18) {
|
1126
|
-
const end2 = reader.uint32() + reader.pos;
|
1127
|
-
while (reader.pos < end2) {
|
1128
|
-
message.coordinates.push(reader.double());
|
1129
|
-
}
|
1130
|
-
continue;
|
1131
|
-
}
|
1132
|
-
break;
|
1133
|
-
}
|
1134
|
-
case 3: {
|
1135
|
-
if (tag !== 26) {
|
1136
|
-
break;
|
1137
|
-
}
|
1138
|
-
message.displayName = reader.string();
|
1020
|
+
message.password = reader.string();
|
1139
1021
|
continue;
|
1140
1022
|
}
|
1141
1023
|
}
|
@@ -1148,38 +1030,36 @@ export const Location = {
|
|
1148
1030
|
},
|
1149
1031
|
fromJSON(object) {
|
1150
1032
|
return {
|
1151
|
-
|
1152
|
-
|
1153
|
-
|
1154
|
-
: [],
|
1155
|
-
displayName: isSet(object.displayName) ? globalThis.String(object.displayName) : "",
|
1033
|
+
name: isSet(object.name) ? globalThis.String(object.name) : "",
|
1034
|
+
email: isSet(object.email) ? globalThis.String(object.email) : "",
|
1035
|
+
password: isSet(object.password) ? globalThis.String(object.password) : "",
|
1156
1036
|
};
|
1157
1037
|
},
|
1158
1038
|
toJSON(message) {
|
1159
1039
|
const obj = {};
|
1160
|
-
if (message.
|
1161
|
-
obj.
|
1040
|
+
if (message.name !== "") {
|
1041
|
+
obj.name = message.name;
|
1162
1042
|
}
|
1163
|
-
if (message.
|
1164
|
-
obj.
|
1043
|
+
if (message.email !== "") {
|
1044
|
+
obj.email = message.email;
|
1165
1045
|
}
|
1166
|
-
if (message.
|
1167
|
-
obj.
|
1046
|
+
if (message.password !== "") {
|
1047
|
+
obj.password = message.password;
|
1168
1048
|
}
|
1169
1049
|
return obj;
|
1170
1050
|
},
|
1171
1051
|
create(base) {
|
1172
|
-
return
|
1052
|
+
return CreateUserRequest.fromPartial(base ?? {});
|
1173
1053
|
},
|
1174
1054
|
fromPartial(object) {
|
1175
|
-
const message =
|
1176
|
-
message.
|
1177
|
-
message.
|
1178
|
-
message.
|
1055
|
+
const message = createBaseCreateUserRequest();
|
1056
|
+
message.name = object.name ?? "";
|
1057
|
+
message.email = object.email ?? "";
|
1058
|
+
message.password = object.password ?? "";
|
1179
1059
|
return message;
|
1180
1060
|
},
|
1181
1061
|
};
|
1182
|
-
function
|
1062
|
+
function createBaseCreateUserResponse() {
|
1183
1063
|
return {
|
1184
1064
|
id: "",
|
1185
1065
|
name: "",
|
@@ -1190,14 +1070,13 @@ function createBaseCreateUserRequest() {
|
|
1190
1070
|
bio: "",
|
1191
1071
|
photos: [],
|
1192
1072
|
interests: [],
|
1193
|
-
location: undefined,
|
1194
1073
|
onboardingCompleted: false,
|
1195
1074
|
status: "",
|
1196
1075
|
createdAt: "",
|
1197
1076
|
updatedAt: "",
|
1198
1077
|
};
|
1199
1078
|
}
|
1200
|
-
export const
|
1079
|
+
export const CreateUserResponse = {
|
1201
1080
|
encode(message, writer = new BinaryWriter()) {
|
1202
1081
|
if (message.id !== "") {
|
1203
1082
|
writer.uint32(10).string(message.id);
|
@@ -1226,9 +1105,6 @@ export const CreateUserRequest = {
|
|
1226
1105
|
for (const v of message.interests) {
|
1227
1106
|
writer.uint32(74).string(v);
|
1228
1107
|
}
|
1229
|
-
if (message.location !== undefined) {
|
1230
|
-
Location.encode(message.location, writer.uint32(90).fork()).join();
|
1231
|
-
}
|
1232
1108
|
if (message.onboardingCompleted !== false) {
|
1233
1109
|
writer.uint32(96).bool(message.onboardingCompleted);
|
1234
1110
|
}
|
@@ -1245,8 +1121,8 @@ export const CreateUserRequest = {
|
|
1245
1121
|
},
|
1246
1122
|
decode(input, length) {
|
1247
1123
|
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
1248
|
-
|
1249
|
-
const message =
|
1124
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
1125
|
+
const message = createBaseCreateUserResponse();
|
1250
1126
|
while (reader.pos < end) {
|
1251
1127
|
const tag = reader.uint32();
|
1252
1128
|
switch (tag >>> 3) {
|
@@ -1313,13 +1189,6 @@ export const CreateUserRequest = {
|
|
1313
1189
|
message.interests.push(reader.string());
|
1314
1190
|
continue;
|
1315
1191
|
}
|
1316
|
-
case 11: {
|
1317
|
-
if (tag !== 90) {
|
1318
|
-
break;
|
1319
|
-
}
|
1320
|
-
message.location = Location.decode(reader, reader.uint32());
|
1321
|
-
continue;
|
1322
|
-
}
|
1323
1192
|
case 12: {
|
1324
1193
|
if (tag !== 96) {
|
1325
1194
|
break;
|
@@ -1369,7 +1238,6 @@ export const CreateUserRequest = {
|
|
1369
1238
|
interests: globalThis.Array.isArray(object?.interests)
|
1370
1239
|
? object.interests.map((e) => globalThis.String(e))
|
1371
1240
|
: [],
|
1372
|
-
location: isSet(object.location) ? Location.fromJSON(object.location) : undefined,
|
1373
1241
|
onboardingCompleted: isSet(object.onboardingCompleted) ? globalThis.Boolean(object.onboardingCompleted) : false,
|
1374
1242
|
status: isSet(object.status) ? globalThis.String(object.status) : "",
|
1375
1243
|
createdAt: isSet(object.createdAt) ? globalThis.String(object.createdAt) : "",
|
@@ -1405,9 +1273,6 @@ export const CreateUserRequest = {
|
|
1405
1273
|
if (message.interests?.length) {
|
1406
1274
|
obj.interests = message.interests;
|
1407
1275
|
}
|
1408
|
-
if (message.location !== undefined) {
|
1409
|
-
obj.location = Location.toJSON(message.location);
|
1410
|
-
}
|
1411
1276
|
if (message.onboardingCompleted !== false) {
|
1412
1277
|
obj.onboardingCompleted = message.onboardingCompleted;
|
1413
1278
|
}
|
@@ -1423,10 +1288,10 @@ export const CreateUserRequest = {
|
|
1423
1288
|
return obj;
|
1424
1289
|
},
|
1425
1290
|
create(base) {
|
1426
|
-
return
|
1291
|
+
return CreateUserResponse.fromPartial(base ?? {});
|
1427
1292
|
},
|
1428
1293
|
fromPartial(object) {
|
1429
|
-
const message =
|
1294
|
+
const message = createBaseCreateUserResponse();
|
1430
1295
|
message.id = object.id ?? "";
|
1431
1296
|
message.name = object.name ?? "";
|
1432
1297
|
message.email = object.email ?? "";
|
@@ -1436,9 +1301,6 @@ export const CreateUserRequest = {
|
|
1436
1301
|
message.bio = object.bio ?? "";
|
1437
1302
|
message.photos = object.photos?.map((e) => e) || [];
|
1438
1303
|
message.interests = object.interests?.map((e) => e) || [];
|
1439
|
-
message.location = (object.location !== undefined && object.location !== null)
|
1440
|
-
? Location.fromPartial(object.location)
|
1441
|
-
: undefined;
|
1442
1304
|
message.onboardingCompleted = object.onboardingCompleted ?? false;
|
1443
1305
|
message.status = object.status ?? "";
|
1444
1306
|
message.createdAt = object.createdAt ?? "";
|
@@ -1446,7 +1308,278 @@ export const CreateUserRequest = {
|
|
1446
1308
|
return message;
|
1447
1309
|
},
|
1448
1310
|
};
|
1449
|
-
function
|
1311
|
+
function createBaseUpdateUserRequest() {
|
1312
|
+
return {
|
1313
|
+
name: undefined,
|
1314
|
+
email: undefined,
|
1315
|
+
password: undefined,
|
1316
|
+
age: undefined,
|
1317
|
+
gender: undefined,
|
1318
|
+
bio: undefined,
|
1319
|
+
photos: [],
|
1320
|
+
interests: [],
|
1321
|
+
preferences: undefined,
|
1322
|
+
location: undefined,
|
1323
|
+
onboardingCompleted: undefined,
|
1324
|
+
status: undefined,
|
1325
|
+
createdAt: undefined,
|
1326
|
+
updatedAt: undefined,
|
1327
|
+
};
|
1328
|
+
}
|
1329
|
+
export const UpdateUserRequest = {
|
1330
|
+
encode(message, writer = new BinaryWriter()) {
|
1331
|
+
if (message.name !== undefined) {
|
1332
|
+
writer.uint32(18).string(message.name);
|
1333
|
+
}
|
1334
|
+
if (message.email !== undefined) {
|
1335
|
+
writer.uint32(26).string(message.email);
|
1336
|
+
}
|
1337
|
+
if (message.password !== undefined) {
|
1338
|
+
writer.uint32(34).string(message.password);
|
1339
|
+
}
|
1340
|
+
if (message.age !== undefined) {
|
1341
|
+
writer.uint32(40).int32(message.age);
|
1342
|
+
}
|
1343
|
+
if (message.gender !== undefined) {
|
1344
|
+
writer.uint32(50).string(message.gender);
|
1345
|
+
}
|
1346
|
+
if (message.bio !== undefined) {
|
1347
|
+
writer.uint32(58).string(message.bio);
|
1348
|
+
}
|
1349
|
+
for (const v of message.photos) {
|
1350
|
+
writer.uint32(66).string(v);
|
1351
|
+
}
|
1352
|
+
for (const v of message.interests) {
|
1353
|
+
writer.uint32(74).string(v);
|
1354
|
+
}
|
1355
|
+
if (message.preferences !== undefined) {
|
1356
|
+
Preferences.encode(message.preferences, writer.uint32(82).fork()).join();
|
1357
|
+
}
|
1358
|
+
if (message.location !== undefined) {
|
1359
|
+
Location.encode(message.location, writer.uint32(90).fork()).join();
|
1360
|
+
}
|
1361
|
+
if (message.onboardingCompleted !== undefined) {
|
1362
|
+
writer.uint32(96).bool(message.onboardingCompleted);
|
1363
|
+
}
|
1364
|
+
if (message.status !== undefined) {
|
1365
|
+
writer.uint32(106).string(message.status);
|
1366
|
+
}
|
1367
|
+
if (message.createdAt !== undefined) {
|
1368
|
+
writer.uint32(114).string(message.createdAt);
|
1369
|
+
}
|
1370
|
+
if (message.updatedAt !== undefined) {
|
1371
|
+
writer.uint32(122).string(message.updatedAt);
|
1372
|
+
}
|
1373
|
+
return writer;
|
1374
|
+
},
|
1375
|
+
decode(input, length) {
|
1376
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
1377
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
1378
|
+
const message = createBaseUpdateUserRequest();
|
1379
|
+
while (reader.pos < end) {
|
1380
|
+
const tag = reader.uint32();
|
1381
|
+
switch (tag >>> 3) {
|
1382
|
+
case 2: {
|
1383
|
+
if (tag !== 18) {
|
1384
|
+
break;
|
1385
|
+
}
|
1386
|
+
message.name = reader.string();
|
1387
|
+
continue;
|
1388
|
+
}
|
1389
|
+
case 3: {
|
1390
|
+
if (tag !== 26) {
|
1391
|
+
break;
|
1392
|
+
}
|
1393
|
+
message.email = reader.string();
|
1394
|
+
continue;
|
1395
|
+
}
|
1396
|
+
case 4: {
|
1397
|
+
if (tag !== 34) {
|
1398
|
+
break;
|
1399
|
+
}
|
1400
|
+
message.password = reader.string();
|
1401
|
+
continue;
|
1402
|
+
}
|
1403
|
+
case 5: {
|
1404
|
+
if (tag !== 40) {
|
1405
|
+
break;
|
1406
|
+
}
|
1407
|
+
message.age = reader.int32();
|
1408
|
+
continue;
|
1409
|
+
}
|
1410
|
+
case 6: {
|
1411
|
+
if (tag !== 50) {
|
1412
|
+
break;
|
1413
|
+
}
|
1414
|
+
message.gender = reader.string();
|
1415
|
+
continue;
|
1416
|
+
}
|
1417
|
+
case 7: {
|
1418
|
+
if (tag !== 58) {
|
1419
|
+
break;
|
1420
|
+
}
|
1421
|
+
message.bio = reader.string();
|
1422
|
+
continue;
|
1423
|
+
}
|
1424
|
+
case 8: {
|
1425
|
+
if (tag !== 66) {
|
1426
|
+
break;
|
1427
|
+
}
|
1428
|
+
message.photos.push(reader.string());
|
1429
|
+
continue;
|
1430
|
+
}
|
1431
|
+
case 9: {
|
1432
|
+
if (tag !== 74) {
|
1433
|
+
break;
|
1434
|
+
}
|
1435
|
+
message.interests.push(reader.string());
|
1436
|
+
continue;
|
1437
|
+
}
|
1438
|
+
case 10: {
|
1439
|
+
if (tag !== 82) {
|
1440
|
+
break;
|
1441
|
+
}
|
1442
|
+
message.preferences = Preferences.decode(reader, reader.uint32());
|
1443
|
+
continue;
|
1444
|
+
}
|
1445
|
+
case 11: {
|
1446
|
+
if (tag !== 90) {
|
1447
|
+
break;
|
1448
|
+
}
|
1449
|
+
message.location = Location.decode(reader, reader.uint32());
|
1450
|
+
continue;
|
1451
|
+
}
|
1452
|
+
case 12: {
|
1453
|
+
if (tag !== 96) {
|
1454
|
+
break;
|
1455
|
+
}
|
1456
|
+
message.onboardingCompleted = reader.bool();
|
1457
|
+
continue;
|
1458
|
+
}
|
1459
|
+
case 13: {
|
1460
|
+
if (tag !== 106) {
|
1461
|
+
break;
|
1462
|
+
}
|
1463
|
+
message.status = reader.string();
|
1464
|
+
continue;
|
1465
|
+
}
|
1466
|
+
case 14: {
|
1467
|
+
if (tag !== 114) {
|
1468
|
+
break;
|
1469
|
+
}
|
1470
|
+
message.createdAt = reader.string();
|
1471
|
+
continue;
|
1472
|
+
}
|
1473
|
+
case 15: {
|
1474
|
+
if (tag !== 122) {
|
1475
|
+
break;
|
1476
|
+
}
|
1477
|
+
message.updatedAt = reader.string();
|
1478
|
+
continue;
|
1479
|
+
}
|
1480
|
+
}
|
1481
|
+
if ((tag & 7) === 4 || tag === 0) {
|
1482
|
+
break;
|
1483
|
+
}
|
1484
|
+
reader.skip(tag & 7);
|
1485
|
+
}
|
1486
|
+
return message;
|
1487
|
+
},
|
1488
|
+
fromJSON(object) {
|
1489
|
+
return {
|
1490
|
+
name: isSet(object.name) ? globalThis.String(object.name) : undefined,
|
1491
|
+
email: isSet(object.email) ? globalThis.String(object.email) : undefined,
|
1492
|
+
password: isSet(object.password) ? globalThis.String(object.password) : undefined,
|
1493
|
+
age: isSet(object.age) ? globalThis.Number(object.age) : undefined,
|
1494
|
+
gender: isSet(object.gender) ? globalThis.String(object.gender) : undefined,
|
1495
|
+
bio: isSet(object.bio) ? globalThis.String(object.bio) : undefined,
|
1496
|
+
photos: globalThis.Array.isArray(object?.photos) ? object.photos.map((e) => globalThis.String(e)) : [],
|
1497
|
+
interests: globalThis.Array.isArray(object?.interests)
|
1498
|
+
? object.interests.map((e) => globalThis.String(e))
|
1499
|
+
: [],
|
1500
|
+
preferences: isSet(object.preferences) ? Preferences.fromJSON(object.preferences) : undefined,
|
1501
|
+
location: isSet(object.location) ? Location.fromJSON(object.location) : undefined,
|
1502
|
+
onboardingCompleted: isSet(object.onboardingCompleted)
|
1503
|
+
? globalThis.Boolean(object.onboardingCompleted)
|
1504
|
+
: undefined,
|
1505
|
+
status: isSet(object.status) ? globalThis.String(object.status) : undefined,
|
1506
|
+
createdAt: isSet(object.createdAt) ? globalThis.String(object.createdAt) : undefined,
|
1507
|
+
updatedAt: isSet(object.updatedAt) ? globalThis.String(object.updatedAt) : undefined,
|
1508
|
+
};
|
1509
|
+
},
|
1510
|
+
toJSON(message) {
|
1511
|
+
const obj = {};
|
1512
|
+
if (message.name !== undefined) {
|
1513
|
+
obj.name = message.name;
|
1514
|
+
}
|
1515
|
+
if (message.email !== undefined) {
|
1516
|
+
obj.email = message.email;
|
1517
|
+
}
|
1518
|
+
if (message.password !== undefined) {
|
1519
|
+
obj.password = message.password;
|
1520
|
+
}
|
1521
|
+
if (message.age !== undefined) {
|
1522
|
+
obj.age = Math.round(message.age);
|
1523
|
+
}
|
1524
|
+
if (message.gender !== undefined) {
|
1525
|
+
obj.gender = message.gender;
|
1526
|
+
}
|
1527
|
+
if (message.bio !== undefined) {
|
1528
|
+
obj.bio = message.bio;
|
1529
|
+
}
|
1530
|
+
if (message.photos?.length) {
|
1531
|
+
obj.photos = message.photos;
|
1532
|
+
}
|
1533
|
+
if (message.interests?.length) {
|
1534
|
+
obj.interests = message.interests;
|
1535
|
+
}
|
1536
|
+
if (message.preferences !== undefined) {
|
1537
|
+
obj.preferences = Preferences.toJSON(message.preferences);
|
1538
|
+
}
|
1539
|
+
if (message.location !== undefined) {
|
1540
|
+
obj.location = Location.toJSON(message.location);
|
1541
|
+
}
|
1542
|
+
if (message.onboardingCompleted !== undefined) {
|
1543
|
+
obj.onboardingCompleted = message.onboardingCompleted;
|
1544
|
+
}
|
1545
|
+
if (message.status !== undefined) {
|
1546
|
+
obj.status = message.status;
|
1547
|
+
}
|
1548
|
+
if (message.createdAt !== undefined) {
|
1549
|
+
obj.createdAt = message.createdAt;
|
1550
|
+
}
|
1551
|
+
if (message.updatedAt !== undefined) {
|
1552
|
+
obj.updatedAt = message.updatedAt;
|
1553
|
+
}
|
1554
|
+
return obj;
|
1555
|
+
},
|
1556
|
+
create(base) {
|
1557
|
+
return UpdateUserRequest.fromPartial(base ?? {});
|
1558
|
+
},
|
1559
|
+
fromPartial(object) {
|
1560
|
+
const message = createBaseUpdateUserRequest();
|
1561
|
+
message.name = object.name ?? undefined;
|
1562
|
+
message.email = object.email ?? undefined;
|
1563
|
+
message.password = object.password ?? undefined;
|
1564
|
+
message.age = object.age ?? undefined;
|
1565
|
+
message.gender = object.gender ?? undefined;
|
1566
|
+
message.bio = object.bio ?? undefined;
|
1567
|
+
message.photos = object.photos?.map((e) => e) || [];
|
1568
|
+
message.interests = object.interests?.map((e) => e) || [];
|
1569
|
+
message.preferences = (object.preferences !== undefined && object.preferences !== null)
|
1570
|
+
? Preferences.fromPartial(object.preferences)
|
1571
|
+
: undefined;
|
1572
|
+
message.location = (object.location !== undefined && object.location !== null)
|
1573
|
+
? Location.fromPartial(object.location)
|
1574
|
+
: undefined;
|
1575
|
+
message.onboardingCompleted = object.onboardingCompleted ?? undefined;
|
1576
|
+
message.status = object.status ?? undefined;
|
1577
|
+
message.createdAt = object.createdAt ?? undefined;
|
1578
|
+
message.updatedAt = object.updatedAt ?? undefined;
|
1579
|
+
return message;
|
1580
|
+
},
|
1581
|
+
};
|
1582
|
+
function createBaseUpdateUserResponse() {
|
1450
1583
|
return {
|
1451
1584
|
id: "",
|
1452
1585
|
name: "",
|
@@ -1463,7 +1596,7 @@ function createBaseCreateUserResponse() {
|
|
1463
1596
|
updatedAt: "",
|
1464
1597
|
};
|
1465
1598
|
}
|
1466
|
-
export const
|
1599
|
+
export const UpdateUserResponse = {
|
1467
1600
|
encode(message, writer = new BinaryWriter()) {
|
1468
1601
|
if (message.id !== "") {
|
1469
1602
|
writer.uint32(10).string(message.id);
|
@@ -1508,8 +1641,8 @@ export const CreateUserResponse = {
|
|
1508
1641
|
},
|
1509
1642
|
decode(input, length) {
|
1510
1643
|
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
1511
|
-
|
1512
|
-
const message =
|
1644
|
+
const end = length === undefined ? reader.len : reader.pos + length;
|
1645
|
+
const message = createBaseUpdateUserResponse();
|
1513
1646
|
while (reader.pos < end) {
|
1514
1647
|
const tag = reader.uint32();
|
1515
1648
|
switch (tag >>> 3) {
|
@@ -1675,10 +1808,10 @@ export const CreateUserResponse = {
|
|
1675
1808
|
return obj;
|
1676
1809
|
},
|
1677
1810
|
create(base) {
|
1678
|
-
return
|
1811
|
+
return UpdateUserResponse.fromPartial(base ?? {});
|
1679
1812
|
},
|
1680
1813
|
fromPartial(object) {
|
1681
|
-
const message =
|
1814
|
+
const message = createBaseUpdateUserResponse();
|
1682
1815
|
message.id = object.id ?? "";
|
1683
1816
|
message.name = object.name ?? "";
|
1684
1817
|
message.email = object.email ?? "";
|
@@ -1723,6 +1856,15 @@ export const UserServiceService = {
|
|
1723
1856
|
responseSerialize: (value) => Buffer.from(CreateUserResponse.encode(value).finish()),
|
1724
1857
|
responseDeserialize: (value) => CreateUserResponse.decode(value),
|
1725
1858
|
},
|
1859
|
+
updateUser: {
|
1860
|
+
path: "/user.v2.UserService/UpdateUser",
|
1861
|
+
requestStream: false,
|
1862
|
+
responseStream: false,
|
1863
|
+
requestSerialize: (value) => Buffer.from(UpdateUserRequest.encode(value).finish()),
|
1864
|
+
requestDeserialize: (value) => UpdateUserRequest.decode(value),
|
1865
|
+
responseSerialize: (value) => Buffer.from(UpdateUserResponse.encode(value).finish()),
|
1866
|
+
responseDeserialize: (value) => UpdateUserResponse.decode(value),
|
1867
|
+
},
|
1726
1868
|
};
|
1727
1869
|
export const UserServiceClient = makeGenericClientConstructor(UserServiceService, "user.v2.UserService");
|
1728
1870
|
function isSet(value) {
|