how to mendix store the generated document via java action?

0
what is the meaning of Core.storeFileDocumentContent(context, this.__OutputDoc, new ByteArrayInputStream(stream.toByteArray()));? what is Core.storeFileDocumentContent what is new ByteArrayInputStream(stream.toByteArray()
asked
1 answers
1

Hello Ashirbad,

That's a wrapper method for a file writer - it simply writes to a file. 

Byte arrays are the main input into file writers.

new ByteArrayInputStream(stream.toByteArray()) converts what I assume is an output byte array stream (or maybe a string) to an input byte array stream.

Here's a link to the java doc on byte array input streams - https://docs.oracle.com/javase/7/docs/api/java/io/ByteArrayInputStream.html

answered