AsynchronousCoder?

Alexander Libman libman at terabit.com.au
Thu Jun 25 20:38:50 PDT 2009


Hi Gili,
AsynchronousCoder is part of AsynchronousFilter framework
The main concept of AsynchronousFilter is described in
http://mail.openjdk.java.net/pipermail/nio-dev/2009-January/000339.html

Since January this framework has been slightly modified, but the basis is
the same.
Generic filter now  is defined as
  abstract class AsynchronousFilter<OUTER_PARM,
                                                     OUTER_RESULT,
                                                      INNER_PARM,
                                                      INNER_RESULT>

and
  public class AsynchronousCoder extends
          AsynchronousFilter<CharBuffer,
                                         Integer,
                                         ByteBuffer,
                                         Integer>

Full code (not well documented yet)  you can find at

http://jproactor.svn.sourceforge.net/viewvc/jproactor/trunk/nio2/src/au/com/
terabit/nio2/filter/

and bunch of tests in
http://jproactor.svn.sourceforge.net/viewvc/jproactor/trunk/nio2/src/au/com/
terabit/nio2/testfilter/

Example of usage for AsynchronousCoder:
http://jproactor.svn.sourceforge.net/viewvc/jproactor/trunk/nio2/src/au/com/
terabit/nio2/testfilter/TestCoder.java

Currently AsynchrnousCoder allows simple read to(write from) CharBuffer.
readLine () not  implemented.
I was thinking  that readLine is more fitted into imaginable
AsynchronousScanner class

Alex

> -----Original Message-----
> From: nio-dev-bounces at openjdk.java.net
> [mailto:nio-dev-bounces at openjdk.java.net]On Behalf Of Gili
> Sent: Thursday, June 25, 2009 4:24 PM
> To: nio-dev at openjdk.java.net
> Subject: AsynchronousCoder?
>
>
>
> Hi,
>
> Alan wrote:
> > Alex Libman has built a filter framework on this API and it includes an
> > AsynchronousCoder for char I/O. You might want to bring it up on the
> > nio-dev mailing list for more discussion.
>
> Where can I find out more information on this API? I'm looking for an
> AsychronousCharChannel of sorts, that will let me read/write on CharBuffer
> and also readLine().
>
> Thank you,
> Gili
> --
> View this message in context:
> http://n2.nabble.com/AsynchronousCoder--tp3157509p3157509.html
> Sent from the nio-dev mailing list archive at Nabble.com.
>
> Checked by AVG - www.avg.com
> Version: 8.5.374 / Virus Database: 270.12.90/2200 - Release Date:
> 06/24/09 12:49:00
>




More information about the nio-dev mailing list