File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Threads and Synchronization and the fly likes CHAR ARRAYS problem Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » Threads and Synchronization
Reply Bookmark "CHAR ARRAYS problem" Watch "CHAR ARRAYS problem" New topic
Author

CHAR ARRAYS problem

Prashant Bopardikar
Greenhorn

Joined: Jun 07, 2002
Posts: 2
I am trying to copy data from a PipedReader into a char array and then stream it out
using out.print(char[]);
The problem is that if I define a small char[] I am unable to get a large amount of data and if I define a large char[] I am unable to get a small
amount of data thro the Reader streamed out.
Can someone HELP...
Thanks in advance
Chris Shepherd
Ranch Hand

Joined: Jun 27, 2000
Posts: 286
how about using a:
stringBuffer.append(char);
or
stringBuffer.append(char[]);
to read in the char data.
Then do:
stringBuffer.toString().toCharArray()
when you are ready to stream it out...
Oh and they're gonna ask you to change your name I think... :roll:
[ June 07, 2002: Message edited by: Chris Shepherd ]
 
 
subject: CHAR ARRAYS problem
 
Threads others viewed
Specifying Transaction Duration
java.rmi.ServerException: RemoteException occurred in server thread
XML Parsing Problem.
Need API: to find difference in two files
Large arrays
developer file tools