linux - How does java AsynchronousFileChannel work if the kernel not support AIO -


i have 2 questions

  1. how asynchronousfilechannel work if operating system not support aio (lower linux 2.6 etc).

  2. how append sth asynchronousfilechannel, far know asynchronousfilechannel supports write(bytebuffer, long position, attachment, completionhandler handler) , write(bytebuffer src, long position) both need position param. should count position myself?

question 2: javadoc

an asynchronous file channel not have current position within file. instead, file position specified each read , write method initiates asynchronous operations.

so yes, need keep track of position yourself.


Comments

Popular posts from this blog

toolbar - How to add link to user registration inside toobar in admin joomla 3 custom component -

linux - disk space limitation when creating war file -