@moqtap/codec 0.10.0 → 0.12.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/CHANGELOG.md +175 -0
- package/README.md +3 -2
- package/dist/auth-redaction-B9JJOlIY.d.cts +100 -0
- package/dist/auth-redaction-B9JJOlIY.d.ts +100 -0
- package/dist/{chunk-RYKQXBG6.cjs → chunk-27K5BUAG.cjs} +481 -517
- package/dist/{chunk-WCPENYNE.js → chunk-3RNQMGKA.js} +359 -390
- package/dist/{chunk-TSUZ6GJV.js → chunk-5AWIXOLB.js} +438 -469
- package/dist/{chunk-4XLYCT5Q.cjs → chunk-5IMHJIAZ.cjs} +52 -2
- package/dist/{chunk-KTNERCTZ.cjs → chunk-5JGZCKJO.cjs} +488 -518
- package/dist/{chunk-WCTMPDUX.cjs → chunk-73K4OSAN.cjs} +401 -432
- package/dist/{chunk-N2V7Z37J.js → chunk-7VQKRGRD.js} +19 -3
- package/dist/{chunk-BIBMDTU5.cjs → chunk-A3UCQOIB.cjs} +486 -517
- package/dist/{chunk-K2B3OVFK.js → chunk-A7PDMVXM.js} +24 -3
- package/dist/{chunk-VZHL2U2N.cjs → chunk-A7VQO6YC.cjs} +54 -38
- package/dist/{chunk-AQ445VV7.cjs → chunk-ACQHZLRZ.cjs} +66 -46
- package/dist/{chunk-L5DRACXS.js → chunk-BBICOMW6.js} +25 -3
- package/dist/{chunk-T4VWPKDG.cjs → chunk-BNIUVOCJ.cjs} +529 -599
- package/dist/{chunk-UKKDOOUO.cjs → chunk-CNC6ANS4.cjs} +58 -37
- package/dist/{chunk-OZRK73NQ.js → chunk-FDLQSWHK.js} +433 -469
- package/dist/{chunk-IJAF6PAY.js → chunk-FFNOE4UR.js} +19 -3
- package/dist/{chunk-CZNW3R5E.cjs → chunk-GMENT63T.cjs} +54 -38
- package/dist/{chunk-XCRCAUGI.cjs → chunk-HM7BLRVP.cjs} +291 -297
- package/dist/{chunk-XHAP2YST.js → chunk-HZONHFNO.js} +19 -3
- package/dist/{chunk-SDJTSMOW.cjs → chunk-ILYABWDK.cjs} +60 -38
- package/dist/{chunk-IDV2JYJ6.cjs → chunk-KRSFTZVO.cjs} +56 -40
- package/dist/{chunk-RIIA4ALQ.cjs → chunk-KSPH6KMH.cjs} +54 -38
- package/dist/{chunk-OUNN4IQB.cjs → chunk-KTY4LAUV.cjs} +482 -497
- package/dist/chunk-OBATJBNL.cjs +868 -0
- package/dist/{chunk-RZTLQAKF.js → chunk-OJNLJT5D.js} +0 -1
- package/dist/{chunk-FT3HDNIB.js → chunk-PJK2ZS3I.js} +467 -537
- package/dist/{chunk-G53WYUXL.js → chunk-PSMZKHOC.js} +441 -456
- package/dist/{chunk-7RE6KSIY.cjs → chunk-Q5JQGHWY.cjs} +0 -1
- package/dist/{chunk-BX2N7TZM.js → chunk-SQTUQY5E.js} +31 -11
- package/dist/chunk-T2TCLZZV.js +2304 -0
- package/dist/chunk-WB65UG7G.cjs +2304 -0
- package/dist/{chunk-CF5DDD3Q.js → chunk-WCRLAKDW.js} +239 -245
- package/dist/{chunk-KYVTM5VI.js → chunk-WL2YUEXH.js} +19 -3
- package/dist/chunk-XPCBPACE.js +868 -0
- package/dist/{chunk-KGDVC4O6.js → chunk-YCNIVZS7.js} +439 -469
- package/dist/{chunk-KLPWJU6W.js → chunk-YRZQVNZO.js} +50 -0
- package/dist/{codec-DOmAmFkI.d.ts → codec-B-oUU-cp.d.ts} +21 -2
- package/dist/{codec-DNmiG2e0.d.cts → codec-B3RpCI9k.d.cts} +21 -2
- package/dist/codec-B5pcOS3m.d.cts +38 -0
- package/dist/{codec-BNy5syCU.d.ts → codec-BLjxwK2f.d.ts} +21 -2
- package/dist/{codec-alVA27Uc.d.ts → codec-BV3CL_3m.d.ts} +21 -2
- package/dist/{codec-Czejcmxr.d.cts → codec-BYCDWgED.d.ts} +22 -3
- package/dist/{codec-DaXjRrOV.d.ts → codec-Bwqq7ZQT.d.ts} +22 -3
- package/dist/{codec-CFWu5KVT.d.cts → codec-BzWxOFby.d.cts} +22 -3
- package/dist/codec-C-nJhNNl.d.ts +38 -0
- package/dist/{codec-EvybrBuY.d.cts → codec-C11VEPbQ.d.cts} +21 -2
- package/dist/codec-C9U0Vzy9.d.cts +68 -0
- package/dist/{codec-Cm3D261p.d.ts → codec-CCx22jnd.d.ts} +21 -2
- package/dist/{codec-CwZ6OCPP.d.ts → codec-CP3zkfTv.d.ts} +22 -3
- package/dist/{codec-BxQTybUX.d.cts → codec-CRmOLDpt.d.ts} +22 -3
- package/dist/{codec-DzkdW4kO.d.cts → codec-CUu56DDU.d.cts} +21 -2
- package/dist/codec-Cb8mUre3.d.ts +68 -0
- package/dist/{codec-f7vxeVIS.d.cts → codec-CemqAQdR.d.cts} +22 -3
- package/dist/{codec-gl4_QEva.d.ts → codec-CxMvsVMS.d.ts} +21 -2
- package/dist/{codec-Bd60SGKH.d.cts → codec-DIgMVTi4.d.cts} +21 -2
- package/dist/{codec--CVeqGQv.d.ts → codec-DYzozF68.d.ts} +21 -2
- package/dist/{codec-CWnf8mn_.d.cts → codec-D_O9zxax.d.ts} +22 -3
- package/dist/{codec-08ZOr5wI.d.ts → codec-Ddc-QxV6.d.cts} +22 -3
- package/dist/{codec-CBdOIfMY.d.ts → codec-DoojMl2z.d.cts} +22 -3
- package/dist/{codec-BrTi4K7r.d.cts → codec-DqdjiOQF.d.ts} +22 -3
- package/dist/{codec-CXCjya_G.d.cts → codec-Dstemwrq.d.cts} +21 -2
- package/dist/{codec-Dl_QIXMz.d.ts → codec-Dt6nuejp.d.ts} +21 -2
- package/dist/{codec-Bux_Q40X.d.ts → codec-DuYhd8fP.d.cts} +22 -3
- package/dist/{codec-Cfo_z5ET.d.cts → codec-DwNOFgPU.d.cts} +21 -2
- package/dist/{codec-guzqtfMk.d.cts → codec-l01BpNhF.d.cts} +21 -2
- package/dist/{codec-C3mdsGx3.d.ts → codec-psN2vB6I.d.cts} +22 -3
- package/dist/draft07-session.d.cts +3 -3
- package/dist/draft07-session.d.ts +3 -3
- package/dist/draft07.cjs +48 -4
- package/dist/draft07.d.cts +44 -4
- package/dist/draft07.d.ts +44 -4
- package/dist/draft07.js +49 -5
- package/dist/draft08-session.d.cts +3 -3
- package/dist/draft08-session.d.ts +3 -3
- package/dist/draft08.cjs +76 -3
- package/dist/draft08.d.cts +73 -5
- package/dist/draft08.d.ts +73 -5
- package/dist/draft08.js +77 -4
- package/dist/draft09-session.d.cts +3 -3
- package/dist/draft09-session.d.ts +3 -3
- package/dist/draft09.cjs +76 -3
- package/dist/draft09.d.cts +73 -5
- package/dist/draft09.d.ts +73 -5
- package/dist/draft09.js +77 -4
- package/dist/draft10-session.d.cts +3 -3
- package/dist/draft10-session.d.ts +3 -3
- package/dist/draft10.cjs +76 -3
- package/dist/draft10.d.cts +73 -5
- package/dist/draft10.d.ts +73 -5
- package/dist/draft10.js +77 -4
- package/dist/draft11-session.d.cts +3 -3
- package/dist/draft11-session.d.ts +3 -3
- package/dist/draft11.cjs +104 -3
- package/dist/draft11.d.cts +101 -5
- package/dist/draft11.d.ts +101 -5
- package/dist/draft11.js +105 -4
- package/dist/draft12-session.d.cts +3 -3
- package/dist/draft12-session.d.ts +3 -3
- package/dist/draft12.cjs +113 -3
- package/dist/draft12.d.cts +110 -5
- package/dist/draft12.d.ts +110 -5
- package/dist/draft12.js +114 -4
- package/dist/draft13-session.d.cts +3 -3
- package/dist/draft13-session.d.ts +3 -3
- package/dist/draft13.cjs +105 -3
- package/dist/draft13.d.cts +102 -5
- package/dist/draft13.d.ts +102 -5
- package/dist/draft13.js +106 -4
- package/dist/draft14-session.d.cts +3 -3
- package/dist/draft14-session.d.ts +3 -3
- package/dist/draft14.cjs +107 -3
- package/dist/draft14.d.cts +104 -31
- package/dist/draft14.d.ts +104 -31
- package/dist/draft14.js +108 -4
- package/dist/draft15-session.d.cts +4 -4
- package/dist/draft15-session.d.ts +4 -4
- package/dist/draft15.cjs +69 -3
- package/dist/draft15.d.cts +68 -25
- package/dist/draft15.d.ts +68 -25
- package/dist/draft15.js +70 -4
- package/dist/draft16-session.cjs +2 -2
- package/dist/draft16-session.d.cts +4 -4
- package/dist/draft16-session.d.ts +4 -4
- package/dist/draft16-session.js +1 -1
- package/dist/draft16.cjs +76 -8
- package/dist/draft16.d.cts +70 -16
- package/dist/draft16.d.ts +70 -16
- package/dist/draft16.js +73 -5
- package/dist/draft17-session.d.cts +4 -4
- package/dist/draft17-session.d.ts +4 -4
- package/dist/draft17.cjs +77 -3
- package/dist/draft17.d.cts +75 -6
- package/dist/draft17.d.ts +75 -6
- package/dist/draft17.js +78 -4
- package/dist/draft18-session.d.cts +4 -4
- package/dist/draft18-session.d.ts +4 -4
- package/dist/draft18.cjs +8 -3
- package/dist/draft18.d.cts +6 -5
- package/dist/draft18.d.ts +6 -5
- package/dist/draft18.js +9 -4
- package/dist/draft19-session.d.cts +4 -4
- package/dist/draft19-session.d.ts +4 -4
- package/dist/draft19.cjs +11 -4
- package/dist/draft19.d.cts +6 -5
- package/dist/draft19.d.ts +6 -5
- package/dist/draft19.js +12 -5
- package/dist/draft20-session.d.cts +4 -4
- package/dist/draft20-session.d.ts +4 -4
- package/dist/draft20.cjs +8 -3
- package/dist/draft20.d.cts +6 -5
- package/dist/draft20.d.ts +6 -5
- package/dist/draft20.js +9 -4
- package/dist/draft21-session.cjs +8 -0
- package/dist/draft21-session.d.cts +195 -0
- package/dist/draft21-session.d.ts +195 -0
- package/dist/draft21-session.js +8 -0
- package/dist/draft21.cjs +222 -0
- package/dist/draft21.d.cts +176 -0
- package/dist/draft21.d.ts +176 -0
- package/dist/draft21.js +222 -0
- package/dist/index.cjs +37 -31
- package/dist/index.d.cts +29 -23
- package/dist/index.d.ts +29 -23
- package/dist/index.js +22 -16
- package/dist/{session-types-Dn7b3RZM.d.ts → session-types-Cxx7W8zZ.d.ts} +1 -1
- package/dist/{session-types-B9idsih-.d.cts → session-types-DZkI_qFG.d.cts} +1 -1
- package/dist/session.cjs +7 -3
- package/dist/session.d.cts +11 -9
- package/dist/session.d.ts +11 -9
- package/dist/session.js +6 -2
- package/dist/{types-DG5_iKuv.d.cts → types-2NisMA8_.d.cts} +1 -1
- package/dist/{types-DG5_iKuv.d.ts → types-2NisMA8_.d.ts} +1 -1
- package/dist/{types-C1rxh-id.d.cts → types-Btp416jt.d.cts} +8 -0
- package/dist/{types-C1rxh-id.d.ts → types-Btp416jt.d.ts} +8 -0
- package/dist/{types-CZTzbIzQ.d.cts → types-BxTL1NXw.d.cts} +7 -0
- package/dist/{types-CZTzbIzQ.d.ts → types-BxTL1NXw.d.ts} +7 -0
- package/dist/{types-pShrs3fN.d.cts → types-CuibHYcf.d.cts} +7 -0
- package/dist/{types-pShrs3fN.d.ts → types-CuibHYcf.d.ts} +7 -0
- package/dist/{types-CY-QWxd-.d.cts → types-CwN7AEoL.d.cts} +13 -1
- package/dist/{types-CY-QWxd-.d.ts → types-CwN7AEoL.d.ts} +13 -1
- package/dist/{types-D4bmW8rY.d.cts → types-DAnalt5K.d.cts} +7 -0
- package/dist/{types-D4bmW8rY.d.ts → types-DAnalt5K.d.ts} +7 -0
- package/dist/types-DDwidj2d.d.cts +371 -0
- package/dist/types-DDwidj2d.d.ts +371 -0
- package/dist/{types-Bg86GGVZ.d.cts → types-DxXNP32l.d.cts} +8 -0
- package/dist/{types-Bg86GGVZ.d.ts → types-DxXNP32l.d.ts} +8 -0
- package/package.json +15 -3
- package/src/core/auth-redaction.ts +190 -0
- package/src/core/types.ts +1 -0
- package/src/drafts/draft07/codec.ts +40 -0
- package/src/drafts/draft07/error-codes.ts +44 -0
- package/src/drafts/draft07/index.ts +15 -0
- package/src/drafts/draft08/codec.ts +40 -0
- package/src/drafts/draft08/error-codes.ts +76 -0
- package/src/drafts/draft08/index.ts +21 -0
- package/src/drafts/draft09/codec.ts +40 -0
- package/src/drafts/draft09/error-codes.ts +76 -0
- package/src/drafts/draft09/index.ts +21 -0
- package/src/drafts/draft10/codec.ts +40 -0
- package/src/drafts/draft10/error-codes.ts +76 -0
- package/src/drafts/draft10/index.ts +21 -0
- package/src/drafts/draft11/codec.ts +60 -0
- package/src/drafts/draft11/error-codes.ts +106 -0
- package/src/drafts/draft11/index.ts +23 -0
- package/src/drafts/draft12/codec.ts +61 -0
- package/src/drafts/draft12/error-codes.ts +116 -0
- package/src/drafts/draft12/index.ts +25 -0
- package/src/drafts/draft13/codec.ts +69 -11
- package/src/drafts/draft13/error-codes.ts +107 -0
- package/src/drafts/draft13/index.ts +23 -0
- package/src/drafts/draft13/types.ts +1 -1
- package/src/drafts/draft14/codec.ts +65 -4
- package/src/drafts/draft14/data-streams.ts +331 -259
- package/src/drafts/draft14/error-codes.ts +109 -0
- package/src/drafts/draft14/index.ts +23 -0
- package/src/drafts/draft15/codec.ts +65 -8
- package/src/drafts/draft15/data-streams.ts +489 -444
- package/src/drafts/draft15/error-codes.ts +66 -0
- package/src/drafts/draft15/index.ts +15 -0
- package/src/drafts/draft15/types.ts +7 -0
- package/src/drafts/draft16/codec.ts +146 -52
- package/src/drafts/draft16/data-streams.ts +513 -442
- package/src/drafts/draft16/error-codes.ts +68 -0
- package/src/drafts/draft16/index.ts +15 -0
- package/src/drafts/draft16/messages.ts +4 -4
- package/src/drafts/draft16/session-fsm.ts +0 -1
- package/src/drafts/draft16/types.ts +22 -8
- package/src/drafts/draft17/codec.ts +73 -12
- package/src/drafts/draft17/data-streams.ts +567 -488
- package/src/drafts/draft17/index.ts +15 -0
- package/src/drafts/draft17/types.ts +7 -0
- package/src/drafts/draft18/codec.ts +66 -9
- package/src/drafts/draft18/data-streams.ts +570 -482
- package/src/drafts/draft18/index.ts +3 -0
- package/src/drafts/draft18/types.ts +16 -8
- package/src/drafts/draft19/codec.ts +70 -10
- package/src/drafts/draft19/data-streams.ts +570 -482
- package/src/drafts/draft19/error-codes.ts +3 -1
- package/src/drafts/draft19/index.ts +3 -0
- package/src/drafts/draft19/messages.ts +3 -1
- package/src/drafts/draft19/types.ts +22 -11
- package/src/drafts/draft20/codec.ts +90 -23
- package/src/drafts/draft20/data-streams.ts +610 -563
- package/src/drafts/draft20/index.ts +3 -0
- package/src/drafts/draft20/types.ts +14 -2
- package/src/drafts/draft21/codec.ts +1816 -0
- package/src/drafts/draft21/data-streams.ts +1338 -0
- package/src/drafts/draft21/error-codes.ts +135 -0
- package/src/drafts/draft21/index.ts +168 -0
- package/src/drafts/draft21/messages.ts +68 -0
- package/src/drafts/draft21/rules.ts +107 -0
- package/src/drafts/draft21/session-fsm.ts +1063 -0
- package/src/drafts/draft21/session.ts +21 -0
- package/src/drafts/draft21/types.ts +473 -0
- package/src/index.ts +9 -1
- package/src/session.ts +4 -0
- package/dist/codec-BJ7BHuiZ.d.ts +0 -18
- package/dist/codec-C6Mx4bwz.d.cts +0 -18
package/dist/draft07.cjs
CHANGED
|
@@ -44,7 +44,8 @@
|
|
|
44
44
|
|
|
45
45
|
|
|
46
46
|
|
|
47
|
-
|
|
47
|
+
|
|
48
|
+
var _chunkKRSFTZVOcjs = require('./chunk-KRSFTZVO.cjs');
|
|
48
49
|
|
|
49
50
|
|
|
50
51
|
|
|
@@ -55,11 +56,48 @@ var _chunkIDV2JYJ6cjs = require('./chunk-IDV2JYJ6.cjs');
|
|
|
55
56
|
var _chunkMZ7VU52Ocjs = require('./chunk-MZ7VU52O.cjs');
|
|
56
57
|
|
|
57
58
|
|
|
58
|
-
|
|
59
|
+
|
|
60
|
+
var _chunk5IMHJIAZcjs = require('./chunk-5IMHJIAZ.cjs');
|
|
61
|
+
|
|
62
|
+
// src/drafts/draft07/error-codes.ts
|
|
63
|
+
var SessionErrorCode = {
|
|
64
|
+
NoError: 0x0n,
|
|
65
|
+
InternalError: 0x1n,
|
|
66
|
+
Unauthorized: 0x2n,
|
|
67
|
+
ProtocolViolation: 0x3n,
|
|
68
|
+
DuplicateTrackAlias: 0x4n,
|
|
69
|
+
ParameterLengthMismatch: 0x5n,
|
|
70
|
+
TooManySubscribes: 0x6n,
|
|
71
|
+
GoawayTimeout: 0x10n
|
|
72
|
+
};
|
|
73
|
+
var SubscribeErrorCode = {
|
|
74
|
+
InternalError: 0x0n,
|
|
75
|
+
InvalidRange: 0x1n,
|
|
76
|
+
RetryTrackAlias: 0x2n,
|
|
77
|
+
TrackDoesNotExist: 0x3n,
|
|
78
|
+
Unauthorized: 0x4n,
|
|
79
|
+
Timeout: 0x5n
|
|
80
|
+
};
|
|
81
|
+
var SubscribeDoneStatusCode = {
|
|
82
|
+
Unsubscribed: 0x0n,
|
|
83
|
+
InternalError: 0x1n,
|
|
84
|
+
Unauthorized: 0x2n,
|
|
85
|
+
TrackEnded: 0x3n,
|
|
86
|
+
SubscriptionEnded: 0x4n,
|
|
87
|
+
GoingAway: 0x5n,
|
|
88
|
+
Expired: 0x6n
|
|
89
|
+
};
|
|
90
|
+
var TrackStatusCode = {
|
|
91
|
+
InProgress: 0x00n,
|
|
92
|
+
TrackDoesNotExist: 0x01n,
|
|
93
|
+
NotYetBegun: 0x02n,
|
|
94
|
+
Finished: 0x03n,
|
|
95
|
+
RelayStatusUnavailable: 0x04n
|
|
96
|
+
};
|
|
59
97
|
|
|
60
98
|
// src/drafts/draft07/index.ts
|
|
61
99
|
var DRAFT_VERSION = 0xff000007n;
|
|
62
|
-
var defaultCodec =
|
|
100
|
+
var defaultCodec = _chunkKRSFTZVOcjs.createDraft07Codec.call(void 0, );
|
|
63
101
|
function encodeMessage(message) {
|
|
64
102
|
return defaultCodec.encodeMessage(message);
|
|
65
103
|
}
|
|
@@ -126,4 +164,10 @@ function createStreamDecoder() {
|
|
|
126
164
|
|
|
127
165
|
|
|
128
166
|
|
|
129
|
-
|
|
167
|
+
|
|
168
|
+
|
|
169
|
+
|
|
170
|
+
|
|
171
|
+
|
|
172
|
+
|
|
173
|
+
exports.CLIENT_ONLY_MESSAGES = _chunkMZ7VU52Ocjs.CLIENT_ONLY_MESSAGES; exports.CONTROL_MESSAGES = _chunkMZ7VU52Ocjs.CONTROL_MESSAGES; exports.DATA_MESSAGES = _chunkMZ7VU52Ocjs.DATA_MESSAGES; exports.DRAFT_VERSION = DRAFT_VERSION; exports.DecodeError = _chunk5IMHJIAZcjs.DecodeError; exports.MESSAGE_ID_MAP = _chunkKRSFTZVOcjs.MESSAGE_ID_MAP; exports.MESSAGE_TYPE_MAP = _chunkKRSFTZVOcjs.MESSAGE_TYPE_MAP; exports.MSG_ANNOUNCE = _chunkKRSFTZVOcjs.MSG_ANNOUNCE; exports.MSG_ANNOUNCE_CANCEL = _chunkKRSFTZVOcjs.MSG_ANNOUNCE_CANCEL; exports.MSG_ANNOUNCE_ERROR = _chunkKRSFTZVOcjs.MSG_ANNOUNCE_ERROR; exports.MSG_ANNOUNCE_OK = _chunkKRSFTZVOcjs.MSG_ANNOUNCE_OK; exports.MSG_CLIENT_SETUP = _chunkKRSFTZVOcjs.MSG_CLIENT_SETUP; exports.MSG_FETCH = _chunkKRSFTZVOcjs.MSG_FETCH; exports.MSG_FETCH_CANCEL = _chunkKRSFTZVOcjs.MSG_FETCH_CANCEL; exports.MSG_FETCH_ERROR = _chunkKRSFTZVOcjs.MSG_FETCH_ERROR; exports.MSG_FETCH_HEADER = _chunkKRSFTZVOcjs.MSG_FETCH_HEADER; exports.MSG_FETCH_OK = _chunkKRSFTZVOcjs.MSG_FETCH_OK; exports.MSG_GOAWAY = _chunkKRSFTZVOcjs.MSG_GOAWAY; exports.MSG_MAX_SUBSCRIBE_ID = _chunkKRSFTZVOcjs.MSG_MAX_SUBSCRIBE_ID; exports.MSG_OBJECT_DATAGRAM = _chunkKRSFTZVOcjs.MSG_OBJECT_DATAGRAM; exports.MSG_SERVER_SETUP = _chunkKRSFTZVOcjs.MSG_SERVER_SETUP; exports.MSG_STREAM_HEADER_SUBGROUP = _chunkKRSFTZVOcjs.MSG_STREAM_HEADER_SUBGROUP; exports.MSG_SUBSCRIBE = _chunkKRSFTZVOcjs.MSG_SUBSCRIBE; exports.MSG_SUBSCRIBE_ANNOUNCES = _chunkKRSFTZVOcjs.MSG_SUBSCRIBE_ANNOUNCES; exports.MSG_SUBSCRIBE_ANNOUNCES_ERROR = _chunkKRSFTZVOcjs.MSG_SUBSCRIBE_ANNOUNCES_ERROR; exports.MSG_SUBSCRIBE_ANNOUNCES_OK = _chunkKRSFTZVOcjs.MSG_SUBSCRIBE_ANNOUNCES_OK; exports.MSG_SUBSCRIBE_DONE = _chunkKRSFTZVOcjs.MSG_SUBSCRIBE_DONE; exports.MSG_SUBSCRIBE_ERROR = _chunkKRSFTZVOcjs.MSG_SUBSCRIBE_ERROR; exports.MSG_SUBSCRIBE_OK = _chunkKRSFTZVOcjs.MSG_SUBSCRIBE_OK; exports.MSG_SUBSCRIBE_UPDATE = _chunkKRSFTZVOcjs.MSG_SUBSCRIBE_UPDATE; exports.MSG_TRACK_STATUS = _chunkKRSFTZVOcjs.MSG_TRACK_STATUS; exports.MSG_TRACK_STATUS_REQUEST = _chunkKRSFTZVOcjs.MSG_TRACK_STATUS_REQUEST; exports.MSG_UNANNOUNCE = _chunkKRSFTZVOcjs.MSG_UNANNOUNCE; exports.MSG_UNSUBSCRIBE = _chunkKRSFTZVOcjs.MSG_UNSUBSCRIBE; exports.MSG_UNSUBSCRIBE_ANNOUNCES = _chunkKRSFTZVOcjs.MSG_UNSUBSCRIBE_ANNOUNCES; exports.PARAM_AUTHORIZATION_INFO = _chunkKRSFTZVOcjs.PARAM_AUTHORIZATION_INFO; exports.PARAM_DELIVERY_TIMEOUT = _chunkKRSFTZVOcjs.PARAM_DELIVERY_TIMEOUT; exports.PARAM_MAX_CACHE_DURATION = _chunkKRSFTZVOcjs.PARAM_MAX_CACHE_DURATION; exports.REDACTION_FILL = _chunk5IMHJIAZcjs.REDACTION_FILL; exports.SERVER_ONLY_MESSAGES = _chunkMZ7VU52Ocjs.SERVER_ONLY_MESSAGES; exports.SETUP_PARAM_MAX_SUBSCRIBE_ID = _chunkKRSFTZVOcjs.SETUP_PARAM_MAX_SUBSCRIBE_ID; exports.SETUP_PARAM_PATH = _chunkKRSFTZVOcjs.SETUP_PARAM_PATH; exports.SETUP_PARAM_ROLE = _chunkKRSFTZVOcjs.SETUP_PARAM_ROLE; exports.SessionErrorCode = SessionErrorCode; exports.SubscribeDoneStatusCode = SubscribeDoneStatusCode; exports.SubscribeErrorCode = SubscribeErrorCode; exports.TrackStatusCode = TrackStatusCode; exports.createDraft07Codec = _chunkKRSFTZVOcjs.createDraft07Codec; exports.createStreamDecoder = createStreamDecoder; exports.decodeDatagram = _chunkKRSFTZVOcjs.decodeDatagram; exports.decodeFetchStream = _chunkKRSFTZVOcjs.decodeFetchStream; exports.decodeMessage = decodeMessage; exports.decodeSubgroupStream = _chunkKRSFTZVOcjs.decodeSubgroupStream; exports.decodeVarInt = _chunkKRSFTZVOcjs.decodeVarInt; exports.encodeDatagram = _chunkKRSFTZVOcjs.encodeDatagram; exports.encodeFetchStream = _chunkKRSFTZVOcjs.encodeFetchStream; exports.encodeMessage = encodeMessage; exports.encodeSubgroupStream = _chunkKRSFTZVOcjs.encodeSubgroupStream; exports.encodeVarInt = _chunkKRSFTZVOcjs.encodeVarInt; exports.getLegalIncoming = _chunkMZ7VU52Ocjs.getLegalIncoming; exports.getLegalOutgoing = _chunkMZ7VU52Ocjs.getLegalOutgoing; exports.redactAuthTokens = _chunkKRSFTZVOcjs.redactAuthTokens;
|
package/dist/draft07.d.cts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
export { D as
|
|
1
|
+
export { A as AuthRedaction, R as REDACTION_FILL } from './auth-redaction-B9JJOlIY.cjs';
|
|
2
|
+
import { b as DecodeResult } from './types-2NisMA8_.cjs';
|
|
3
|
+
export { D as DecodeError, a as DecodeErrorCode } from './types-2NisMA8_.cjs';
|
|
4
|
+
export { D as Draft07Codec, c as createDraft07Codec, r as redactAuthTokens } from './codec-B5pcOS3m.cjs';
|
|
4
5
|
import { b as DatagramObject, F as FetchStream, S as SubgroupStream, a as Draft07MessageType, D as Draft07Message } from './types-Dl4IaAHR.cjs';
|
|
5
6
|
export { A as Announce, c as AnnounceCancel, d as AnnounceError, e as AnnounceOk, C as ClientSetup, f as DataStreamEvent, g as DataStreamHeader, h as Draft07DataStream, i as Draft07Params, j as Draft07SetupParams, k as Fetch, l as FetchCancel, m as FetchError, n as FetchObjectPayload, o as FetchOk, p as FetchStreamHeader, G as GoAway, M as MaxSubscribeId, O as ObjectDatagram, q as ObjectPayload, r as ServerSetup, s as StreamHeaderSubgroup, t as SubgroupStreamHeader, u as Subscribe, v as SubscribeAnnounces, w as SubscribeAnnouncesError, x as SubscribeAnnouncesOk, y as SubscribeDone, z as SubscribeError, B as SubscribeOk, E as SubscribeUpdate, T as TrackStatus, H as TrackStatusRequest, U as Unannounce, I as UnknownParam, J as Unsubscribe, K as UnsubscribeAnnounces } from './types-Dl4IaAHR.cjs';
|
|
6
7
|
|
|
@@ -11,6 +12,45 @@ declare function decodeSubgroupStream(bytes: Uint8Array): DecodeResult<SubgroupS
|
|
|
11
12
|
declare function decodeDatagram(bytes: Uint8Array): DecodeResult<DatagramObject>;
|
|
12
13
|
declare function decodeFetchStream(bytes: Uint8Array): DecodeResult<FetchStream>;
|
|
13
14
|
|
|
15
|
+
declare const SessionErrorCode: {
|
|
16
|
+
readonly NoError: 0n;
|
|
17
|
+
readonly InternalError: 1n;
|
|
18
|
+
readonly Unauthorized: 2n;
|
|
19
|
+
readonly ProtocolViolation: 3n;
|
|
20
|
+
readonly DuplicateTrackAlias: 4n;
|
|
21
|
+
readonly ParameterLengthMismatch: 5n;
|
|
22
|
+
readonly TooManySubscribes: 6n;
|
|
23
|
+
readonly GoawayTimeout: 16n;
|
|
24
|
+
};
|
|
25
|
+
type SessionErrorCodeValue = (typeof SessionErrorCode)[keyof typeof SessionErrorCode];
|
|
26
|
+
declare const SubscribeErrorCode: {
|
|
27
|
+
readonly InternalError: 0n;
|
|
28
|
+
readonly InvalidRange: 1n;
|
|
29
|
+
readonly RetryTrackAlias: 2n;
|
|
30
|
+
readonly TrackDoesNotExist: 3n;
|
|
31
|
+
readonly Unauthorized: 4n;
|
|
32
|
+
readonly Timeout: 5n;
|
|
33
|
+
};
|
|
34
|
+
type SubscribeErrorCodeValue = (typeof SubscribeErrorCode)[keyof typeof SubscribeErrorCode];
|
|
35
|
+
declare const SubscribeDoneStatusCode: {
|
|
36
|
+
readonly Unsubscribed: 0n;
|
|
37
|
+
readonly InternalError: 1n;
|
|
38
|
+
readonly Unauthorized: 2n;
|
|
39
|
+
readonly TrackEnded: 3n;
|
|
40
|
+
readonly SubscriptionEnded: 4n;
|
|
41
|
+
readonly GoingAway: 5n;
|
|
42
|
+
readonly Expired: 6n;
|
|
43
|
+
};
|
|
44
|
+
type SubscribeDoneStatusCodeValue = (typeof SubscribeDoneStatusCode)[keyof typeof SubscribeDoneStatusCode];
|
|
45
|
+
declare const TrackStatusCode: {
|
|
46
|
+
readonly InProgress: 0n;
|
|
47
|
+
readonly TrackDoesNotExist: 1n;
|
|
48
|
+
readonly NotYetBegun: 2n;
|
|
49
|
+
readonly Finished: 3n;
|
|
50
|
+
readonly RelayStatusUnavailable: 4n;
|
|
51
|
+
};
|
|
52
|
+
type TrackStatusCodeValue = (typeof TrackStatusCode)[keyof typeof TrackStatusCode];
|
|
53
|
+
|
|
14
54
|
declare const MSG_SUBSCRIBE_UPDATE = 2n;
|
|
15
55
|
declare const MSG_SUBSCRIBE = 3n;
|
|
16
56
|
declare const MSG_SUBSCRIBE_OK = 4n;
|
|
@@ -64,4 +104,4 @@ declare function encodeMessage(message: Draft07Message): Uint8Array;
|
|
|
64
104
|
declare function decodeMessage(bytes: Uint8Array): DecodeResult<Draft07Message>;
|
|
65
105
|
declare function createStreamDecoder(): TransformStream<Uint8Array, Draft07Message>;
|
|
66
106
|
|
|
67
|
-
export { CLIENT_ONLY_MESSAGES, CONTROL_MESSAGES, DATA_MESSAGES, DRAFT_VERSION, DecodeResult, DatagramObject as Draft07DatagramObject, Draft07Message, Draft07MessageType, FetchStream, MESSAGE_ID_MAP, MESSAGE_TYPE_MAP, MSG_ANNOUNCE, MSG_ANNOUNCE_CANCEL, MSG_ANNOUNCE_ERROR, MSG_ANNOUNCE_OK, MSG_CLIENT_SETUP, MSG_FETCH, MSG_FETCH_CANCEL, MSG_FETCH_ERROR, MSG_FETCH_HEADER, MSG_FETCH_OK, MSG_GOAWAY, MSG_MAX_SUBSCRIBE_ID, MSG_OBJECT_DATAGRAM, MSG_SERVER_SETUP, MSG_STREAM_HEADER_SUBGROUP, MSG_SUBSCRIBE, MSG_SUBSCRIBE_ANNOUNCES, MSG_SUBSCRIBE_ANNOUNCES_ERROR, MSG_SUBSCRIBE_ANNOUNCES_OK, MSG_SUBSCRIBE_DONE, MSG_SUBSCRIBE_ERROR, MSG_SUBSCRIBE_OK, MSG_SUBSCRIBE_UPDATE, MSG_TRACK_STATUS, MSG_TRACK_STATUS_REQUEST, MSG_UNANNOUNCE, MSG_UNSUBSCRIBE, MSG_UNSUBSCRIBE_ANNOUNCES, PARAM_AUTHORIZATION_INFO, PARAM_DELIVERY_TIMEOUT, PARAM_MAX_CACHE_DURATION, SERVER_ONLY_MESSAGES, SETUP_PARAM_MAX_SUBSCRIBE_ID, SETUP_PARAM_PATH, SETUP_PARAM_ROLE, SubgroupStream, createStreamDecoder, decodeDatagram, decodeFetchStream, decodeMessage, decodeSubgroupStream, decodeVarInt, encodeDatagram, encodeFetchStream, encodeMessage, encodeSubgroupStream, encodeVarInt, getLegalIncoming, getLegalOutgoing };
|
|
107
|
+
export { CLIENT_ONLY_MESSAGES, CONTROL_MESSAGES, DATA_MESSAGES, DRAFT_VERSION, DecodeResult, DatagramObject as Draft07DatagramObject, Draft07Message, Draft07MessageType, FetchStream, MESSAGE_ID_MAP, MESSAGE_TYPE_MAP, MSG_ANNOUNCE, MSG_ANNOUNCE_CANCEL, MSG_ANNOUNCE_ERROR, MSG_ANNOUNCE_OK, MSG_CLIENT_SETUP, MSG_FETCH, MSG_FETCH_CANCEL, MSG_FETCH_ERROR, MSG_FETCH_HEADER, MSG_FETCH_OK, MSG_GOAWAY, MSG_MAX_SUBSCRIBE_ID, MSG_OBJECT_DATAGRAM, MSG_SERVER_SETUP, MSG_STREAM_HEADER_SUBGROUP, MSG_SUBSCRIBE, MSG_SUBSCRIBE_ANNOUNCES, MSG_SUBSCRIBE_ANNOUNCES_ERROR, MSG_SUBSCRIBE_ANNOUNCES_OK, MSG_SUBSCRIBE_DONE, MSG_SUBSCRIBE_ERROR, MSG_SUBSCRIBE_OK, MSG_SUBSCRIBE_UPDATE, MSG_TRACK_STATUS, MSG_TRACK_STATUS_REQUEST, MSG_UNANNOUNCE, MSG_UNSUBSCRIBE, MSG_UNSUBSCRIBE_ANNOUNCES, PARAM_AUTHORIZATION_INFO, PARAM_DELIVERY_TIMEOUT, PARAM_MAX_CACHE_DURATION, SERVER_ONLY_MESSAGES, SETUP_PARAM_MAX_SUBSCRIBE_ID, SETUP_PARAM_PATH, SETUP_PARAM_ROLE, SessionErrorCode, type SessionErrorCodeValue, SubgroupStream, SubscribeDoneStatusCode, type SubscribeDoneStatusCodeValue, SubscribeErrorCode, type SubscribeErrorCodeValue, TrackStatusCode, type TrackStatusCodeValue, createStreamDecoder, decodeDatagram, decodeFetchStream, decodeMessage, decodeSubgroupStream, decodeVarInt, encodeDatagram, encodeFetchStream, encodeMessage, encodeSubgroupStream, encodeVarInt, getLegalIncoming, getLegalOutgoing };
|
package/dist/draft07.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
export { D as
|
|
1
|
+
export { A as AuthRedaction, R as REDACTION_FILL } from './auth-redaction-B9JJOlIY.js';
|
|
2
|
+
import { b as DecodeResult } from './types-2NisMA8_.js';
|
|
3
|
+
export { D as DecodeError, a as DecodeErrorCode } from './types-2NisMA8_.js';
|
|
4
|
+
export { D as Draft07Codec, c as createDraft07Codec, r as redactAuthTokens } from './codec-C-nJhNNl.js';
|
|
4
5
|
import { b as DatagramObject, F as FetchStream, S as SubgroupStream, a as Draft07MessageType, D as Draft07Message } from './types-Dl4IaAHR.js';
|
|
5
6
|
export { A as Announce, c as AnnounceCancel, d as AnnounceError, e as AnnounceOk, C as ClientSetup, f as DataStreamEvent, g as DataStreamHeader, h as Draft07DataStream, i as Draft07Params, j as Draft07SetupParams, k as Fetch, l as FetchCancel, m as FetchError, n as FetchObjectPayload, o as FetchOk, p as FetchStreamHeader, G as GoAway, M as MaxSubscribeId, O as ObjectDatagram, q as ObjectPayload, r as ServerSetup, s as StreamHeaderSubgroup, t as SubgroupStreamHeader, u as Subscribe, v as SubscribeAnnounces, w as SubscribeAnnouncesError, x as SubscribeAnnouncesOk, y as SubscribeDone, z as SubscribeError, B as SubscribeOk, E as SubscribeUpdate, T as TrackStatus, H as TrackStatusRequest, U as Unannounce, I as UnknownParam, J as Unsubscribe, K as UnsubscribeAnnounces } from './types-Dl4IaAHR.js';
|
|
6
7
|
|
|
@@ -11,6 +12,45 @@ declare function decodeSubgroupStream(bytes: Uint8Array): DecodeResult<SubgroupS
|
|
|
11
12
|
declare function decodeDatagram(bytes: Uint8Array): DecodeResult<DatagramObject>;
|
|
12
13
|
declare function decodeFetchStream(bytes: Uint8Array): DecodeResult<FetchStream>;
|
|
13
14
|
|
|
15
|
+
declare const SessionErrorCode: {
|
|
16
|
+
readonly NoError: 0n;
|
|
17
|
+
readonly InternalError: 1n;
|
|
18
|
+
readonly Unauthorized: 2n;
|
|
19
|
+
readonly ProtocolViolation: 3n;
|
|
20
|
+
readonly DuplicateTrackAlias: 4n;
|
|
21
|
+
readonly ParameterLengthMismatch: 5n;
|
|
22
|
+
readonly TooManySubscribes: 6n;
|
|
23
|
+
readonly GoawayTimeout: 16n;
|
|
24
|
+
};
|
|
25
|
+
type SessionErrorCodeValue = (typeof SessionErrorCode)[keyof typeof SessionErrorCode];
|
|
26
|
+
declare const SubscribeErrorCode: {
|
|
27
|
+
readonly InternalError: 0n;
|
|
28
|
+
readonly InvalidRange: 1n;
|
|
29
|
+
readonly RetryTrackAlias: 2n;
|
|
30
|
+
readonly TrackDoesNotExist: 3n;
|
|
31
|
+
readonly Unauthorized: 4n;
|
|
32
|
+
readonly Timeout: 5n;
|
|
33
|
+
};
|
|
34
|
+
type SubscribeErrorCodeValue = (typeof SubscribeErrorCode)[keyof typeof SubscribeErrorCode];
|
|
35
|
+
declare const SubscribeDoneStatusCode: {
|
|
36
|
+
readonly Unsubscribed: 0n;
|
|
37
|
+
readonly InternalError: 1n;
|
|
38
|
+
readonly Unauthorized: 2n;
|
|
39
|
+
readonly TrackEnded: 3n;
|
|
40
|
+
readonly SubscriptionEnded: 4n;
|
|
41
|
+
readonly GoingAway: 5n;
|
|
42
|
+
readonly Expired: 6n;
|
|
43
|
+
};
|
|
44
|
+
type SubscribeDoneStatusCodeValue = (typeof SubscribeDoneStatusCode)[keyof typeof SubscribeDoneStatusCode];
|
|
45
|
+
declare const TrackStatusCode: {
|
|
46
|
+
readonly InProgress: 0n;
|
|
47
|
+
readonly TrackDoesNotExist: 1n;
|
|
48
|
+
readonly NotYetBegun: 2n;
|
|
49
|
+
readonly Finished: 3n;
|
|
50
|
+
readonly RelayStatusUnavailable: 4n;
|
|
51
|
+
};
|
|
52
|
+
type TrackStatusCodeValue = (typeof TrackStatusCode)[keyof typeof TrackStatusCode];
|
|
53
|
+
|
|
14
54
|
declare const MSG_SUBSCRIBE_UPDATE = 2n;
|
|
15
55
|
declare const MSG_SUBSCRIBE = 3n;
|
|
16
56
|
declare const MSG_SUBSCRIBE_OK = 4n;
|
|
@@ -64,4 +104,4 @@ declare function encodeMessage(message: Draft07Message): Uint8Array;
|
|
|
64
104
|
declare function decodeMessage(bytes: Uint8Array): DecodeResult<Draft07Message>;
|
|
65
105
|
declare function createStreamDecoder(): TransformStream<Uint8Array, Draft07Message>;
|
|
66
106
|
|
|
67
|
-
export { CLIENT_ONLY_MESSAGES, CONTROL_MESSAGES, DATA_MESSAGES, DRAFT_VERSION, DecodeResult, DatagramObject as Draft07DatagramObject, Draft07Message, Draft07MessageType, FetchStream, MESSAGE_ID_MAP, MESSAGE_TYPE_MAP, MSG_ANNOUNCE, MSG_ANNOUNCE_CANCEL, MSG_ANNOUNCE_ERROR, MSG_ANNOUNCE_OK, MSG_CLIENT_SETUP, MSG_FETCH, MSG_FETCH_CANCEL, MSG_FETCH_ERROR, MSG_FETCH_HEADER, MSG_FETCH_OK, MSG_GOAWAY, MSG_MAX_SUBSCRIBE_ID, MSG_OBJECT_DATAGRAM, MSG_SERVER_SETUP, MSG_STREAM_HEADER_SUBGROUP, MSG_SUBSCRIBE, MSG_SUBSCRIBE_ANNOUNCES, MSG_SUBSCRIBE_ANNOUNCES_ERROR, MSG_SUBSCRIBE_ANNOUNCES_OK, MSG_SUBSCRIBE_DONE, MSG_SUBSCRIBE_ERROR, MSG_SUBSCRIBE_OK, MSG_SUBSCRIBE_UPDATE, MSG_TRACK_STATUS, MSG_TRACK_STATUS_REQUEST, MSG_UNANNOUNCE, MSG_UNSUBSCRIBE, MSG_UNSUBSCRIBE_ANNOUNCES, PARAM_AUTHORIZATION_INFO, PARAM_DELIVERY_TIMEOUT, PARAM_MAX_CACHE_DURATION, SERVER_ONLY_MESSAGES, SETUP_PARAM_MAX_SUBSCRIBE_ID, SETUP_PARAM_PATH, SETUP_PARAM_ROLE, SubgroupStream, createStreamDecoder, decodeDatagram, decodeFetchStream, decodeMessage, decodeSubgroupStream, decodeVarInt, encodeDatagram, encodeFetchStream, encodeMessage, encodeSubgroupStream, encodeVarInt, getLegalIncoming, getLegalOutgoing };
|
|
107
|
+
export { CLIENT_ONLY_MESSAGES, CONTROL_MESSAGES, DATA_MESSAGES, DRAFT_VERSION, DecodeResult, DatagramObject as Draft07DatagramObject, Draft07Message, Draft07MessageType, FetchStream, MESSAGE_ID_MAP, MESSAGE_TYPE_MAP, MSG_ANNOUNCE, MSG_ANNOUNCE_CANCEL, MSG_ANNOUNCE_ERROR, MSG_ANNOUNCE_OK, MSG_CLIENT_SETUP, MSG_FETCH, MSG_FETCH_CANCEL, MSG_FETCH_ERROR, MSG_FETCH_HEADER, MSG_FETCH_OK, MSG_GOAWAY, MSG_MAX_SUBSCRIBE_ID, MSG_OBJECT_DATAGRAM, MSG_SERVER_SETUP, MSG_STREAM_HEADER_SUBGROUP, MSG_SUBSCRIBE, MSG_SUBSCRIBE_ANNOUNCES, MSG_SUBSCRIBE_ANNOUNCES_ERROR, MSG_SUBSCRIBE_ANNOUNCES_OK, MSG_SUBSCRIBE_DONE, MSG_SUBSCRIBE_ERROR, MSG_SUBSCRIBE_OK, MSG_SUBSCRIBE_UPDATE, MSG_TRACK_STATUS, MSG_TRACK_STATUS_REQUEST, MSG_UNANNOUNCE, MSG_UNSUBSCRIBE, MSG_UNSUBSCRIBE_ANNOUNCES, PARAM_AUTHORIZATION_INFO, PARAM_DELIVERY_TIMEOUT, PARAM_MAX_CACHE_DURATION, SERVER_ONLY_MESSAGES, SETUP_PARAM_MAX_SUBSCRIBE_ID, SETUP_PARAM_PATH, SETUP_PARAM_ROLE, SessionErrorCode, type SessionErrorCodeValue, SubgroupStream, SubscribeDoneStatusCode, type SubscribeDoneStatusCodeValue, SubscribeErrorCode, type SubscribeErrorCodeValue, TrackStatusCode, type TrackStatusCodeValue, createStreamDecoder, decodeDatagram, decodeFetchStream, decodeMessage, decodeSubgroupStream, decodeVarInt, encodeDatagram, encodeFetchStream, encodeMessage, encodeSubgroupStream, encodeVarInt, getLegalIncoming, getLegalOutgoing };
|
package/dist/draft07.js
CHANGED
|
@@ -43,8 +43,9 @@ import {
|
|
|
43
43
|
encodeDatagram,
|
|
44
44
|
encodeFetchStream,
|
|
45
45
|
encodeSubgroupStream,
|
|
46
|
-
encodeVarInt
|
|
47
|
-
|
|
46
|
+
encodeVarInt,
|
|
47
|
+
redactAuthTokens
|
|
48
|
+
} from "./chunk-WL2YUEXH.js";
|
|
48
49
|
import {
|
|
49
50
|
CLIENT_ONLY_MESSAGES,
|
|
50
51
|
CONTROL_MESSAGES,
|
|
@@ -54,8 +55,45 @@ import {
|
|
|
54
55
|
getLegalOutgoing
|
|
55
56
|
} from "./chunk-C6KUWLQC.js";
|
|
56
57
|
import {
|
|
57
|
-
DecodeError
|
|
58
|
-
|
|
58
|
+
DecodeError,
|
|
59
|
+
REDACTION_FILL
|
|
60
|
+
} from "./chunk-YRZQVNZO.js";
|
|
61
|
+
|
|
62
|
+
// src/drafts/draft07/error-codes.ts
|
|
63
|
+
var SessionErrorCode = {
|
|
64
|
+
NoError: 0x0n,
|
|
65
|
+
InternalError: 0x1n,
|
|
66
|
+
Unauthorized: 0x2n,
|
|
67
|
+
ProtocolViolation: 0x3n,
|
|
68
|
+
DuplicateTrackAlias: 0x4n,
|
|
69
|
+
ParameterLengthMismatch: 0x5n,
|
|
70
|
+
TooManySubscribes: 0x6n,
|
|
71
|
+
GoawayTimeout: 0x10n
|
|
72
|
+
};
|
|
73
|
+
var SubscribeErrorCode = {
|
|
74
|
+
InternalError: 0x0n,
|
|
75
|
+
InvalidRange: 0x1n,
|
|
76
|
+
RetryTrackAlias: 0x2n,
|
|
77
|
+
TrackDoesNotExist: 0x3n,
|
|
78
|
+
Unauthorized: 0x4n,
|
|
79
|
+
Timeout: 0x5n
|
|
80
|
+
};
|
|
81
|
+
var SubscribeDoneStatusCode = {
|
|
82
|
+
Unsubscribed: 0x0n,
|
|
83
|
+
InternalError: 0x1n,
|
|
84
|
+
Unauthorized: 0x2n,
|
|
85
|
+
TrackEnded: 0x3n,
|
|
86
|
+
SubscriptionEnded: 0x4n,
|
|
87
|
+
GoingAway: 0x5n,
|
|
88
|
+
Expired: 0x6n
|
|
89
|
+
};
|
|
90
|
+
var TrackStatusCode = {
|
|
91
|
+
InProgress: 0x00n,
|
|
92
|
+
TrackDoesNotExist: 0x01n,
|
|
93
|
+
NotYetBegun: 0x02n,
|
|
94
|
+
Finished: 0x03n,
|
|
95
|
+
RelayStatusUnavailable: 0x04n
|
|
96
|
+
};
|
|
59
97
|
|
|
60
98
|
// src/drafts/draft07/index.ts
|
|
61
99
|
var DRAFT_VERSION = 0xff000007n;
|
|
@@ -108,10 +146,15 @@ export {
|
|
|
108
146
|
PARAM_AUTHORIZATION_INFO,
|
|
109
147
|
PARAM_DELIVERY_TIMEOUT,
|
|
110
148
|
PARAM_MAX_CACHE_DURATION,
|
|
149
|
+
REDACTION_FILL,
|
|
111
150
|
SERVER_ONLY_MESSAGES,
|
|
112
151
|
SETUP_PARAM_MAX_SUBSCRIBE_ID,
|
|
113
152
|
SETUP_PARAM_PATH,
|
|
114
153
|
SETUP_PARAM_ROLE,
|
|
154
|
+
SessionErrorCode,
|
|
155
|
+
SubscribeDoneStatusCode,
|
|
156
|
+
SubscribeErrorCode,
|
|
157
|
+
TrackStatusCode,
|
|
115
158
|
createDraft07Codec,
|
|
116
159
|
createStreamDecoder,
|
|
117
160
|
decodeDatagram,
|
|
@@ -125,5 +168,6 @@ export {
|
|
|
125
168
|
encodeSubgroupStream,
|
|
126
169
|
encodeVarInt,
|
|
127
170
|
getLegalIncoming,
|
|
128
|
-
getLegalOutgoing
|
|
171
|
+
getLegalOutgoing,
|
|
172
|
+
redactAuthTokens
|
|
129
173
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { k as SessionStateOptionsRole, a as SessionState } from './session-types-
|
|
2
|
-
export { A as AnnouncePhase, b as AnnounceState, F as FetchPhase, c as FetchState, P as ProtocolViolation, d as ProtocolViolationCode, g as SessionPhase, h as SideEffect, i as SubscriptionPhase, j as SubscriptionState, T as TransitionResult, V as ValidationResult } from './session-types-
|
|
1
|
+
import { k as SessionStateOptionsRole, a as SessionState } from './session-types-DZkI_qFG.cjs';
|
|
2
|
+
export { A as AnnouncePhase, b as AnnounceState, F as FetchPhase, c as FetchState, P as ProtocolViolation, d as ProtocolViolationCode, g as SessionPhase, h as SideEffect, i as SubscriptionPhase, j as SubscriptionState, T as TransitionResult, V as ValidationResult } from './session-types-DZkI_qFG.cjs';
|
|
3
3
|
import { D as Draft08Message, a as Draft08MessageType } from './types-jV1yDDBA.cjs';
|
|
4
|
-
import './types-
|
|
4
|
+
import './types-2NisMA8_.cjs';
|
|
5
5
|
|
|
6
6
|
declare function createDraft08SessionState(role: SessionStateOptionsRole): SessionState<Draft08Message, Draft08MessageType>;
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { k as SessionStateOptionsRole, a as SessionState } from './session-types-
|
|
2
|
-
export { A as AnnouncePhase, b as AnnounceState, F as FetchPhase, c as FetchState, P as ProtocolViolation, d as ProtocolViolationCode, g as SessionPhase, h as SideEffect, i as SubscriptionPhase, j as SubscriptionState, T as TransitionResult, V as ValidationResult } from './session-types-
|
|
1
|
+
import { k as SessionStateOptionsRole, a as SessionState } from './session-types-Cxx7W8zZ.js';
|
|
2
|
+
export { A as AnnouncePhase, b as AnnounceState, F as FetchPhase, c as FetchState, P as ProtocolViolation, d as ProtocolViolationCode, g as SessionPhase, h as SideEffect, i as SubscriptionPhase, j as SubscriptionState, T as TransitionResult, V as ValidationResult } from './session-types-Cxx7W8zZ.js';
|
|
3
3
|
import { D as Draft08Message, a as Draft08MessageType } from './types-jV1yDDBA.js';
|
|
4
|
-
import './types-
|
|
4
|
+
import './types-2NisMA8_.js';
|
|
5
5
|
|
|
6
6
|
declare function createDraft08SessionState(role: SessionStateOptionsRole): SessionState<Draft08Message, Draft08MessageType>;
|
|
7
7
|
|
package/dist/draft08.cjs
CHANGED
|
@@ -45,7 +45,8 @@
|
|
|
45
45
|
|
|
46
46
|
|
|
47
47
|
|
|
48
|
-
|
|
48
|
+
|
|
49
|
+
var _chunkA7VQO6YCcjs = require('./chunk-A7VQO6YC.cjs');
|
|
49
50
|
|
|
50
51
|
|
|
51
52
|
|
|
@@ -56,7 +57,70 @@ var _chunkVZHL2U2Ncjs = require('./chunk-VZHL2U2N.cjs');
|
|
|
56
57
|
|
|
57
58
|
|
|
58
59
|
var _chunkMYXAD5JCcjs = require('./chunk-MYXAD5JC.cjs');
|
|
59
|
-
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
var _chunk5IMHJIAZcjs = require('./chunk-5IMHJIAZ.cjs');
|
|
63
|
+
|
|
64
|
+
// src/drafts/draft08/error-codes.ts
|
|
65
|
+
var SessionErrorCode = {
|
|
66
|
+
NoError: 0x0n,
|
|
67
|
+
InternalError: 0x1n,
|
|
68
|
+
Unauthorized: 0x2n,
|
|
69
|
+
ProtocolViolation: 0x3n,
|
|
70
|
+
DuplicateTrackAlias: 0x4n,
|
|
71
|
+
ParameterLengthMismatch: 0x5n,
|
|
72
|
+
TooManySubscribes: 0x6n,
|
|
73
|
+
GoawayTimeout: 0x10n,
|
|
74
|
+
ControlMessageTimeout: 0x11n,
|
|
75
|
+
DataStreamTimeout: 0x12n
|
|
76
|
+
};
|
|
77
|
+
var AnnounceErrorCode = {
|
|
78
|
+
InternalError: 0x0n,
|
|
79
|
+
Unauthorized: 0x1n,
|
|
80
|
+
Timeout: 0x2n,
|
|
81
|
+
NotSupported: 0x3n,
|
|
82
|
+
Uninterested: 0x4n
|
|
83
|
+
};
|
|
84
|
+
var SubscribeErrorCode = {
|
|
85
|
+
InternalError: 0x0n,
|
|
86
|
+
Unauthorized: 0x1n,
|
|
87
|
+
Timeout: 0x2n,
|
|
88
|
+
NotSupported: 0x3n,
|
|
89
|
+
TrackDoesNotExist: 0x4n,
|
|
90
|
+
InvalidRange: 0x5n,
|
|
91
|
+
RetryTrackAlias: 0x6n
|
|
92
|
+
};
|
|
93
|
+
var FetchErrorCode = {
|
|
94
|
+
InternalError: 0x0n,
|
|
95
|
+
Unauthorized: 0x1n,
|
|
96
|
+
Timeout: 0x2n,
|
|
97
|
+
NotSupported: 0x3n,
|
|
98
|
+
TrackDoesNotExist: 0x4n,
|
|
99
|
+
InvalidRange: 0x5n
|
|
100
|
+
};
|
|
101
|
+
var SubscribeDoneStatusCode = {
|
|
102
|
+
InternalError: 0x0n,
|
|
103
|
+
Unauthorized: 0x1n,
|
|
104
|
+
TrackEnded: 0x2n,
|
|
105
|
+
SubscriptionEnded: 0x3n,
|
|
106
|
+
GoingAway: 0x4n,
|
|
107
|
+
Expired: 0x5n,
|
|
108
|
+
TooFarBehind: 0x6n
|
|
109
|
+
};
|
|
110
|
+
var SubscribeAnnouncesErrorCode = {
|
|
111
|
+
InternalError: 0x0n,
|
|
112
|
+
Unauthorized: 0x1n,
|
|
113
|
+
Timeout: 0x2n,
|
|
114
|
+
NotSupported: 0x3n,
|
|
115
|
+
NamespacePrefixUnknown: 0x4n
|
|
116
|
+
};
|
|
117
|
+
var TrackStatusCode = {
|
|
118
|
+
InProgress: 0x00n,
|
|
119
|
+
TrackDoesNotExist: 0x01n,
|
|
120
|
+
NotYetBegun: 0x02n,
|
|
121
|
+
Finished: 0x03n,
|
|
122
|
+
RelayStatusUnavailable: 0x04n
|
|
123
|
+
};
|
|
60
124
|
|
|
61
125
|
// src/drafts/draft08/index.ts
|
|
62
126
|
var DRAFT_VERSION = 0xff000008n;
|
|
@@ -116,4 +180,13 @@ var DRAFT_VERSION = 0xff000008n;
|
|
|
116
180
|
|
|
117
181
|
|
|
118
182
|
|
|
119
|
-
|
|
183
|
+
|
|
184
|
+
|
|
185
|
+
|
|
186
|
+
|
|
187
|
+
|
|
188
|
+
|
|
189
|
+
|
|
190
|
+
|
|
191
|
+
|
|
192
|
+
exports.AnnounceErrorCode = AnnounceErrorCode; exports.BIDIRECTIONAL_MESSAGES = _chunkMYXAD5JCcjs.BIDIRECTIONAL_MESSAGES; exports.CLIENT_ONLY_MESSAGES = _chunkMYXAD5JCcjs.CLIENT_ONLY_MESSAGES; exports.CONTROL_MESSAGES = _chunkMYXAD5JCcjs.CONTROL_MESSAGES; exports.DRAFT_VERSION = DRAFT_VERSION; exports.Draft08SessionFSM = _chunkMYXAD5JCcjs.Draft08SessionFSM; exports.FetchErrorCode = FetchErrorCode; exports.MESSAGE_ID_MAP = _chunkA7VQO6YCcjs.MESSAGE_ID_MAP; exports.MESSAGE_TYPE_MAP = _chunkA7VQO6YCcjs.MESSAGE_TYPE_MAP; exports.MSG_ANNOUNCE = _chunkA7VQO6YCcjs.MSG_ANNOUNCE; exports.MSG_ANNOUNCE_CANCEL = _chunkA7VQO6YCcjs.MSG_ANNOUNCE_CANCEL; exports.MSG_ANNOUNCE_ERROR = _chunkA7VQO6YCcjs.MSG_ANNOUNCE_ERROR; exports.MSG_ANNOUNCE_OK = _chunkA7VQO6YCcjs.MSG_ANNOUNCE_OK; exports.MSG_CLIENT_SETUP = _chunkA7VQO6YCcjs.MSG_CLIENT_SETUP; exports.MSG_FETCH = _chunkA7VQO6YCcjs.MSG_FETCH; exports.MSG_FETCH_CANCEL = _chunkA7VQO6YCcjs.MSG_FETCH_CANCEL; exports.MSG_FETCH_ERROR = _chunkA7VQO6YCcjs.MSG_FETCH_ERROR; exports.MSG_FETCH_OK = _chunkA7VQO6YCcjs.MSG_FETCH_OK; exports.MSG_GOAWAY = _chunkA7VQO6YCcjs.MSG_GOAWAY; exports.MSG_MAX_SUBSCRIBE_ID = _chunkA7VQO6YCcjs.MSG_MAX_SUBSCRIBE_ID; exports.MSG_SERVER_SETUP = _chunkA7VQO6YCcjs.MSG_SERVER_SETUP; exports.MSG_SUBSCRIBE = _chunkA7VQO6YCcjs.MSG_SUBSCRIBE; exports.MSG_SUBSCRIBES_BLOCKED = _chunkA7VQO6YCcjs.MSG_SUBSCRIBES_BLOCKED; exports.MSG_SUBSCRIBE_ANNOUNCES = _chunkA7VQO6YCcjs.MSG_SUBSCRIBE_ANNOUNCES; exports.MSG_SUBSCRIBE_ANNOUNCES_ERROR = _chunkA7VQO6YCcjs.MSG_SUBSCRIBE_ANNOUNCES_ERROR; exports.MSG_SUBSCRIBE_ANNOUNCES_OK = _chunkA7VQO6YCcjs.MSG_SUBSCRIBE_ANNOUNCES_OK; exports.MSG_SUBSCRIBE_DONE = _chunkA7VQO6YCcjs.MSG_SUBSCRIBE_DONE; exports.MSG_SUBSCRIBE_ERROR = _chunkA7VQO6YCcjs.MSG_SUBSCRIBE_ERROR; exports.MSG_SUBSCRIBE_OK = _chunkA7VQO6YCcjs.MSG_SUBSCRIBE_OK; exports.MSG_SUBSCRIBE_UPDATE = _chunkA7VQO6YCcjs.MSG_SUBSCRIBE_UPDATE; exports.MSG_TRACK_STATUS = _chunkA7VQO6YCcjs.MSG_TRACK_STATUS; exports.MSG_TRACK_STATUS_REQUEST = _chunkA7VQO6YCcjs.MSG_TRACK_STATUS_REQUEST; exports.MSG_UNANNOUNCE = _chunkA7VQO6YCcjs.MSG_UNANNOUNCE; exports.MSG_UNSUBSCRIBE = _chunkA7VQO6YCcjs.MSG_UNSUBSCRIBE; exports.MSG_UNSUBSCRIBE_ANNOUNCES = _chunkA7VQO6YCcjs.MSG_UNSUBSCRIBE_ANNOUNCES; exports.PARAM_AUTHORIZATION_INFO = _chunkA7VQO6YCcjs.PARAM_AUTHORIZATION_INFO; exports.PARAM_DELIVERY_TIMEOUT = _chunkA7VQO6YCcjs.PARAM_DELIVERY_TIMEOUT; exports.PARAM_MAX_CACHE_DURATION = _chunkA7VQO6YCcjs.PARAM_MAX_CACHE_DURATION; exports.REDACTION_FILL = _chunk5IMHJIAZcjs.REDACTION_FILL; exports.SERVER_ONLY_MESSAGES = _chunkMYXAD5JCcjs.SERVER_ONLY_MESSAGES; exports.SETUP_PARAM_MAX_SUBSCRIBE_ID = _chunkA7VQO6YCcjs.SETUP_PARAM_MAX_SUBSCRIBE_ID; exports.SETUP_PARAM_PATH = _chunkA7VQO6YCcjs.SETUP_PARAM_PATH; exports.SessionErrorCode = SessionErrorCode; exports.SubscribeAnnouncesErrorCode = SubscribeAnnouncesErrorCode; exports.SubscribeDoneStatusCode = SubscribeDoneStatusCode; exports.SubscribeErrorCode = SubscribeErrorCode; exports.TrackStatusCode = TrackStatusCode; exports.createDraft08Codec = _chunkA7VQO6YCcjs.createDraft08Codec; exports.createDraft08SessionState = _chunkMYXAD5JCcjs.createDraft08SessionState; exports.createStreamDecoder = _chunkA7VQO6YCcjs.createStreamDecoder; exports.decodeDataStream = _chunkA7VQO6YCcjs.decodeDataStream; exports.decodeDatagram = _chunkA7VQO6YCcjs.decodeDatagram; exports.decodeDatagramStatus = _chunkA7VQO6YCcjs.decodeDatagramStatus; exports.decodeFetchStream = _chunkA7VQO6YCcjs.decodeFetchStream; exports.decodeMessage = _chunkA7VQO6YCcjs.decodeMessage; exports.decodeSubgroupStream = _chunkA7VQO6YCcjs.decodeSubgroupStream; exports.encodeDatagram = _chunkA7VQO6YCcjs.encodeDatagram; exports.encodeDatagramStatus = _chunkA7VQO6YCcjs.encodeDatagramStatus; exports.encodeFetchStream = _chunkA7VQO6YCcjs.encodeFetchStream; exports.encodeMessage = _chunkA7VQO6YCcjs.encodeMessage; exports.encodeSubgroupStream = _chunkA7VQO6YCcjs.encodeSubgroupStream; exports.getLegalIncoming = _chunkMYXAD5JCcjs.getLegalIncoming; exports.getLegalOutgoing = _chunkMYXAD5JCcjs.getLegalOutgoing; exports.redactAuthTokens = _chunkA7VQO6YCcjs.redactAuthTokens;
|
package/dist/draft08.d.cts
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { A as AuthRedaction, R as REDACTION_FILL } from './auth-redaction-B9JJOlIY.cjs';
|
|
2
|
+
export { D as Draft08Codec, c as createDraft08Codec, a as createStreamDecoder, d as decodeMessage, e as encodeMessage, r as redactAuthTokens } from './codec-CUu56DDU.cjs';
|
|
2
3
|
import { b as Draft08DataStream, c as DatagramObject, d as DatagramStatusObject, F as FetchStream, S as SubgroupStream, a as Draft08MessageType, D as Draft08Message } from './types-jV1yDDBA.cjs';
|
|
3
4
|
export { e as DataStreamEvent, f as DataStreamHeader, g as Draft08Announce, h as Draft08AnnounceCancel, i as Draft08AnnounceError, j as Draft08AnnounceOk, k as Draft08BaseMessage, l as Draft08ClientSetup, m as Draft08Fetch, n as Draft08FetchCancel, o as Draft08FetchError, p as Draft08FetchOk, q as Draft08GoAway, r as Draft08MaxSubscribeId, s as Draft08Params, t as Draft08ServerSetup, u as Draft08SetupParams, v as Draft08Subscribe, w as Draft08SubscribeAnnounces, x as Draft08SubscribeAnnouncesError, y as Draft08SubscribeAnnouncesOk, z as Draft08SubscribeDone, A as Draft08SubscribeError, B as Draft08SubscribeOk, C as Draft08SubscribeUpdate, E as Draft08SubscribesBlocked, G as Draft08TrackStatus, H as Draft08TrackStatusRequest, I as Draft08Unannounce, J as Draft08Unsubscribe, K as Draft08UnsubscribeAnnounces, L as FetchObjectPayload, M as FetchStreamHeader, N as JoiningFetch, O as ObjectPayload, P as StandaloneFetch, Q as SubgroupStreamHeader, U as UnknownParam } from './types-jV1yDDBA.cjs';
|
|
4
5
|
export { createDraft08SessionState } from './draft08-session.cjs';
|
|
5
|
-
import { g as SessionPhase, j as SubscriptionState, b as AnnounceState, c as FetchState, V as ValidationResult, T as TransitionResult } from './session-types-
|
|
6
|
-
export { A as AnnouncePhase, F as FetchPhase, P as ProtocolViolation, d as ProtocolViolationCode, a as SessionState, h as SideEffect, i as SubscriptionPhase } from './session-types-
|
|
7
|
-
import { b as DecodeResult } from './types-
|
|
6
|
+
import { g as SessionPhase, j as SubscriptionState, b as AnnounceState, c as FetchState, V as ValidationResult, T as TransitionResult } from './session-types-DZkI_qFG.cjs';
|
|
7
|
+
export { A as AnnouncePhase, F as FetchPhase, P as ProtocolViolation, d as ProtocolViolationCode, a as SessionState, h as SideEffect, i as SubscriptionPhase } from './session-types-DZkI_qFG.cjs';
|
|
8
|
+
import { b as DecodeResult } from './types-2NisMA8_.cjs';
|
|
8
9
|
|
|
9
10
|
declare function encodeSubgroupStream(stream: SubgroupStream): Uint8Array;
|
|
10
11
|
declare function encodeDatagram(dg: DatagramObject): Uint8Array;
|
|
@@ -16,6 +17,73 @@ declare function decodeDatagramStatus(bytes: Uint8Array): DecodeResult<DatagramS
|
|
|
16
17
|
declare function decodeFetchStream(bytes: Uint8Array): DecodeResult<FetchStream>;
|
|
17
18
|
declare function decodeDataStream(streamType: 'subgroup' | 'datagram' | 'datagram_status' | 'fetch', bytes: Uint8Array): DecodeResult<Draft08DataStream>;
|
|
18
19
|
|
|
20
|
+
declare const SessionErrorCode: {
|
|
21
|
+
readonly NoError: 0n;
|
|
22
|
+
readonly InternalError: 1n;
|
|
23
|
+
readonly Unauthorized: 2n;
|
|
24
|
+
readonly ProtocolViolation: 3n;
|
|
25
|
+
readonly DuplicateTrackAlias: 4n;
|
|
26
|
+
readonly ParameterLengthMismatch: 5n;
|
|
27
|
+
readonly TooManySubscribes: 6n;
|
|
28
|
+
readonly GoawayTimeout: 16n;
|
|
29
|
+
readonly ControlMessageTimeout: 17n;
|
|
30
|
+
readonly DataStreamTimeout: 18n;
|
|
31
|
+
};
|
|
32
|
+
type SessionErrorCodeValue = (typeof SessionErrorCode)[keyof typeof SessionErrorCode];
|
|
33
|
+
declare const AnnounceErrorCode: {
|
|
34
|
+
readonly InternalError: 0n;
|
|
35
|
+
readonly Unauthorized: 1n;
|
|
36
|
+
readonly Timeout: 2n;
|
|
37
|
+
readonly NotSupported: 3n;
|
|
38
|
+
readonly Uninterested: 4n;
|
|
39
|
+
};
|
|
40
|
+
type AnnounceErrorCodeValue = (typeof AnnounceErrorCode)[keyof typeof AnnounceErrorCode];
|
|
41
|
+
declare const SubscribeErrorCode: {
|
|
42
|
+
readonly InternalError: 0n;
|
|
43
|
+
readonly Unauthorized: 1n;
|
|
44
|
+
readonly Timeout: 2n;
|
|
45
|
+
readonly NotSupported: 3n;
|
|
46
|
+
readonly TrackDoesNotExist: 4n;
|
|
47
|
+
readonly InvalidRange: 5n;
|
|
48
|
+
readonly RetryTrackAlias: 6n;
|
|
49
|
+
};
|
|
50
|
+
type SubscribeErrorCodeValue = (typeof SubscribeErrorCode)[keyof typeof SubscribeErrorCode];
|
|
51
|
+
declare const FetchErrorCode: {
|
|
52
|
+
readonly InternalError: 0n;
|
|
53
|
+
readonly Unauthorized: 1n;
|
|
54
|
+
readonly Timeout: 2n;
|
|
55
|
+
readonly NotSupported: 3n;
|
|
56
|
+
readonly TrackDoesNotExist: 4n;
|
|
57
|
+
readonly InvalidRange: 5n;
|
|
58
|
+
};
|
|
59
|
+
type FetchErrorCodeValue = (typeof FetchErrorCode)[keyof typeof FetchErrorCode];
|
|
60
|
+
declare const SubscribeDoneStatusCode: {
|
|
61
|
+
readonly InternalError: 0n;
|
|
62
|
+
readonly Unauthorized: 1n;
|
|
63
|
+
readonly TrackEnded: 2n;
|
|
64
|
+
readonly SubscriptionEnded: 3n;
|
|
65
|
+
readonly GoingAway: 4n;
|
|
66
|
+
readonly Expired: 5n;
|
|
67
|
+
readonly TooFarBehind: 6n;
|
|
68
|
+
};
|
|
69
|
+
type SubscribeDoneStatusCodeValue = (typeof SubscribeDoneStatusCode)[keyof typeof SubscribeDoneStatusCode];
|
|
70
|
+
declare const SubscribeAnnouncesErrorCode: {
|
|
71
|
+
readonly InternalError: 0n;
|
|
72
|
+
readonly Unauthorized: 1n;
|
|
73
|
+
readonly Timeout: 2n;
|
|
74
|
+
readonly NotSupported: 3n;
|
|
75
|
+
readonly NamespacePrefixUnknown: 4n;
|
|
76
|
+
};
|
|
77
|
+
type SubscribeAnnouncesErrorCodeValue = (typeof SubscribeAnnouncesErrorCode)[keyof typeof SubscribeAnnouncesErrorCode];
|
|
78
|
+
declare const TrackStatusCode: {
|
|
79
|
+
readonly InProgress: 0n;
|
|
80
|
+
readonly TrackDoesNotExist: 1n;
|
|
81
|
+
readonly NotYetBegun: 2n;
|
|
82
|
+
readonly Finished: 3n;
|
|
83
|
+
readonly RelayStatusUnavailable: 4n;
|
|
84
|
+
};
|
|
85
|
+
type TrackStatusCodeValue = (typeof TrackStatusCode)[keyof typeof TrackStatusCode];
|
|
86
|
+
|
|
19
87
|
declare const MSG_SUBSCRIBE_UPDATE = 2n;
|
|
20
88
|
declare const MSG_SUBSCRIBE = 3n;
|
|
21
89
|
declare const MSG_SUBSCRIBE_OK = 4n;
|
|
@@ -104,4 +172,4 @@ declare class Draft08SessionFSM {
|
|
|
104
172
|
|
|
105
173
|
declare const DRAFT_VERSION = 4278190088n;
|
|
106
174
|
|
|
107
|
-
export { AnnounceState, BIDIRECTIONAL_MESSAGES, CLIENT_ONLY_MESSAGES, CONTROL_MESSAGES, DRAFT_VERSION, DatagramObject, DatagramStatusObject, Draft08DataStream, Draft08Message, Draft08MessageType, Draft08SessionFSM, FetchState, FetchStream, MESSAGE_ID_MAP, MESSAGE_TYPE_MAP, MSG_ANNOUNCE, MSG_ANNOUNCE_CANCEL, MSG_ANNOUNCE_ERROR, MSG_ANNOUNCE_OK, MSG_CLIENT_SETUP, MSG_FETCH, MSG_FETCH_CANCEL, MSG_FETCH_ERROR, MSG_FETCH_OK, MSG_GOAWAY, MSG_MAX_SUBSCRIBE_ID, MSG_SERVER_SETUP, MSG_SUBSCRIBE, MSG_SUBSCRIBES_BLOCKED, MSG_SUBSCRIBE_ANNOUNCES, MSG_SUBSCRIBE_ANNOUNCES_ERROR, MSG_SUBSCRIBE_ANNOUNCES_OK, MSG_SUBSCRIBE_DONE, MSG_SUBSCRIBE_ERROR, MSG_SUBSCRIBE_OK, MSG_SUBSCRIBE_UPDATE, MSG_TRACK_STATUS, MSG_TRACK_STATUS_REQUEST, MSG_UNANNOUNCE, MSG_UNSUBSCRIBE, MSG_UNSUBSCRIBE_ANNOUNCES, PARAM_AUTHORIZATION_INFO, PARAM_DELIVERY_TIMEOUT, PARAM_MAX_CACHE_DURATION, SERVER_ONLY_MESSAGES, SETUP_PARAM_MAX_SUBSCRIBE_ID, SETUP_PARAM_PATH, SessionPhase, SubgroupStream, SubscriptionState, TransitionResult, ValidationResult, decodeDataStream, decodeDatagram, decodeDatagramStatus, decodeFetchStream, decodeSubgroupStream, encodeDatagram, encodeDatagramStatus, encodeFetchStream, encodeSubgroupStream, getLegalIncoming, getLegalOutgoing };
|
|
175
|
+
export { AnnounceErrorCode, type AnnounceErrorCodeValue, AnnounceState, BIDIRECTIONAL_MESSAGES, CLIENT_ONLY_MESSAGES, CONTROL_MESSAGES, DRAFT_VERSION, DatagramObject, DatagramStatusObject, Draft08DataStream, Draft08Message, Draft08MessageType, Draft08SessionFSM, FetchErrorCode, type FetchErrorCodeValue, FetchState, FetchStream, MESSAGE_ID_MAP, MESSAGE_TYPE_MAP, MSG_ANNOUNCE, MSG_ANNOUNCE_CANCEL, MSG_ANNOUNCE_ERROR, MSG_ANNOUNCE_OK, MSG_CLIENT_SETUP, MSG_FETCH, MSG_FETCH_CANCEL, MSG_FETCH_ERROR, MSG_FETCH_OK, MSG_GOAWAY, MSG_MAX_SUBSCRIBE_ID, MSG_SERVER_SETUP, MSG_SUBSCRIBE, MSG_SUBSCRIBES_BLOCKED, MSG_SUBSCRIBE_ANNOUNCES, MSG_SUBSCRIBE_ANNOUNCES_ERROR, MSG_SUBSCRIBE_ANNOUNCES_OK, MSG_SUBSCRIBE_DONE, MSG_SUBSCRIBE_ERROR, MSG_SUBSCRIBE_OK, MSG_SUBSCRIBE_UPDATE, MSG_TRACK_STATUS, MSG_TRACK_STATUS_REQUEST, MSG_UNANNOUNCE, MSG_UNSUBSCRIBE, MSG_UNSUBSCRIBE_ANNOUNCES, PARAM_AUTHORIZATION_INFO, PARAM_DELIVERY_TIMEOUT, PARAM_MAX_CACHE_DURATION, SERVER_ONLY_MESSAGES, SETUP_PARAM_MAX_SUBSCRIBE_ID, SETUP_PARAM_PATH, SessionErrorCode, type SessionErrorCodeValue, SessionPhase, SubgroupStream, SubscribeAnnouncesErrorCode, type SubscribeAnnouncesErrorCodeValue, SubscribeDoneStatusCode, type SubscribeDoneStatusCodeValue, SubscribeErrorCode, type SubscribeErrorCodeValue, SubscriptionState, TrackStatusCode, type TrackStatusCodeValue, TransitionResult, ValidationResult, decodeDataStream, decodeDatagram, decodeDatagramStatus, decodeFetchStream, decodeSubgroupStream, encodeDatagram, encodeDatagramStatus, encodeFetchStream, encodeSubgroupStream, getLegalIncoming, getLegalOutgoing };
|
package/dist/draft08.d.ts
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { A as AuthRedaction, R as REDACTION_FILL } from './auth-redaction-B9JJOlIY.js';
|
|
2
|
+
export { D as Draft08Codec, c as createDraft08Codec, a as createStreamDecoder, d as decodeMessage, e as encodeMessage, r as redactAuthTokens } from './codec-Dt6nuejp.js';
|
|
2
3
|
import { b as Draft08DataStream, c as DatagramObject, d as DatagramStatusObject, F as FetchStream, S as SubgroupStream, a as Draft08MessageType, D as Draft08Message } from './types-jV1yDDBA.js';
|
|
3
4
|
export { e as DataStreamEvent, f as DataStreamHeader, g as Draft08Announce, h as Draft08AnnounceCancel, i as Draft08AnnounceError, j as Draft08AnnounceOk, k as Draft08BaseMessage, l as Draft08ClientSetup, m as Draft08Fetch, n as Draft08FetchCancel, o as Draft08FetchError, p as Draft08FetchOk, q as Draft08GoAway, r as Draft08MaxSubscribeId, s as Draft08Params, t as Draft08ServerSetup, u as Draft08SetupParams, v as Draft08Subscribe, w as Draft08SubscribeAnnounces, x as Draft08SubscribeAnnouncesError, y as Draft08SubscribeAnnouncesOk, z as Draft08SubscribeDone, A as Draft08SubscribeError, B as Draft08SubscribeOk, C as Draft08SubscribeUpdate, E as Draft08SubscribesBlocked, G as Draft08TrackStatus, H as Draft08TrackStatusRequest, I as Draft08Unannounce, J as Draft08Unsubscribe, K as Draft08UnsubscribeAnnounces, L as FetchObjectPayload, M as FetchStreamHeader, N as JoiningFetch, O as ObjectPayload, P as StandaloneFetch, Q as SubgroupStreamHeader, U as UnknownParam } from './types-jV1yDDBA.js';
|
|
4
5
|
export { createDraft08SessionState } from './draft08-session.js';
|
|
5
|
-
import { g as SessionPhase, j as SubscriptionState, b as AnnounceState, c as FetchState, V as ValidationResult, T as TransitionResult } from './session-types-
|
|
6
|
-
export { A as AnnouncePhase, F as FetchPhase, P as ProtocolViolation, d as ProtocolViolationCode, a as SessionState, h as SideEffect, i as SubscriptionPhase } from './session-types-
|
|
7
|
-
import { b as DecodeResult } from './types-
|
|
6
|
+
import { g as SessionPhase, j as SubscriptionState, b as AnnounceState, c as FetchState, V as ValidationResult, T as TransitionResult } from './session-types-Cxx7W8zZ.js';
|
|
7
|
+
export { A as AnnouncePhase, F as FetchPhase, P as ProtocolViolation, d as ProtocolViolationCode, a as SessionState, h as SideEffect, i as SubscriptionPhase } from './session-types-Cxx7W8zZ.js';
|
|
8
|
+
import { b as DecodeResult } from './types-2NisMA8_.js';
|
|
8
9
|
|
|
9
10
|
declare function encodeSubgroupStream(stream: SubgroupStream): Uint8Array;
|
|
10
11
|
declare function encodeDatagram(dg: DatagramObject): Uint8Array;
|
|
@@ -16,6 +17,73 @@ declare function decodeDatagramStatus(bytes: Uint8Array): DecodeResult<DatagramS
|
|
|
16
17
|
declare function decodeFetchStream(bytes: Uint8Array): DecodeResult<FetchStream>;
|
|
17
18
|
declare function decodeDataStream(streamType: 'subgroup' | 'datagram' | 'datagram_status' | 'fetch', bytes: Uint8Array): DecodeResult<Draft08DataStream>;
|
|
18
19
|
|
|
20
|
+
declare const SessionErrorCode: {
|
|
21
|
+
readonly NoError: 0n;
|
|
22
|
+
readonly InternalError: 1n;
|
|
23
|
+
readonly Unauthorized: 2n;
|
|
24
|
+
readonly ProtocolViolation: 3n;
|
|
25
|
+
readonly DuplicateTrackAlias: 4n;
|
|
26
|
+
readonly ParameterLengthMismatch: 5n;
|
|
27
|
+
readonly TooManySubscribes: 6n;
|
|
28
|
+
readonly GoawayTimeout: 16n;
|
|
29
|
+
readonly ControlMessageTimeout: 17n;
|
|
30
|
+
readonly DataStreamTimeout: 18n;
|
|
31
|
+
};
|
|
32
|
+
type SessionErrorCodeValue = (typeof SessionErrorCode)[keyof typeof SessionErrorCode];
|
|
33
|
+
declare const AnnounceErrorCode: {
|
|
34
|
+
readonly InternalError: 0n;
|
|
35
|
+
readonly Unauthorized: 1n;
|
|
36
|
+
readonly Timeout: 2n;
|
|
37
|
+
readonly NotSupported: 3n;
|
|
38
|
+
readonly Uninterested: 4n;
|
|
39
|
+
};
|
|
40
|
+
type AnnounceErrorCodeValue = (typeof AnnounceErrorCode)[keyof typeof AnnounceErrorCode];
|
|
41
|
+
declare const SubscribeErrorCode: {
|
|
42
|
+
readonly InternalError: 0n;
|
|
43
|
+
readonly Unauthorized: 1n;
|
|
44
|
+
readonly Timeout: 2n;
|
|
45
|
+
readonly NotSupported: 3n;
|
|
46
|
+
readonly TrackDoesNotExist: 4n;
|
|
47
|
+
readonly InvalidRange: 5n;
|
|
48
|
+
readonly RetryTrackAlias: 6n;
|
|
49
|
+
};
|
|
50
|
+
type SubscribeErrorCodeValue = (typeof SubscribeErrorCode)[keyof typeof SubscribeErrorCode];
|
|
51
|
+
declare const FetchErrorCode: {
|
|
52
|
+
readonly InternalError: 0n;
|
|
53
|
+
readonly Unauthorized: 1n;
|
|
54
|
+
readonly Timeout: 2n;
|
|
55
|
+
readonly NotSupported: 3n;
|
|
56
|
+
readonly TrackDoesNotExist: 4n;
|
|
57
|
+
readonly InvalidRange: 5n;
|
|
58
|
+
};
|
|
59
|
+
type FetchErrorCodeValue = (typeof FetchErrorCode)[keyof typeof FetchErrorCode];
|
|
60
|
+
declare const SubscribeDoneStatusCode: {
|
|
61
|
+
readonly InternalError: 0n;
|
|
62
|
+
readonly Unauthorized: 1n;
|
|
63
|
+
readonly TrackEnded: 2n;
|
|
64
|
+
readonly SubscriptionEnded: 3n;
|
|
65
|
+
readonly GoingAway: 4n;
|
|
66
|
+
readonly Expired: 5n;
|
|
67
|
+
readonly TooFarBehind: 6n;
|
|
68
|
+
};
|
|
69
|
+
type SubscribeDoneStatusCodeValue = (typeof SubscribeDoneStatusCode)[keyof typeof SubscribeDoneStatusCode];
|
|
70
|
+
declare const SubscribeAnnouncesErrorCode: {
|
|
71
|
+
readonly InternalError: 0n;
|
|
72
|
+
readonly Unauthorized: 1n;
|
|
73
|
+
readonly Timeout: 2n;
|
|
74
|
+
readonly NotSupported: 3n;
|
|
75
|
+
readonly NamespacePrefixUnknown: 4n;
|
|
76
|
+
};
|
|
77
|
+
type SubscribeAnnouncesErrorCodeValue = (typeof SubscribeAnnouncesErrorCode)[keyof typeof SubscribeAnnouncesErrorCode];
|
|
78
|
+
declare const TrackStatusCode: {
|
|
79
|
+
readonly InProgress: 0n;
|
|
80
|
+
readonly TrackDoesNotExist: 1n;
|
|
81
|
+
readonly NotYetBegun: 2n;
|
|
82
|
+
readonly Finished: 3n;
|
|
83
|
+
readonly RelayStatusUnavailable: 4n;
|
|
84
|
+
};
|
|
85
|
+
type TrackStatusCodeValue = (typeof TrackStatusCode)[keyof typeof TrackStatusCode];
|
|
86
|
+
|
|
19
87
|
declare const MSG_SUBSCRIBE_UPDATE = 2n;
|
|
20
88
|
declare const MSG_SUBSCRIBE = 3n;
|
|
21
89
|
declare const MSG_SUBSCRIBE_OK = 4n;
|
|
@@ -104,4 +172,4 @@ declare class Draft08SessionFSM {
|
|
|
104
172
|
|
|
105
173
|
declare const DRAFT_VERSION = 4278190088n;
|
|
106
174
|
|
|
107
|
-
export { AnnounceState, BIDIRECTIONAL_MESSAGES, CLIENT_ONLY_MESSAGES, CONTROL_MESSAGES, DRAFT_VERSION, DatagramObject, DatagramStatusObject, Draft08DataStream, Draft08Message, Draft08MessageType, Draft08SessionFSM, FetchState, FetchStream, MESSAGE_ID_MAP, MESSAGE_TYPE_MAP, MSG_ANNOUNCE, MSG_ANNOUNCE_CANCEL, MSG_ANNOUNCE_ERROR, MSG_ANNOUNCE_OK, MSG_CLIENT_SETUP, MSG_FETCH, MSG_FETCH_CANCEL, MSG_FETCH_ERROR, MSG_FETCH_OK, MSG_GOAWAY, MSG_MAX_SUBSCRIBE_ID, MSG_SERVER_SETUP, MSG_SUBSCRIBE, MSG_SUBSCRIBES_BLOCKED, MSG_SUBSCRIBE_ANNOUNCES, MSG_SUBSCRIBE_ANNOUNCES_ERROR, MSG_SUBSCRIBE_ANNOUNCES_OK, MSG_SUBSCRIBE_DONE, MSG_SUBSCRIBE_ERROR, MSG_SUBSCRIBE_OK, MSG_SUBSCRIBE_UPDATE, MSG_TRACK_STATUS, MSG_TRACK_STATUS_REQUEST, MSG_UNANNOUNCE, MSG_UNSUBSCRIBE, MSG_UNSUBSCRIBE_ANNOUNCES, PARAM_AUTHORIZATION_INFO, PARAM_DELIVERY_TIMEOUT, PARAM_MAX_CACHE_DURATION, SERVER_ONLY_MESSAGES, SETUP_PARAM_MAX_SUBSCRIBE_ID, SETUP_PARAM_PATH, SessionPhase, SubgroupStream, SubscriptionState, TransitionResult, ValidationResult, decodeDataStream, decodeDatagram, decodeDatagramStatus, decodeFetchStream, decodeSubgroupStream, encodeDatagram, encodeDatagramStatus, encodeFetchStream, encodeSubgroupStream, getLegalIncoming, getLegalOutgoing };
|
|
175
|
+
export { AnnounceErrorCode, type AnnounceErrorCodeValue, AnnounceState, BIDIRECTIONAL_MESSAGES, CLIENT_ONLY_MESSAGES, CONTROL_MESSAGES, DRAFT_VERSION, DatagramObject, DatagramStatusObject, Draft08DataStream, Draft08Message, Draft08MessageType, Draft08SessionFSM, FetchErrorCode, type FetchErrorCodeValue, FetchState, FetchStream, MESSAGE_ID_MAP, MESSAGE_TYPE_MAP, MSG_ANNOUNCE, MSG_ANNOUNCE_CANCEL, MSG_ANNOUNCE_ERROR, MSG_ANNOUNCE_OK, MSG_CLIENT_SETUP, MSG_FETCH, MSG_FETCH_CANCEL, MSG_FETCH_ERROR, MSG_FETCH_OK, MSG_GOAWAY, MSG_MAX_SUBSCRIBE_ID, MSG_SERVER_SETUP, MSG_SUBSCRIBE, MSG_SUBSCRIBES_BLOCKED, MSG_SUBSCRIBE_ANNOUNCES, MSG_SUBSCRIBE_ANNOUNCES_ERROR, MSG_SUBSCRIBE_ANNOUNCES_OK, MSG_SUBSCRIBE_DONE, MSG_SUBSCRIBE_ERROR, MSG_SUBSCRIBE_OK, MSG_SUBSCRIBE_UPDATE, MSG_TRACK_STATUS, MSG_TRACK_STATUS_REQUEST, MSG_UNANNOUNCE, MSG_UNSUBSCRIBE, MSG_UNSUBSCRIBE_ANNOUNCES, PARAM_AUTHORIZATION_INFO, PARAM_DELIVERY_TIMEOUT, PARAM_MAX_CACHE_DURATION, SERVER_ONLY_MESSAGES, SETUP_PARAM_MAX_SUBSCRIBE_ID, SETUP_PARAM_PATH, SessionErrorCode, type SessionErrorCodeValue, SessionPhase, SubgroupStream, SubscribeAnnouncesErrorCode, type SubscribeAnnouncesErrorCodeValue, SubscribeDoneStatusCode, type SubscribeDoneStatusCodeValue, SubscribeErrorCode, type SubscribeErrorCodeValue, SubscriptionState, TrackStatusCode, type TrackStatusCodeValue, TransitionResult, ValidationResult, decodeDataStream, decodeDatagram, decodeDatagramStatus, decodeFetchStream, decodeSubgroupStream, encodeDatagram, encodeDatagramStatus, encodeFetchStream, encodeSubgroupStream, getLegalIncoming, getLegalOutgoing };
|