Publish Document (array of struct)

We are working with IOAdapter to read files with a structure like that:
000AAABBB
111CCCDDD
222EEEFFF
222EEEFFF
111CCCDDD
222EEEFFF
222EEEFFF
222EEEFFF
000…

we have no problem to read it, but we don’t know how to publish a document type array of struct:

000AAABBB
111CCCDDD
222EEEFFF
222EEEFFF
111CCCDDD
222EEEFFF
222EEEFFF
222EEEFFF
000AAABBB
111CCCDDD
222EEEFFF
222EEEFFF
111CCCDDD
222EEEFFF
222EEEFFF
222EEEFFF

Thank in advance
Paco

If I understand correctly, what you want is to output is a structure like this:

parent[ ]
– child [ ]
---- grandchild [ ]

It is possible to go from your file to this type of structure but it’s a rather manual process.

First, you need to create a mapstep with this structure.

Second you need to parse through your results from the file and basically store them (as instances of the mapstep) in some type of persistant structure. Something like hashtables and vectors can work for this, but consider the size of what your file will be.

Third, now that you have made the first pass through you can initialize the size of the struct (arrays) in the mapstep from step one.

Fourth, copy the results from the persistant objects to the redimensioned mapstep.

Now you’re ready to publish! Sound confusing? It’s not easy to do but it works.

Hi,
do you have problem in defining an event containing a sequence of struct using the Document Type Editor?? Do you have problems in publishing an event with such structure from a Java application???

Let me know, because I’ve used events with sequence of struct.

Best regards
Alessio