moqtail 0.15.0 → 0.17.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 +153 -473
- package/dist/client-CjdF7_cL.d.cts +1928 -0
- package/dist/{client-BviQ20Lc.cjs → client-FnSNJocV.cjs} +1102 -1192
- package/dist/client-I8mDg-Ls.d.mts +1928 -0
- package/dist/{client-zi0lmuIL.mjs → client-MXn-lkAA.mjs} +940 -1018
- package/dist/client.cjs +202 -7
- package/dist/client.d.cts +23 -1944
- package/dist/client.d.mts +23 -1944
- package/dist/client.mjs +195 -2
- package/dist/emitter-UbeRcbuf.mjs +109 -0
- package/dist/{logger-c2NoQqtx.cjs → emitter-qNJYD3yQ.cjs} +61 -2
- package/dist/{index-BY6e1obL.d.cts → index-BaZgHZ8D.d.mts} +124 -324
- package/dist/index-Bn8VlVoN.d.cts +2261 -0
- package/dist/index-Ch5QUygw.d.mts +2261 -0
- package/dist/index.cjs +18 -14
- package/dist/index.d.cts +20 -4
- package/dist/index.d.mts +20 -4
- package/dist/index.mjs +5 -4
- package/dist/logger-B8IYkljn.d.cts +64 -0
- package/dist/logger-B8IYkljn.d.mts +64 -0
- package/dist/model.cjs +380 -572
- package/dist/model.d.cts +2901 -2
- package/dist/model.d.mts +17 -2
- package/dist/model.mjs +380 -572
- package/dist/player/component.cjs +364 -0
- package/dist/player/component.d.cts +59 -0
- package/dist/player/component.d.mts +59 -0
- package/dist/player/component.mjs +362 -0
- package/dist/player-C6y-qpHz.cjs +8488 -0
- package/dist/player-DfJB6vBH.mjs +8293 -0
- package/dist/player.cjs +31 -0
- package/dist/player.d.cts +17 -0
- package/dist/player.d.mts +17 -0
- package/dist/player.mjs +1 -0
- package/dist/util.cjs +9 -10
- package/dist/util.d.cts +20 -13
- package/dist/util.d.mts +20 -13
- package/dist/util.mjs +4 -6
- package/package.json +46 -5
- package/dist/index-BY6e1obL.d.mts +0 -3087
- package/dist/logger-ByDB8lYF.mjs +0 -56
- package/dist/logger-dEoueCj7.d.cts +0 -35
- package/dist/logger-dEoueCj7.d.mts +0 -35
package/dist/model.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/model/error/error.ts
|
|
2
2
|
/**
|
|
3
3
|
* Copyright 2025 The MOQtail Authors
|
|
4
4
|
*
|
|
@@ -195,8 +195,7 @@ var TerminationError = class extends MOQtailError {
|
|
|
195
195
|
this.terminationCode = terminationCode;
|
|
196
196
|
}
|
|
197
197
|
};
|
|
198
|
-
|
|
199
|
-
//#region src/model/common/pair.ts
|
|
198
|
+
// src/model/common/pair.ts
|
|
200
199
|
/**
|
|
201
200
|
* Copyright 2025 The MOQtail Authors
|
|
202
201
|
*
|
|
@@ -449,8 +448,7 @@ function isVarInt(pair) {
|
|
|
449
448
|
function isBytes(pair) {
|
|
450
449
|
return pair.value instanceof Uint8Array;
|
|
451
450
|
}
|
|
452
|
-
|
|
453
|
-
//#region src/model/common/location.ts
|
|
451
|
+
// src/model/common/location.ts
|
|
454
452
|
/**
|
|
455
453
|
* Copyright 2025 The MOQtail Authors
|
|
456
454
|
*
|
|
@@ -536,8 +534,7 @@ var Location = class Location {
|
|
|
536
534
|
return 0;
|
|
537
535
|
}
|
|
538
536
|
};
|
|
539
|
-
|
|
540
|
-
//#region src/model/common/tuple.ts
|
|
537
|
+
// src/model/common/tuple.ts
|
|
541
538
|
/**
|
|
542
539
|
* Copyright 2025 The MOQtail Authors
|
|
543
540
|
*
|
|
@@ -706,8 +703,7 @@ var Tuple = class Tuple {
|
|
|
706
703
|
return this.fields.every((f, i) => f.value.toString() === other.fields[i].value.toString());
|
|
707
704
|
}
|
|
708
705
|
};
|
|
709
|
-
|
|
710
|
-
//#region src/model/common/reason_phrase.ts
|
|
706
|
+
// src/model/common/reason_phrase.ts
|
|
711
707
|
/**
|
|
712
708
|
* Copyright 2025 The MOQtail Authors
|
|
713
709
|
*
|
|
@@ -811,8 +807,7 @@ var ReasonPhrase = class ReasonPhrase {
|
|
|
811
807
|
}
|
|
812
808
|
}
|
|
813
809
|
};
|
|
814
|
-
|
|
815
|
-
//#region src/model/error/constant.ts
|
|
810
|
+
// src/model/error/constant.ts
|
|
816
811
|
/**
|
|
817
812
|
* Copyright 2025 The MOQtail Authors
|
|
818
813
|
*
|
|
@@ -879,8 +874,7 @@ let TerminationCode = /* @__PURE__ */ function(TerminationCode) {
|
|
|
879
874
|
}
|
|
880
875
|
_TerminationCode.tryFrom = tryFrom;
|
|
881
876
|
})(TerminationCode || (TerminationCode = {}));
|
|
882
|
-
|
|
883
|
-
//#region src/model/error/stream_reset.ts
|
|
877
|
+
// src/model/error/stream_reset.ts
|
|
884
878
|
/**
|
|
885
879
|
* Copyright 2026 The MOQtail Authors
|
|
886
880
|
*
|
|
@@ -934,8 +928,7 @@ let StreamResetCode = /* @__PURE__ */ function(StreamResetCode) {
|
|
|
934
928
|
}
|
|
935
929
|
_StreamResetCode.tryFrom = tryFrom;
|
|
936
930
|
})(StreamResetCode || (StreamResetCode = {}));
|
|
937
|
-
|
|
938
|
-
//#region src/model/data/constant.ts
|
|
931
|
+
// src/model/data/constant.ts
|
|
939
932
|
/**
|
|
940
933
|
* Copyright 2025 The MOQtail Authors
|
|
941
934
|
*
|
|
@@ -1239,8 +1232,268 @@ let ObjectStatus = /* @__PURE__ */ function(ObjectStatus) {
|
|
|
1239
1232
|
}
|
|
1240
1233
|
_ObjectStatus.tryFrom = tryFrom;
|
|
1241
1234
|
})(ObjectStatus || (ObjectStatus = {}));
|
|
1242
|
-
|
|
1243
|
-
|
|
1235
|
+
// src/model/common/grease.ts
|
|
1236
|
+
/**
|
|
1237
|
+
* Copyright 2026 The MOQtail Authors
|
|
1238
|
+
*
|
|
1239
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
1240
|
+
* you may not use this file except in compliance with the License.
|
|
1241
|
+
* You may obtain a copy of the License at
|
|
1242
|
+
*
|
|
1243
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
1244
|
+
*
|
|
1245
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
1246
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
1247
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
1248
|
+
* See the License for the specific language governing permissions and
|
|
1249
|
+
* limitations under the License.
|
|
1250
|
+
*/
|
|
1251
|
+
/**
|
|
1252
|
+
* GREASE reservations (§14). Values matching `0x7f * N + 0x9D` are reserved across
|
|
1253
|
+
* several registries (Setup Options, Properties, error codes) so peers can emit them
|
|
1254
|
+
* to exercise unknown-value handling. Receivers treat them like any other unknown
|
|
1255
|
+
* value: ignore, never fatal.
|
|
1256
|
+
*/
|
|
1257
|
+
/** Step between successive GREASE values. */
|
|
1258
|
+
const GREASE_STEP = 127n;
|
|
1259
|
+
/** The smallest GREASE value (N = 0). */
|
|
1260
|
+
const GREASE_BASE = 157n;
|
|
1261
|
+
/** The largest GREASE value that still fits a varint, i.e. `0x3fffffffffffffde`. */
|
|
1262
|
+
const GREASE_MAX = 4611686018427387870n;
|
|
1263
|
+
/**
|
|
1264
|
+
* @public
|
|
1265
|
+
* True if `value` is a reserved GREASE value, i.e. `0x7f * N + 0x9D` for some
|
|
1266
|
+
* non-negative `N`.
|
|
1267
|
+
*/
|
|
1268
|
+
function isGrease(value) {
|
|
1269
|
+
const v = BigInt(value);
|
|
1270
|
+
return v >= 157n && (v - 157n) % 127n === 0n;
|
|
1271
|
+
}
|
|
1272
|
+
/**
|
|
1273
|
+
* @public
|
|
1274
|
+
* The `N`-th GREASE value, `0x7f * N + 0x9D`, or undefined if it would exceed what a
|
|
1275
|
+
* varint can carry (the pattern is capped at `0x3fffffffffffffde`).
|
|
1276
|
+
*/
|
|
1277
|
+
function greaseValue(n) {
|
|
1278
|
+
const value = GREASE_STEP * BigInt(n) + GREASE_BASE;
|
|
1279
|
+
return value > GREASE_MAX ? void 0 : value;
|
|
1280
|
+
}
|
|
1281
|
+
// src/model/property/constant.ts
|
|
1282
|
+
/**
|
|
1283
|
+
* Copyright 2025 The MOQtail Authors
|
|
1284
|
+
*
|
|
1285
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
1286
|
+
* you may not use this file except in compliance with the License.
|
|
1287
|
+
* You may obtain a copy of the License at
|
|
1288
|
+
*
|
|
1289
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
1290
|
+
*
|
|
1291
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
1292
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
1293
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
1294
|
+
* See the License for the specific language governing permissions and
|
|
1295
|
+
* limitations under the License.
|
|
1296
|
+
*/
|
|
1297
|
+
let LOCPropertyId = /* @__PURE__ */ function(LOCPropertyId) {
|
|
1298
|
+
LOCPropertyId[LOCPropertyId["Timescale"] = 8] = "Timescale";
|
|
1299
|
+
LOCPropertyId[LOCPropertyId["VideoFrameMarking"] = 9] = "VideoFrameMarking";
|
|
1300
|
+
LOCPropertyId[LOCPropertyId["AudioLevel"] = 12] = "AudioLevel";
|
|
1301
|
+
LOCPropertyId[LOCPropertyId["VideoConfig"] = 13] = "VideoConfig";
|
|
1302
|
+
LOCPropertyId[LOCPropertyId["AudioConfig"] = 15] = "AudioConfig";
|
|
1303
|
+
LOCPropertyId[LOCPropertyId["Timestamp"] = 16] = "Timestamp";
|
|
1304
|
+
return LOCPropertyId;
|
|
1305
|
+
}({});
|
|
1306
|
+
let TrackPropertyType = /* @__PURE__ */ function(TrackPropertyType) {
|
|
1307
|
+
TrackPropertyType[TrackPropertyType["ObjectDeliveryTimeout"] = 2] = "ObjectDeliveryTimeout";
|
|
1308
|
+
TrackPropertyType[TrackPropertyType["MaxCacheDuration"] = 4] = "MaxCacheDuration";
|
|
1309
|
+
TrackPropertyType[TrackPropertyType["SubgroupDeliveryTimeout"] = 6] = "SubgroupDeliveryTimeout";
|
|
1310
|
+
TrackPropertyType[TrackPropertyType["ImmutableProperties"] = 11] = "ImmutableProperties";
|
|
1311
|
+
TrackPropertyType[TrackPropertyType["DefaultPublisherPriority"] = 14] = "DefaultPublisherPriority";
|
|
1312
|
+
TrackPropertyType[TrackPropertyType["DefaultPublisherGroupOrder"] = 34] = "DefaultPublisherGroupOrder";
|
|
1313
|
+
TrackPropertyType[TrackPropertyType["DynamicGroups"] = 48] = "DynamicGroups";
|
|
1314
|
+
TrackPropertyType[TrackPropertyType["PriorGroupIdGap"] = 60] = "PriorGroupIdGap";
|
|
1315
|
+
TrackPropertyType[TrackPropertyType["PriorObjectIdGap"] = 62] = "PriorObjectIdGap";
|
|
1316
|
+
return TrackPropertyType;
|
|
1317
|
+
}({});
|
|
1318
|
+
function locPropertyIdFromNumber(value) {
|
|
1319
|
+
switch (value) {
|
|
1320
|
+
case 8: return 8;
|
|
1321
|
+
case 9: return 9;
|
|
1322
|
+
case 12: return 12;
|
|
1323
|
+
case 13: return 13;
|
|
1324
|
+
case 15: return 15;
|
|
1325
|
+
case 16: return 16;
|
|
1326
|
+
default: throw new InvalidTypeError("locPropertyIdFromNumber", `Invalid LOC property id: ${value}`);
|
|
1327
|
+
}
|
|
1328
|
+
}
|
|
1329
|
+
/**
|
|
1330
|
+
* @public
|
|
1331
|
+
* Registration-policy ranges for the Property Type space.
|
|
1332
|
+
*
|
|
1333
|
+
*/
|
|
1334
|
+
const PropertyRanges = {
|
|
1335
|
+
/** Standards Action or IESG Approval (1-byte encoding). */
|
|
1336
|
+
StandardsAction: {
|
|
1337
|
+
from: 0n,
|
|
1338
|
+
to: 119n
|
|
1339
|
+
},
|
|
1340
|
+
/** Application-specific use, no registration permitted (1-byte encoding). */
|
|
1341
|
+
AppSpecific1Byte: {
|
|
1342
|
+
from: 120n,
|
|
1343
|
+
to: 127n
|
|
1344
|
+
},
|
|
1345
|
+
/** Specification Required (2-byte encoding). */
|
|
1346
|
+
SpecRequired: {
|
|
1347
|
+
from: 128n,
|
|
1348
|
+
to: 14335n
|
|
1349
|
+
},
|
|
1350
|
+
/** Application-specific use, no registration permitted (2-byte encoding). */
|
|
1351
|
+
AppSpecific2Byte: {
|
|
1352
|
+
from: 14336n,
|
|
1353
|
+
to: 16383n
|
|
1354
|
+
},
|
|
1355
|
+
/** Mandatory Track Properties; Track scope only. */
|
|
1356
|
+
MandatoryTrack: {
|
|
1357
|
+
from: 16384n,
|
|
1358
|
+
to: 32767n
|
|
1359
|
+
},
|
|
1360
|
+
/** First Come First Served begins here (open-ended). */
|
|
1361
|
+
Fcfs: { from: 32768n }
|
|
1362
|
+
};
|
|
1363
|
+
function inRange(range, typeValue) {
|
|
1364
|
+
return typeValue >= range.from && (range.to === void 0 || typeValue <= range.to);
|
|
1365
|
+
}
|
|
1366
|
+
/**
|
|
1367
|
+
* @public
|
|
1368
|
+
* True if a Property Type is reserved for application-specific use (either encoding-width
|
|
1369
|
+
* range), for which no IANA registration is permitted.
|
|
1370
|
+
*/
|
|
1371
|
+
function isApplicationSpecificProperty(typeValue) {
|
|
1372
|
+
const v = BigInt(typeValue);
|
|
1373
|
+
return inRange(PropertyRanges.AppSpecific1Byte, v) || inRange(PropertyRanges.AppSpecific2Byte, v);
|
|
1374
|
+
}
|
|
1375
|
+
// src/model/property/object_property.ts
|
|
1376
|
+
/**
|
|
1377
|
+
* Copyright 2026 The MOQtail Authors
|
|
1378
|
+
*
|
|
1379
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
1380
|
+
* you may not use this file except in compliance with the License.
|
|
1381
|
+
* You may obtain a copy of the License at
|
|
1382
|
+
*
|
|
1383
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
1384
|
+
*
|
|
1385
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
1386
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
1387
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
1388
|
+
* See the License for the specific language governing permissions and
|
|
1389
|
+
* limitations under the License.
|
|
1390
|
+
*/
|
|
1391
|
+
var ImmutablePropertiesObjectProperty = class ImmutablePropertiesObjectProperty {
|
|
1392
|
+
properties;
|
|
1393
|
+
static TYPE = 11;
|
|
1394
|
+
constructor(properties) {
|
|
1395
|
+
this.properties = properties;
|
|
1396
|
+
}
|
|
1397
|
+
toKeyValuePair() {
|
|
1398
|
+
return KeyValuePair.tryNewBytes(ImmutablePropertiesObjectProperty.TYPE, serializeKvpList(this.properties).toUint8Array());
|
|
1399
|
+
}
|
|
1400
|
+
static fromKeyValuePair(pair) {
|
|
1401
|
+
if (Number(pair.typeValue) !== ImmutablePropertiesObjectProperty.TYPE || !(pair.value instanceof Uint8Array)) return void 0;
|
|
1402
|
+
const properties = deserializeKvpListUntilEmpty(new FrozenByteBuffer(pair.value));
|
|
1403
|
+
properties.forEach(rejectMandatoryTrackProperty);
|
|
1404
|
+
if (properties.some((inner) => Number(inner.typeValue) === 11)) throw new ProtocolViolationError("ImmutablePropertiesObjectProperty.fromKeyValuePair", "ImmutableProperties must not contain nested ImmutableProperties (0x0B)");
|
|
1405
|
+
return new ImmutablePropertiesObjectProperty(properties);
|
|
1406
|
+
}
|
|
1407
|
+
};
|
|
1408
|
+
function rejectMandatoryTrackProperty(pair) {
|
|
1409
|
+
const { from, to } = PropertyRanges.MandatoryTrack;
|
|
1410
|
+
if (pair.typeValue >= from && pair.typeValue <= to && !isGrease(pair.typeValue)) throw new ProtocolViolationError("ObjectProperty.fromKeyValuePair", `Mandatory Track Property 0x${pair.typeValue.toString(16)} is not allowed on an Object`);
|
|
1411
|
+
}
|
|
1412
|
+
var PriorGroupIdGapProperty = class PriorGroupIdGapProperty {
|
|
1413
|
+
gap;
|
|
1414
|
+
static TYPE = 60;
|
|
1415
|
+
constructor(gap) {
|
|
1416
|
+
this.gap = gap;
|
|
1417
|
+
}
|
|
1418
|
+
toKeyValuePair() {
|
|
1419
|
+
return KeyValuePair.tryNewVarInt(PriorGroupIdGapProperty.TYPE, this.gap);
|
|
1420
|
+
}
|
|
1421
|
+
static fromKeyValuePair(pair) {
|
|
1422
|
+
if (Number(pair.typeValue) !== PriorGroupIdGapProperty.TYPE || typeof pair.value !== "bigint") return void 0;
|
|
1423
|
+
return new PriorGroupIdGapProperty(pair.value);
|
|
1424
|
+
}
|
|
1425
|
+
};
|
|
1426
|
+
var PriorObjectIdGapProperty = class PriorObjectIdGapProperty {
|
|
1427
|
+
gap;
|
|
1428
|
+
static TYPE = 62;
|
|
1429
|
+
constructor(gap) {
|
|
1430
|
+
this.gap = gap;
|
|
1431
|
+
}
|
|
1432
|
+
toKeyValuePair() {
|
|
1433
|
+
return KeyValuePair.tryNewVarInt(PriorObjectIdGapProperty.TYPE, this.gap);
|
|
1434
|
+
}
|
|
1435
|
+
static fromKeyValuePair(pair) {
|
|
1436
|
+
if (Number(pair.typeValue) !== PriorObjectIdGapProperty.TYPE || typeof pair.value !== "bigint") return void 0;
|
|
1437
|
+
return new PriorObjectIdGapProperty(pair.value);
|
|
1438
|
+
}
|
|
1439
|
+
};
|
|
1440
|
+
var UnknownObjectProperty = class {
|
|
1441
|
+
kvp;
|
|
1442
|
+
constructor(kvp) {
|
|
1443
|
+
this.kvp = kvp;
|
|
1444
|
+
}
|
|
1445
|
+
toKeyValuePair() {
|
|
1446
|
+
return this.kvp;
|
|
1447
|
+
}
|
|
1448
|
+
};
|
|
1449
|
+
let ObjectProperty;
|
|
1450
|
+
(function(_ObjectProperty) {
|
|
1451
|
+
function fromKeyValuePair(pair) {
|
|
1452
|
+
rejectMandatoryTrackProperty(pair);
|
|
1453
|
+
return ImmutablePropertiesObjectProperty.fromKeyValuePair(pair) ?? PriorGroupIdGapProperty.fromKeyValuePair(pair) ?? PriorObjectIdGapProperty.fromKeyValuePair(pair) ?? new UnknownObjectProperty(pair);
|
|
1454
|
+
}
|
|
1455
|
+
_ObjectProperty.fromKeyValuePair = fromKeyValuePair;
|
|
1456
|
+
function deserializeRaw(buf) {
|
|
1457
|
+
try {
|
|
1458
|
+
const pairs = deserializeKvpListUntilEmpty(buf);
|
|
1459
|
+
pairs.forEach(fromKeyValuePair);
|
|
1460
|
+
return pairs;
|
|
1461
|
+
} catch (e) {
|
|
1462
|
+
if (e instanceof NotEnoughBytesError) throw new ProtocolViolationError("ObjectProperty.deserializeRaw", e.message);
|
|
1463
|
+
throw e;
|
|
1464
|
+
}
|
|
1465
|
+
}
|
|
1466
|
+
_ObjectProperty.deserializeRaw = deserializeRaw;
|
|
1467
|
+
function toKeyValuePair(ext) {
|
|
1468
|
+
return ext.toKeyValuePair();
|
|
1469
|
+
}
|
|
1470
|
+
_ObjectProperty.toKeyValuePair = toKeyValuePair;
|
|
1471
|
+
function deserializeAll(buf) {
|
|
1472
|
+
return deserializeKvpListUntilEmpty(buf).map(fromKeyValuePair);
|
|
1473
|
+
}
|
|
1474
|
+
_ObjectProperty.deserializeAll = deserializeAll;
|
|
1475
|
+
function serializeInto(exts, payload) {
|
|
1476
|
+
payload.putBytes(serializeKvpList(exts.map((ext) => ext.toKeyValuePair())).toUint8Array());
|
|
1477
|
+
}
|
|
1478
|
+
_ObjectProperty.serializeInto = serializeInto;
|
|
1479
|
+
function isImmutableProperties(ext) {
|
|
1480
|
+
return ext instanceof ImmutablePropertiesObjectProperty;
|
|
1481
|
+
}
|
|
1482
|
+
_ObjectProperty.isImmutableProperties = isImmutableProperties;
|
|
1483
|
+
function isPriorGroupIdGap(ext) {
|
|
1484
|
+
return ext instanceof PriorGroupIdGapProperty;
|
|
1485
|
+
}
|
|
1486
|
+
_ObjectProperty.isPriorGroupIdGap = isPriorGroupIdGap;
|
|
1487
|
+
function isPriorObjectIdGap(ext) {
|
|
1488
|
+
return ext instanceof PriorObjectIdGapProperty;
|
|
1489
|
+
}
|
|
1490
|
+
_ObjectProperty.isPriorObjectIdGap = isPriorObjectIdGap;
|
|
1491
|
+
function isUnknown(ext) {
|
|
1492
|
+
return ext instanceof UnknownObjectProperty;
|
|
1493
|
+
}
|
|
1494
|
+
_ObjectProperty.isUnknown = isUnknown;
|
|
1495
|
+
})(ObjectProperty || (ObjectProperty = {}));
|
|
1496
|
+
// src/model/data/datagram.ts
|
|
1244
1497
|
/**
|
|
1245
1498
|
* Copyright 2026 The MOQtail Authors
|
|
1246
1499
|
*
|
|
@@ -1340,7 +1593,10 @@ var Datagram = class Datagram {
|
|
|
1340
1593
|
if (ObjectDatagramType.hasDefaultPriority(msgType)) publisherPriority = null;
|
|
1341
1594
|
else publisherPriority = buf.getU8();
|
|
1342
1595
|
let properties = null;
|
|
1343
|
-
if (ObjectDatagramType.hasProperties(msgType))
|
|
1596
|
+
if (ObjectDatagramType.hasProperties(msgType)) {
|
|
1597
|
+
const headerBytes = new FrozenByteBuffer(buf.getLengthPrefixedBytes());
|
|
1598
|
+
properties = ObjectProperty.deserializeRaw(headerBytes);
|
|
1599
|
+
}
|
|
1344
1600
|
let payload = null;
|
|
1345
1601
|
let objectStatus = null;
|
|
1346
1602
|
if (ObjectDatagramType.isStatus(msgType)) objectStatus = ObjectStatus.tryFrom(buf.getVI());
|
|
@@ -1349,8 +1605,7 @@ var Datagram = class Datagram {
|
|
|
1349
1605
|
return new Datagram(msgType, trackAlias, new Location(groupId, objectId), publisherPriority, properties, payload, objectStatus, endOfGroup);
|
|
1350
1606
|
}
|
|
1351
1607
|
};
|
|
1352
|
-
|
|
1353
|
-
//#region src/model/data/fetch_header.ts
|
|
1608
|
+
// src/model/data/fetch_header.ts
|
|
1354
1609
|
/**
|
|
1355
1610
|
* Copyright 2025 The MOQtail Authors
|
|
1356
1611
|
*
|
|
@@ -1386,8 +1641,7 @@ var FetchHeader = class FetchHeader {
|
|
|
1386
1641
|
return new FetchHeader(type, requestId);
|
|
1387
1642
|
}
|
|
1388
1643
|
};
|
|
1389
|
-
|
|
1390
|
-
//#region src/model/control/constant.ts
|
|
1644
|
+
// src/model/control/constant.ts
|
|
1391
1645
|
/**
|
|
1392
1646
|
* Copyright 2025 The MOQtail Authors
|
|
1393
1647
|
*
|
|
@@ -1682,8 +1936,7 @@ let RequestErrorCode = /* @__PURE__ */ function(RequestErrorCode) {
|
|
|
1682
1936
|
}
|
|
1683
1937
|
_RequestErrorCode.fromWire = fromWire;
|
|
1684
1938
|
})(RequestErrorCode || (RequestErrorCode = {}));
|
|
1685
|
-
|
|
1686
|
-
//#region src/model/data/fetch_object.ts
|
|
1939
|
+
// src/model/data/fetch_object.ts
|
|
1687
1940
|
/**
|
|
1688
1941
|
* Copyright 2025 The MOQtail Authors
|
|
1689
1942
|
*
|
|
@@ -1908,7 +2161,8 @@ var FetchObject = class FetchObject {
|
|
|
1908
2161
|
let properties = null;
|
|
1909
2162
|
if (hasProperties) {
|
|
1910
2163
|
const extLen = buf.getNumberVI();
|
|
1911
|
-
|
|
2164
|
+
const headerBytes = new FrozenByteBuffer(buf.getBytes(extLen));
|
|
2165
|
+
properties = ObjectProperty.deserializeRaw(headerBytes);
|
|
1912
2166
|
}
|
|
1913
2167
|
const payloadLen = buf.getNumberVI();
|
|
1914
2168
|
const payload = buf.getBytes(payloadLen);
|
|
@@ -1917,8 +2171,7 @@ var FetchObject = class FetchObject {
|
|
|
1917
2171
|
return FetchObject.newObject(groupId, resolvedSubgroupId, objectId, publisherPriority, forwardingPreference, properties, payload);
|
|
1918
2172
|
}
|
|
1919
2173
|
};
|
|
1920
|
-
|
|
1921
|
-
//#region src/model/data/full_track_name.ts
|
|
2174
|
+
// src/model/data/full_track_name.ts
|
|
1922
2175
|
/**
|
|
1923
2176
|
* Copyright 2025 The MOQtail Authors
|
|
1924
2177
|
*
|
|
@@ -2019,103 +2272,7 @@ var FullTrackName = class FullTrackName {
|
|
|
2019
2272
|
return new FullTrackName(namespace, name);
|
|
2020
2273
|
}
|
|
2021
2274
|
};
|
|
2022
|
-
|
|
2023
|
-
//#region src/model/property/constant.ts
|
|
2024
|
-
/**
|
|
2025
|
-
* Copyright 2025 The MOQtail Authors
|
|
2026
|
-
*
|
|
2027
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
2028
|
-
* you may not use this file except in compliance with the License.
|
|
2029
|
-
* You may obtain a copy of the License at
|
|
2030
|
-
*
|
|
2031
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
2032
|
-
*
|
|
2033
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
2034
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
2035
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
2036
|
-
* See the License for the specific language governing permissions and
|
|
2037
|
-
* limitations under the License.
|
|
2038
|
-
*/
|
|
2039
|
-
let LOCPropertyId = /* @__PURE__ */ function(LOCPropertyId) {
|
|
2040
|
-
LOCPropertyId[LOCPropertyId["Timescale"] = 8] = "Timescale";
|
|
2041
|
-
LOCPropertyId[LOCPropertyId["VideoFrameMarking"] = 9] = "VideoFrameMarking";
|
|
2042
|
-
LOCPropertyId[LOCPropertyId["AudioLevel"] = 12] = "AudioLevel";
|
|
2043
|
-
LOCPropertyId[LOCPropertyId["VideoConfig"] = 13] = "VideoConfig";
|
|
2044
|
-
LOCPropertyId[LOCPropertyId["AudioConfig"] = 15] = "AudioConfig";
|
|
2045
|
-
LOCPropertyId[LOCPropertyId["Timestamp"] = 16] = "Timestamp";
|
|
2046
|
-
return LOCPropertyId;
|
|
2047
|
-
}({});
|
|
2048
|
-
let TrackPropertyType = /* @__PURE__ */ function(TrackPropertyType) {
|
|
2049
|
-
TrackPropertyType[TrackPropertyType["ObjectDeliveryTimeout"] = 2] = "ObjectDeliveryTimeout";
|
|
2050
|
-
TrackPropertyType[TrackPropertyType["MaxCacheDuration"] = 4] = "MaxCacheDuration";
|
|
2051
|
-
TrackPropertyType[TrackPropertyType["SubgroupDeliveryTimeout"] = 6] = "SubgroupDeliveryTimeout";
|
|
2052
|
-
TrackPropertyType[TrackPropertyType["ImmutableProperties"] = 11] = "ImmutableProperties";
|
|
2053
|
-
TrackPropertyType[TrackPropertyType["DefaultPublisherPriority"] = 14] = "DefaultPublisherPriority";
|
|
2054
|
-
TrackPropertyType[TrackPropertyType["DefaultPublisherGroupOrder"] = 34] = "DefaultPublisherGroupOrder";
|
|
2055
|
-
TrackPropertyType[TrackPropertyType["DynamicGroups"] = 48] = "DynamicGroups";
|
|
2056
|
-
TrackPropertyType[TrackPropertyType["PriorGroupIdGap"] = 60] = "PriorGroupIdGap";
|
|
2057
|
-
TrackPropertyType[TrackPropertyType["PriorObjectIdGap"] = 62] = "PriorObjectIdGap";
|
|
2058
|
-
return TrackPropertyType;
|
|
2059
|
-
}({});
|
|
2060
|
-
function locPropertyIdFromNumber(value) {
|
|
2061
|
-
switch (value) {
|
|
2062
|
-
case 8: return 8;
|
|
2063
|
-
case 9: return 9;
|
|
2064
|
-
case 12: return 12;
|
|
2065
|
-
case 13: return 13;
|
|
2066
|
-
case 15: return 15;
|
|
2067
|
-
case 16: return 16;
|
|
2068
|
-
default: throw new InvalidTypeError("locPropertyIdFromNumber", `Invalid LOC property id: ${value}`);
|
|
2069
|
-
}
|
|
2070
|
-
}
|
|
2071
|
-
/**
|
|
2072
|
-
* @public
|
|
2073
|
-
* Registration-policy ranges for the Property Type space.
|
|
2074
|
-
*
|
|
2075
|
-
*/
|
|
2076
|
-
const PropertyRanges = {
|
|
2077
|
-
/** Standards Action or IESG Approval (1-byte encoding). */
|
|
2078
|
-
StandardsAction: {
|
|
2079
|
-
from: 0n,
|
|
2080
|
-
to: 119n
|
|
2081
|
-
},
|
|
2082
|
-
/** Application-specific use, no registration permitted (1-byte encoding). */
|
|
2083
|
-
AppSpecific1Byte: {
|
|
2084
|
-
from: 120n,
|
|
2085
|
-
to: 127n
|
|
2086
|
-
},
|
|
2087
|
-
/** Specification Required (2-byte encoding). */
|
|
2088
|
-
SpecRequired: {
|
|
2089
|
-
from: 128n,
|
|
2090
|
-
to: 14335n
|
|
2091
|
-
},
|
|
2092
|
-
/** Application-specific use, no registration permitted (2-byte encoding). */
|
|
2093
|
-
AppSpecific2Byte: {
|
|
2094
|
-
from: 14336n,
|
|
2095
|
-
to: 16383n
|
|
2096
|
-
},
|
|
2097
|
-
/** Mandatory Track Properties; Track scope only. */
|
|
2098
|
-
MandatoryTrack: {
|
|
2099
|
-
from: 16384n,
|
|
2100
|
-
to: 32767n
|
|
2101
|
-
},
|
|
2102
|
-
/** First Come First Served begins here (open-ended). */
|
|
2103
|
-
Fcfs: { from: 32768n }
|
|
2104
|
-
};
|
|
2105
|
-
function inRange(range, typeValue) {
|
|
2106
|
-
return typeValue >= range.from && (range.to === void 0 || typeValue <= range.to);
|
|
2107
|
-
}
|
|
2108
|
-
/**
|
|
2109
|
-
* @public
|
|
2110
|
-
* True if a Property Type is reserved for application-specific use (either encoding-width
|
|
2111
|
-
* range), for which no IANA registration is permitted.
|
|
2112
|
-
*/
|
|
2113
|
-
function isApplicationSpecificProperty(typeValue) {
|
|
2114
|
-
const v = BigInt(typeValue);
|
|
2115
|
-
return inRange(PropertyRanges.AppSpecific1Byte, v) || inRange(PropertyRanges.AppSpecific2Byte, v);
|
|
2116
|
-
}
|
|
2117
|
-
//#endregion
|
|
2118
|
-
//#region src/model/property/timestamp.ts
|
|
2275
|
+
// src/model/property/timestamp.ts
|
|
2119
2276
|
/**
|
|
2120
2277
|
* Copyright 2025 The MOQtail Authors
|
|
2121
2278
|
*
|
|
@@ -2144,8 +2301,7 @@ var Timestamp = class Timestamp {
|
|
|
2144
2301
|
if (Number(pair.typeValue) === Timestamp.TYPE && typeof pair.value === "bigint") return new Timestamp(pair.value);
|
|
2145
2302
|
}
|
|
2146
2303
|
};
|
|
2147
|
-
|
|
2148
|
-
//#region src/model/property/timescale.ts
|
|
2304
|
+
// src/model/property/timescale.ts
|
|
2149
2305
|
/**
|
|
2150
2306
|
* Copyright 2026 The MOQtail Authors
|
|
2151
2307
|
*
|
|
@@ -2174,8 +2330,7 @@ var Timescale = class Timescale {
|
|
|
2174
2330
|
if (Number(pair.typeValue) === Timescale.TYPE && typeof pair.value === "bigint") return new Timescale(pair.value);
|
|
2175
2331
|
}
|
|
2176
2332
|
};
|
|
2177
|
-
|
|
2178
|
-
//#region src/model/property/video_frame_marking.ts
|
|
2333
|
+
// src/model/property/video_frame_marking.ts
|
|
2179
2334
|
/**
|
|
2180
2335
|
* Copyright 2025 The MOQtail Authors
|
|
2181
2336
|
*
|
|
@@ -2211,8 +2366,7 @@ var VideoFrameMarking = class VideoFrameMarking {
|
|
|
2211
2366
|
if (Number(pair.typeValue) === VideoFrameMarking.TYPE && pair.value instanceof Uint8Array) return new VideoFrameMarking(pair.value);
|
|
2212
2367
|
}
|
|
2213
2368
|
};
|
|
2214
|
-
|
|
2215
|
-
//#region src/model/property/audio_level.ts
|
|
2369
|
+
// src/model/property/audio_level.ts
|
|
2216
2370
|
/**
|
|
2217
2371
|
* Copyright 2025 The MOQtail Authors
|
|
2218
2372
|
*
|
|
@@ -2241,8 +2395,7 @@ var AudioLevel = class AudioLevel {
|
|
|
2241
2395
|
if (Number(pair.typeValue) === AudioLevel.TYPE && typeof pair.value === "bigint") return new AudioLevel(pair.value);
|
|
2242
2396
|
}
|
|
2243
2397
|
};
|
|
2244
|
-
|
|
2245
|
-
//#region src/model/property/video_config.ts
|
|
2398
|
+
// src/model/property/video_config.ts
|
|
2246
2399
|
/**
|
|
2247
2400
|
* Copyright 2025 The MOQtail Authors
|
|
2248
2401
|
*
|
|
@@ -2271,8 +2424,7 @@ var VideoConfig = class VideoConfig {
|
|
|
2271
2424
|
if (Number(pair.typeValue) === VideoConfig.TYPE && pair.value instanceof Uint8Array) return new VideoConfig(pair.value);
|
|
2272
2425
|
}
|
|
2273
2426
|
};
|
|
2274
|
-
|
|
2275
|
-
//#region src/model/property/audio_config.ts
|
|
2427
|
+
// src/model/property/audio_config.ts
|
|
2276
2428
|
/**
|
|
2277
2429
|
* Copyright 2026 The MOQtail Authors
|
|
2278
2430
|
*
|
|
@@ -2301,8 +2453,7 @@ var AudioConfig = class AudioConfig {
|
|
|
2301
2453
|
if (Number(pair.typeValue) === AudioConfig.TYPE && pair.value instanceof Uint8Array) return new AudioConfig(pair.value);
|
|
2302
2454
|
}
|
|
2303
2455
|
};
|
|
2304
|
-
|
|
2305
|
-
//#region src/model/property/loc.ts
|
|
2456
|
+
// src/model/property/loc.ts
|
|
2306
2457
|
let LOCProperty;
|
|
2307
2458
|
(function(_LOCProperty) {
|
|
2308
2459
|
function fromKeyValuePair(pair) {
|
|
@@ -2381,55 +2532,7 @@ var LOCProperties = class {
|
|
|
2381
2532
|
return result;
|
|
2382
2533
|
}
|
|
2383
2534
|
};
|
|
2384
|
-
|
|
2385
|
-
//#region src/model/common/grease.ts
|
|
2386
|
-
/**
|
|
2387
|
-
* Copyright 2026 The MOQtail Authors
|
|
2388
|
-
*
|
|
2389
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
2390
|
-
* you may not use this file except in compliance with the License.
|
|
2391
|
-
* You may obtain a copy of the License at
|
|
2392
|
-
*
|
|
2393
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
2394
|
-
*
|
|
2395
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
2396
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
2397
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
2398
|
-
* See the License for the specific language governing permissions and
|
|
2399
|
-
* limitations under the License.
|
|
2400
|
-
*/
|
|
2401
|
-
/**
|
|
2402
|
-
* GREASE reservations (§14). Values matching `0x7f * N + 0x9D` are reserved across
|
|
2403
|
-
* several registries (Setup Options, Properties, error codes) so peers can emit them
|
|
2404
|
-
* to exercise unknown-value handling. Receivers treat them like any other unknown
|
|
2405
|
-
* value: ignore, never fatal.
|
|
2406
|
-
*/
|
|
2407
|
-
/** Step between successive GREASE values. */
|
|
2408
|
-
const GREASE_STEP = 127n;
|
|
2409
|
-
/** The smallest GREASE value (N = 0). */
|
|
2410
|
-
const GREASE_BASE = 157n;
|
|
2411
|
-
/** The largest GREASE value that still fits a varint, i.e. `0x3fffffffffffffde`. */
|
|
2412
|
-
const GREASE_MAX = 4611686018427387870n;
|
|
2413
|
-
/**
|
|
2414
|
-
* @public
|
|
2415
|
-
* True if `value` is a reserved GREASE value, i.e. `0x7f * N + 0x9D` for some
|
|
2416
|
-
* non-negative `N`.
|
|
2417
|
-
*/
|
|
2418
|
-
function isGrease(value) {
|
|
2419
|
-
const v = BigInt(value);
|
|
2420
|
-
return v >= 157n && (v - 157n) % 127n === 0n;
|
|
2421
|
-
}
|
|
2422
|
-
/**
|
|
2423
|
-
* @public
|
|
2424
|
-
* The `N`-th GREASE value, `0x7f * N + 0x9D`, or undefined if it would exceed what a
|
|
2425
|
-
* varint can carry (the pattern is capped at `0x3fffffffffffffde`).
|
|
2426
|
-
*/
|
|
2427
|
-
function greaseValue(n) {
|
|
2428
|
-
const value = GREASE_STEP * BigInt(n) + GREASE_BASE;
|
|
2429
|
-
return value > GREASE_MAX ? void 0 : value;
|
|
2430
|
-
}
|
|
2431
|
-
//#endregion
|
|
2432
|
-
//#region src/model/property/track_property.ts
|
|
2535
|
+
// src/model/property/track_property.ts
|
|
2433
2536
|
/**
|
|
2434
2537
|
* Copyright 2026 The MOQtail Authors
|
|
2435
2538
|
*
|
|
@@ -2609,8 +2712,7 @@ let TrackProperty;
|
|
|
2609
2712
|
}
|
|
2610
2713
|
_TrackProperty.isUnknown = isUnknown;
|
|
2611
2714
|
})(TrackProperty || (TrackProperty = {}));
|
|
2612
|
-
|
|
2613
|
-
//#region src/model/property/object_property.ts
|
|
2715
|
+
// src/model/property/find.ts
|
|
2614
2716
|
/**
|
|
2615
2717
|
* Copyright 2026 The MOQtail Authors
|
|
2616
2718
|
*
|
|
@@ -2626,96 +2728,25 @@ let TrackProperty;
|
|
|
2626
2728
|
* See the License for the specific language governing permissions and
|
|
2627
2729
|
* limitations under the License.
|
|
2628
2730
|
*/
|
|
2629
|
-
|
|
2630
|
-
|
|
2631
|
-
|
|
2632
|
-
|
|
2633
|
-
|
|
2634
|
-
|
|
2635
|
-
|
|
2636
|
-
|
|
2637
|
-
|
|
2638
|
-
|
|
2639
|
-
|
|
2640
|
-
|
|
2641
|
-
|
|
2642
|
-
|
|
2643
|
-
|
|
2644
|
-
|
|
2645
|
-
var PriorGroupIdGapProperty = class PriorGroupIdGapProperty {
|
|
2646
|
-
gap;
|
|
2647
|
-
static TYPE = 60;
|
|
2648
|
-
constructor(gap) {
|
|
2649
|
-
this.gap = gap;
|
|
2650
|
-
}
|
|
2651
|
-
toKeyValuePair() {
|
|
2652
|
-
return KeyValuePair.tryNewVarInt(PriorGroupIdGapProperty.TYPE, this.gap);
|
|
2653
|
-
}
|
|
2654
|
-
static fromKeyValuePair(pair) {
|
|
2655
|
-
if (Number(pair.typeValue) !== PriorGroupIdGapProperty.TYPE || typeof pair.value !== "bigint") return void 0;
|
|
2656
|
-
return new PriorGroupIdGapProperty(pair.value);
|
|
2657
|
-
}
|
|
2658
|
-
};
|
|
2659
|
-
var PriorObjectIdGapProperty = class PriorObjectIdGapProperty {
|
|
2660
|
-
gap;
|
|
2661
|
-
static TYPE = 62;
|
|
2662
|
-
constructor(gap) {
|
|
2663
|
-
this.gap = gap;
|
|
2664
|
-
}
|
|
2665
|
-
toKeyValuePair() {
|
|
2666
|
-
return KeyValuePair.tryNewVarInt(PriorObjectIdGapProperty.TYPE, this.gap);
|
|
2667
|
-
}
|
|
2668
|
-
static fromKeyValuePair(pair) {
|
|
2669
|
-
if (Number(pair.typeValue) !== PriorObjectIdGapProperty.TYPE || typeof pair.value !== "bigint") return void 0;
|
|
2670
|
-
return new PriorObjectIdGapProperty(pair.value);
|
|
2671
|
-
}
|
|
2672
|
-
};
|
|
2673
|
-
var UnknownObjectProperty = class {
|
|
2674
|
-
kvp;
|
|
2675
|
-
constructor(kvp) {
|
|
2676
|
-
this.kvp = kvp;
|
|
2677
|
-
}
|
|
2678
|
-
toKeyValuePair() {
|
|
2679
|
-
return this.kvp;
|
|
2680
|
-
}
|
|
2681
|
-
};
|
|
2682
|
-
let ObjectProperty;
|
|
2683
|
-
(function(_ObjectProperty) {
|
|
2684
|
-
function fromKeyValuePair(pair) {
|
|
2685
|
-
return ImmutablePropertiesObjectProperty.fromKeyValuePair(pair) ?? PriorGroupIdGapProperty.fromKeyValuePair(pair) ?? PriorObjectIdGapProperty.fromKeyValuePair(pair) ?? new UnknownObjectProperty(pair);
|
|
2686
|
-
}
|
|
2687
|
-
_ObjectProperty.fromKeyValuePair = fromKeyValuePair;
|
|
2688
|
-
function toKeyValuePair(ext) {
|
|
2689
|
-
return ext.toKeyValuePair();
|
|
2690
|
-
}
|
|
2691
|
-
_ObjectProperty.toKeyValuePair = toKeyValuePair;
|
|
2692
|
-
function deserializeAll(buf) {
|
|
2693
|
-
return deserializeKvpListUntilEmpty(buf).map(fromKeyValuePair);
|
|
2694
|
-
}
|
|
2695
|
-
_ObjectProperty.deserializeAll = deserializeAll;
|
|
2696
|
-
function serializeInto(exts, payload) {
|
|
2697
|
-
payload.putBytes(serializeKvpList(exts.map((ext) => ext.toKeyValuePair())).toUint8Array());
|
|
2698
|
-
}
|
|
2699
|
-
_ObjectProperty.serializeInto = serializeInto;
|
|
2700
|
-
function isImmutableProperties(ext) {
|
|
2701
|
-
return ext instanceof ImmutablePropertiesObjectProperty;
|
|
2702
|
-
}
|
|
2703
|
-
_ObjectProperty.isImmutableProperties = isImmutableProperties;
|
|
2704
|
-
function isPriorGroupIdGap(ext) {
|
|
2705
|
-
return ext instanceof PriorGroupIdGapProperty;
|
|
2706
|
-
}
|
|
2707
|
-
_ObjectProperty.isPriorGroupIdGap = isPriorGroupIdGap;
|
|
2708
|
-
function isPriorObjectIdGap(ext) {
|
|
2709
|
-
return ext instanceof PriorObjectIdGapProperty;
|
|
2710
|
-
}
|
|
2711
|
-
_ObjectProperty.isPriorObjectIdGap = isPriorObjectIdGap;
|
|
2712
|
-
function isUnknown(ext) {
|
|
2713
|
-
return ext instanceof UnknownObjectProperty;
|
|
2731
|
+
/**
|
|
2732
|
+
* @public
|
|
2733
|
+
* Finds the first property of `reader`'s type in a track or object property list and
|
|
2734
|
+
* returns it typed, or `undefined`. Unknown properties keep their raw key-value pair, so
|
|
2735
|
+
* a type the model doesn't know is still found.
|
|
2736
|
+
*
|
|
2737
|
+
* @example
|
|
2738
|
+
* ```ts
|
|
2739
|
+
* const timeout = findProperty(subscribeOk.trackProperties, ObjectDeliveryTimeoutProperty)
|
|
2740
|
+
* ```
|
|
2741
|
+
*/
|
|
2742
|
+
function findProperty(properties, reader) {
|
|
2743
|
+
const type = BigInt(reader.TYPE);
|
|
2744
|
+
for (const property of properties ?? []) {
|
|
2745
|
+
const pair = property instanceof KeyValuePair ? property : property.toKeyValuePair();
|
|
2746
|
+
if (pair.typeValue === type) return reader.fromKeyValuePair(pair);
|
|
2714
2747
|
}
|
|
2715
|
-
|
|
2716
|
-
|
|
2717
|
-
//#endregion
|
|
2718
|
-
//#region src/model/data/subgroup_object.ts
|
|
2748
|
+
}
|
|
2749
|
+
// src/model/data/subgroup_object.ts
|
|
2719
2750
|
/**
|
|
2720
2751
|
* Copyright 2025 The MOQtail Authors
|
|
2721
2752
|
*
|
|
@@ -2770,7 +2801,8 @@ var SubgroupObject = class SubgroupObject {
|
|
|
2770
2801
|
let properties = null;
|
|
2771
2802
|
if (hasProperties) {
|
|
2772
2803
|
const extLen = buf.getNumberVI();
|
|
2773
|
-
|
|
2804
|
+
const headerBytes = new FrozenByteBuffer(buf.getBytes(extLen));
|
|
2805
|
+
properties = ObjectProperty.deserializeRaw(headerBytes);
|
|
2774
2806
|
}
|
|
2775
2807
|
const payloadLen = buf.getNumberVI();
|
|
2776
2808
|
let objectStatus = null;
|
|
@@ -2780,8 +2812,7 @@ var SubgroupObject = class SubgroupObject {
|
|
|
2780
2812
|
return new SubgroupObject(objectId, normalizeProperties(properties), objectStatus, payload);
|
|
2781
2813
|
}
|
|
2782
2814
|
};
|
|
2783
|
-
|
|
2784
|
-
//#region src/model/data/object.ts
|
|
2815
|
+
// src/model/data/object.ts
|
|
2785
2816
|
var MoqtObject = class MoqtObject {
|
|
2786
2817
|
fullTrackName;
|
|
2787
2818
|
publisherPriority;
|
|
@@ -2901,8 +2932,7 @@ var MoqtObject = class MoqtObject {
|
|
|
2901
2932
|
else return SubgroupObject.newWithStatus(this.location.object, this.properties, this.objectStatus);
|
|
2902
2933
|
}
|
|
2903
2934
|
};
|
|
2904
|
-
|
|
2905
|
-
//#region src/model/data/subgroup_header.ts
|
|
2935
|
+
// src/model/data/subgroup_header.ts
|
|
2906
2936
|
/**
|
|
2907
2937
|
* Copyright 2025 The MOQtail Authors
|
|
2908
2938
|
*
|
|
@@ -2973,8 +3003,7 @@ var SubgroupHeader = class SubgroupHeader {
|
|
|
2973
3003
|
if (this.subgroupId === void 0 && SubgroupHeaderType.isSubgroupIdFirstObjectId(this.type)) this.subgroupId = firstObjectId;
|
|
2974
3004
|
}
|
|
2975
3005
|
};
|
|
2976
|
-
|
|
2977
|
-
//#region src/model/data/request_id.ts
|
|
3006
|
+
// src/model/data/request_id.ts
|
|
2978
3007
|
/**
|
|
2979
3008
|
* Copyright 2025 The MOQtail Authors
|
|
2980
3009
|
*
|
|
@@ -3092,8 +3121,7 @@ var RequestIdMap = class {
|
|
|
3092
3121
|
return this.nameToRequestId.has(name);
|
|
3093
3122
|
}
|
|
3094
3123
|
};
|
|
3095
|
-
|
|
3096
|
-
//#region src/model/data/header.ts
|
|
3124
|
+
// src/model/data/header.ts
|
|
3097
3125
|
/**
|
|
3098
3126
|
* Copyright 2025 The MOQtail Authors
|
|
3099
3127
|
*
|
|
@@ -3141,8 +3169,7 @@ let Header;
|
|
|
3141
3169
|
}
|
|
3142
3170
|
_Header.deserialize = deserialize;
|
|
3143
3171
|
})(Header || (Header = {}));
|
|
3144
|
-
|
|
3145
|
-
//#region src/model/common/byte_buffer.ts
|
|
3172
|
+
// src/model/common/byte_buffer.ts
|
|
3146
3173
|
/**
|
|
3147
3174
|
* Copyright 2025 The MOQtail Authors
|
|
3148
3175
|
*
|
|
@@ -3385,8 +3412,7 @@ var FrozenByteBuffer = class extends BaseByteBuffer {
|
|
|
3385
3412
|
return this.buf.length;
|
|
3386
3413
|
}
|
|
3387
3414
|
};
|
|
3388
|
-
|
|
3389
|
-
//#region src/model/control/publish_skipped.ts
|
|
3415
|
+
// src/model/control/publish_skipped.ts
|
|
3390
3416
|
/**
|
|
3391
3417
|
* Copyright 2026 The MOQtail Authors
|
|
3392
3418
|
*
|
|
@@ -3438,8 +3464,7 @@ var PublishSkipped = class PublishSkipped {
|
|
|
3438
3464
|
return new PublishSkipped(trackNamespaceSuffix, trackName);
|
|
3439
3465
|
}
|
|
3440
3466
|
};
|
|
3441
|
-
|
|
3442
|
-
//#region src/model/parameter/constant.ts
|
|
3467
|
+
// src/model/parameter/constant.ts
|
|
3443
3468
|
/**
|
|
3444
3469
|
* Copyright 2026 The MOQtail Authors
|
|
3445
3470
|
*
|
|
@@ -3563,8 +3588,7 @@ function tokenAliasTypeFromNumber(value) {
|
|
|
3563
3588
|
default: throw new InvalidTypeError("tokenAliasTypeFromNumber", `Invalid token alias type: ${value}`);
|
|
3564
3589
|
}
|
|
3565
3590
|
}
|
|
3566
|
-
|
|
3567
|
-
//#region src/model/common/moqt_url.ts
|
|
3591
|
+
// src/model/common/moqt_url.ts
|
|
3568
3592
|
/**
|
|
3569
3593
|
* Copyright 2026 The MOQtail Authors
|
|
3570
3594
|
*
|
|
@@ -3580,6 +3604,8 @@ function tokenAliasTypeFromNumber(value) {
|
|
|
3580
3604
|
* See the License for the specific language governing permissions and
|
|
3581
3605
|
* limitations under the License.
|
|
3582
3606
|
*/
|
|
3607
|
+
/** URI schemes are case-insensitive (RFC 3986 §3.1, MSF 11.1). */
|
|
3608
|
+
const MOQT_SCHEME = /^moqt:\/\//i;
|
|
3583
3609
|
/**
|
|
3584
3610
|
* @public
|
|
3585
3611
|
* A parsed `moqt://authority/path[?query][#fragment]` URI.
|
|
@@ -3603,7 +3629,7 @@ var MoqtUrl = class MoqtUrl {
|
|
|
3603
3629
|
this.fragment = fragment;
|
|
3604
3630
|
}
|
|
3605
3631
|
static parse(input) {
|
|
3606
|
-
if (!
|
|
3632
|
+
if (!MOQT_SCHEME.test(input)) throw new ProtocolViolationError("MoqtUrl.parse", `URL must use the moqt:// scheme: ${input}`);
|
|
3607
3633
|
let rest = input.slice(7);
|
|
3608
3634
|
let fragment;
|
|
3609
3635
|
const hashIdx = rest.indexOf("#");
|
|
@@ -3659,7 +3685,7 @@ function parseFragment(fragment) {
|
|
|
3659
3685
|
*/
|
|
3660
3686
|
function resolveTransportUrl(url) {
|
|
3661
3687
|
const raw = typeof url === "string" ? url : url.toString();
|
|
3662
|
-
if (!
|
|
3688
|
+
if (!MOQT_SCHEME.test(raw)) return {
|
|
3663
3689
|
transportUrl: raw,
|
|
3664
3690
|
moqtUrl: void 0
|
|
3665
3691
|
};
|
|
@@ -3669,8 +3695,7 @@ function resolveTransportUrl(url) {
|
|
|
3669
3695
|
moqtUrl
|
|
3670
3696
|
};
|
|
3671
3697
|
}
|
|
3672
|
-
|
|
3673
|
-
//#region src/model/common/redirect.ts
|
|
3698
|
+
// src/model/common/redirect.ts
|
|
3674
3699
|
/**
|
|
3675
3700
|
* Copyright 2026 The MOQtail Authors
|
|
3676
3701
|
*
|
|
@@ -3721,8 +3746,7 @@ var Redirect = class Redirect {
|
|
|
3721
3746
|
return new Redirect(connectUri, trackNamespace, trackName);
|
|
3722
3747
|
}
|
|
3723
3748
|
};
|
|
3724
|
-
|
|
3725
|
-
//#region src/model/parameter/common/authorization_token.ts
|
|
3749
|
+
// src/model/parameter/common/authorization_token.ts
|
|
3726
3750
|
/**
|
|
3727
3751
|
* Copyright 2026 The MOQtail Authors
|
|
3728
3752
|
*
|
|
@@ -3789,7 +3813,6 @@ var AuthorizationToken = class AuthorizationToken {
|
|
|
3789
3813
|
case 3:
|
|
3790
3814
|
payload.putVI(this.variant.tokenType);
|
|
3791
3815
|
payload.putBytes(this.variant.tokenValue);
|
|
3792
|
-
break;
|
|
3793
3816
|
}
|
|
3794
3817
|
return KeyValuePair.tryNewBytes(AuthorizationToken.TYPE, payload.toUint8Array());
|
|
3795
3818
|
}
|
|
@@ -3835,8 +3858,7 @@ var AuthorizationToken = class AuthorizationToken {
|
|
|
3835
3858
|
}
|
|
3836
3859
|
}
|
|
3837
3860
|
};
|
|
3838
|
-
|
|
3839
|
-
//#region src/model/parameter/message/fill_timeout.ts
|
|
3861
|
+
// src/model/parameter/message/fill_timeout.ts
|
|
3840
3862
|
/**
|
|
3841
3863
|
* Copyright 2026 The MOQtail Authors
|
|
3842
3864
|
*
|
|
@@ -3870,8 +3892,7 @@ var FillTimeout = class FillTimeout {
|
|
|
3870
3892
|
return new FillTimeout(pair.value);
|
|
3871
3893
|
}
|
|
3872
3894
|
};
|
|
3873
|
-
|
|
3874
|
-
//#region src/model/parameter/message/object_delivery_timeout.ts
|
|
3895
|
+
// src/model/parameter/message/object_delivery_timeout.ts
|
|
3875
3896
|
/**
|
|
3876
3897
|
* Copyright 2026 The MOQtail Authors
|
|
3877
3898
|
*
|
|
@@ -3907,8 +3928,7 @@ var ObjectDeliveryTimeout = class ObjectDeliveryTimeout {
|
|
|
3907
3928
|
return new ObjectDeliveryTimeout(pair.value);
|
|
3908
3929
|
}
|
|
3909
3930
|
};
|
|
3910
|
-
|
|
3911
|
-
//#region src/model/parameter/message/rendezvous_timeout.ts
|
|
3931
|
+
// src/model/parameter/message/rendezvous_timeout.ts
|
|
3912
3932
|
/**
|
|
3913
3933
|
* Copyright 2026 The MOQtail Authors
|
|
3914
3934
|
*
|
|
@@ -3942,8 +3962,7 @@ var RendezvousTimeout = class RendezvousTimeout {
|
|
|
3942
3962
|
return new RendezvousTimeout(pair.value);
|
|
3943
3963
|
}
|
|
3944
3964
|
};
|
|
3945
|
-
|
|
3946
|
-
//#region src/model/parameter/message/subgroup_delivery_timeout.ts
|
|
3965
|
+
// src/model/parameter/message/subgroup_delivery_timeout.ts
|
|
3947
3966
|
/**
|
|
3948
3967
|
* Copyright 2026 The MOQtail Authors
|
|
3949
3968
|
*
|
|
@@ -3977,8 +3996,7 @@ var SubgroupDeliveryTimeout = class SubgroupDeliveryTimeout {
|
|
|
3977
3996
|
return new SubgroupDeliveryTimeout(pair.value);
|
|
3978
3997
|
}
|
|
3979
3998
|
};
|
|
3980
|
-
|
|
3981
|
-
//#region src/model/parameter/message/expires.ts
|
|
3999
|
+
// src/model/parameter/message/expires.ts
|
|
3982
4000
|
/**
|
|
3983
4001
|
* Copyright 2026 The MOQtail Authors
|
|
3984
4002
|
*
|
|
@@ -4013,8 +4031,7 @@ var Expires = class Expires {
|
|
|
4013
4031
|
return new Expires(pair.value);
|
|
4014
4032
|
}
|
|
4015
4033
|
};
|
|
4016
|
-
|
|
4017
|
-
//#region src/model/parameter/message/forward.ts
|
|
4034
|
+
// src/model/parameter/message/forward.ts
|
|
4018
4035
|
/**
|
|
4019
4036
|
* Copyright 2026 The MOQtail Authors
|
|
4020
4037
|
*
|
|
@@ -4051,8 +4068,7 @@ var Forward = class Forward {
|
|
|
4051
4068
|
return new Forward(pair.value === 1n);
|
|
4052
4069
|
}
|
|
4053
4070
|
};
|
|
4054
|
-
|
|
4055
|
-
//#region src/model/parameter/message/include_properties.ts
|
|
4071
|
+
// src/model/parameter/message/include_properties.ts
|
|
4056
4072
|
/**
|
|
4057
4073
|
* Copyright 2026 The MOQtail Authors
|
|
4058
4074
|
*
|
|
@@ -4090,8 +4106,7 @@ var IncludeProperties = class IncludeProperties {
|
|
|
4090
4106
|
return new IncludeProperties(pair.value === 1n);
|
|
4091
4107
|
}
|
|
4092
4108
|
};
|
|
4093
|
-
|
|
4094
|
-
//#region src/model/parameter/message/group_order_param.ts
|
|
4109
|
+
// src/model/parameter/message/group_order_param.ts
|
|
4095
4110
|
/**
|
|
4096
4111
|
* Copyright 2026 The MOQtail Authors
|
|
4097
4112
|
*
|
|
@@ -4128,8 +4143,7 @@ var GroupOrderParam = class GroupOrderParam {
|
|
|
4128
4143
|
return new GroupOrderParam(Number(pair.value));
|
|
4129
4144
|
}
|
|
4130
4145
|
};
|
|
4131
|
-
|
|
4132
|
-
//#region src/model/parameter/message/largest_object.ts
|
|
4146
|
+
// src/model/parameter/message/largest_object.ts
|
|
4133
4147
|
/**
|
|
4134
4148
|
* Copyright 2026 The MOQtail Authors
|
|
4135
4149
|
*
|
|
@@ -4170,8 +4184,7 @@ var LargestObject = class LargestObject {
|
|
|
4170
4184
|
return new LargestObject(location);
|
|
4171
4185
|
}
|
|
4172
4186
|
};
|
|
4173
|
-
|
|
4174
|
-
//#region src/model/parameter/message/new_group_request.ts
|
|
4187
|
+
// src/model/parameter/message/new_group_request.ts
|
|
4175
4188
|
/**
|
|
4176
4189
|
* Copyright 2026 The MOQtail Authors
|
|
4177
4190
|
*
|
|
@@ -4206,8 +4219,7 @@ var NewGroupRequest = class NewGroupRequest {
|
|
|
4206
4219
|
return new NewGroupRequest(pair.value);
|
|
4207
4220
|
}
|
|
4208
4221
|
};
|
|
4209
|
-
|
|
4210
|
-
//#region src/model/parameter/message/switching_set_assignment.ts
|
|
4222
|
+
// src/model/parameter/message/switching_set_assignment.ts
|
|
4211
4223
|
/**
|
|
4212
4224
|
* Copyright 2026 The MOQtail Authors
|
|
4213
4225
|
*
|
|
@@ -4274,8 +4286,7 @@ var SwitchingSetAssignment = class SwitchingSetAssignment {
|
|
|
4274
4286
|
return new SwitchingSetAssignment(switchingSetId, algorithmId, throughputThresholdKbps, setThroughputWeight, activateSwitching, setRank);
|
|
4275
4287
|
}
|
|
4276
4288
|
};
|
|
4277
|
-
|
|
4278
|
-
//#region src/model/parameter/message/subscriber_priority.ts
|
|
4289
|
+
// src/model/parameter/message/subscriber_priority.ts
|
|
4279
4290
|
/**
|
|
4280
4291
|
* Copyright 2026 The MOQtail Authors
|
|
4281
4292
|
*
|
|
@@ -4312,8 +4323,7 @@ var SubscriberPriority = class SubscriberPriority {
|
|
|
4312
4323
|
return new SubscriberPriority(Number(pair.value));
|
|
4313
4324
|
}
|
|
4314
4325
|
};
|
|
4315
|
-
|
|
4316
|
-
//#region src/model/parameter/message/location_filter.ts
|
|
4326
|
+
// src/model/parameter/message/location_filter.ts
|
|
4317
4327
|
/**
|
|
4318
4328
|
* Copyright 2026 The MOQtail Authors
|
|
4319
4329
|
*
|
|
@@ -4487,8 +4497,7 @@ var LocationFilter = class LocationFilter {
|
|
|
4487
4497
|
return filter;
|
|
4488
4498
|
}
|
|
4489
4499
|
};
|
|
4490
|
-
|
|
4491
|
-
//#region src/model/parameter/message/switch_from.ts
|
|
4500
|
+
// src/model/parameter/message/switch_from.ts
|
|
4492
4501
|
/**
|
|
4493
4502
|
* Copyright 2026 The MOQtail Authors
|
|
4494
4503
|
*
|
|
@@ -4539,8 +4548,7 @@ var SwitchFrom = class SwitchFrom {
|
|
|
4539
4548
|
return new SwitchFrom(requestId, Number(modeValue), (flags & 128) !== 0);
|
|
4540
4549
|
}
|
|
4541
4550
|
};
|
|
4542
|
-
|
|
4543
|
-
//#region src/model/parameter/message/fill_parameters.ts
|
|
4551
|
+
// src/model/parameter/message/fill_parameters.ts
|
|
4544
4552
|
/**
|
|
4545
4553
|
* Copyright 2026 The MOQtail Authors
|
|
4546
4554
|
*
|
|
@@ -4598,8 +4606,7 @@ var FillParameters = class FillParameters {
|
|
|
4598
4606
|
return new FillParameters(MessageParameters.fromKeyValuePairs(pairs));
|
|
4599
4607
|
}
|
|
4600
4608
|
};
|
|
4601
|
-
|
|
4602
|
-
//#region src/model/parameter/message/range_filter.ts
|
|
4609
|
+
// src/model/parameter/message/range_filter.ts
|
|
4603
4610
|
/**
|
|
4604
4611
|
* Copyright 2026 The MOQtail Authors
|
|
4605
4612
|
*
|
|
@@ -4791,8 +4798,7 @@ var RangeFilter = class RangeFilter {
|
|
|
4791
4798
|
return new RangeFilter(kind, setId, propertyType, deltas);
|
|
4792
4799
|
}
|
|
4793
4800
|
};
|
|
4794
|
-
|
|
4795
|
-
//#region src/model/parameter/message_parameter.ts
|
|
4801
|
+
// src/model/parameter/message_parameter.ts
|
|
4796
4802
|
/**
|
|
4797
4803
|
* Copyright 2026 The MOQtail Authors
|
|
4798
4804
|
*
|
|
@@ -4983,14 +4989,14 @@ function valueShapeOf(typeValue) {
|
|
|
4983
4989
|
case BigInt(53): return 1;
|
|
4984
4990
|
case BigInt(9): return 2;
|
|
4985
4991
|
case BigInt(33): return 3;
|
|
4992
|
+
case BigInt(52): return 4;
|
|
4986
4993
|
case BigInt(36):
|
|
4987
|
-
case BigInt(52):
|
|
4988
4994
|
case BigInt(37):
|
|
4989
4995
|
case BigInt(38):
|
|
4990
4996
|
case BigInt(39):
|
|
4991
4997
|
case BigInt(40):
|
|
4992
|
-
case BigInt(41): return
|
|
4993
|
-
default: return typeValue % 2n === 0n ? 0 :
|
|
4998
|
+
case BigInt(41): return 5;
|
|
4999
|
+
default: return typeValue % 2n === 0n ? 0 : 5;
|
|
4994
5000
|
}
|
|
4995
5001
|
}
|
|
4996
5002
|
/**
|
|
@@ -5010,14 +5016,13 @@ function serializeMessageParameterKvps(items) {
|
|
|
5010
5016
|
break;
|
|
5011
5017
|
case 2:
|
|
5012
5018
|
case 3:
|
|
5019
|
+
case 4:
|
|
5013
5020
|
if (isBytes(kvp)) buf.putBytes(kvp.value);
|
|
5014
5021
|
break;
|
|
5015
|
-
case
|
|
5022
|
+
case 5:
|
|
5016
5023
|
if (isBytes(kvp)) buf.putLengthPrefixedBytes(kvp.value);
|
|
5017
5024
|
break;
|
|
5018
|
-
case 0:
|
|
5019
|
-
if (isVarInt(kvp)) buf.putVI(kvp.value);
|
|
5020
|
-
break;
|
|
5025
|
+
case 0: if (isVarInt(kvp)) buf.putVI(kvp.value);
|
|
5021
5026
|
}
|
|
5022
5027
|
prevType = kvp.typeValue;
|
|
5023
5028
|
}
|
|
@@ -5052,11 +5057,12 @@ function readMessageParameterKvps(buf, more) {
|
|
|
5052
5057
|
items.push(KeyValuePair.newBytes(typeValue, LocationFilter.deserializeValue(buf).serializeValue()));
|
|
5053
5058
|
break;
|
|
5054
5059
|
case 4:
|
|
5055
|
-
items.push(KeyValuePair.
|
|
5060
|
+
items.push(KeyValuePair.newBytes(typeValue, Tuple.deserialize(buf).serialize().toUint8Array()));
|
|
5056
5061
|
break;
|
|
5057
|
-
case
|
|
5058
|
-
items.push(KeyValuePair.
|
|
5062
|
+
case 5:
|
|
5063
|
+
items.push(KeyValuePair.deserializeBytesValue(buf, typeValue));
|
|
5059
5064
|
break;
|
|
5065
|
+
case 0: items.push(KeyValuePair.tryNewVarInt(typeValue, buf.getVI()));
|
|
5060
5066
|
}
|
|
5061
5067
|
prevType = typeValue;
|
|
5062
5068
|
}
|
|
@@ -5077,8 +5083,7 @@ function applyMessageParameterUpdate(current, updates) {
|
|
|
5077
5083
|
const kept = current.filter((p) => !updated.has(typeOf(p)));
|
|
5078
5084
|
current.splice(0, current.length, ...kept, ...updates.filter((u) => !(u instanceof RangeFilter && u.isRemoval)));
|
|
5079
5085
|
}
|
|
5080
|
-
|
|
5081
|
-
//#region src/model/control/publish_namespace.ts
|
|
5086
|
+
// src/model/control/publish_namespace.ts
|
|
5082
5087
|
/**
|
|
5083
5088
|
* Copyright 2025 The MOQtail Authors
|
|
5084
5089
|
*
|
|
@@ -5162,8 +5167,7 @@ var PublishNamespace = class PublishNamespace {
|
|
|
5162
5167
|
return new PublishNamespace(requestId, trackNamespace, parameters);
|
|
5163
5168
|
}
|
|
5164
5169
|
};
|
|
5165
|
-
|
|
5166
|
-
//#region src/model/control/namespace.ts
|
|
5170
|
+
// src/model/control/namespace.ts
|
|
5167
5171
|
/**
|
|
5168
5172
|
* Copyright 2025 The MOQtail Authors
|
|
5169
5173
|
*
|
|
@@ -5208,8 +5212,7 @@ var Namespace = class Namespace {
|
|
|
5208
5212
|
return new Namespace(trackNamespaceSuffix);
|
|
5209
5213
|
}
|
|
5210
5214
|
};
|
|
5211
|
-
|
|
5212
|
-
//#region src/model/control/namespace_done.ts
|
|
5215
|
+
// src/model/control/namespace_done.ts
|
|
5213
5216
|
/**
|
|
5214
5217
|
* Copyright 2025 The MOQtail Authors
|
|
5215
5218
|
*
|
|
@@ -5254,8 +5257,7 @@ var NamespaceDone = class NamespaceDone {
|
|
|
5254
5257
|
return new NamespaceDone(trackNamespaceSuffix);
|
|
5255
5258
|
}
|
|
5256
5259
|
};
|
|
5257
|
-
|
|
5258
|
-
//#region src/model/control/setup.ts
|
|
5260
|
+
// src/model/control/setup.ts
|
|
5259
5261
|
/**
|
|
5260
5262
|
* Copyright 2026 The MOQtail Authors
|
|
5261
5263
|
*
|
|
@@ -5304,8 +5306,7 @@ var Setup = class Setup {
|
|
|
5304
5306
|
return new Setup(setupOptions);
|
|
5305
5307
|
}
|
|
5306
5308
|
};
|
|
5307
|
-
|
|
5308
|
-
//#region src/model/control/fetch.ts
|
|
5309
|
+
// src/model/control/fetch.ts
|
|
5309
5310
|
/**
|
|
5310
5311
|
* Copyright 2025 The MOQtail Authors
|
|
5311
5312
|
*
|
|
@@ -5362,8 +5363,7 @@ var Fetch = class Fetch {
|
|
|
5362
5363
|
return new Fetch(requestId, fullTrackName, parameters);
|
|
5363
5364
|
}
|
|
5364
5365
|
};
|
|
5365
|
-
|
|
5366
|
-
//#region src/model/control/fetch_ok.ts
|
|
5366
|
+
// src/model/control/fetch_ok.ts
|
|
5367
5367
|
/**
|
|
5368
5368
|
* Copyright 2025 The MOQtail Authors
|
|
5369
5369
|
*
|
|
@@ -5427,8 +5427,7 @@ var FetchOk = class FetchOk {
|
|
|
5427
5427
|
return new FetchOk(endOfTrack, endLocation, parameters, trackProperties);
|
|
5428
5428
|
}
|
|
5429
5429
|
};
|
|
5430
|
-
|
|
5431
|
-
//#region src/model/control/goaway.ts
|
|
5430
|
+
// src/model/control/goaway.ts
|
|
5432
5431
|
/**
|
|
5433
5432
|
* Copyright 2025 The MOQtail Authors
|
|
5434
5433
|
*
|
|
@@ -5503,8 +5502,7 @@ var GoAway = class GoAway {
|
|
|
5503
5502
|
return new GoAway(newSessionUri, timeout);
|
|
5504
5503
|
}
|
|
5505
5504
|
};
|
|
5506
|
-
|
|
5507
|
-
//#region src/model/control/subscribe.ts
|
|
5505
|
+
// src/model/control/subscribe.ts
|
|
5508
5506
|
/**
|
|
5509
5507
|
* Copyright 2025 The MOQtail Authors
|
|
5510
5508
|
*
|
|
@@ -5557,8 +5555,7 @@ var Subscribe = class Subscribe {
|
|
|
5557
5555
|
return new Subscribe(requestId, fullTrackName, parameters);
|
|
5558
5556
|
}
|
|
5559
5557
|
};
|
|
5560
|
-
|
|
5561
|
-
//#region src/model/control/publish_done.ts
|
|
5558
|
+
// src/model/control/publish_done.ts
|
|
5562
5559
|
/**
|
|
5563
5560
|
* Copyright 2025 The MOQtail Authors
|
|
5564
5561
|
*
|
|
@@ -5614,8 +5611,7 @@ var PublishDone = class PublishDone {
|
|
|
5614
5611
|
return new PublishDone(statusCode, streamCount, errorReason);
|
|
5615
5612
|
}
|
|
5616
5613
|
};
|
|
5617
|
-
|
|
5618
|
-
//#region src/model/control/publish.ts
|
|
5614
|
+
// src/model/control/publish.ts
|
|
5619
5615
|
/**
|
|
5620
5616
|
* Copyright 2025 The MOQtail Authors
|
|
5621
5617
|
*
|
|
@@ -5673,8 +5669,7 @@ var Publish = class Publish {
|
|
|
5673
5669
|
return new Publish(requestId, fullTrackName, trackAlias, parameters, trackProperties);
|
|
5674
5670
|
}
|
|
5675
5671
|
};
|
|
5676
|
-
|
|
5677
|
-
//#region src/model/control/subscribe_ok.ts
|
|
5672
|
+
// src/model/control/subscribe_ok.ts
|
|
5678
5673
|
/**
|
|
5679
5674
|
* Copyright 2025 The MOQtail Authors
|
|
5680
5675
|
*
|
|
@@ -5732,8 +5727,7 @@ var SubscribeOk = class SubscribeOk {
|
|
|
5732
5727
|
return new SubscribeOk(trackAlias, parameters, trackProperties);
|
|
5733
5728
|
}
|
|
5734
5729
|
};
|
|
5735
|
-
|
|
5736
|
-
//#region src/model/control/request_update.ts
|
|
5730
|
+
// src/model/control/request_update.ts
|
|
5737
5731
|
/**
|
|
5738
5732
|
* Copyright 2025 The MOQtail Authors
|
|
5739
5733
|
*
|
|
@@ -5797,8 +5791,7 @@ var RequestUpdate = class RequestUpdate {
|
|
|
5797
5791
|
return true;
|
|
5798
5792
|
}
|
|
5799
5793
|
};
|
|
5800
|
-
|
|
5801
|
-
//#region src/model/control/track_status.ts
|
|
5794
|
+
// src/model/control/track_status.ts
|
|
5802
5795
|
/**
|
|
5803
5796
|
* Copyright 2025 The MOQtail Authors
|
|
5804
5797
|
*
|
|
@@ -5867,8 +5860,7 @@ var TrackStatus = class TrackStatus {
|
|
|
5867
5860
|
return new TrackStatus(requestId, trackAlias, fullTrackName, subscriberPriority, groupOrder, forward, locationFilter, subscribeParameters);
|
|
5868
5861
|
}
|
|
5869
5862
|
};
|
|
5870
|
-
|
|
5871
|
-
//#region src/model/control/subscribe_namespace.ts
|
|
5863
|
+
// src/model/control/subscribe_namespace.ts
|
|
5872
5864
|
/**
|
|
5873
5865
|
* Copyright 2025 The MOQtail Authors
|
|
5874
5866
|
*
|
|
@@ -5918,8 +5910,7 @@ var SubscribeNamespace = class SubscribeNamespace {
|
|
|
5918
5910
|
return new SubscribeNamespace(requestId, trackNamespacePrefix, parameters);
|
|
5919
5911
|
}
|
|
5920
5912
|
};
|
|
5921
|
-
|
|
5922
|
-
//#region src/model/control/subscribe_tracks.ts
|
|
5913
|
+
// src/model/control/subscribe_tracks.ts
|
|
5923
5914
|
/**
|
|
5924
5915
|
* Copyright 2026 The MOQtail Authors
|
|
5925
5916
|
*
|
|
@@ -5976,8 +5967,7 @@ var SubscribeTracks = class SubscribeTracks {
|
|
|
5976
5967
|
return new SubscribeTracks(requestId, trackNamespacePrefix, parameters);
|
|
5977
5968
|
}
|
|
5978
5969
|
};
|
|
5979
|
-
|
|
5980
|
-
//#region src/model/control/request_ok.ts
|
|
5970
|
+
// src/model/control/request_ok.ts
|
|
5981
5971
|
/**
|
|
5982
5972
|
* Copyright 2026 The MOQtail Authors
|
|
5983
5973
|
*
|
|
@@ -6060,8 +6050,7 @@ var RequestOk = class RequestOk {
|
|
|
6060
6050
|
return new RequestOk(parameters, trackProperties);
|
|
6061
6051
|
}
|
|
6062
6052
|
};
|
|
6063
|
-
|
|
6064
|
-
//#region src/model/control/request_error.ts
|
|
6053
|
+
// src/model/control/request_error.ts
|
|
6065
6054
|
/**
|
|
6066
6055
|
* Copyright 2025 The MOQtail Authors
|
|
6067
6056
|
*
|
|
@@ -6123,8 +6112,7 @@ var RequestError = class RequestError {
|
|
|
6123
6112
|
return new RequestError(errorCode, retryInterval, reasonPhrase, redirect);
|
|
6124
6113
|
}
|
|
6125
6114
|
};
|
|
6126
|
-
|
|
6127
|
-
//#region src/model/control/control_message.ts
|
|
6115
|
+
// src/model/control/control_message.ts
|
|
6128
6116
|
/**
|
|
6129
6117
|
* Copyright 2025 The MOQtail Authors
|
|
6130
6118
|
*
|
|
@@ -6177,176 +6165,7 @@ let ControlMessage;
|
|
|
6177
6165
|
}
|
|
6178
6166
|
_ControlMessage.serialize = serialize;
|
|
6179
6167
|
})(ControlMessage || (ControlMessage = {}));
|
|
6180
|
-
|
|
6181
|
-
//#region src/model/catalog/cmsf.ts
|
|
6182
|
-
function isString(v) {
|
|
6183
|
-
return typeof v === "string";
|
|
6184
|
-
}
|
|
6185
|
-
function isNumber(v) {
|
|
6186
|
-
return typeof v === "number";
|
|
6187
|
-
}
|
|
6188
|
-
function isStringArray(v) {
|
|
6189
|
-
return Array.isArray(v) && v.every((item) => isString(item));
|
|
6190
|
-
}
|
|
6191
|
-
function isValidPackaging(v) {
|
|
6192
|
-
return v === "cmaf" || v === "chunk-per-object" || v === "timeline";
|
|
6193
|
-
}
|
|
6194
|
-
function isValidRole(v) {
|
|
6195
|
-
return v === "video" || v === "audio" || v === "timeline";
|
|
6196
|
-
}
|
|
6197
|
-
function isValidBase64(str) {
|
|
6198
|
-
try {
|
|
6199
|
-
return btoa(atob(str)) === str;
|
|
6200
|
-
} catch {
|
|
6201
|
-
return false;
|
|
6202
|
-
}
|
|
6203
|
-
}
|
|
6204
|
-
function validateTrack(track) {
|
|
6205
|
-
if (typeof track !== "object" || track === null) throw new Error("Track must be an object");
|
|
6206
|
-
const t = track;
|
|
6207
|
-
if (!isString(t["name"])) throw new Error("Track.name must be a string");
|
|
6208
|
-
if (!isValidPackaging(t["packaging"])) throw new Error("Track.packaging must be 'cmaf', 'chunk-per-object', or 'timeline'");
|
|
6209
|
-
if (!isValidRole(t["role"])) throw new Error("Track.role must be 'video', 'audio', or 'timeline'");
|
|
6210
|
-
const name = t["name"];
|
|
6211
|
-
const packaging = t["packaging"];
|
|
6212
|
-
const role = t["role"];
|
|
6213
|
-
let codec;
|
|
6214
|
-
if (t["codec"] !== void 0) {
|
|
6215
|
-
if (!isString(t["codec"])) throw new Error("Track.codec must be a string");
|
|
6216
|
-
codec = t["codec"];
|
|
6217
|
-
}
|
|
6218
|
-
let depends;
|
|
6219
|
-
if (t["depends"] !== void 0) {
|
|
6220
|
-
if (!isStringArray(t["depends"])) throw new Error("Track.depends must be an array of strings");
|
|
6221
|
-
depends = t["depends"];
|
|
6222
|
-
}
|
|
6223
|
-
let mimeType;
|
|
6224
|
-
if (t["mimeType"] !== void 0) {
|
|
6225
|
-
if (!isString(t["mimeType"])) throw new Error("Track.mimeType must be a string");
|
|
6226
|
-
mimeType = t["mimeType"];
|
|
6227
|
-
}
|
|
6228
|
-
let width;
|
|
6229
|
-
if (t["width"] !== void 0) {
|
|
6230
|
-
if (!isNumber(t["width"])) throw new Error("Track.width must be a number");
|
|
6231
|
-
width = t["width"];
|
|
6232
|
-
}
|
|
6233
|
-
let height;
|
|
6234
|
-
if (t["height"] !== void 0) {
|
|
6235
|
-
if (!isNumber(t["height"])) throw new Error("Track.height must be a number");
|
|
6236
|
-
height = t["height"];
|
|
6237
|
-
}
|
|
6238
|
-
let timescale;
|
|
6239
|
-
if (t["timescale"] !== void 0) {
|
|
6240
|
-
if (!isNumber(t["timescale"])) throw new Error("Track.timescale must be a number");
|
|
6241
|
-
timescale = t["timescale"];
|
|
6242
|
-
}
|
|
6243
|
-
let bitrate;
|
|
6244
|
-
if (t["bitrate"] !== void 0) {
|
|
6245
|
-
if (!isNumber(t["bitrate"])) throw new Error("Track.bitrate must be a number");
|
|
6246
|
-
bitrate = t["bitrate"];
|
|
6247
|
-
}
|
|
6248
|
-
let initData;
|
|
6249
|
-
if (t["initData"] !== void 0) {
|
|
6250
|
-
if (!isString(t["initData"])) throw new Error("Track.initData must be a string");
|
|
6251
|
-
if (!isValidBase64(t["initData"])) throw new Error("Track.initData must be a valid base64 string");
|
|
6252
|
-
initData = t["initData"];
|
|
6253
|
-
}
|
|
6254
|
-
if (packaging === "cmaf" && (!codec || codec.length === 0)) throw new Error("codec is required when packaging is 'cmaf'");
|
|
6255
|
-
if (packaging === "timeline" && mimeType !== "text/csv") throw new Error("mimeType must be 'text/csv' when packaging is 'timeline'");
|
|
6256
|
-
if (packaging === "timeline" && (!depends || depends.length === 0)) throw new Error("At least one dependee must be present when packaging is 'timeline'");
|
|
6257
|
-
const result = {
|
|
6258
|
-
name,
|
|
6259
|
-
packaging,
|
|
6260
|
-
role
|
|
6261
|
-
};
|
|
6262
|
-
if (codec !== void 0) result.codec = codec;
|
|
6263
|
-
if (depends !== void 0) result.depends = depends;
|
|
6264
|
-
if (mimeType !== void 0) result.mimeType = mimeType;
|
|
6265
|
-
if (width !== void 0) result.width = width;
|
|
6266
|
-
if (height !== void 0) result.height = height;
|
|
6267
|
-
if (timescale !== void 0) result.timescale = timescale;
|
|
6268
|
-
if (bitrate !== void 0) result.bitrate = bitrate;
|
|
6269
|
-
if (initData !== void 0) result.initData = initData;
|
|
6270
|
-
return result;
|
|
6271
|
-
}
|
|
6272
|
-
function validateCMSF(obj) {
|
|
6273
|
-
if (typeof obj !== "object" || obj === null) throw new Error("CMSF must be an object");
|
|
6274
|
-
const o = obj;
|
|
6275
|
-
if (!isString(o["version"])) throw new Error("CMSF.version must be a string");
|
|
6276
|
-
if (!Array.isArray(o["tracks"])) throw new Error("CMSF.tracks must be an array");
|
|
6277
|
-
return {
|
|
6278
|
-
version: o["version"],
|
|
6279
|
-
tracks: o["tracks"].map(validateTrack)
|
|
6280
|
-
};
|
|
6281
|
-
}
|
|
6282
|
-
var CMSFCatalog = class CMSFCatalog {
|
|
6283
|
-
#catalog;
|
|
6284
|
-
constructor(catalog) {
|
|
6285
|
-
this.#catalog = catalog;
|
|
6286
|
-
}
|
|
6287
|
-
static from(payload) {
|
|
6288
|
-
const json = new TextDecoder().decode(payload);
|
|
6289
|
-
const catalog = validateCMSF(JSON.parse(json));
|
|
6290
|
-
return new CMSFCatalog(catalog);
|
|
6291
|
-
}
|
|
6292
|
-
getByTrackName(trackName) {
|
|
6293
|
-
return this.#catalog.tracks.find((track) => track.name === this.extractTrackName(trackName));
|
|
6294
|
-
}
|
|
6295
|
-
getTracks(role) {
|
|
6296
|
-
if (role) return this.#catalog.tracks.filter((track) => track.role === role);
|
|
6297
|
-
return this.#catalog.tracks;
|
|
6298
|
-
}
|
|
6299
|
-
getVideo(index = 0) {
|
|
6300
|
-
const videos = this.#catalog.tracks.filter((track) => track.role === "video");
|
|
6301
|
-
if (index < 0 || index >= videos.length) return void 0;
|
|
6302
|
-
return videos[index];
|
|
6303
|
-
}
|
|
6304
|
-
getAudio(index = 0) {
|
|
6305
|
-
const audios = this.#catalog.tracks.filter((track) => track.role === "audio");
|
|
6306
|
-
if (index < 0 || index >= audios.length) return void 0;
|
|
6307
|
-
return audios[index];
|
|
6308
|
-
}
|
|
6309
|
-
getTimeline(index = 0) {
|
|
6310
|
-
const timelines = this.#catalog.tracks.filter((track) => track.role === "timeline");
|
|
6311
|
-
if (index < 0 || index >= timelines.length) return void 0;
|
|
6312
|
-
return timelines[index];
|
|
6313
|
-
}
|
|
6314
|
-
getCodecString(trackName) {
|
|
6315
|
-
const track = this.#catalog.tracks.find((track) => track.name === this.extractTrackName(trackName));
|
|
6316
|
-
if (!track) return void 0;
|
|
6317
|
-
if (!track.codec) throw new Error(`Track ${trackName} does not have a codec`);
|
|
6318
|
-
return track.codec;
|
|
6319
|
-
}
|
|
6320
|
-
getRole(trackName) {
|
|
6321
|
-
const track = this.#catalog.tracks.find((track) => track.name === this.extractTrackName(trackName));
|
|
6322
|
-
if (!track) return void 0;
|
|
6323
|
-
return track.role;
|
|
6324
|
-
}
|
|
6325
|
-
getPackaging(trackName) {
|
|
6326
|
-
const track = this.#catalog.tracks.find((track) => track.name === this.extractTrackName(trackName));
|
|
6327
|
-
if (!track) return void 0;
|
|
6328
|
-
return track.packaging;
|
|
6329
|
-
}
|
|
6330
|
-
isCMAF(trackName) {
|
|
6331
|
-
const packaging = this.getPackaging(trackName);
|
|
6332
|
-
return packaging === "cmaf" || packaging === "chunk-per-object";
|
|
6333
|
-
}
|
|
6334
|
-
getTimescale(trackName) {
|
|
6335
|
-
return this.#catalog.tracks.find((track) => track.name === this.extractTrackName(trackName))?.timescale;
|
|
6336
|
-
}
|
|
6337
|
-
getInitData(trackName) {
|
|
6338
|
-
const track = this.#catalog.tracks.find((track) => track.name === this.extractTrackName(trackName));
|
|
6339
|
-
if (!track) return void 0;
|
|
6340
|
-
if (!track.initData) throw new Error(`Track ${trackName} does not have initData`);
|
|
6341
|
-
return new Uint8Array(atob(track.initData).split("").map((c) => c.charCodeAt(0)));
|
|
6342
|
-
}
|
|
6343
|
-
extractTrackName(input) {
|
|
6344
|
-
const parts = input.split("/");
|
|
6345
|
-
return parts[parts.length - 1];
|
|
6346
|
-
}
|
|
6347
|
-
};
|
|
6348
|
-
//#endregion
|
|
6349
|
-
//#region src/model/parameter/setup/path.ts
|
|
6168
|
+
// src/model/parameter/setup/path.ts
|
|
6350
6169
|
/**
|
|
6351
6170
|
* Copyright 2025 The MOQtail Authors
|
|
6352
6171
|
*
|
|
@@ -6378,8 +6197,7 @@ var Path = class Path {
|
|
|
6378
6197
|
return new Path(moqtPath);
|
|
6379
6198
|
}
|
|
6380
6199
|
};
|
|
6381
|
-
|
|
6382
|
-
//#region src/model/parameter/setup/max_auth_token_cache_size.ts
|
|
6200
|
+
// src/model/parameter/setup/max_auth_token_cache_size.ts
|
|
6383
6201
|
/**
|
|
6384
6202
|
* Copyright 2025 The MOQtail Authors
|
|
6385
6203
|
*
|
|
@@ -6409,8 +6227,7 @@ var MaxAuthTokenCacheSize = class MaxAuthTokenCacheSize {
|
|
|
6409
6227
|
return new MaxAuthTokenCacheSize(pair.value);
|
|
6410
6228
|
}
|
|
6411
6229
|
};
|
|
6412
|
-
|
|
6413
|
-
//#region src/model/parameter/setup/authority.ts
|
|
6230
|
+
// src/model/parameter/setup/authority.ts
|
|
6414
6231
|
/**
|
|
6415
6232
|
* Copyright 2026 The MOQtail Authors
|
|
6416
6233
|
*
|
|
@@ -6432,7 +6249,7 @@ var MaxAuthTokenCacheSize = class MaxAuthTokenCacheSize {
|
|
|
6432
6249
|
*
|
|
6433
6250
|
* Client-only; MUST NOT be sent by a server or over WebTransport. moqtail-ts always
|
|
6434
6251
|
* connects over WebTransport, so its own handshake never sends this — see
|
|
6435
|
-
* `MOQtailClient.
|
|
6252
|
+
* `MOQtailClient.init`.
|
|
6436
6253
|
*/
|
|
6437
6254
|
var Authority = class Authority {
|
|
6438
6255
|
authority;
|
|
@@ -6450,8 +6267,7 @@ var Authority = class Authority {
|
|
|
6450
6267
|
return new Authority(authority);
|
|
6451
6268
|
}
|
|
6452
6269
|
};
|
|
6453
|
-
|
|
6454
|
-
//#region src/model/parameter/setup/max_filter_ranges.ts
|
|
6270
|
+
// src/model/parameter/setup/max_filter_ranges.ts
|
|
6455
6271
|
/**
|
|
6456
6272
|
* Copyright 2026 The MOQtail Authors
|
|
6457
6273
|
*
|
|
@@ -6486,8 +6302,7 @@ var MaxFilterRanges = class MaxFilterRanges {
|
|
|
6486
6302
|
return new MaxFilterRanges(pair.value);
|
|
6487
6303
|
}
|
|
6488
6304
|
};
|
|
6489
|
-
|
|
6490
|
-
//#region src/model/parameter/setup/moqt_implementation.ts
|
|
6305
|
+
// src/model/parameter/setup/moqt_implementation.ts
|
|
6491
6306
|
/**
|
|
6492
6307
|
* Copyright 2026 The MOQtail Authors
|
|
6493
6308
|
*
|
|
@@ -6523,8 +6338,7 @@ var MoqtImplementation = class MoqtImplementation {
|
|
|
6523
6338
|
return new MoqtImplementation(info);
|
|
6524
6339
|
}
|
|
6525
6340
|
};
|
|
6526
|
-
|
|
6527
|
-
//#region src/model/parameter/setup/max_request_updates.ts
|
|
6341
|
+
// src/model/parameter/setup/max_request_updates.ts
|
|
6528
6342
|
/**
|
|
6529
6343
|
* Copyright 2026 The MOQtail Authors
|
|
6530
6344
|
*
|
|
@@ -6559,8 +6373,7 @@ var MaxRequestUpdates = class MaxRequestUpdates {
|
|
|
6559
6373
|
return new MaxRequestUpdates(pair.value);
|
|
6560
6374
|
}
|
|
6561
6375
|
};
|
|
6562
|
-
|
|
6563
|
-
//#region src/model/parameter/setup/ssts_algorithms.ts
|
|
6376
|
+
// src/model/parameter/setup/ssts_algorithms.ts
|
|
6564
6377
|
/**
|
|
6565
6378
|
* Copyright 2026 The MOQtail Authors
|
|
6566
6379
|
*
|
|
@@ -6604,8 +6417,7 @@ var SstsAlgorithms = class SstsAlgorithms {
|
|
|
6604
6417
|
return new SstsAlgorithms(algorithms);
|
|
6605
6418
|
}
|
|
6606
6419
|
};
|
|
6607
|
-
|
|
6608
|
-
//#region src/model/parameter/setup_option.ts
|
|
6420
|
+
// src/model/parameter/setup_option.ts
|
|
6609
6421
|
let SetupOption;
|
|
6610
6422
|
(function(_SetupOption) {
|
|
6611
6423
|
function fromKeyValuePair(pair) {
|
|
@@ -6699,8 +6511,7 @@ var SetupOptions = class {
|
|
|
6699
6511
|
return result;
|
|
6700
6512
|
}
|
|
6701
6513
|
};
|
|
6702
|
-
|
|
6703
|
-
//#region src/model/parameter/message/combined_filter.ts
|
|
6514
|
+
// src/model/parameter/message/combined_filter.ts
|
|
6704
6515
|
/**
|
|
6705
6516
|
* Copyright 2026 The MOQtail Authors
|
|
6706
6517
|
*
|
|
@@ -6763,9 +6574,7 @@ var CombinedFilter = class {
|
|
|
6763
6574
|
case RangeFilterKind.Priority:
|
|
6764
6575
|
set.priority = ranges;
|
|
6765
6576
|
break;
|
|
6766
|
-
case RangeFilterKind.ObjectProperty:
|
|
6767
|
-
set.properties.set(filter.propertyType, ranges);
|
|
6768
|
-
break;
|
|
6577
|
+
case RangeFilterKind.ObjectProperty: set.properties.set(filter.propertyType, ranges);
|
|
6769
6578
|
}
|
|
6770
6579
|
}
|
|
6771
6580
|
this.rangeCount = rangeCount;
|
|
@@ -6818,5 +6627,4 @@ function propertiesPass(required, properties) {
|
|
|
6818
6627
|
}
|
|
6819
6628
|
return true;
|
|
6820
6629
|
}
|
|
6821
|
-
|
|
6822
|
-
export { AudioConfig, AudioLevel, Authority, AuthorizationToken, BaseByteBuffer, ByteBuffer, CMSFCatalog, CastingError, CombinedFilter, ControlMessage, ControlMessageType, DEFAULT_PUBLISHER_PRIORITY, Datagram, DefaultPublisherGroupOrderProperty, DefaultPublisherPriorityProperty, DynamicGroupsProperty, EndOfRangeKind, Expires, Fetch, FetchHeader, FetchHeaderType, FetchObject, FetchOk, FillParameters, FillTimeout, Forward, FrozenByteBuffer, FullTrackName, GREASE_BASE, GREASE_STEP, GoAway, GroupOrder, GroupOrderParam, Header, ImmutablePropertiesObjectProperty, ImmutablePropertiesTrackProperty, IncludeProperties, InternalError, InvalidEnumValue, InvalidFilterError, InvalidTypeError, InvalidUTF8Error, KeyValueFormattingError, KeyValuePair, LOCProperties, LOCProperty, LOCPropertyId, LargestObject, LengthExceedsMaxError, Location, LocationFilter, LocationFilterType, MAX_FULL_TRACK_NAME_LENGTH, MAX_NAMESPACE_TUPLE_COUNT, MAX_NEW_SESSION_URI_LENGTH, MAX_REASON_PHRASE_LEN, MOQtailError, MaxAuthTokenCacheSize, MaxCacheDurationProperty, MaxFilterRanges, MaxRequestUpdates, MessageParameter, MessageParameterType, MessageParameters, MoqtImplementation, MoqtObject, MoqtUrl, Namespace, NamespaceDone, NewGroupRequest, NotEnoughBytesError, ObjectDatagramType, ObjectDeliveryTimeout, ObjectDeliveryTimeoutProperty, ObjectForwardingPreference, ObjectProperty, ObjectStatus, Path, PriorGroupIdGapProperty, PriorObjectIdGapProperty, PropertyRanges, ProtocolViolationError, Publish, PublishDone, PublishDoneStatusCode, PublishNamespace, PublishSkipped, RangeFilter, RangeFilterKind, ReasonPhrase, Redirect, RendezvousTimeout, RequestError, RequestErrorCode, RequestIdError, RequestIdMap, RequestOk, RequestUpdate, SUPPORTED_VERSIONS, Setup, SetupOption, SetupOptionType, SetupOptions, SstsAlgorithms, StreamResetCode, SubgroupDeliveryTimeout, SubgroupDeliveryTimeoutProperty, SubgroupHeader, SubgroupHeaderType, SubgroupObject, Subscribe, SubscribeNamespace, SubscribeOk, SubscribeTracks, SubscriberPriority, SwitchFrom, SwitchMode, SwitchingSetAssignment, TerminationCode, TerminationError, TimeoutError, Timescale, Timestamp, TokenAliasType, TrackNameError, TrackProperty, TrackPropertyType, TrackStatus, TrackStatusCode, Tuple, TupleField, UnknownObjectProperty, UnknownTrackProperty, VarIntOverflowError, VideoConfig, VideoFrameMarking, applyMessageParameterUpdate, assertNoAuthorityOverWebTransport, deserializeKvpList, deserializeKvpListUntilEmpty, deserializeMessageParameterKvps, encodeRanges, greaseValue, isApplicationSpecificProperty, isBytes, isGrease, isVarInt, locPropertyIdFromNumber, messageParameterTypeFromNumber, resolveTransportUrl, serializeKvpList, serializeMessageParameterKvps, setupOptionTypeFromNumber, tokenAliasTypeFromNumber };
|
|
6630
|
+
export { AudioConfig, AudioLevel, Authority, AuthorizationToken, BaseByteBuffer, ByteBuffer, CastingError, CombinedFilter, ControlMessage, ControlMessageType, DEFAULT_PUBLISHER_PRIORITY, Datagram, DefaultPublisherGroupOrderProperty, DefaultPublisherPriorityProperty, DynamicGroupsProperty, EndOfRangeKind, Expires, Fetch, FetchHeader, FetchHeaderType, FetchObject, FetchOk, FillParameters, FillTimeout, Forward, FrozenByteBuffer, FullTrackName, GREASE_BASE, GREASE_STEP, GoAway, GroupOrder, GroupOrderParam, Header, ImmutablePropertiesObjectProperty, ImmutablePropertiesTrackProperty, IncludeProperties, InternalError, InvalidEnumValue, InvalidFilterError, InvalidTypeError, InvalidUTF8Error, KeyValueFormattingError, KeyValuePair, LOCProperties, LOCProperty, LOCPropertyId, LargestObject, LengthExceedsMaxError, Location, LocationFilter, LocationFilterType, MAX_FULL_TRACK_NAME_LENGTH, MAX_NAMESPACE_TUPLE_COUNT, MAX_NEW_SESSION_URI_LENGTH, MAX_REASON_PHRASE_LEN, MOQtailError, MaxAuthTokenCacheSize, MaxCacheDurationProperty, MaxFilterRanges, MaxRequestUpdates, MessageParameter, MessageParameterType, MessageParameters, MoqtImplementation, MoqtObject, MoqtUrl, Namespace, NamespaceDone, NewGroupRequest, NotEnoughBytesError, ObjectDatagramType, ObjectDeliveryTimeout, ObjectDeliveryTimeoutProperty, ObjectForwardingPreference, ObjectProperty, ObjectStatus, Path, PriorGroupIdGapProperty, PriorObjectIdGapProperty, PropertyRanges, ProtocolViolationError, Publish, PublishDone, PublishDoneStatusCode, PublishNamespace, PublishSkipped, RangeFilter, RangeFilterKind, ReasonPhrase, Redirect, RendezvousTimeout, RequestError, RequestErrorCode, RequestIdError, RequestIdMap, RequestOk, RequestUpdate, SUPPORTED_VERSIONS, Setup, SetupOption, SetupOptionType, SetupOptions, SstsAlgorithms, StreamResetCode, SubgroupDeliveryTimeout, SubgroupDeliveryTimeoutProperty, SubgroupHeader, SubgroupHeaderType, SubgroupObject, Subscribe, SubscribeNamespace, SubscribeOk, SubscribeTracks, SubscriberPriority, SwitchFrom, SwitchMode, SwitchingSetAssignment, TerminationCode, TerminationError, TimeoutError, Timescale, Timestamp, TokenAliasType, TrackNameError, TrackProperty, TrackPropertyType, TrackStatus, TrackStatusCode, Tuple, TupleField, UnknownObjectProperty, UnknownTrackProperty, VarIntOverflowError, VideoConfig, VideoFrameMarking, applyMessageParameterUpdate, assertNoAuthorityOverWebTransport, deserializeKvpList, deserializeKvpListUntilEmpty, deserializeMessageParameterKvps, encodeRanges, findProperty, greaseValue, isApplicationSpecificProperty, isBytes, isGrease, isVarInt, locPropertyIdFromNumber, messageParameterTypeFromNumber, resolveTransportUrl, serializeKvpList, serializeMessageParameterKvps, setupOptionTypeFromNumber, tokenAliasTypeFromNumber };
|