/
chat_pb.ts
69 lines (60 loc) · 1.67 KB
/
chat_pb.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
// @generated by protoc-gen-es v1.3.0 with parameter "target=ts"
// @generated from file chat.proto (syntax proto3)
/* eslint-disable */
// @ts-nocheck
import type {
BinaryReadOptions,
FieldList,
JsonReadOptions,
JsonValue,
PartialMessage,
PlainMessage,
} from "@bufbuild/protobuf";
import { Message as Message$1, proto3 } from "@bufbuild/protobuf";
/**
* @generated from message Message
*/
export class Message extends Message$1<Message> {
/**
* @generated from field: string author = 1;
*/
author = "";
/**
* @generated from field: string body = 2;
*/
body = "";
constructor(data?: PartialMessage<Message>) {
super();
proto3.util.initPartial(data, this);
}
static readonly runtime: typeof proto3 = proto3;
static readonly typeName = "Message";
static readonly fields: FieldList = proto3.util.newFieldList(() => [
{ no: 1, name: "author", kind: "scalar", T: 9 /* ScalarType.STRING */ },
{ no: 2, name: "body", kind: "scalar", T: 9 /* ScalarType.STRING */ },
]);
static fromBinary(
bytes: Uint8Array,
options?: Partial<BinaryReadOptions>
): Message {
return new Message().fromBinary(bytes, options);
}
static fromJson(
jsonValue: JsonValue,
options?: Partial<JsonReadOptions>
): Message {
return new Message().fromJson(jsonValue, options);
}
static fromJsonString(
jsonString: string,
options?: Partial<JsonReadOptions>
): Message {
return new Message().fromJsonString(jsonString, options);
}
static equals(
a: Message | PlainMessage<Message> | undefined,
b: Message | PlainMessage<Message> | undefined
): boolean {
return proto3.util.equals(Message, a, b);
}
}