On 23.02.2013 15:54,
wrote:
>> ... You would have to create more complex code if you want to align char
> position and byte position.
> ~
> but then why do they have a:
> ~
> docs/api/java/nio/channels/FileChannel.html#position()
> ~
> in the API? How/What is it used for?
http://docs.oracle.com/javase/7/docs...html#position()
> ~
> If you read the FileChannel.position() as you read off the chars from the
> CharBuffer you always get 0 (as if the offset pointer in the underlying
> FileChannel would not advance)
Probably because you are not reading through the channel but mapping the
file into memory.
Please stop ripping your posting threads apart. Thank you.
robert
--
remember.guy do |as, often| as.you_can - without end
http://blog.rubybestpractices.com/