Repository navigation
|
I currently have a prototype using the EDIStreamReader to build up an EDI pojo at the ICE/GROUP/Transaction level. Since I don't need to break down anything beyond a list of segments within each transaction, is there a way to configure the stream reader to just read a composite as a single segment text section? |
Replies: 1 comment 1 reply
Hi @hancockks , do you need to just list the segment tags or are you also using the element data? To answer your question, there isn't any configuration option for that, but you could easily use a |
Hi @hancockks , do you need to just list the segment tags or are you also using the element data?
To answer your question, there isn't any configuration option for that, but you could easily use a
StringBuilderfor it. When your application encounters aSTART_COMPOSITEevent, set the length of the builder to 0. Then, for eachELEMENT_DATAevent, append the text from the event. Finally, use the value from the builder whenEND_COMPOSITEoccurs.