Skip to content

source.getSegmentDelimiter

Use when: You want to read values from the original incoming message before any mapping changes. If you need the modified message during mapping, use message.getSegmentDelimiter.

Signature: source.getSegmentDelimiter()

Returns: String separator - the segment delimiter associated with the message

Get the segment delimiter used for this message.

Note

This method only applies to the following formatted messages: HL7, EDIFACT, X12.

Parameters

None

Example

// Given an HL7, EDIFACT, or X12 source message.

// Retrieve the segment delimiter used by the message.
var segmentDelimiter = source.getSegmentDelimiter(); // expected: "\r" for HL7, "~" for X12