Le 4/19/14 3:57 PM, Alon Bar-Lev a écrit :
> On Sat, Apr 19, 2014 at 3:52 PM, Jon V. <[email protected]> wrote:
>> NIO controls and deals with the selectors. Async IO is a part of that but
>> is not the same thing. Async io means that if a write cannot be fully
>> flushed. It will not block until it can be. NIO provides us the events to
>> tell us that data is available in the socket.
> Async IO is the ability for a single thread to perform (multiplex) IO
> (connect, read, write, close etc..) for multiple file descriptors.
>
> As far as I know, without NIO you cannot achieve that in Java.

There are two ways to do Async in Java, since Java 7 : NIO and AIO. Both
are asynchronous IO.

The difference between NIO and AIO is that when you try to read or write
something, this can be done in a simpler way, as you may pass the
reference to an handler which will be called automatically, when you
have to take care of this with NIO.

To be clear, the distinction should be between blocking IO and
non-blocking IO. NIO and AIO are part of the non-blocking IO.

-- 
Regards,
Cordialement,
Emmanuel Lécharny
www.iktek.com 

Reply via email to