Description
Toggle escape state at each escape delimiter, count completed pairs, count separators outside pairs, and report unclosedEscape.
Clinical exchange formats use exact delimiters, character grammars, and scoped identifiers. A local token check addresses one syntax condition and can succeed without validating a complete message or its clinical meaning.
Toggle escape state at each escape delimiter, count completed pairs, count separators outside pairs, and report unclosedEscape.
When to use this tool
Use HL7 Component Escape Gap when you need one bounded spelling, delimiter, or identifier component.
How to use the tool and how it works
- Enter componentText, escapeCharacter, componentSeparator. Use the units and conventions below.
- Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
- Read unescapedSeparators, completedEscapes, unclosedEscape. Inspect unclosedEscape before interpreting the associated values.
Require distinct one-unit escapeCharacter and componentSeparator. Toggle escape state at each escape delimiter, count completed pairs, count separators outside pairs, and report unclosedEscape.1
| Input field | Meaning and units | Accepted input |
|---|---|---|
| componentText | Component Text | Required. Text; maximum UTF-16 length 8192. |
| escapeCharacter | Escape Character | Required. Text; maximum UTF-16 length 8192. |
| componentSeparator | Component Separator | Required. Text; maximum UTF-16 length 8192. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| unescapedSeparators | Unescaped Separators | Required. Safe integer. |
| completedEscapes | Completed Escapes | Required. Safe integer. |
| unclosedEscape | Unclosed Escape | Required. Boolean. |
{
"input": {
"componentText": "A\\S\\B^C",
"escapeCharacter": "\\",
"componentSeparator": "^"
},
"output": {
"unescapedSeparators": 1,
"completedEscapes": 1,
"unclosedEscape": false
}
} Limitations and assumptions
- This screens delimiter balance only; empty or invalid escape bodies can still form completed pairs, and no HL7 escape semantics or full message is validated.
- Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.
Alternative or Complementary methods
Use the relevant full standard, implementation profile, and validated parser when interoperable or clinical record validity matters.
References
Similar or alternative tools
- HL7 Repeat Escape Unescape One Token
Decode F, S, R, T, or E as field, component, repetition, subcomponent, or escape delimiter.
- HL7 Delimiter Role Label
Map the concatenated order to field, component, repetition, escape, subcomponent, and optional truncation roles.