Pipe.SourceChannel


Pipe.SourceChannel java.nio.channels

Java 1.4 closeable

This public inner class is represents the read end of a pipe. Bytes that are written to the corresponding write end of the pipe (see Pipe.SinkChannel ) become available for reading through this channel. Obtain a Pipe.SourceChannel by creating a Pipe object with Pipe. open ( ) and then calling the source( ) method of that object. See also the containing Pipe class.

Pipe.SourceChannel implements ReadableByteChannel and ScatteringByteChannel and defines the read( ) methods of those interfaces. This class subclasses SelectableChannel , so that it can be used with a Selector . It overrides the abstract validOps( ) method of SelectableChannel to return SelectionKey.OP_READ , but defines no new methods of its own.

 public abstract static class  Pipe.SourceChannel  extends java.nio.channels.spi. AbstractSelectableChannel implements ReadableByteChannel, ScatteringByteChannel {  // Protected Constructors  protected  SourceChannel  (java.nio.channels.spi.SelectorProvider  provider  );  // Public Methods Overriding SelectableChannel  public final int  validOps  ( );  constant  } 

Returned By

Pipe.source( )



Java In A Nutshell
Java In A Nutshell, 5th Edition
ISBN: 0596007736
EAN: 2147483647
Year: 2004
Pages: 1220

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net