Source: externs/shaka/mp4_parser.js

  1. /*! @license
  2. * Shaka Player
  3. * Copyright 2016 Google LLC
  4. * SPDX-License-Identifier: Apache-2.0
  5. */
  6. /**
  7. * @externs
  8. */
  9. /**
  10. * @typedef {{
  11. * name: string,
  12. * parser: !shaka.util.Mp4Parser,
  13. * partialOkay: boolean,
  14. * stopOnPartial: boolean,
  15. * start: number,
  16. * size: number,
  17. * version: ?number,
  18. * flags: ?number,
  19. * reader: !shaka.util.DataViewReader,
  20. * has64BitSize: boolean
  21. * }}
  22. *
  23. * @property {string} name
  24. * The box name, a 4-character string (fourcc).
  25. * @property {!shaka.util.Mp4Parser} parser
  26. * The parser that parsed this box. The parser can be used to parse child
  27. * boxes where the configuration of the current parser is needed to parsed
  28. * other boxes.
  29. * @property {boolean} partialOkay
  30. * If true, allows reading partial payloads from some boxes. If the goal is a
  31. * child box, we can sometimes find it without enough data to find all child
  32. * boxes. This property allows the partialOkay flag from parse() to be
  33. * propagated through methods like children().
  34. * @property {boolean} stopOnPartial
  35. * If true, stop reading if an incomplete box is detected.
  36. * @property {number} start
  37. * The start of this box (before the header) in the original buffer. This
  38. * start position is the absolute position.
  39. * @property {number} size
  40. * The size of this box (including the header).
  41. * @property {?number} version
  42. * The version for a full box, null for basic boxes.
  43. * @property {?number} flags
  44. * The flags for a full box, null for basic boxes.
  45. * @property {!shaka.util.DataViewReader} reader
  46. * The reader for this box is only for this box. Reading or not reading to
  47. * the end will have no affect on the parser reading other sibling boxes.
  48. * @property {boolean} has64BitSize
  49. * If true, the box header had a 64-bit size field. This affects the offsets
  50. * of other fields.
  51. * @exportDoc
  52. */
  53. shaka.extern.ParsedBox;