Win a copy of Java 9 Modularity: Patterns and Practices for Developing Maintainable Applications this week in the Java 9 forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

alternative for FileCopyUtils of spring in struts  RSS feed

 
subham ja
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have to use this type of method{copy(byte[] in, OutputStream out) } in my struts program..
But i am unable to find the solution of it..
please help me in this.
 
Jeanne Boyarsky
author & internet detective
Sheriff
Posts: 37381
531
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to CodeRanch!

Looking at the ,%20java.io.OutputStream)]JavaDoc, that method looks like it could be written in two lines:


And a few more lines if you need to handle the exception from close.

Then I looked at the implementation. They have some valdiations and add a buffered writer. But there isn't much to it there either.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!