Interface: Hl7Position
Positional context attached to every warning and fatal error. Fields are
1-indexed against the HL7 spec convention (see RawSegment.fields for the
index 0 slot convention). All fields past segmentIndex are optional,
for a top-level fatal like EMPTY_INPUT only segmentIndex: 0 is
populated; for a tokenizer warning deep inside a subcomponent all five
indices may be set.
Remarks
With exactOptionalPropertyTypes: true, do not pass fieldIndex: undefined
explicitly: omit the key instead.
Example
import type { Hl7Position } from "@cosyte/hl7";
const pos: Hl7Position = { segmentIndex: 2, fieldIndex: 5 };
Properties
componentIndex?
readonlyoptionalcomponentIndex?:number
fieldIndex?
readonlyoptionalfieldIndex?:number
repetitionIndex?
readonlyoptionalrepetitionIndex?:number
segmentIndex
readonlysegmentIndex:number
subcomponentIndex?
readonlyoptionalsubcomponentIndex?:number