S
Spendius
Hi,
What do you think is the best way to read a few bytes
from a file that's been loaded up a FileChannel ? Should
I necessarily map it (I only need a few tens of bytes, even
when my file is several hundreds of megs big !) ? Or should
I use one of the 4 'read()' methods the FileChannel class
provides ? If so, how should instantiate the ByteBuffer
required to work with these 'read()' methods ? And what's
its use actually ?
(in fact I don't want to map my files, because they may
happen to be pretty large -several hundreds of megs-, and
mapping them would force me to lay down some algorithm to
deal with the files size in order to map them by chunks...)
Thanks in advance !
Regards,
Spendius
What do you think is the best way to read a few bytes
from a file that's been loaded up a FileChannel ? Should
I necessarily map it (I only need a few tens of bytes, even
when my file is several hundreds of megs big !) ? Or should
I use one of the 4 'read()' methods the FileChannel class
provides ? If so, how should instantiate the ByteBuffer
required to work with these 'read()' methods ? And what's
its use actually ?
(in fact I don't want to map my files, because they may
happen to be pretty large -several hundreds of megs-, and
mapping them would force me to lay down some algorithm to
deal with the files size in order to map them by chunks...)
Thanks in advance !
Regards,
Spendius