@webvpn/dgram 0.0.1 → 0.2.0
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/build/index.cjs +2235 -2327
- package/build/index.cjs.map +1 -1
- package/build/index.d.ts +5 -184
- package/build/index.js +10094 -2664
- package/build/index.js.map +1 -1
- package/package.json +4 -6
- package/src/index.ts +5 -698
- package/vite-plugin-node-stdlib-browser.cjs +61 -61
- package/vite.config.ts +29 -29
- package/build/index.mjs +0 -3252
- package/build/index.mjs.map +0 -1
- package/build/test.d.ts +0 -1
- package/build/utils.d.ts +0 -13
- package/index.html +0 -11
- package/src/chrome-dgram.js +0 -503
- package/src/flatbuffers/client-packet-type.ts +0 -40
- package/src/flatbuffers/client-packet.ts +0 -162
- package/src/flatbuffers/client-tcpserver-close.ts +0 -93
- package/src/flatbuffers/client-tcpserver-get-connections.ts +0 -93
- package/src/flatbuffers/client-tcpserver-listen.ts +0 -211
- package/src/flatbuffers/client-tcpserver.ts +0 -159
- package/src/flatbuffers/client-tcpsocket-connect.ts +0 -253
- package/src/flatbuffers/client-tcpsocket-destroy-soon.ts +0 -75
- package/src/flatbuffers/client-tcpsocket-destroy.ts +0 -93
- package/src/flatbuffers/client-tcpsocket-end.ts +0 -93
- package/src/flatbuffers/client-tcpsocket-pause.ts +0 -75
- package/src/flatbuffers/client-tcpsocket-reset-and-destroy.ts +0 -75
- package/src/flatbuffers/client-tcpsocket-resume.ts +0 -75
- package/src/flatbuffers/client-tcpsocket-set-encoding.ts +0 -93
- package/src/flatbuffers/client-tcpsocket-set-keep-alive.ts +0 -103
- package/src/flatbuffers/client-tcpsocket-set-no-delay.ts +0 -89
- package/src/flatbuffers/client-tcpsocket-set-timeout.ts +0 -107
- package/src/flatbuffers/client-tcpsocket-write.ts +0 -147
- package/src/flatbuffers/client-tcpsocket.ts +0 -89
- package/src/flatbuffers/client-udpsocket-add-membership.ts +0 -110
- package/src/flatbuffers/client-udpsocket-add-source-specific-membership.ts +0 -127
- package/src/flatbuffers/client-udpsocket-bind.ts +0 -138
- package/src/flatbuffers/client-udpsocket-close.ts +0 -93
- package/src/flatbuffers/client-udpsocket-disconnect.ts +0 -75
- package/src/flatbuffers/client-udpsocket-drop-membership.ts +0 -110
- package/src/flatbuffers/client-udpsocket-drop-source-specific-membership.ts +0 -127
- package/src/flatbuffers/client-udpsocket-send.ts +0 -189
- package/src/flatbuffers/client-udpsocket-set-broadcast.ts +0 -89
- package/src/flatbuffers/client-udpsocket-set-multicast-interface.ts +0 -93
- package/src/flatbuffers/client-udpsocket-set-multicast-loopback.ts +0 -89
- package/src/flatbuffers/client-udpsocket-set-multicast-ttl.ts +0 -89
- package/src/flatbuffers/client-udpsocket-set-recv-buffer-size.ts +0 -89
- package/src/flatbuffers/client-udpsocket-set-send-buffer-size.ts +0 -89
- package/src/flatbuffers/client-udpsocket-set-ttl.ts +0 -89
- package/src/flatbuffers/client-udpsocket.ts +0 -149
- package/src/flatbuffers/packet-handshake-type.ts +0 -9
- package/src/flatbuffers/packet.ts +0 -210
- package/src/flatbuffers/schema.ts +0 -75
- package/src/flatbuffers/server-packet-type.ts +0 -38
- package/src/flatbuffers/server-packet.ts +0 -158
- package/src/flatbuffers/server-tcpserver-callback-close.ts +0 -93
- package/src/flatbuffers/server-tcpserver-callback-get-connections.ts +0 -124
- package/src/flatbuffers/server-tcpserver-callback-listen.ts +0 -141
- package/src/flatbuffers/server-tcpserver-event-close.ts +0 -75
- package/src/flatbuffers/server-tcpserver-event-drop.ts +0 -75
- package/src/flatbuffers/server-tcpserver-event-error.ts +0 -75
- package/src/flatbuffers/server-tcpserver-event-listening.ts +0 -124
- package/src/flatbuffers/server-tcpsocket-callback-connect.ts +0 -189
- package/src/flatbuffers/server-tcpsocket-callback-end.ts +0 -93
- package/src/flatbuffers/server-tcpsocket-callback-set-timeout.ts +0 -93
- package/src/flatbuffers/server-tcpsocket-callback-write.ts +0 -93
- package/src/flatbuffers/server-tcpsocket-event-close.ts +0 -89
- package/src/flatbuffers/server-tcpsocket-event-connect.ts +0 -172
- package/src/flatbuffers/server-tcpsocket-event-connection-attempt-failed.ts +0 -138
- package/src/flatbuffers/server-tcpsocket-event-connection-attempt-timeout.ts +0 -121
- package/src/flatbuffers/server-tcpsocket-event-connection-attempt.ts +0 -121
- package/src/flatbuffers/server-tcpsocket-event-data.ts +0 -113
- package/src/flatbuffers/server-tcpsocket-event-drain.ts +0 -75
- package/src/flatbuffers/server-tcpsocket-event-end.ts +0 -75
- package/src/flatbuffers/server-tcpsocket-event-error.ts +0 -93
- package/src/flatbuffers/server-tcpsocket-event-lookup.ts +0 -141
- package/src/flatbuffers/server-tcpsocket-event-ready.ts +0 -75
- package/src/flatbuffers/server-tcpsocket-event-timeout.ts +0 -75
- package/src/flatbuffers/server-udpsocket-callback-bind.ts +0 -141
- package/src/flatbuffers/server-udpsocket-callback-close.ts +0 -93
- package/src/flatbuffers/server-udpsocket-callback-connect.ts +0 -141
- package/src/flatbuffers/server-udpsocket-callback-send.ts +0 -93
- package/src/flatbuffers/server-udpsocket-event-close.ts +0 -75
- package/src/flatbuffers/server-udpsocket-event-connect.ts +0 -75
- package/src/flatbuffers/server-udpsocket-event-error.ts +0 -93
- package/src/flatbuffers/server-udpsocket-event-listening.ts +0 -124
- package/src/flatbuffers/server-udpsocket-event-message.ts +0 -175
- package/src/net.js +0 -2442
- package/src/test.ts +0 -34
- package/src/types.ts +0 -16
- package/src/utils.ts +0 -45
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
// automatically generated by the FlatBuffers compiler, do not modify
|
|
2
|
-
|
|
3
|
-
/* eslint-disable @typescript-eslint/no-unused-vars, @typescript-eslint/no-explicit-any, @typescript-eslint/no-non-null-assertion */
|
|
4
|
-
|
|
5
|
-
import * as flatbuffers from 'flatbuffers';
|
|
6
|
-
|
|
7
|
-
import { ClientPacketType } from './client-packet-type.js';
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
export class ClientUDPSocketClose implements flatbuffers.IUnpackableObject<ClientUDPSocketCloseT> {
|
|
11
|
-
bb: flatbuffers.ByteBuffer|null = null;
|
|
12
|
-
bb_pos = 0;
|
|
13
|
-
__init(i:number, bb:flatbuffers.ByteBuffer):ClientUDPSocketClose {
|
|
14
|
-
this.bb_pos = i;
|
|
15
|
-
this.bb = bb;
|
|
16
|
-
return this;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
static getRootAsClientUDPSocketClose(bb:flatbuffers.ByteBuffer, obj?:ClientUDPSocketClose):ClientUDPSocketClose {
|
|
20
|
-
return (obj || new ClientUDPSocketClose()).__init(bb.readInt32(bb.position()) + bb.position(), bb);
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
static getSizePrefixedRootAsClientUDPSocketClose(bb:flatbuffers.ByteBuffer, obj?:ClientUDPSocketClose):ClientUDPSocketClose {
|
|
24
|
-
bb.setPosition(bb.position() + flatbuffers.SIZE_PREFIX_LENGTH);
|
|
25
|
-
return (obj || new ClientUDPSocketClose()).__init(bb.readInt32(bb.position()) + bb.position(), bb);
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
type():ClientPacketType {
|
|
29
|
-
const offset = this.bb!.__offset(this.bb_pos, 4);
|
|
30
|
-
return offset ? this.bb!.readInt8(this.bb_pos + offset) : ClientPacketType.TCPSocket;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
uuid():string|null
|
|
34
|
-
uuid(optionalEncoding:flatbuffers.Encoding):string|Uint8Array|null
|
|
35
|
-
uuid(optionalEncoding?:any):string|Uint8Array|null {
|
|
36
|
-
const offset = this.bb!.__offset(this.bb_pos, 6);
|
|
37
|
-
return offset ? this.bb!.__string(this.bb_pos + offset, optionalEncoding) : null;
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
static startClientUDPSocketClose(builder:flatbuffers.Builder) {
|
|
41
|
-
builder.startObject(2);
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
static addType(builder:flatbuffers.Builder, type:ClientPacketType) {
|
|
45
|
-
builder.addFieldInt8(0, type, ClientPacketType.TCPSocket);
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
static addUuid(builder:flatbuffers.Builder, uuidOffset:flatbuffers.Offset) {
|
|
49
|
-
builder.addFieldOffset(1, uuidOffset, 0);
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
static endClientUDPSocketClose(builder:flatbuffers.Builder):flatbuffers.Offset {
|
|
53
|
-
const offset = builder.endObject();
|
|
54
|
-
return offset;
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
static createClientUDPSocketClose(builder:flatbuffers.Builder, type:ClientPacketType, uuidOffset:flatbuffers.Offset):flatbuffers.Offset {
|
|
58
|
-
ClientUDPSocketClose.startClientUDPSocketClose(builder);
|
|
59
|
-
ClientUDPSocketClose.addType(builder, type);
|
|
60
|
-
ClientUDPSocketClose.addUuid(builder, uuidOffset);
|
|
61
|
-
return ClientUDPSocketClose.endClientUDPSocketClose(builder);
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
unpack(): ClientUDPSocketCloseT {
|
|
65
|
-
return new ClientUDPSocketCloseT(
|
|
66
|
-
this.type(),
|
|
67
|
-
this.uuid()
|
|
68
|
-
);
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
unpackTo(_o: ClientUDPSocketCloseT): void {
|
|
73
|
-
_o.type = this.type();
|
|
74
|
-
_o.uuid = this.uuid();
|
|
75
|
-
}
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
export class ClientUDPSocketCloseT implements flatbuffers.IGeneratedObject {
|
|
79
|
-
constructor(
|
|
80
|
-
public type: ClientPacketType = ClientPacketType.TCPSocket,
|
|
81
|
-
public uuid: string|Uint8Array|null = null
|
|
82
|
-
){}
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
pack(builder:flatbuffers.Builder): flatbuffers.Offset {
|
|
86
|
-
const uuid = (this.uuid !== null ? builder.createString(this.uuid!) : 0);
|
|
87
|
-
|
|
88
|
-
return ClientUDPSocketClose.createClientUDPSocketClose(builder,
|
|
89
|
-
this.type,
|
|
90
|
-
uuid
|
|
91
|
-
);
|
|
92
|
-
}
|
|
93
|
-
}
|
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
// automatically generated by the FlatBuffers compiler, do not modify
|
|
2
|
-
|
|
3
|
-
/* eslint-disable @typescript-eslint/no-unused-vars, @typescript-eslint/no-explicit-any, @typescript-eslint/no-non-null-assertion */
|
|
4
|
-
|
|
5
|
-
import * as flatbuffers from 'flatbuffers';
|
|
6
|
-
|
|
7
|
-
import { ClientPacketType } from './client-packet-type.js';
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
export class ClientUDPSocketDisconnect implements flatbuffers.IUnpackableObject<ClientUDPSocketDisconnectT> {
|
|
11
|
-
bb: flatbuffers.ByteBuffer|null = null;
|
|
12
|
-
bb_pos = 0;
|
|
13
|
-
__init(i:number, bb:flatbuffers.ByteBuffer):ClientUDPSocketDisconnect {
|
|
14
|
-
this.bb_pos = i;
|
|
15
|
-
this.bb = bb;
|
|
16
|
-
return this;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
static getRootAsClientUDPSocketDisconnect(bb:flatbuffers.ByteBuffer, obj?:ClientUDPSocketDisconnect):ClientUDPSocketDisconnect {
|
|
20
|
-
return (obj || new ClientUDPSocketDisconnect()).__init(bb.readInt32(bb.position()) + bb.position(), bb);
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
static getSizePrefixedRootAsClientUDPSocketDisconnect(bb:flatbuffers.ByteBuffer, obj?:ClientUDPSocketDisconnect):ClientUDPSocketDisconnect {
|
|
24
|
-
bb.setPosition(bb.position() + flatbuffers.SIZE_PREFIX_LENGTH);
|
|
25
|
-
return (obj || new ClientUDPSocketDisconnect()).__init(bb.readInt32(bb.position()) + bb.position(), bb);
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
type():ClientPacketType {
|
|
29
|
-
const offset = this.bb!.__offset(this.bb_pos, 4);
|
|
30
|
-
return offset ? this.bb!.readInt8(this.bb_pos + offset) : ClientPacketType.TCPSocket;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
static startClientUDPSocketDisconnect(builder:flatbuffers.Builder) {
|
|
34
|
-
builder.startObject(1);
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
static addType(builder:flatbuffers.Builder, type:ClientPacketType) {
|
|
38
|
-
builder.addFieldInt8(0, type, ClientPacketType.TCPSocket);
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
static endClientUDPSocketDisconnect(builder:flatbuffers.Builder):flatbuffers.Offset {
|
|
42
|
-
const offset = builder.endObject();
|
|
43
|
-
return offset;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
static createClientUDPSocketDisconnect(builder:flatbuffers.Builder, type:ClientPacketType):flatbuffers.Offset {
|
|
47
|
-
ClientUDPSocketDisconnect.startClientUDPSocketDisconnect(builder);
|
|
48
|
-
ClientUDPSocketDisconnect.addType(builder, type);
|
|
49
|
-
return ClientUDPSocketDisconnect.endClientUDPSocketDisconnect(builder);
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
unpack(): ClientUDPSocketDisconnectT {
|
|
53
|
-
return new ClientUDPSocketDisconnectT(
|
|
54
|
-
this.type()
|
|
55
|
-
);
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
unpackTo(_o: ClientUDPSocketDisconnectT): void {
|
|
60
|
-
_o.type = this.type();
|
|
61
|
-
}
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
export class ClientUDPSocketDisconnectT implements flatbuffers.IGeneratedObject {
|
|
65
|
-
constructor(
|
|
66
|
-
public type: ClientPacketType = ClientPacketType.TCPSocket
|
|
67
|
-
){}
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
pack(builder:flatbuffers.Builder): flatbuffers.Offset {
|
|
71
|
-
return ClientUDPSocketDisconnect.createClientUDPSocketDisconnect(builder,
|
|
72
|
-
this.type
|
|
73
|
-
);
|
|
74
|
-
}
|
|
75
|
-
}
|
|
@@ -1,110 +0,0 @@
|
|
|
1
|
-
// automatically generated by the FlatBuffers compiler, do not modify
|
|
2
|
-
|
|
3
|
-
/* eslint-disable @typescript-eslint/no-unused-vars, @typescript-eslint/no-explicit-any, @typescript-eslint/no-non-null-assertion */
|
|
4
|
-
|
|
5
|
-
import * as flatbuffers from 'flatbuffers';
|
|
6
|
-
|
|
7
|
-
import { ClientPacketType } from './client-packet-type.js';
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
export class ClientUDPSocketDropMembership implements flatbuffers.IUnpackableObject<ClientUDPSocketDropMembershipT> {
|
|
11
|
-
bb: flatbuffers.ByteBuffer|null = null;
|
|
12
|
-
bb_pos = 0;
|
|
13
|
-
__init(i:number, bb:flatbuffers.ByteBuffer):ClientUDPSocketDropMembership {
|
|
14
|
-
this.bb_pos = i;
|
|
15
|
-
this.bb = bb;
|
|
16
|
-
return this;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
static getRootAsClientUDPSocketDropMembership(bb:flatbuffers.ByteBuffer, obj?:ClientUDPSocketDropMembership):ClientUDPSocketDropMembership {
|
|
20
|
-
return (obj || new ClientUDPSocketDropMembership()).__init(bb.readInt32(bb.position()) + bb.position(), bb);
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
static getSizePrefixedRootAsClientUDPSocketDropMembership(bb:flatbuffers.ByteBuffer, obj?:ClientUDPSocketDropMembership):ClientUDPSocketDropMembership {
|
|
24
|
-
bb.setPosition(bb.position() + flatbuffers.SIZE_PREFIX_LENGTH);
|
|
25
|
-
return (obj || new ClientUDPSocketDropMembership()).__init(bb.readInt32(bb.position()) + bb.position(), bb);
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
type():ClientPacketType {
|
|
29
|
-
const offset = this.bb!.__offset(this.bb_pos, 4);
|
|
30
|
-
return offset ? this.bb!.readInt8(this.bb_pos + offset) : ClientPacketType.TCPSocket;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
multicastAddress():string|null
|
|
34
|
-
multicastAddress(optionalEncoding:flatbuffers.Encoding):string|Uint8Array|null
|
|
35
|
-
multicastAddress(optionalEncoding?:any):string|Uint8Array|null {
|
|
36
|
-
const offset = this.bb!.__offset(this.bb_pos, 6);
|
|
37
|
-
return offset ? this.bb!.__string(this.bb_pos + offset, optionalEncoding) : null;
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
multicastInterface():string|null
|
|
41
|
-
multicastInterface(optionalEncoding:flatbuffers.Encoding):string|Uint8Array|null
|
|
42
|
-
multicastInterface(optionalEncoding?:any):string|Uint8Array|null {
|
|
43
|
-
const offset = this.bb!.__offset(this.bb_pos, 8);
|
|
44
|
-
return offset ? this.bb!.__string(this.bb_pos + offset, optionalEncoding) : null;
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
static startClientUDPSocketDropMembership(builder:flatbuffers.Builder) {
|
|
48
|
-
builder.startObject(3);
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
static addType(builder:flatbuffers.Builder, type:ClientPacketType) {
|
|
52
|
-
builder.addFieldInt8(0, type, ClientPacketType.TCPSocket);
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
static addMulticastAddress(builder:flatbuffers.Builder, multicastAddressOffset:flatbuffers.Offset) {
|
|
56
|
-
builder.addFieldOffset(1, multicastAddressOffset, 0);
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
static addMulticastInterface(builder:flatbuffers.Builder, multicastInterfaceOffset:flatbuffers.Offset) {
|
|
60
|
-
builder.addFieldOffset(2, multicastInterfaceOffset, 0);
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
static endClientUDPSocketDropMembership(builder:flatbuffers.Builder):flatbuffers.Offset {
|
|
64
|
-
const offset = builder.endObject();
|
|
65
|
-
return offset;
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
static createClientUDPSocketDropMembership(builder:flatbuffers.Builder, type:ClientPacketType, multicastAddressOffset:flatbuffers.Offset, multicastInterfaceOffset:flatbuffers.Offset):flatbuffers.Offset {
|
|
69
|
-
ClientUDPSocketDropMembership.startClientUDPSocketDropMembership(builder);
|
|
70
|
-
ClientUDPSocketDropMembership.addType(builder, type);
|
|
71
|
-
ClientUDPSocketDropMembership.addMulticastAddress(builder, multicastAddressOffset);
|
|
72
|
-
ClientUDPSocketDropMembership.addMulticastInterface(builder, multicastInterfaceOffset);
|
|
73
|
-
return ClientUDPSocketDropMembership.endClientUDPSocketDropMembership(builder);
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
unpack(): ClientUDPSocketDropMembershipT {
|
|
77
|
-
return new ClientUDPSocketDropMembershipT(
|
|
78
|
-
this.type(),
|
|
79
|
-
this.multicastAddress(),
|
|
80
|
-
this.multicastInterface()
|
|
81
|
-
);
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
unpackTo(_o: ClientUDPSocketDropMembershipT): void {
|
|
86
|
-
_o.type = this.type();
|
|
87
|
-
_o.multicastAddress = this.multicastAddress();
|
|
88
|
-
_o.multicastInterface = this.multicastInterface();
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
export class ClientUDPSocketDropMembershipT implements flatbuffers.IGeneratedObject {
|
|
93
|
-
constructor(
|
|
94
|
-
public type: ClientPacketType = ClientPacketType.TCPSocket,
|
|
95
|
-
public multicastAddress: string|Uint8Array|null = null,
|
|
96
|
-
public multicastInterface: string|Uint8Array|null = null
|
|
97
|
-
){}
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
pack(builder:flatbuffers.Builder): flatbuffers.Offset {
|
|
101
|
-
const multicastAddress = (this.multicastAddress !== null ? builder.createString(this.multicastAddress!) : 0);
|
|
102
|
-
const multicastInterface = (this.multicastInterface !== null ? builder.createString(this.multicastInterface!) : 0);
|
|
103
|
-
|
|
104
|
-
return ClientUDPSocketDropMembership.createClientUDPSocketDropMembership(builder,
|
|
105
|
-
this.type,
|
|
106
|
-
multicastAddress,
|
|
107
|
-
multicastInterface
|
|
108
|
-
);
|
|
109
|
-
}
|
|
110
|
-
}
|
|
@@ -1,127 +0,0 @@
|
|
|
1
|
-
// automatically generated by the FlatBuffers compiler, do not modify
|
|
2
|
-
|
|
3
|
-
/* eslint-disable @typescript-eslint/no-unused-vars, @typescript-eslint/no-explicit-any, @typescript-eslint/no-non-null-assertion */
|
|
4
|
-
|
|
5
|
-
import * as flatbuffers from 'flatbuffers';
|
|
6
|
-
|
|
7
|
-
import { ClientPacketType } from './client-packet-type.js';
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
export class ClientUDPSocketDropSourceSpecificMembership implements flatbuffers.IUnpackableObject<ClientUDPSocketDropSourceSpecificMembershipT> {
|
|
11
|
-
bb: flatbuffers.ByteBuffer|null = null;
|
|
12
|
-
bb_pos = 0;
|
|
13
|
-
__init(i:number, bb:flatbuffers.ByteBuffer):ClientUDPSocketDropSourceSpecificMembership {
|
|
14
|
-
this.bb_pos = i;
|
|
15
|
-
this.bb = bb;
|
|
16
|
-
return this;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
static getRootAsClientUDPSocketDropSourceSpecificMembership(bb:flatbuffers.ByteBuffer, obj?:ClientUDPSocketDropSourceSpecificMembership):ClientUDPSocketDropSourceSpecificMembership {
|
|
20
|
-
return (obj || new ClientUDPSocketDropSourceSpecificMembership()).__init(bb.readInt32(bb.position()) + bb.position(), bb);
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
static getSizePrefixedRootAsClientUDPSocketDropSourceSpecificMembership(bb:flatbuffers.ByteBuffer, obj?:ClientUDPSocketDropSourceSpecificMembership):ClientUDPSocketDropSourceSpecificMembership {
|
|
24
|
-
bb.setPosition(bb.position() + flatbuffers.SIZE_PREFIX_LENGTH);
|
|
25
|
-
return (obj || new ClientUDPSocketDropSourceSpecificMembership()).__init(bb.readInt32(bb.position()) + bb.position(), bb);
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
type():ClientPacketType {
|
|
29
|
-
const offset = this.bb!.__offset(this.bb_pos, 4);
|
|
30
|
-
return offset ? this.bb!.readInt8(this.bb_pos + offset) : ClientPacketType.TCPSocket;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
sourceAddress():string|null
|
|
34
|
-
sourceAddress(optionalEncoding:flatbuffers.Encoding):string|Uint8Array|null
|
|
35
|
-
sourceAddress(optionalEncoding?:any):string|Uint8Array|null {
|
|
36
|
-
const offset = this.bb!.__offset(this.bb_pos, 6);
|
|
37
|
-
return offset ? this.bb!.__string(this.bb_pos + offset, optionalEncoding) : null;
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
groupAddress():string|null
|
|
41
|
-
groupAddress(optionalEncoding:flatbuffers.Encoding):string|Uint8Array|null
|
|
42
|
-
groupAddress(optionalEncoding?:any):string|Uint8Array|null {
|
|
43
|
-
const offset = this.bb!.__offset(this.bb_pos, 8);
|
|
44
|
-
return offset ? this.bb!.__string(this.bb_pos + offset, optionalEncoding) : null;
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
multicastInterface():string|null
|
|
48
|
-
multicastInterface(optionalEncoding:flatbuffers.Encoding):string|Uint8Array|null
|
|
49
|
-
multicastInterface(optionalEncoding?:any):string|Uint8Array|null {
|
|
50
|
-
const offset = this.bb!.__offset(this.bb_pos, 10);
|
|
51
|
-
return offset ? this.bb!.__string(this.bb_pos + offset, optionalEncoding) : null;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
static startClientUDPSocketDropSourceSpecificMembership(builder:flatbuffers.Builder) {
|
|
55
|
-
builder.startObject(4);
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
static addType(builder:flatbuffers.Builder, type:ClientPacketType) {
|
|
59
|
-
builder.addFieldInt8(0, type, ClientPacketType.TCPSocket);
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
static addSourceAddress(builder:flatbuffers.Builder, sourceAddressOffset:flatbuffers.Offset) {
|
|
63
|
-
builder.addFieldOffset(1, sourceAddressOffset, 0);
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
static addGroupAddress(builder:flatbuffers.Builder, groupAddressOffset:flatbuffers.Offset) {
|
|
67
|
-
builder.addFieldOffset(2, groupAddressOffset, 0);
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
static addMulticastInterface(builder:flatbuffers.Builder, multicastInterfaceOffset:flatbuffers.Offset) {
|
|
71
|
-
builder.addFieldOffset(3, multicastInterfaceOffset, 0);
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
static endClientUDPSocketDropSourceSpecificMembership(builder:flatbuffers.Builder):flatbuffers.Offset {
|
|
75
|
-
const offset = builder.endObject();
|
|
76
|
-
return offset;
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
static createClientUDPSocketDropSourceSpecificMembership(builder:flatbuffers.Builder, type:ClientPacketType, sourceAddressOffset:flatbuffers.Offset, groupAddressOffset:flatbuffers.Offset, multicastInterfaceOffset:flatbuffers.Offset):flatbuffers.Offset {
|
|
80
|
-
ClientUDPSocketDropSourceSpecificMembership.startClientUDPSocketDropSourceSpecificMembership(builder);
|
|
81
|
-
ClientUDPSocketDropSourceSpecificMembership.addType(builder, type);
|
|
82
|
-
ClientUDPSocketDropSourceSpecificMembership.addSourceAddress(builder, sourceAddressOffset);
|
|
83
|
-
ClientUDPSocketDropSourceSpecificMembership.addGroupAddress(builder, groupAddressOffset);
|
|
84
|
-
ClientUDPSocketDropSourceSpecificMembership.addMulticastInterface(builder, multicastInterfaceOffset);
|
|
85
|
-
return ClientUDPSocketDropSourceSpecificMembership.endClientUDPSocketDropSourceSpecificMembership(builder);
|
|
86
|
-
}
|
|
87
|
-
|
|
88
|
-
unpack(): ClientUDPSocketDropSourceSpecificMembershipT {
|
|
89
|
-
return new ClientUDPSocketDropSourceSpecificMembershipT(
|
|
90
|
-
this.type(),
|
|
91
|
-
this.sourceAddress(),
|
|
92
|
-
this.groupAddress(),
|
|
93
|
-
this.multicastInterface()
|
|
94
|
-
);
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
unpackTo(_o: ClientUDPSocketDropSourceSpecificMembershipT): void {
|
|
99
|
-
_o.type = this.type();
|
|
100
|
-
_o.sourceAddress = this.sourceAddress();
|
|
101
|
-
_o.groupAddress = this.groupAddress();
|
|
102
|
-
_o.multicastInterface = this.multicastInterface();
|
|
103
|
-
}
|
|
104
|
-
}
|
|
105
|
-
|
|
106
|
-
export class ClientUDPSocketDropSourceSpecificMembershipT implements flatbuffers.IGeneratedObject {
|
|
107
|
-
constructor(
|
|
108
|
-
public type: ClientPacketType = ClientPacketType.TCPSocket,
|
|
109
|
-
public sourceAddress: string|Uint8Array|null = null,
|
|
110
|
-
public groupAddress: string|Uint8Array|null = null,
|
|
111
|
-
public multicastInterface: string|Uint8Array|null = null
|
|
112
|
-
){}
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
pack(builder:flatbuffers.Builder): flatbuffers.Offset {
|
|
116
|
-
const sourceAddress = (this.sourceAddress !== null ? builder.createString(this.sourceAddress!) : 0);
|
|
117
|
-
const groupAddress = (this.groupAddress !== null ? builder.createString(this.groupAddress!) : 0);
|
|
118
|
-
const multicastInterface = (this.multicastInterface !== null ? builder.createString(this.multicastInterface!) : 0);
|
|
119
|
-
|
|
120
|
-
return ClientUDPSocketDropSourceSpecificMembership.createClientUDPSocketDropSourceSpecificMembership(builder,
|
|
121
|
-
this.type,
|
|
122
|
-
sourceAddress,
|
|
123
|
-
groupAddress,
|
|
124
|
-
multicastInterface
|
|
125
|
-
);
|
|
126
|
-
}
|
|
127
|
-
}
|
|
@@ -1,189 +0,0 @@
|
|
|
1
|
-
// automatically generated by the FlatBuffers compiler, do not modify
|
|
2
|
-
|
|
3
|
-
/* eslint-disable @typescript-eslint/no-unused-vars, @typescript-eslint/no-explicit-any, @typescript-eslint/no-non-null-assertion */
|
|
4
|
-
|
|
5
|
-
import * as flatbuffers from 'flatbuffers';
|
|
6
|
-
|
|
7
|
-
import { ClientPacketType } from './client-packet-type.js';
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
export class ClientUDPSocketSend implements flatbuffers.IUnpackableObject<ClientUDPSocketSendT> {
|
|
11
|
-
bb: flatbuffers.ByteBuffer|null = null;
|
|
12
|
-
bb_pos = 0;
|
|
13
|
-
__init(i:number, bb:flatbuffers.ByteBuffer):ClientUDPSocketSend {
|
|
14
|
-
this.bb_pos = i;
|
|
15
|
-
this.bb = bb;
|
|
16
|
-
return this;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
static getRootAsClientUDPSocketSend(bb:flatbuffers.ByteBuffer, obj?:ClientUDPSocketSend):ClientUDPSocketSend {
|
|
20
|
-
return (obj || new ClientUDPSocketSend()).__init(bb.readInt32(bb.position()) + bb.position(), bb);
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
static getSizePrefixedRootAsClientUDPSocketSend(bb:flatbuffers.ByteBuffer, obj?:ClientUDPSocketSend):ClientUDPSocketSend {
|
|
24
|
-
bb.setPosition(bb.position() + flatbuffers.SIZE_PREFIX_LENGTH);
|
|
25
|
-
return (obj || new ClientUDPSocketSend()).__init(bb.readInt32(bb.position()) + bb.position(), bb);
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
type():ClientPacketType {
|
|
29
|
-
const offset = this.bb!.__offset(this.bb_pos, 4);
|
|
30
|
-
return offset ? this.bb!.readInt8(this.bb_pos + offset) : ClientPacketType.TCPSocket;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
uuid():string|null
|
|
34
|
-
uuid(optionalEncoding:flatbuffers.Encoding):string|Uint8Array|null
|
|
35
|
-
uuid(optionalEncoding?:any):string|Uint8Array|null {
|
|
36
|
-
const offset = this.bb!.__offset(this.bb_pos, 6);
|
|
37
|
-
return offset ? this.bb!.__string(this.bb_pos + offset, optionalEncoding) : null;
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
data(index: number):number|null {
|
|
41
|
-
const offset = this.bb!.__offset(this.bb_pos, 8);
|
|
42
|
-
return offset ? this.bb!.readUint8(this.bb!.__vector(this.bb_pos + offset) + index) : 0;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
dataLength():number {
|
|
46
|
-
const offset = this.bb!.__offset(this.bb_pos, 8);
|
|
47
|
-
return offset ? this.bb!.__vector_len(this.bb_pos + offset) : 0;
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
dataArray():Uint8Array|null {
|
|
51
|
-
const offset = this.bb!.__offset(this.bb_pos, 8);
|
|
52
|
-
return offset ? new Uint8Array(this.bb!.bytes().buffer, this.bb!.bytes().byteOffset + this.bb!.__vector(this.bb_pos + offset), this.bb!.__vector_len(this.bb_pos + offset)) : null;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
offset():number {
|
|
56
|
-
const offset = this.bb!.__offset(this.bb_pos, 10);
|
|
57
|
-
return offset ? this.bb!.readFloat32(this.bb_pos + offset) : 0.0;
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
length():number {
|
|
61
|
-
const offset = this.bb!.__offset(this.bb_pos, 12);
|
|
62
|
-
return offset ? this.bb!.readFloat32(this.bb_pos + offset) : 0.0;
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
port():number {
|
|
66
|
-
const offset = this.bb!.__offset(this.bb_pos, 14);
|
|
67
|
-
return offset ? this.bb!.readFloat32(this.bb_pos + offset) : 0.0;
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
address():string|null
|
|
71
|
-
address(optionalEncoding:flatbuffers.Encoding):string|Uint8Array|null
|
|
72
|
-
address(optionalEncoding?:any):string|Uint8Array|null {
|
|
73
|
-
const offset = this.bb!.__offset(this.bb_pos, 16);
|
|
74
|
-
return offset ? this.bb!.__string(this.bb_pos + offset, optionalEncoding) : null;
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
static startClientUDPSocketSend(builder:flatbuffers.Builder) {
|
|
78
|
-
builder.startObject(7);
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
static addType(builder:flatbuffers.Builder, type:ClientPacketType) {
|
|
82
|
-
builder.addFieldInt8(0, type, ClientPacketType.TCPSocket);
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
static addUuid(builder:flatbuffers.Builder, uuidOffset:flatbuffers.Offset) {
|
|
86
|
-
builder.addFieldOffset(1, uuidOffset, 0);
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
static addData(builder:flatbuffers.Builder, dataOffset:flatbuffers.Offset) {
|
|
90
|
-
builder.addFieldOffset(2, dataOffset, 0);
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
static createDataVector(builder:flatbuffers.Builder, data:number[]|Uint8Array):flatbuffers.Offset {
|
|
94
|
-
builder.startVector(1, data.length, 1);
|
|
95
|
-
for (let i = data.length - 1; i >= 0; i--) {
|
|
96
|
-
builder.addInt8(data[i]!);
|
|
97
|
-
}
|
|
98
|
-
return builder.endVector();
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
static startDataVector(builder:flatbuffers.Builder, numElems:number) {
|
|
102
|
-
builder.startVector(1, numElems, 1);
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
static addOffset(builder:flatbuffers.Builder, offset:number) {
|
|
106
|
-
builder.addFieldFloat32(3, offset, 0.0);
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
static addLength(builder:flatbuffers.Builder, length:number) {
|
|
110
|
-
builder.addFieldFloat32(4, length, 0.0);
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
static addPort(builder:flatbuffers.Builder, port:number) {
|
|
114
|
-
builder.addFieldFloat32(5, port, 0.0);
|
|
115
|
-
}
|
|
116
|
-
|
|
117
|
-
static addAddress(builder:flatbuffers.Builder, addressOffset:flatbuffers.Offset) {
|
|
118
|
-
builder.addFieldOffset(6, addressOffset, 0);
|
|
119
|
-
}
|
|
120
|
-
|
|
121
|
-
static endClientUDPSocketSend(builder:flatbuffers.Builder):flatbuffers.Offset {
|
|
122
|
-
const offset = builder.endObject();
|
|
123
|
-
return offset;
|
|
124
|
-
}
|
|
125
|
-
|
|
126
|
-
static createClientUDPSocketSend(builder:flatbuffers.Builder, type:ClientPacketType, uuidOffset:flatbuffers.Offset, dataOffset:flatbuffers.Offset, offset:number, length:number, port:number, addressOffset:flatbuffers.Offset):flatbuffers.Offset {
|
|
127
|
-
ClientUDPSocketSend.startClientUDPSocketSend(builder);
|
|
128
|
-
ClientUDPSocketSend.addType(builder, type);
|
|
129
|
-
ClientUDPSocketSend.addUuid(builder, uuidOffset);
|
|
130
|
-
ClientUDPSocketSend.addData(builder, dataOffset);
|
|
131
|
-
ClientUDPSocketSend.addOffset(builder, offset);
|
|
132
|
-
ClientUDPSocketSend.addLength(builder, length);
|
|
133
|
-
ClientUDPSocketSend.addPort(builder, port);
|
|
134
|
-
ClientUDPSocketSend.addAddress(builder, addressOffset);
|
|
135
|
-
return ClientUDPSocketSend.endClientUDPSocketSend(builder);
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
unpack(): ClientUDPSocketSendT {
|
|
139
|
-
return new ClientUDPSocketSendT(
|
|
140
|
-
this.type(),
|
|
141
|
-
this.uuid(),
|
|
142
|
-
this.bb!.createScalarList<number>(this.data.bind(this), this.dataLength()),
|
|
143
|
-
this.offset(),
|
|
144
|
-
this.length(),
|
|
145
|
-
this.port(),
|
|
146
|
-
this.address()
|
|
147
|
-
);
|
|
148
|
-
}
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
unpackTo(_o: ClientUDPSocketSendT): void {
|
|
152
|
-
_o.type = this.type();
|
|
153
|
-
_o.uuid = this.uuid();
|
|
154
|
-
_o.data = this.bb!.createScalarList<number>(this.data.bind(this), this.dataLength());
|
|
155
|
-
_o.offset = this.offset();
|
|
156
|
-
_o.length = this.length();
|
|
157
|
-
_o.port = this.port();
|
|
158
|
-
_o.address = this.address();
|
|
159
|
-
}
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
export class ClientUDPSocketSendT implements flatbuffers.IGeneratedObject {
|
|
163
|
-
constructor(
|
|
164
|
-
public type: ClientPacketType = ClientPacketType.TCPSocket,
|
|
165
|
-
public uuid: string|Uint8Array|null = null,
|
|
166
|
-
public data: (number)[] = [],
|
|
167
|
-
public offset: number = 0.0,
|
|
168
|
-
public length: number = 0.0,
|
|
169
|
-
public port: number = 0.0,
|
|
170
|
-
public address: string|Uint8Array|null = null
|
|
171
|
-
){}
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
pack(builder:flatbuffers.Builder): flatbuffers.Offset {
|
|
175
|
-
const uuid = (this.uuid !== null ? builder.createString(this.uuid!) : 0);
|
|
176
|
-
const data = ClientUDPSocketSend.createDataVector(builder, this.data);
|
|
177
|
-
const address = (this.address !== null ? builder.createString(this.address!) : 0);
|
|
178
|
-
|
|
179
|
-
return ClientUDPSocketSend.createClientUDPSocketSend(builder,
|
|
180
|
-
this.type,
|
|
181
|
-
uuid,
|
|
182
|
-
data,
|
|
183
|
-
this.offset,
|
|
184
|
-
this.length,
|
|
185
|
-
this.port,
|
|
186
|
-
address
|
|
187
|
-
);
|
|
188
|
-
}
|
|
189
|
-
}
|
|
@@ -1,89 +0,0 @@
|
|
|
1
|
-
// automatically generated by the FlatBuffers compiler, do not modify
|
|
2
|
-
|
|
3
|
-
/* eslint-disable @typescript-eslint/no-unused-vars, @typescript-eslint/no-explicit-any, @typescript-eslint/no-non-null-assertion */
|
|
4
|
-
|
|
5
|
-
import * as flatbuffers from 'flatbuffers';
|
|
6
|
-
|
|
7
|
-
import { ClientPacketType } from './client-packet-type.js';
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
export class ClientUDPSocketSetBroadcast implements flatbuffers.IUnpackableObject<ClientUDPSocketSetBroadcastT> {
|
|
11
|
-
bb: flatbuffers.ByteBuffer|null = null;
|
|
12
|
-
bb_pos = 0;
|
|
13
|
-
__init(i:number, bb:flatbuffers.ByteBuffer):ClientUDPSocketSetBroadcast {
|
|
14
|
-
this.bb_pos = i;
|
|
15
|
-
this.bb = bb;
|
|
16
|
-
return this;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
static getRootAsClientUDPSocketSetBroadcast(bb:flatbuffers.ByteBuffer, obj?:ClientUDPSocketSetBroadcast):ClientUDPSocketSetBroadcast {
|
|
20
|
-
return (obj || new ClientUDPSocketSetBroadcast()).__init(bb.readInt32(bb.position()) + bb.position(), bb);
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
static getSizePrefixedRootAsClientUDPSocketSetBroadcast(bb:flatbuffers.ByteBuffer, obj?:ClientUDPSocketSetBroadcast):ClientUDPSocketSetBroadcast {
|
|
24
|
-
bb.setPosition(bb.position() + flatbuffers.SIZE_PREFIX_LENGTH);
|
|
25
|
-
return (obj || new ClientUDPSocketSetBroadcast()).__init(bb.readInt32(bb.position()) + bb.position(), bb);
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
type():ClientPacketType {
|
|
29
|
-
const offset = this.bb!.__offset(this.bb_pos, 4);
|
|
30
|
-
return offset ? this.bb!.readInt8(this.bb_pos + offset) : ClientPacketType.TCPSocket;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
flag():boolean {
|
|
34
|
-
const offset = this.bb!.__offset(this.bb_pos, 6);
|
|
35
|
-
return offset ? !!this.bb!.readInt8(this.bb_pos + offset) : false;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
static startClientUDPSocketSetBroadcast(builder:flatbuffers.Builder) {
|
|
39
|
-
builder.startObject(2);
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
static addType(builder:flatbuffers.Builder, type:ClientPacketType) {
|
|
43
|
-
builder.addFieldInt8(0, type, ClientPacketType.TCPSocket);
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
static addFlag(builder:flatbuffers.Builder, flag:boolean) {
|
|
47
|
-
builder.addFieldInt8(1, +flag, +false);
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
static endClientUDPSocketSetBroadcast(builder:flatbuffers.Builder):flatbuffers.Offset {
|
|
51
|
-
const offset = builder.endObject();
|
|
52
|
-
return offset;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
static createClientUDPSocketSetBroadcast(builder:flatbuffers.Builder, type:ClientPacketType, flag:boolean):flatbuffers.Offset {
|
|
56
|
-
ClientUDPSocketSetBroadcast.startClientUDPSocketSetBroadcast(builder);
|
|
57
|
-
ClientUDPSocketSetBroadcast.addType(builder, type);
|
|
58
|
-
ClientUDPSocketSetBroadcast.addFlag(builder, flag);
|
|
59
|
-
return ClientUDPSocketSetBroadcast.endClientUDPSocketSetBroadcast(builder);
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
unpack(): ClientUDPSocketSetBroadcastT {
|
|
63
|
-
return new ClientUDPSocketSetBroadcastT(
|
|
64
|
-
this.type(),
|
|
65
|
-
this.flag()
|
|
66
|
-
);
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
unpackTo(_o: ClientUDPSocketSetBroadcastT): void {
|
|
71
|
-
_o.type = this.type();
|
|
72
|
-
_o.flag = this.flag();
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
export class ClientUDPSocketSetBroadcastT implements flatbuffers.IGeneratedObject {
|
|
77
|
-
constructor(
|
|
78
|
-
public type: ClientPacketType = ClientPacketType.TCPSocket,
|
|
79
|
-
public flag: boolean = false
|
|
80
|
-
){}
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
pack(builder:flatbuffers.Builder): flatbuffers.Offset {
|
|
84
|
-
return ClientUDPSocketSetBroadcast.createClientUDPSocketSetBroadcast(builder,
|
|
85
|
-
this.type,
|
|
86
|
-
this.flag
|
|
87
|
-
);
|
|
88
|
-
}
|
|
89
|
-
}
|