@moqtap/codec 0.5.0 → 0.7.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/README.md +4 -2
- package/dist/{chunk-CXFAQKL3.js → chunk-23KRITJ6.js} +1 -1
- package/dist/{chunk-JL3NEW3O.cjs → chunk-4XLYCT5Q.cjs} +90 -1
- package/dist/{chunk-DLSGOZ6P.js → chunk-5XZKO2U5.js} +34 -34
- package/dist/chunk-APTV6F72.js +2095 -0
- package/dist/{chunk-JB5VDJ2V.cjs → chunk-B56AG5HU.cjs} +37 -37
- package/dist/chunk-CQ65LKPQ.cjs +446 -0
- package/dist/{chunk-4HBKHNU2.cjs → chunk-CZNW3R5E.cjs} +37 -37
- package/dist/{chunk-Q5D6OW6Q.js → chunk-DORX55MO.js} +1 -1
- package/dist/{chunk-OGZTQA24.cjs → chunk-EQAYMCXO.cjs} +64 -64
- package/dist/{chunk-HYI6LFMD.js → chunk-HEO2JG6C.js} +1 -1
- package/dist/{chunk-UP4XPH4J.js → chunk-I55J3KXD.js} +31 -31
- package/dist/{chunk-HZHSO7EW.cjs → chunk-IDV2JYJ6.cjs} +39 -39
- package/dist/{chunk-BAG6YWCP.cjs → chunk-IEJULBKB.cjs} +63 -63
- package/dist/{chunk-Y6KCSM3V.js → chunk-IJAF6PAY.js} +1 -1
- package/dist/{chunk-WMJVSBBE.cjs → chunk-J3ASFPCX.cjs} +57 -57
- package/dist/{chunk-COWGGUL4.js → chunk-JKMYAUGY.js} +1 -1
- package/dist/{chunk-SIYYMFCC.cjs → chunk-KCH4BQXK.cjs} +37 -37
- package/dist/{chunk-VOU7PNHI.js → chunk-KLPWJU6W.js} +89 -0
- package/dist/{chunk-NZ7GYEMT.js → chunk-KNLPX3YA.js} +1 -1
- package/dist/{chunk-A33U4WVS.cjs → chunk-KTVN4P6J.cjs} +67 -67
- package/dist/{chunk-7KBAWOBA.js → chunk-KYVTM5VI.js} +1 -1
- package/dist/{chunk-RZ3UML47.js → chunk-MD2OA7SE.js} +1 -1
- package/dist/chunk-MH7537FB.cjs +2095 -0
- package/dist/{chunk-SHMA4PBY.js → chunk-N2V7Z37J.js} +1 -1
- package/dist/chunk-O5DQ44TM.js +446 -0
- package/dist/{chunk-HO44OANK.cjs → chunk-QGIHC6BA.cjs} +36 -36
- package/dist/{chunk-PKEOQSSZ.cjs → chunk-RIIA4ALQ.cjs} +37 -37
- package/dist/{chunk-XZE5R57R.cjs → chunk-VZHL2U2N.cjs} +37 -37
- package/dist/{chunk-RW4UG7CN.js → chunk-XHAP2YST.js} +1 -1
- package/dist/{chunk-JTRU76JN.cjs → chunk-Y4FRXYX6.cjs} +59 -59
- package/dist/{codec-yJ_axwtp.d.cts → codec-B1snaM9L.d.cts} +1 -1
- package/dist/{codec-Tdey03Bo.d.ts → codec-BLYAy2OP.d.ts} +1 -1
- package/dist/{codec-DqHwYWM-.d.ts → codec-BNS3gS77.d.ts} +1 -1
- package/dist/{codec-CBLLytyP.d.cts → codec-BOtv3R5j.d.cts} +1 -1
- package/dist/{codec-C17JvsEU.d.cts → codec-BOyrk_C9.d.cts} +1 -1
- package/dist/{codec-BsSNjvB3.d.cts → codec-BqqoYdh_.d.cts} +1 -1
- package/dist/{codec-BhW5CGZq.d.ts → codec-CI0BjmHc.d.ts} +1 -1
- package/dist/{codec-BvzKRqiP.d.ts → codec-CWj5iTxA.d.ts} +1 -1
- package/dist/{codec-DbpLHKXN.d.cts → codec-CyApDKwf.d.cts} +1 -1
- package/dist/{codec-6s9d5yZm.d.ts → codec-D2JbI2tp.d.ts} +1 -1
- package/dist/{codec-BzRIVIzS.d.ts → codec-D47r_-Rl.d.ts} +1 -1
- package/dist/{codec-GayA_uN0.d.ts → codec-D49OofBr.d.ts} +1 -1
- package/dist/{codec-MxIhLDR5.d.cts → codec-D89DWXbv.d.cts} +1 -1
- package/dist/{codec-CzBmYisK.d.cts → codec-D95gT98n.d.cts} +1 -1
- package/dist/codec-DAePx2NL.d.ts +30 -0
- package/dist/{codec-D_9X0i31.d.ts → codec-DJmV04i0.d.ts} +1 -1
- package/dist/{codec-Cbv3sG2y.d.ts → codec-DL0njGkL.d.ts} +1 -1
- package/dist/{codec-D2YMCU11.d.cts → codec-DQWQSam3.d.cts} +1 -1
- package/dist/{codec-Bp4HPezr.d.ts → codec-DplRgIKq.d.ts} +1 -1
- package/dist/{codec-3ZgEK-Yj.d.ts → codec-DujHf55Z.d.ts} +1 -1
- package/dist/{codec-DS-As0Pp.d.cts → codec-DvcJgYKq.d.cts} +1 -1
- package/dist/{codec-D5Ss123f.d.cts → codec-NMsTK0GX.d.cts} +1 -1
- package/dist/{codec-BvSmr-Jp.d.ts → codec-WwwUipaU.d.ts} +1 -1
- package/dist/{codec-B6ouUJrm.d.cts → codec-cou9XBMF.d.cts} +1 -1
- package/dist/{codec-R28KwiGM.d.cts → codec-hvkJfCF5.d.cts} +1 -1
- package/dist/codec-xeuGZY77.d.cts +30 -0
- package/dist/draft07-session.d.cts +3 -3
- package/dist/draft07-session.d.ts +3 -3
- package/dist/draft07.cjs +4 -4
- package/dist/draft07.d.cts +3 -3
- package/dist/draft07.d.ts +3 -3
- package/dist/draft07.js +2 -2
- package/dist/draft08-session.d.cts +3 -3
- package/dist/draft08-session.d.ts +3 -3
- package/dist/draft08.cjs +3 -3
- package/dist/draft08.d.cts +4 -4
- package/dist/draft08.d.ts +4 -4
- package/dist/draft08.js +2 -2
- package/dist/draft09-session.d.cts +3 -3
- package/dist/draft09-session.d.ts +3 -3
- package/dist/draft09.cjs +3 -3
- package/dist/draft09.d.cts +4 -4
- package/dist/draft09.d.ts +4 -4
- package/dist/draft09.js +2 -2
- package/dist/draft10-session.d.cts +3 -3
- package/dist/draft10-session.d.ts +3 -3
- package/dist/draft10.cjs +3 -3
- package/dist/draft10.d.cts +4 -4
- package/dist/draft10.d.ts +4 -4
- package/dist/draft10.js +2 -2
- package/dist/draft11-session.d.cts +3 -3
- package/dist/draft11-session.d.ts +3 -3
- package/dist/draft11.cjs +3 -3
- package/dist/draft11.d.cts +4 -4
- package/dist/draft11.d.ts +4 -4
- package/dist/draft11.js +2 -2
- package/dist/draft12-session.d.cts +3 -3
- package/dist/draft12-session.d.ts +3 -3
- package/dist/draft12.cjs +3 -3
- package/dist/draft12.d.cts +4 -4
- package/dist/draft12.d.ts +4 -4
- package/dist/draft12.js +2 -2
- package/dist/draft13-session.d.cts +3 -3
- package/dist/draft13-session.d.ts +3 -3
- package/dist/draft13.cjs +3 -3
- package/dist/draft13.d.cts +4 -4
- package/dist/draft13.d.ts +4 -4
- package/dist/draft13.js +2 -2
- package/dist/draft14-session.d.cts +3 -3
- package/dist/draft14-session.d.ts +3 -3
- package/dist/draft14.cjs +3 -3
- package/dist/draft14.d.cts +4 -4
- package/dist/draft14.d.ts +4 -4
- package/dist/draft14.js +2 -2
- package/dist/draft15-session.d.cts +3 -3
- package/dist/draft15-session.d.ts +3 -3
- package/dist/draft15.cjs +3 -3
- package/dist/draft15.d.cts +4 -4
- package/dist/draft15.d.ts +4 -4
- package/dist/draft15.js +2 -2
- package/dist/draft16-session.d.cts +3 -3
- package/dist/draft16-session.d.ts +3 -3
- package/dist/draft16.cjs +3 -3
- package/dist/draft16.d.cts +4 -4
- package/dist/draft16.d.ts +4 -4
- package/dist/draft16.js +2 -2
- package/dist/draft17-session.d.cts +3 -3
- package/dist/draft17-session.d.ts +3 -3
- package/dist/draft17.cjs +3 -3
- package/dist/draft17.d.cts +3 -3
- package/dist/draft17.d.ts +3 -3
- package/dist/draft17.js +2 -2
- package/dist/draft18-session.d.cts +3 -3
- package/dist/draft18-session.d.ts +3 -3
- package/dist/draft18.cjs +3 -3
- package/dist/draft18.d.cts +3 -3
- package/dist/draft18.d.ts +3 -3
- package/dist/draft18.js +2 -2
- package/dist/draft19-session.cjs +8 -0
- package/dist/draft19-session.d.cts +50 -0
- package/dist/draft19-session.d.ts +50 -0
- package/dist/draft19-session.js +8 -0
- package/dist/draft19.cjs +189 -0
- package/dist/draft19.d.cts +130 -0
- package/dist/draft19.d.ts +130 -0
- package/dist/draft19.js +189 -0
- package/dist/index.cjs +33 -27
- package/dist/index.d.cts +20 -15
- package/dist/index.d.ts +20 -15
- package/dist/index.js +20 -14
- package/dist/{session-types-DBpCRtrL.d.ts → session-types-C0l_-Ups.d.ts} +1 -1
- package/dist/{session-types-sBaTRwDh.d.cts → session-types-KsqyVp6y.d.cts} +1 -1
- package/dist/session.cjs +5 -1
- package/dist/session.d.cts +5 -3
- package/dist/session.d.ts +5 -3
- package/dist/session.js +5 -1
- package/dist/{types-CnBuq68e.d.cts → types-CdCSIfvI.d.cts} +1 -1
- package/dist/{types-CnBuq68e.d.ts → types-CdCSIfvI.d.ts} +1 -1
- package/dist/types-zHgCS6o5.d.cts +265 -0
- package/dist/types-zHgCS6o5.d.ts +265 -0
- package/package.json +14 -2
- package/src/core/buffer-reader.ts +74 -2
- package/src/core/buffer-writer.ts +56 -4
- package/src/core/types.ts +1 -0
- package/src/drafts/draft17/codec.ts +2 -2
- package/src/drafts/draft17/data-streams.ts +2 -2
- package/src/drafts/draft18/codec.ts +2 -2
- package/src/drafts/draft18/data-streams.ts +2 -2
- package/src/drafts/draft19/codec.ts +1425 -0
- package/src/drafts/draft19/data-streams.ts +996 -0
- package/src/drafts/draft19/error-codes.ts +78 -0
- package/src/drafts/draft19/index.ts +126 -0
- package/src/drafts/draft19/messages.ts +58 -0
- package/src/drafts/draft19/rules.ts +85 -0
- package/src/drafts/draft19/session-fsm.ts +451 -0
- package/src/drafts/draft19/session.ts +15 -0
- package/src/drafts/draft19/types.ts +368 -0
- package/src/index.ts +9 -1
- package/src/session.ts +4 -0
package/dist/draft19.cjs
ADDED
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
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
|
+
var _chunkMH7537FBcjs = require('./chunk-MH7537FB.cjs');
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
var _chunkCQ65LKPQcjs = require('./chunk-CQ65LKPQ.cjs');
|
|
55
|
+
require('./chunk-4XLYCT5Q.cjs');
|
|
56
|
+
|
|
57
|
+
// src/drafts/draft19/error-codes.ts
|
|
58
|
+
var SessionTerminationCode = {
|
|
59
|
+
NoError: 0x0n,
|
|
60
|
+
InternalError: 0x1n,
|
|
61
|
+
Unauthorized: 0x2n,
|
|
62
|
+
ProtocolViolation: 0x3n,
|
|
63
|
+
InvalidRequestId: 0x4n,
|
|
64
|
+
DuplicateTrackAlias: 0x5n,
|
|
65
|
+
KeyValueFormattingError: 0x6n,
|
|
66
|
+
InvalidPath: 0x8n,
|
|
67
|
+
MalformedPath: 0x9n,
|
|
68
|
+
GoawayTimeout: 0x10n,
|
|
69
|
+
ControlMessageTimeout: 0x11n,
|
|
70
|
+
DataStreamTimeout: 0x12n,
|
|
71
|
+
AuthTokenCacheOverflow: 0x13n,
|
|
72
|
+
DuplicateAuthTokenAlias: 0x14n,
|
|
73
|
+
VersionNegotiationFailed: 0x15n,
|
|
74
|
+
MalformedAuthToken: 0x16n,
|
|
75
|
+
UnknownAuthTokenAlias: 0x17n,
|
|
76
|
+
ExpiredAuthToken: 0x18n,
|
|
77
|
+
InvalidAuthority: 0x19n,
|
|
78
|
+
MalformedAuthority: 0x1an,
|
|
79
|
+
TooManyRequestUpdates: 0x1bn
|
|
80
|
+
// NEW in draft-19
|
|
81
|
+
};
|
|
82
|
+
var RequestErrorCode = {
|
|
83
|
+
InternalError: 0x0n,
|
|
84
|
+
Unauthorized: 0x1n,
|
|
85
|
+
Timeout: 0x2n,
|
|
86
|
+
NotSupported: 0x3n,
|
|
87
|
+
MalformedAuthToken: 0x4n,
|
|
88
|
+
ExpiredAuthToken: 0x5n,
|
|
89
|
+
GoingAway: 0x6n,
|
|
90
|
+
ExcessiveLoad: 0x9n,
|
|
91
|
+
DoesNotExist: 0x10n,
|
|
92
|
+
InvalidRange: 0x11n,
|
|
93
|
+
MalformedTrack: 0x12n,
|
|
94
|
+
// DuplicateSubscription (0x19) removed in draft-19 — multiple concurrent subscriptions per Track are now allowed
|
|
95
|
+
Uninterested: 0x20n,
|
|
96
|
+
PrefixOverlap: 0x30n,
|
|
97
|
+
NamespaceTooLarge: 0x31n,
|
|
98
|
+
InvalidJoiningRequestId: 0x32n,
|
|
99
|
+
UnsupportedExtension: 0x33n,
|
|
100
|
+
Redirect: 0x34n,
|
|
101
|
+
ConflictingFilters: 0x35n,
|
|
102
|
+
// NEW in draft-19
|
|
103
|
+
InvalidFilter: 0x36n
|
|
104
|
+
// NEW in draft-19
|
|
105
|
+
};
|
|
106
|
+
var PublishDoneCode = {
|
|
107
|
+
InternalError: 0x0n,
|
|
108
|
+
Unauthorized: 0x1n,
|
|
109
|
+
TrackEnded: 0x2n,
|
|
110
|
+
SubscriptionEnded: 0x3n,
|
|
111
|
+
GoingAway: 0x4n,
|
|
112
|
+
TooFarBehind: 0x5n,
|
|
113
|
+
Expired: 0x6n,
|
|
114
|
+
UpdateFailed: 0x8n,
|
|
115
|
+
ExcessiveLoad: 0x9n,
|
|
116
|
+
MalformedTrack: 0x12n
|
|
117
|
+
};
|
|
118
|
+
var DataStreamResetCode = {
|
|
119
|
+
InternalError: 0x0n,
|
|
120
|
+
Cancelled: 0x1n,
|
|
121
|
+
DeliveryTimeout: 0x2n,
|
|
122
|
+
SessionClosed: 0x3n,
|
|
123
|
+
GoingAway: 0x4n,
|
|
124
|
+
TooFarBehind: 0x5n,
|
|
125
|
+
UnknownObjectStatus: 0x6n,
|
|
126
|
+
ExpiredAuthToken: 0x7n,
|
|
127
|
+
ExcessiveLoad: 0x9n,
|
|
128
|
+
MalformedTrack: 0x12n
|
|
129
|
+
};
|
|
130
|
+
|
|
131
|
+
// src/drafts/draft19/index.ts
|
|
132
|
+
var DRAFT_VERSION = 0xff000013n;
|
|
133
|
+
|
|
134
|
+
|
|
135
|
+
|
|
136
|
+
|
|
137
|
+
|
|
138
|
+
|
|
139
|
+
|
|
140
|
+
|
|
141
|
+
|
|
142
|
+
|
|
143
|
+
|
|
144
|
+
|
|
145
|
+
|
|
146
|
+
|
|
147
|
+
|
|
148
|
+
|
|
149
|
+
|
|
150
|
+
|
|
151
|
+
|
|
152
|
+
|
|
153
|
+
|
|
154
|
+
|
|
155
|
+
|
|
156
|
+
|
|
157
|
+
|
|
158
|
+
|
|
159
|
+
|
|
160
|
+
|
|
161
|
+
|
|
162
|
+
|
|
163
|
+
|
|
164
|
+
|
|
165
|
+
|
|
166
|
+
|
|
167
|
+
|
|
168
|
+
|
|
169
|
+
|
|
170
|
+
|
|
171
|
+
|
|
172
|
+
|
|
173
|
+
|
|
174
|
+
|
|
175
|
+
|
|
176
|
+
|
|
177
|
+
|
|
178
|
+
|
|
179
|
+
|
|
180
|
+
|
|
181
|
+
|
|
182
|
+
|
|
183
|
+
|
|
184
|
+
|
|
185
|
+
|
|
186
|
+
|
|
187
|
+
|
|
188
|
+
|
|
189
|
+
exports.BIDIRECTIONAL_MESSAGES = _chunkCQ65LKPQcjs.BIDIRECTIONAL_MESSAGES; exports.CLIENT_ONLY_MESSAGES = _chunkCQ65LKPQcjs.CLIENT_ONLY_MESSAGES; exports.CONTROL_MESSAGES = _chunkCQ65LKPQcjs.CONTROL_MESSAGES; exports.DRAFT_VERSION = DRAFT_VERSION; exports.DataStreamResetCode = DataStreamResetCode; exports.Draft19SessionFSM = _chunkCQ65LKPQcjs.Draft19SessionFSM; exports.MESSAGE_ID_MAP = _chunkMH7537FBcjs.MESSAGE_ID_MAP; exports.MESSAGE_TYPE_MAP = _chunkMH7537FBcjs.MESSAGE_TYPE_MAP; exports.MSG_FETCH = _chunkMH7537FBcjs.MSG_FETCH; exports.MSG_FETCH_OK = _chunkMH7537FBcjs.MSG_FETCH_OK; exports.MSG_GOAWAY = _chunkMH7537FBcjs.MSG_GOAWAY; exports.MSG_NAMESPACE = _chunkMH7537FBcjs.MSG_NAMESPACE; exports.MSG_NAMESPACE_DONE = _chunkMH7537FBcjs.MSG_NAMESPACE_DONE; exports.MSG_PUBLISH = _chunkMH7537FBcjs.MSG_PUBLISH; exports.MSG_PUBLISH_DONE = _chunkMH7537FBcjs.MSG_PUBLISH_DONE; exports.MSG_PUBLISH_NAMESPACE = _chunkMH7537FBcjs.MSG_PUBLISH_NAMESPACE; exports.MSG_PUBLISH_OK = _chunkMH7537FBcjs.MSG_PUBLISH_OK; exports.MSG_PUBLISH_SKIPPED = _chunkMH7537FBcjs.MSG_PUBLISH_SKIPPED; exports.MSG_REQUEST_ERROR = _chunkMH7537FBcjs.MSG_REQUEST_ERROR; exports.MSG_REQUEST_OK = _chunkMH7537FBcjs.MSG_REQUEST_OK; exports.MSG_REQUEST_UPDATE = _chunkMH7537FBcjs.MSG_REQUEST_UPDATE; exports.MSG_SETUP = _chunkMH7537FBcjs.MSG_SETUP; exports.MSG_SUBSCRIBE = _chunkMH7537FBcjs.MSG_SUBSCRIBE; exports.MSG_SUBSCRIBE_NAMESPACE = _chunkMH7537FBcjs.MSG_SUBSCRIBE_NAMESPACE; exports.MSG_SUBSCRIBE_OK = _chunkMH7537FBcjs.MSG_SUBSCRIBE_OK; exports.MSG_SUBSCRIBE_TRACKS = _chunkMH7537FBcjs.MSG_SUBSCRIBE_TRACKS; exports.MSG_TRACK_STATUS = _chunkMH7537FBcjs.MSG_TRACK_STATUS; exports.PublishDoneCode = PublishDoneCode; exports.RequestErrorCode = RequestErrorCode; exports.SERVER_ONLY_MESSAGES = _chunkCQ65LKPQcjs.SERVER_ONLY_MESSAGES; exports.SETUP_OPT_AUTHORITY = _chunkMH7537FBcjs.SETUP_OPT_AUTHORITY; exports.SETUP_OPT_AUTHORIZATION_TOKEN = _chunkMH7537FBcjs.SETUP_OPT_AUTHORIZATION_TOKEN; exports.SETUP_OPT_MAX_AUTH_TOKEN_CACHE_SIZE = _chunkMH7537FBcjs.SETUP_OPT_MAX_AUTH_TOKEN_CACHE_SIZE; exports.SETUP_OPT_MAX_FILTER_RANGES = _chunkMH7537FBcjs.SETUP_OPT_MAX_FILTER_RANGES; exports.SETUP_OPT_MAX_REQUEST_UPDATES = _chunkMH7537FBcjs.SETUP_OPT_MAX_REQUEST_UPDATES; exports.SETUP_OPT_MOQT_IMPLEMENTATION = _chunkMH7537FBcjs.SETUP_OPT_MOQT_IMPLEMENTATION; exports.SETUP_OPT_PATH = _chunkMH7537FBcjs.SETUP_OPT_PATH; exports.SessionTerminationCode = SessionTerminationCode; exports.createDataStreamDecoder = _chunkMH7537FBcjs.createDataStreamDecoder; exports.createDraft19Codec = _chunkMH7537FBcjs.createDraft19Codec; exports.createDraft19SessionState = _chunkCQ65LKPQcjs.createDraft19SessionState; exports.createFetchStreamDecoder = _chunkMH7537FBcjs.createFetchStreamDecoder; exports.createStreamDecoder = _chunkMH7537FBcjs.createStreamDecoder; exports.createSubgroupStreamDecoder = _chunkMH7537FBcjs.createSubgroupStreamDecoder; exports.decodeDataStream = _chunkMH7537FBcjs.decodeDataStream; exports.decodeDatagram = _chunkMH7537FBcjs.decodeDatagram; exports.decodeFetchStream = _chunkMH7537FBcjs.decodeFetchStream; exports.decodeMessage = _chunkMH7537FBcjs.decodeMessage; exports.decodeSubgroupStream = _chunkMH7537FBcjs.decodeSubgroupStream; exports.encodeDatagram = _chunkMH7537FBcjs.encodeDatagram; exports.encodeFetchStream = _chunkMH7537FBcjs.encodeFetchStream; exports.encodeMessage = _chunkMH7537FBcjs.encodeMessage; exports.encodeSubgroupStream = _chunkMH7537FBcjs.encodeSubgroupStream; exports.getLegalIncoming = _chunkCQ65LKPQcjs.getLegalIncoming; exports.getLegalOutgoing = _chunkCQ65LKPQcjs.getLegalOutgoing;
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
export { D as Draft19Codec, c as createDraft19Codec, a as createStreamDecoder, d as decodeMessage, e as encodeMessage } from './codec-xeuGZY77.cjs';
|
|
2
|
+
import { b as DataStreamEvent, F as FetchStreamHeader, O as ObjectPayload, S as SubgroupStreamHeader, c as Draft19DataStream, d as DatagramObject, e as FetchStream, f as SubgroupStream, a as Draft19MessageType } from './types-zHgCS6o5.cjs';
|
|
3
|
+
export { g as DataStreamHeader, h as Draft19BaseMessage, i as Draft19Fetch, j as Draft19FetchOk, k as Draft19GoAway, D as Draft19Message, l as Draft19Namespace, m as Draft19NamespaceDone, n as Draft19Params, o as Draft19Publish, p as Draft19PublishDone, q as Draft19PublishNamespace, r as Draft19PublishSkipped, s as Draft19RequestError, t as Draft19RequestOk, u as Draft19RequestUpdate, v as Draft19Setup, w as Draft19SetupOptions, x as Draft19Subscribe, y as Draft19SubscribeNamespace, z as Draft19SubscribeOk, A as Draft19SubscribeTracks, B as Draft19TrackProperties, C as Draft19TrackStatus, E as FetchObjectPayload, J as JoiningFetch, L as LargestObject, G as LocationFilter, R as RangeFilter, H as RangeFilterRange, I as Redirect, K as StandaloneFetch, U as UnknownParam } from './types-zHgCS6o5.cjs';
|
|
4
|
+
export { Draft19SessionFSM, createDraft19SessionState } from './draft19-session.cjs';
|
|
5
|
+
export { P as ProtocolViolation, g as SessionPhase, h as SideEffect, T as TransitionResult, V as ValidationResult } from './session-types-KsqyVp6y.cjs';
|
|
6
|
+
import { b as DecodeResult } from './types-CdCSIfvI.cjs';
|
|
7
|
+
|
|
8
|
+
declare function encodeSubgroupStream(stream: SubgroupStream): Uint8Array;
|
|
9
|
+
declare function encodeDatagram(dg: DatagramObject): Uint8Array;
|
|
10
|
+
declare function encodeFetchStream(stream: FetchStream): Uint8Array;
|
|
11
|
+
declare function decodeSubgroupStream(bytes: Uint8Array): DecodeResult<SubgroupStream>;
|
|
12
|
+
declare function decodeDatagram(bytes: Uint8Array): DecodeResult<DatagramObject>;
|
|
13
|
+
declare function decodeFetchStream(bytes: Uint8Array): DecodeResult<FetchStream>;
|
|
14
|
+
declare function decodeDataStream(streamType: 'subgroup' | 'datagram' | 'fetch', bytes: Uint8Array): DecodeResult<Draft19DataStream>;
|
|
15
|
+
declare function createSubgroupStreamDecoder(): TransformStream<Uint8Array, SubgroupStreamHeader | ObjectPayload>;
|
|
16
|
+
declare function createFetchStreamDecoder(): TransformStream<Uint8Array, FetchStreamHeader | ObjectPayload>;
|
|
17
|
+
declare function createDataStreamDecoder(): TransformStream<Uint8Array, DataStreamEvent>;
|
|
18
|
+
|
|
19
|
+
declare const SessionTerminationCode: {
|
|
20
|
+
readonly NoError: 0n;
|
|
21
|
+
readonly InternalError: 1n;
|
|
22
|
+
readonly Unauthorized: 2n;
|
|
23
|
+
readonly ProtocolViolation: 3n;
|
|
24
|
+
readonly InvalidRequestId: 4n;
|
|
25
|
+
readonly DuplicateTrackAlias: 5n;
|
|
26
|
+
readonly KeyValueFormattingError: 6n;
|
|
27
|
+
readonly InvalidPath: 8n;
|
|
28
|
+
readonly MalformedPath: 9n;
|
|
29
|
+
readonly GoawayTimeout: 16n;
|
|
30
|
+
readonly ControlMessageTimeout: 17n;
|
|
31
|
+
readonly DataStreamTimeout: 18n;
|
|
32
|
+
readonly AuthTokenCacheOverflow: 19n;
|
|
33
|
+
readonly DuplicateAuthTokenAlias: 20n;
|
|
34
|
+
readonly VersionNegotiationFailed: 21n;
|
|
35
|
+
readonly MalformedAuthToken: 22n;
|
|
36
|
+
readonly UnknownAuthTokenAlias: 23n;
|
|
37
|
+
readonly ExpiredAuthToken: 24n;
|
|
38
|
+
readonly InvalidAuthority: 25n;
|
|
39
|
+
readonly MalformedAuthority: 26n;
|
|
40
|
+
readonly TooManyRequestUpdates: 27n;
|
|
41
|
+
};
|
|
42
|
+
type SessionTerminationCodeValue = (typeof SessionTerminationCode)[keyof typeof SessionTerminationCode];
|
|
43
|
+
declare const RequestErrorCode: {
|
|
44
|
+
readonly InternalError: 0n;
|
|
45
|
+
readonly Unauthorized: 1n;
|
|
46
|
+
readonly Timeout: 2n;
|
|
47
|
+
readonly NotSupported: 3n;
|
|
48
|
+
readonly MalformedAuthToken: 4n;
|
|
49
|
+
readonly ExpiredAuthToken: 5n;
|
|
50
|
+
readonly GoingAway: 6n;
|
|
51
|
+
readonly ExcessiveLoad: 9n;
|
|
52
|
+
readonly DoesNotExist: 16n;
|
|
53
|
+
readonly InvalidRange: 17n;
|
|
54
|
+
readonly MalformedTrack: 18n;
|
|
55
|
+
readonly Uninterested: 32n;
|
|
56
|
+
readonly PrefixOverlap: 48n;
|
|
57
|
+
readonly NamespaceTooLarge: 49n;
|
|
58
|
+
readonly InvalidJoiningRequestId: 50n;
|
|
59
|
+
readonly UnsupportedExtension: 51n;
|
|
60
|
+
readonly Redirect: 52n;
|
|
61
|
+
readonly ConflictingFilters: 53n;
|
|
62
|
+
readonly InvalidFilter: 54n;
|
|
63
|
+
};
|
|
64
|
+
type RequestErrorCodeValue = (typeof RequestErrorCode)[keyof typeof RequestErrorCode];
|
|
65
|
+
declare const PublishDoneCode: {
|
|
66
|
+
readonly InternalError: 0n;
|
|
67
|
+
readonly Unauthorized: 1n;
|
|
68
|
+
readonly TrackEnded: 2n;
|
|
69
|
+
readonly SubscriptionEnded: 3n;
|
|
70
|
+
readonly GoingAway: 4n;
|
|
71
|
+
readonly TooFarBehind: 5n;
|
|
72
|
+
readonly Expired: 6n;
|
|
73
|
+
readonly UpdateFailed: 8n;
|
|
74
|
+
readonly ExcessiveLoad: 9n;
|
|
75
|
+
readonly MalformedTrack: 18n;
|
|
76
|
+
};
|
|
77
|
+
type PublishDoneCodeValue = (typeof PublishDoneCode)[keyof typeof PublishDoneCode];
|
|
78
|
+
declare const DataStreamResetCode: {
|
|
79
|
+
readonly InternalError: 0n;
|
|
80
|
+
readonly Cancelled: 1n;
|
|
81
|
+
readonly DeliveryTimeout: 2n;
|
|
82
|
+
readonly SessionClosed: 3n;
|
|
83
|
+
readonly GoingAway: 4n;
|
|
84
|
+
readonly TooFarBehind: 5n;
|
|
85
|
+
readonly UnknownObjectStatus: 6n;
|
|
86
|
+
readonly ExpiredAuthToken: 7n;
|
|
87
|
+
readonly ExcessiveLoad: 9n;
|
|
88
|
+
readonly MalformedTrack: 18n;
|
|
89
|
+
};
|
|
90
|
+
type DataStreamResetCodeValue = (typeof DataStreamResetCode)[keyof typeof DataStreamResetCode];
|
|
91
|
+
|
|
92
|
+
declare const MSG_REQUEST_UPDATE = 2n;
|
|
93
|
+
declare const MSG_SUBSCRIBE = 3n;
|
|
94
|
+
declare const MSG_SUBSCRIBE_OK = 4n;
|
|
95
|
+
declare const MSG_REQUEST_ERROR = 5n;
|
|
96
|
+
declare const MSG_PUBLISH_NAMESPACE = 6n;
|
|
97
|
+
declare const MSG_REQUEST_OK = 7n;
|
|
98
|
+
declare const MSG_NAMESPACE = 8n;
|
|
99
|
+
declare const MSG_PUBLISH_DONE = 11n;
|
|
100
|
+
declare const MSG_TRACK_STATUS = 13n;
|
|
101
|
+
declare const MSG_NAMESPACE_DONE = 14n;
|
|
102
|
+
declare const MSG_PUBLISH_SKIPPED = 15n;
|
|
103
|
+
declare const MSG_GOAWAY = 16n;
|
|
104
|
+
declare const MSG_FETCH = 22n;
|
|
105
|
+
declare const MSG_FETCH_OK = 24n;
|
|
106
|
+
declare const MSG_PUBLISH = 29n;
|
|
107
|
+
declare const MSG_PUBLISH_OK = 7n;
|
|
108
|
+
declare const MSG_SUBSCRIBE_NAMESPACE = 80n;
|
|
109
|
+
declare const MSG_SUBSCRIBE_TRACKS = 81n;
|
|
110
|
+
declare const MSG_SETUP = 12032n;
|
|
111
|
+
declare const SETUP_OPT_PATH = 1n;
|
|
112
|
+
declare const SETUP_OPT_AUTHORIZATION_TOKEN = 3n;
|
|
113
|
+
declare const SETUP_OPT_MAX_AUTH_TOKEN_CACHE_SIZE = 4n;
|
|
114
|
+
declare const SETUP_OPT_AUTHORITY = 5n;
|
|
115
|
+
declare const SETUP_OPT_MAX_FILTER_RANGES = 6n;
|
|
116
|
+
declare const SETUP_OPT_MOQT_IMPLEMENTATION = 7n;
|
|
117
|
+
declare const SETUP_OPT_MAX_REQUEST_UPDATES = 8n;
|
|
118
|
+
declare const MESSAGE_TYPE_MAP: ReadonlyMap<bigint, string>;
|
|
119
|
+
declare const MESSAGE_ID_MAP: ReadonlyMap<string, bigint>;
|
|
120
|
+
|
|
121
|
+
declare const CONTROL_MESSAGES: ReadonlySet<Draft19MessageType>;
|
|
122
|
+
declare const CLIENT_ONLY_MESSAGES: ReadonlySet<Draft19MessageType>;
|
|
123
|
+
declare const SERVER_ONLY_MESSAGES: ReadonlySet<Draft19MessageType>;
|
|
124
|
+
declare const BIDIRECTIONAL_MESSAGES: ReadonlySet<Draft19MessageType>;
|
|
125
|
+
declare function getLegalOutgoing(phase: string, _role: 'client' | 'server'): Set<Draft19MessageType>;
|
|
126
|
+
declare function getLegalIncoming(phase: string, role: 'client' | 'server'): Set<Draft19MessageType>;
|
|
127
|
+
|
|
128
|
+
declare const DRAFT_VERSION = 4278190099n;
|
|
129
|
+
|
|
130
|
+
export { BIDIRECTIONAL_MESSAGES, CLIENT_ONLY_MESSAGES, CONTROL_MESSAGES, DRAFT_VERSION, DataStreamEvent, DataStreamResetCode, type DataStreamResetCodeValue, DatagramObject, Draft19DataStream, Draft19MessageType, FetchStream, FetchStreamHeader, MESSAGE_ID_MAP, MESSAGE_TYPE_MAP, MSG_FETCH, MSG_FETCH_OK, MSG_GOAWAY, MSG_NAMESPACE, MSG_NAMESPACE_DONE, MSG_PUBLISH, MSG_PUBLISH_DONE, MSG_PUBLISH_NAMESPACE, MSG_PUBLISH_OK, MSG_PUBLISH_SKIPPED, MSG_REQUEST_ERROR, MSG_REQUEST_OK, MSG_REQUEST_UPDATE, MSG_SETUP, MSG_SUBSCRIBE, MSG_SUBSCRIBE_NAMESPACE, MSG_SUBSCRIBE_OK, MSG_SUBSCRIBE_TRACKS, MSG_TRACK_STATUS, ObjectPayload, PublishDoneCode, type PublishDoneCodeValue, RequestErrorCode, type RequestErrorCodeValue, SERVER_ONLY_MESSAGES, SETUP_OPT_AUTHORITY, SETUP_OPT_AUTHORIZATION_TOKEN, SETUP_OPT_MAX_AUTH_TOKEN_CACHE_SIZE, SETUP_OPT_MAX_FILTER_RANGES, SETUP_OPT_MAX_REQUEST_UPDATES, SETUP_OPT_MOQT_IMPLEMENTATION, SETUP_OPT_PATH, SessionTerminationCode, type SessionTerminationCodeValue, SubgroupStream, SubgroupStreamHeader, createDataStreamDecoder, createFetchStreamDecoder, createSubgroupStreamDecoder, decodeDataStream, decodeDatagram, decodeFetchStream, decodeSubgroupStream, encodeDatagram, encodeFetchStream, encodeSubgroupStream, getLegalIncoming, getLegalOutgoing };
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
export { D as Draft19Codec, c as createDraft19Codec, a as createStreamDecoder, d as decodeMessage, e as encodeMessage } from './codec-DAePx2NL.js';
|
|
2
|
+
import { b as DataStreamEvent, F as FetchStreamHeader, O as ObjectPayload, S as SubgroupStreamHeader, c as Draft19DataStream, d as DatagramObject, e as FetchStream, f as SubgroupStream, a as Draft19MessageType } from './types-zHgCS6o5.js';
|
|
3
|
+
export { g as DataStreamHeader, h as Draft19BaseMessage, i as Draft19Fetch, j as Draft19FetchOk, k as Draft19GoAway, D as Draft19Message, l as Draft19Namespace, m as Draft19NamespaceDone, n as Draft19Params, o as Draft19Publish, p as Draft19PublishDone, q as Draft19PublishNamespace, r as Draft19PublishSkipped, s as Draft19RequestError, t as Draft19RequestOk, u as Draft19RequestUpdate, v as Draft19Setup, w as Draft19SetupOptions, x as Draft19Subscribe, y as Draft19SubscribeNamespace, z as Draft19SubscribeOk, A as Draft19SubscribeTracks, B as Draft19TrackProperties, C as Draft19TrackStatus, E as FetchObjectPayload, J as JoiningFetch, L as LargestObject, G as LocationFilter, R as RangeFilter, H as RangeFilterRange, I as Redirect, K as StandaloneFetch, U as UnknownParam } from './types-zHgCS6o5.js';
|
|
4
|
+
export { Draft19SessionFSM, createDraft19SessionState } from './draft19-session.js';
|
|
5
|
+
export { P as ProtocolViolation, g as SessionPhase, h as SideEffect, T as TransitionResult, V as ValidationResult } from './session-types-C0l_-Ups.js';
|
|
6
|
+
import { b as DecodeResult } from './types-CdCSIfvI.js';
|
|
7
|
+
|
|
8
|
+
declare function encodeSubgroupStream(stream: SubgroupStream): Uint8Array;
|
|
9
|
+
declare function encodeDatagram(dg: DatagramObject): Uint8Array;
|
|
10
|
+
declare function encodeFetchStream(stream: FetchStream): Uint8Array;
|
|
11
|
+
declare function decodeSubgroupStream(bytes: Uint8Array): DecodeResult<SubgroupStream>;
|
|
12
|
+
declare function decodeDatagram(bytes: Uint8Array): DecodeResult<DatagramObject>;
|
|
13
|
+
declare function decodeFetchStream(bytes: Uint8Array): DecodeResult<FetchStream>;
|
|
14
|
+
declare function decodeDataStream(streamType: 'subgroup' | 'datagram' | 'fetch', bytes: Uint8Array): DecodeResult<Draft19DataStream>;
|
|
15
|
+
declare function createSubgroupStreamDecoder(): TransformStream<Uint8Array, SubgroupStreamHeader | ObjectPayload>;
|
|
16
|
+
declare function createFetchStreamDecoder(): TransformStream<Uint8Array, FetchStreamHeader | ObjectPayload>;
|
|
17
|
+
declare function createDataStreamDecoder(): TransformStream<Uint8Array, DataStreamEvent>;
|
|
18
|
+
|
|
19
|
+
declare const SessionTerminationCode: {
|
|
20
|
+
readonly NoError: 0n;
|
|
21
|
+
readonly InternalError: 1n;
|
|
22
|
+
readonly Unauthorized: 2n;
|
|
23
|
+
readonly ProtocolViolation: 3n;
|
|
24
|
+
readonly InvalidRequestId: 4n;
|
|
25
|
+
readonly DuplicateTrackAlias: 5n;
|
|
26
|
+
readonly KeyValueFormattingError: 6n;
|
|
27
|
+
readonly InvalidPath: 8n;
|
|
28
|
+
readonly MalformedPath: 9n;
|
|
29
|
+
readonly GoawayTimeout: 16n;
|
|
30
|
+
readonly ControlMessageTimeout: 17n;
|
|
31
|
+
readonly DataStreamTimeout: 18n;
|
|
32
|
+
readonly AuthTokenCacheOverflow: 19n;
|
|
33
|
+
readonly DuplicateAuthTokenAlias: 20n;
|
|
34
|
+
readonly VersionNegotiationFailed: 21n;
|
|
35
|
+
readonly MalformedAuthToken: 22n;
|
|
36
|
+
readonly UnknownAuthTokenAlias: 23n;
|
|
37
|
+
readonly ExpiredAuthToken: 24n;
|
|
38
|
+
readonly InvalidAuthority: 25n;
|
|
39
|
+
readonly MalformedAuthority: 26n;
|
|
40
|
+
readonly TooManyRequestUpdates: 27n;
|
|
41
|
+
};
|
|
42
|
+
type SessionTerminationCodeValue = (typeof SessionTerminationCode)[keyof typeof SessionTerminationCode];
|
|
43
|
+
declare const RequestErrorCode: {
|
|
44
|
+
readonly InternalError: 0n;
|
|
45
|
+
readonly Unauthorized: 1n;
|
|
46
|
+
readonly Timeout: 2n;
|
|
47
|
+
readonly NotSupported: 3n;
|
|
48
|
+
readonly MalformedAuthToken: 4n;
|
|
49
|
+
readonly ExpiredAuthToken: 5n;
|
|
50
|
+
readonly GoingAway: 6n;
|
|
51
|
+
readonly ExcessiveLoad: 9n;
|
|
52
|
+
readonly DoesNotExist: 16n;
|
|
53
|
+
readonly InvalidRange: 17n;
|
|
54
|
+
readonly MalformedTrack: 18n;
|
|
55
|
+
readonly Uninterested: 32n;
|
|
56
|
+
readonly PrefixOverlap: 48n;
|
|
57
|
+
readonly NamespaceTooLarge: 49n;
|
|
58
|
+
readonly InvalidJoiningRequestId: 50n;
|
|
59
|
+
readonly UnsupportedExtension: 51n;
|
|
60
|
+
readonly Redirect: 52n;
|
|
61
|
+
readonly ConflictingFilters: 53n;
|
|
62
|
+
readonly InvalidFilter: 54n;
|
|
63
|
+
};
|
|
64
|
+
type RequestErrorCodeValue = (typeof RequestErrorCode)[keyof typeof RequestErrorCode];
|
|
65
|
+
declare const PublishDoneCode: {
|
|
66
|
+
readonly InternalError: 0n;
|
|
67
|
+
readonly Unauthorized: 1n;
|
|
68
|
+
readonly TrackEnded: 2n;
|
|
69
|
+
readonly SubscriptionEnded: 3n;
|
|
70
|
+
readonly GoingAway: 4n;
|
|
71
|
+
readonly TooFarBehind: 5n;
|
|
72
|
+
readonly Expired: 6n;
|
|
73
|
+
readonly UpdateFailed: 8n;
|
|
74
|
+
readonly ExcessiveLoad: 9n;
|
|
75
|
+
readonly MalformedTrack: 18n;
|
|
76
|
+
};
|
|
77
|
+
type PublishDoneCodeValue = (typeof PublishDoneCode)[keyof typeof PublishDoneCode];
|
|
78
|
+
declare const DataStreamResetCode: {
|
|
79
|
+
readonly InternalError: 0n;
|
|
80
|
+
readonly Cancelled: 1n;
|
|
81
|
+
readonly DeliveryTimeout: 2n;
|
|
82
|
+
readonly SessionClosed: 3n;
|
|
83
|
+
readonly GoingAway: 4n;
|
|
84
|
+
readonly TooFarBehind: 5n;
|
|
85
|
+
readonly UnknownObjectStatus: 6n;
|
|
86
|
+
readonly ExpiredAuthToken: 7n;
|
|
87
|
+
readonly ExcessiveLoad: 9n;
|
|
88
|
+
readonly MalformedTrack: 18n;
|
|
89
|
+
};
|
|
90
|
+
type DataStreamResetCodeValue = (typeof DataStreamResetCode)[keyof typeof DataStreamResetCode];
|
|
91
|
+
|
|
92
|
+
declare const MSG_REQUEST_UPDATE = 2n;
|
|
93
|
+
declare const MSG_SUBSCRIBE = 3n;
|
|
94
|
+
declare const MSG_SUBSCRIBE_OK = 4n;
|
|
95
|
+
declare const MSG_REQUEST_ERROR = 5n;
|
|
96
|
+
declare const MSG_PUBLISH_NAMESPACE = 6n;
|
|
97
|
+
declare const MSG_REQUEST_OK = 7n;
|
|
98
|
+
declare const MSG_NAMESPACE = 8n;
|
|
99
|
+
declare const MSG_PUBLISH_DONE = 11n;
|
|
100
|
+
declare const MSG_TRACK_STATUS = 13n;
|
|
101
|
+
declare const MSG_NAMESPACE_DONE = 14n;
|
|
102
|
+
declare const MSG_PUBLISH_SKIPPED = 15n;
|
|
103
|
+
declare const MSG_GOAWAY = 16n;
|
|
104
|
+
declare const MSG_FETCH = 22n;
|
|
105
|
+
declare const MSG_FETCH_OK = 24n;
|
|
106
|
+
declare const MSG_PUBLISH = 29n;
|
|
107
|
+
declare const MSG_PUBLISH_OK = 7n;
|
|
108
|
+
declare const MSG_SUBSCRIBE_NAMESPACE = 80n;
|
|
109
|
+
declare const MSG_SUBSCRIBE_TRACKS = 81n;
|
|
110
|
+
declare const MSG_SETUP = 12032n;
|
|
111
|
+
declare const SETUP_OPT_PATH = 1n;
|
|
112
|
+
declare const SETUP_OPT_AUTHORIZATION_TOKEN = 3n;
|
|
113
|
+
declare const SETUP_OPT_MAX_AUTH_TOKEN_CACHE_SIZE = 4n;
|
|
114
|
+
declare const SETUP_OPT_AUTHORITY = 5n;
|
|
115
|
+
declare const SETUP_OPT_MAX_FILTER_RANGES = 6n;
|
|
116
|
+
declare const SETUP_OPT_MOQT_IMPLEMENTATION = 7n;
|
|
117
|
+
declare const SETUP_OPT_MAX_REQUEST_UPDATES = 8n;
|
|
118
|
+
declare const MESSAGE_TYPE_MAP: ReadonlyMap<bigint, string>;
|
|
119
|
+
declare const MESSAGE_ID_MAP: ReadonlyMap<string, bigint>;
|
|
120
|
+
|
|
121
|
+
declare const CONTROL_MESSAGES: ReadonlySet<Draft19MessageType>;
|
|
122
|
+
declare const CLIENT_ONLY_MESSAGES: ReadonlySet<Draft19MessageType>;
|
|
123
|
+
declare const SERVER_ONLY_MESSAGES: ReadonlySet<Draft19MessageType>;
|
|
124
|
+
declare const BIDIRECTIONAL_MESSAGES: ReadonlySet<Draft19MessageType>;
|
|
125
|
+
declare function getLegalOutgoing(phase: string, _role: 'client' | 'server'): Set<Draft19MessageType>;
|
|
126
|
+
declare function getLegalIncoming(phase: string, role: 'client' | 'server'): Set<Draft19MessageType>;
|
|
127
|
+
|
|
128
|
+
declare const DRAFT_VERSION = 4278190099n;
|
|
129
|
+
|
|
130
|
+
export { BIDIRECTIONAL_MESSAGES, CLIENT_ONLY_MESSAGES, CONTROL_MESSAGES, DRAFT_VERSION, DataStreamEvent, DataStreamResetCode, type DataStreamResetCodeValue, DatagramObject, Draft19DataStream, Draft19MessageType, FetchStream, FetchStreamHeader, MESSAGE_ID_MAP, MESSAGE_TYPE_MAP, MSG_FETCH, MSG_FETCH_OK, MSG_GOAWAY, MSG_NAMESPACE, MSG_NAMESPACE_DONE, MSG_PUBLISH, MSG_PUBLISH_DONE, MSG_PUBLISH_NAMESPACE, MSG_PUBLISH_OK, MSG_PUBLISH_SKIPPED, MSG_REQUEST_ERROR, MSG_REQUEST_OK, MSG_REQUEST_UPDATE, MSG_SETUP, MSG_SUBSCRIBE, MSG_SUBSCRIBE_NAMESPACE, MSG_SUBSCRIBE_OK, MSG_SUBSCRIBE_TRACKS, MSG_TRACK_STATUS, ObjectPayload, PublishDoneCode, type PublishDoneCodeValue, RequestErrorCode, type RequestErrorCodeValue, SERVER_ONLY_MESSAGES, SETUP_OPT_AUTHORITY, SETUP_OPT_AUTHORIZATION_TOKEN, SETUP_OPT_MAX_AUTH_TOKEN_CACHE_SIZE, SETUP_OPT_MAX_FILTER_RANGES, SETUP_OPT_MAX_REQUEST_UPDATES, SETUP_OPT_MOQT_IMPLEMENTATION, SETUP_OPT_PATH, SessionTerminationCode, type SessionTerminationCodeValue, SubgroupStream, SubgroupStreamHeader, createDataStreamDecoder, createFetchStreamDecoder, createSubgroupStreamDecoder, decodeDataStream, decodeDatagram, decodeFetchStream, decodeSubgroupStream, encodeDatagram, encodeFetchStream, encodeSubgroupStream, getLegalIncoming, getLegalOutgoing };
|
package/dist/draft19.js
ADDED
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
import {
|
|
2
|
+
MESSAGE_ID_MAP,
|
|
3
|
+
MESSAGE_TYPE_MAP,
|
|
4
|
+
MSG_FETCH,
|
|
5
|
+
MSG_FETCH_OK,
|
|
6
|
+
MSG_GOAWAY,
|
|
7
|
+
MSG_NAMESPACE,
|
|
8
|
+
MSG_NAMESPACE_DONE,
|
|
9
|
+
MSG_PUBLISH,
|
|
10
|
+
MSG_PUBLISH_DONE,
|
|
11
|
+
MSG_PUBLISH_NAMESPACE,
|
|
12
|
+
MSG_PUBLISH_OK,
|
|
13
|
+
MSG_PUBLISH_SKIPPED,
|
|
14
|
+
MSG_REQUEST_ERROR,
|
|
15
|
+
MSG_REQUEST_OK,
|
|
16
|
+
MSG_REQUEST_UPDATE,
|
|
17
|
+
MSG_SETUP,
|
|
18
|
+
MSG_SUBSCRIBE,
|
|
19
|
+
MSG_SUBSCRIBE_NAMESPACE,
|
|
20
|
+
MSG_SUBSCRIBE_OK,
|
|
21
|
+
MSG_SUBSCRIBE_TRACKS,
|
|
22
|
+
MSG_TRACK_STATUS,
|
|
23
|
+
SETUP_OPT_AUTHORITY,
|
|
24
|
+
SETUP_OPT_AUTHORIZATION_TOKEN,
|
|
25
|
+
SETUP_OPT_MAX_AUTH_TOKEN_CACHE_SIZE,
|
|
26
|
+
SETUP_OPT_MAX_FILTER_RANGES,
|
|
27
|
+
SETUP_OPT_MAX_REQUEST_UPDATES,
|
|
28
|
+
SETUP_OPT_MOQT_IMPLEMENTATION,
|
|
29
|
+
SETUP_OPT_PATH,
|
|
30
|
+
createDataStreamDecoder,
|
|
31
|
+
createDraft19Codec,
|
|
32
|
+
createFetchStreamDecoder,
|
|
33
|
+
createStreamDecoder,
|
|
34
|
+
createSubgroupStreamDecoder,
|
|
35
|
+
decodeDataStream,
|
|
36
|
+
decodeDatagram,
|
|
37
|
+
decodeFetchStream,
|
|
38
|
+
decodeMessage,
|
|
39
|
+
decodeSubgroupStream,
|
|
40
|
+
encodeDatagram,
|
|
41
|
+
encodeFetchStream,
|
|
42
|
+
encodeMessage,
|
|
43
|
+
encodeSubgroupStream
|
|
44
|
+
} from "./chunk-APTV6F72.js";
|
|
45
|
+
import {
|
|
46
|
+
BIDIRECTIONAL_MESSAGES,
|
|
47
|
+
CLIENT_ONLY_MESSAGES,
|
|
48
|
+
CONTROL_MESSAGES,
|
|
49
|
+
Draft19SessionFSM,
|
|
50
|
+
SERVER_ONLY_MESSAGES,
|
|
51
|
+
createDraft19SessionState,
|
|
52
|
+
getLegalIncoming,
|
|
53
|
+
getLegalOutgoing
|
|
54
|
+
} from "./chunk-O5DQ44TM.js";
|
|
55
|
+
import "./chunk-KLPWJU6W.js";
|
|
56
|
+
|
|
57
|
+
// src/drafts/draft19/error-codes.ts
|
|
58
|
+
var SessionTerminationCode = {
|
|
59
|
+
NoError: 0x0n,
|
|
60
|
+
InternalError: 0x1n,
|
|
61
|
+
Unauthorized: 0x2n,
|
|
62
|
+
ProtocolViolation: 0x3n,
|
|
63
|
+
InvalidRequestId: 0x4n,
|
|
64
|
+
DuplicateTrackAlias: 0x5n,
|
|
65
|
+
KeyValueFormattingError: 0x6n,
|
|
66
|
+
InvalidPath: 0x8n,
|
|
67
|
+
MalformedPath: 0x9n,
|
|
68
|
+
GoawayTimeout: 0x10n,
|
|
69
|
+
ControlMessageTimeout: 0x11n,
|
|
70
|
+
DataStreamTimeout: 0x12n,
|
|
71
|
+
AuthTokenCacheOverflow: 0x13n,
|
|
72
|
+
DuplicateAuthTokenAlias: 0x14n,
|
|
73
|
+
VersionNegotiationFailed: 0x15n,
|
|
74
|
+
MalformedAuthToken: 0x16n,
|
|
75
|
+
UnknownAuthTokenAlias: 0x17n,
|
|
76
|
+
ExpiredAuthToken: 0x18n,
|
|
77
|
+
InvalidAuthority: 0x19n,
|
|
78
|
+
MalformedAuthority: 0x1an,
|
|
79
|
+
TooManyRequestUpdates: 0x1bn
|
|
80
|
+
// NEW in draft-19
|
|
81
|
+
};
|
|
82
|
+
var RequestErrorCode = {
|
|
83
|
+
InternalError: 0x0n,
|
|
84
|
+
Unauthorized: 0x1n,
|
|
85
|
+
Timeout: 0x2n,
|
|
86
|
+
NotSupported: 0x3n,
|
|
87
|
+
MalformedAuthToken: 0x4n,
|
|
88
|
+
ExpiredAuthToken: 0x5n,
|
|
89
|
+
GoingAway: 0x6n,
|
|
90
|
+
ExcessiveLoad: 0x9n,
|
|
91
|
+
DoesNotExist: 0x10n,
|
|
92
|
+
InvalidRange: 0x11n,
|
|
93
|
+
MalformedTrack: 0x12n,
|
|
94
|
+
// DuplicateSubscription (0x19) removed in draft-19 — multiple concurrent subscriptions per Track are now allowed
|
|
95
|
+
Uninterested: 0x20n,
|
|
96
|
+
PrefixOverlap: 0x30n,
|
|
97
|
+
NamespaceTooLarge: 0x31n,
|
|
98
|
+
InvalidJoiningRequestId: 0x32n,
|
|
99
|
+
UnsupportedExtension: 0x33n,
|
|
100
|
+
Redirect: 0x34n,
|
|
101
|
+
ConflictingFilters: 0x35n,
|
|
102
|
+
// NEW in draft-19
|
|
103
|
+
InvalidFilter: 0x36n
|
|
104
|
+
// NEW in draft-19
|
|
105
|
+
};
|
|
106
|
+
var PublishDoneCode = {
|
|
107
|
+
InternalError: 0x0n,
|
|
108
|
+
Unauthorized: 0x1n,
|
|
109
|
+
TrackEnded: 0x2n,
|
|
110
|
+
SubscriptionEnded: 0x3n,
|
|
111
|
+
GoingAway: 0x4n,
|
|
112
|
+
TooFarBehind: 0x5n,
|
|
113
|
+
Expired: 0x6n,
|
|
114
|
+
UpdateFailed: 0x8n,
|
|
115
|
+
ExcessiveLoad: 0x9n,
|
|
116
|
+
MalformedTrack: 0x12n
|
|
117
|
+
};
|
|
118
|
+
var DataStreamResetCode = {
|
|
119
|
+
InternalError: 0x0n,
|
|
120
|
+
Cancelled: 0x1n,
|
|
121
|
+
DeliveryTimeout: 0x2n,
|
|
122
|
+
SessionClosed: 0x3n,
|
|
123
|
+
GoingAway: 0x4n,
|
|
124
|
+
TooFarBehind: 0x5n,
|
|
125
|
+
UnknownObjectStatus: 0x6n,
|
|
126
|
+
ExpiredAuthToken: 0x7n,
|
|
127
|
+
ExcessiveLoad: 0x9n,
|
|
128
|
+
MalformedTrack: 0x12n
|
|
129
|
+
};
|
|
130
|
+
|
|
131
|
+
// src/drafts/draft19/index.ts
|
|
132
|
+
var DRAFT_VERSION = 0xff000013n;
|
|
133
|
+
export {
|
|
134
|
+
BIDIRECTIONAL_MESSAGES,
|
|
135
|
+
CLIENT_ONLY_MESSAGES,
|
|
136
|
+
CONTROL_MESSAGES,
|
|
137
|
+
DRAFT_VERSION,
|
|
138
|
+
DataStreamResetCode,
|
|
139
|
+
Draft19SessionFSM,
|
|
140
|
+
MESSAGE_ID_MAP,
|
|
141
|
+
MESSAGE_TYPE_MAP,
|
|
142
|
+
MSG_FETCH,
|
|
143
|
+
MSG_FETCH_OK,
|
|
144
|
+
MSG_GOAWAY,
|
|
145
|
+
MSG_NAMESPACE,
|
|
146
|
+
MSG_NAMESPACE_DONE,
|
|
147
|
+
MSG_PUBLISH,
|
|
148
|
+
MSG_PUBLISH_DONE,
|
|
149
|
+
MSG_PUBLISH_NAMESPACE,
|
|
150
|
+
MSG_PUBLISH_OK,
|
|
151
|
+
MSG_PUBLISH_SKIPPED,
|
|
152
|
+
MSG_REQUEST_ERROR,
|
|
153
|
+
MSG_REQUEST_OK,
|
|
154
|
+
MSG_REQUEST_UPDATE,
|
|
155
|
+
MSG_SETUP,
|
|
156
|
+
MSG_SUBSCRIBE,
|
|
157
|
+
MSG_SUBSCRIBE_NAMESPACE,
|
|
158
|
+
MSG_SUBSCRIBE_OK,
|
|
159
|
+
MSG_SUBSCRIBE_TRACKS,
|
|
160
|
+
MSG_TRACK_STATUS,
|
|
161
|
+
PublishDoneCode,
|
|
162
|
+
RequestErrorCode,
|
|
163
|
+
SERVER_ONLY_MESSAGES,
|
|
164
|
+
SETUP_OPT_AUTHORITY,
|
|
165
|
+
SETUP_OPT_AUTHORIZATION_TOKEN,
|
|
166
|
+
SETUP_OPT_MAX_AUTH_TOKEN_CACHE_SIZE,
|
|
167
|
+
SETUP_OPT_MAX_FILTER_RANGES,
|
|
168
|
+
SETUP_OPT_MAX_REQUEST_UPDATES,
|
|
169
|
+
SETUP_OPT_MOQT_IMPLEMENTATION,
|
|
170
|
+
SETUP_OPT_PATH,
|
|
171
|
+
SessionTerminationCode,
|
|
172
|
+
createDataStreamDecoder,
|
|
173
|
+
createDraft19Codec,
|
|
174
|
+
createDraft19SessionState,
|
|
175
|
+
createFetchStreamDecoder,
|
|
176
|
+
createStreamDecoder,
|
|
177
|
+
createSubgroupStreamDecoder,
|
|
178
|
+
decodeDataStream,
|
|
179
|
+
decodeDatagram,
|
|
180
|
+
decodeFetchStream,
|
|
181
|
+
decodeMessage,
|
|
182
|
+
decodeSubgroupStream,
|
|
183
|
+
encodeDatagram,
|
|
184
|
+
encodeFetchStream,
|
|
185
|
+
encodeMessage,
|
|
186
|
+
encodeSubgroupStream,
|
|
187
|
+
getLegalIncoming,
|
|
188
|
+
getLegalOutgoing
|
|
189
|
+
};
|