SofaBuffers TypeScript - v0.11.0
    Preparing search index...

    Class StringSeq

    Collects the elements of a string wrapper-sequence array into out.

    The destination, placed at out[id]; grown as elements arrive, with gaps filled by the element default "".

    The decoder's shared PayloadAcc — one per decode, since only one payload is ever in flight.

    The schema count, an index capacity: an element id at or above it is INVALID (§7.1/§5.1) — a statement about validity. Pass UNBOUNDED (-1) for an array the schema left unbounded, where receiverCap governs instead.

    The element maxlen in bytes, or UNBOUNDED (-1) for an element the schema left open, where receiverElemMax governs instead.

    The schema field name, used only in the rejection message.

    The receiver-side index cap that applies only when the schema left the array unbounded (§6.2.1): exceeding it is LIMIT_EXCEEDED, a policy rejection, not INVALID. There is no unlimited setting — a wrapper array announces no count, so the index is the only place a receiver can bound it. Required, with no default (§6.2.1).

    The receiver-side max_dyn_string_len for an element the schema left unbounded (§6.2.1), checked at the length word and answered with LIMIT_EXCEEDED. A wrapper array's string elements never reach the generated visitor — their length words come here — so this is where that cap belongs, and it is why the decoder needs no module-wide limit object at all. Required, with no default: FIXLEN_MAX is the format's bound, not a receiver cap, and §6.2.1 forbids presenting it as one.

    Index
    • Parameters

      • out: string[]
      • acc: PayloadAcc
      • cap: number
      • elemMax: number
      • name: string
      • receiverCap: number
      • receiverElemMax: number

      Returns StringSeq

    cap: number
    elemMax: number
    name: string
    out: string[]
    receiverCap: number
    receiverElemMax: number
    • The element's fixlen length word (Visitor.fixlenBegin).

      The bounds are decided by this word, so they are checked here — before any payload byte — and again in element below.

      That is not redundancy for its own sake: a message that ends inside an over-long element must still be INVALID, and only this event runs early enough to say so. Without it the verdict would degrade to INCOMPLETE, which §5.2.3 forbids for input already known to be malformed and which §6.4 forbids a chunk boundary from changing.

      An element of the wrong fixlen subtype is left alone: §7.3 requires it to be skipped, not rejected, and it is skipped by this class simply ignoring it.

      Parameters

      Returns void

    • One payload piece of element id (Visitor.string).

      Parameters

      • id: number
      • total: number
      • offset: number
      • src: Uint8Array
      • start: number
      • end: number

      Returns void