Demos and Usage of org.apache.commons.io.IOUtils.toByteArray(String input)


   1: 
   2: import org.apache.commons.io.IOUtils;
   3: import org.apache.commons.logging.Log;
   4:         ...
   5:                     servletXmlEntry = newJarEntry;
   6:                     servletXmlBuffer = IOUtils.toByteArray(source);
   7:                 }
   8:         ...
   9:                 else if (Assembler.PORTLET_XML.equals(newJarEntry.getName())) {
  10:                     portletXmlBuffer = IOUtils.toByteArray(source);
  11:                     dest.putNextEntry(newJarEntry);
  12:         ...
  13:                     IOUtils.write(portletXmlBuffer, dest);

View Full Code Here