How to redirect output to a byte array?
I've Googled this, and looked around in the tutorials, but I haven't found a simple example of how to assign an output to a byte array. Maybe I'm just too much of a newbie to know how to navigate the documentation, but...
What I need is for this code (which does exactly what I want) to put the output in a byte array instead of in the file "test.txt". How do I accomplish that?
Thanks,
--gary
FileWriter writer =null;
try{
writer =new FileWriter("test.txt");
MinimalHTMLWriter htmlWriter =new MinimalHTMLWriter(writer,
(StyledDocument)textRegion.getDocument());
htmlWriter.write();
}
catch (IOException ex){
... etc...

