Page 1 of 1
About Question enthuware.ocpjp.v7.2.1717 :
Posted: Sun Feb 02, 2014 7:40 pm
by icepeanuts
I can't find the answer of option 4 in Java API doc. Where is it? Thanks.
Re: About Question enthuware.ocpjp.v7.2.1717 :
Posted: Sun Feb 02, 2014 9:09 pm
by admin
JavaDoc doesn't say that in those terms but it is implied from the description -
Instances of this class support both reading and writing to a random access file. A random access file behaves like a large array of bytes stored in the file system. There is a kind of cursor, or index into the implied array, called the file pointer; input operations read bytes starting at the file pointer and advance the file pointer past the bytes read. If the random access file is created in read/write mode, then output operations are also available; output operations write bytes starting at the file pointer and advance the file pointer past the bytes written. Output operations that write past the current end of the implied array cause the array to be extended. The file pointer can be read by the getFilePointer method and set by the seek method.
It doesn't say that data that exists beyond the file pointer will be deleted. You may try it out.
Re: About Question enthuware.ocpjp.v7.2.1717 :
Posted: Sat Feb 08, 2014 2:46 am
by icepeanuts
thanks
Re: About Question enthuware.ocpjp.v7.2.1717 :
Posted: Wed Nov 09, 2016 5:44 pm
by lczoccante
For the exam 1z0-804 (java 7 ocp), I have been studying the OCA/OCP java SE 7 Programmer I & II study guide, oracle press. And on chapter 9 of this book they cover I/O, however they do not mention nothing about RandomAccessFile or OutputStream objects, and some of these exercises are about these topics, the book covers File, FileReader, BufferedReader, FileWriter, BufferedWriter. What do I need to know for the exam, apart what is the book ?
Regards
Re: About Question enthuware.ocpjp.v7.2.1717 :
Posted: Wed Nov 09, 2016 10:23 pm
by admin
RandomAccessFile and OutputStream are important for the exam. The exam has questions on it.
Our question bank covers every thing you need for the exam. If you just go through the questions and their explanations, that will be enough. You don't need to worry about anything else.
HTH,
Paul.