aspose file tools*
The moose likes I/O and Streams and the fly likes Byte and character oriented Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » I/O and Streams
Bookmark "Byte and character oriented" Watch "Byte and character oriented" New topic
Author

Byte and character oriented

Nitin Kharbade
Greenhorn

Joined: Oct 09, 2010
Posts: 25
When to use Byte and character oriented classes in file operation especially? Generally which one is used. Thanks.
James Sabre
Ranch Hand

Joined: Sep 07, 2004
Posts: 781

Nitin Kharbade wrote:When to use Byte and character oriented classes in file operation especially? Generally which one is used. Thanks.


When your data is binary use bytes and when it is text use characters. It is normally safe to use byte for holding text but it is most definitely not safe to use characters for holding binary data.


Retired horse trader.
 Note: double-underline links may be advertisements automatically added by this site and are probably not endorsed by me.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Byte and character oriented
 
Similar Threads
IO streams
problem with file writing
whats the catch for making two things that do same work ?
Accessing file inside JAR
Difference between Reader/Writer and InputStream/Output Stream?