Please note that the contents of this offline web site may be out of date. To access the most recent documentation visit the online version .
Note that links that point to online resources are green in color and will open in a new window.
We would love it if you could give us feedback about this material by filling this form (You have to be online to fill it)
Android APIs
public abstract class

Pipe

extends Object
java.lang.Object
   ↳ java.nio.channels.Pipe

Class Overview

A pipe contains two channels, forming a unidirectional pipe. One is the writable sink channel, and the other is the readable source channel. When bytes are written into the writable channel they can be read from the readable channel. Bytes are read in the order in which they were written.

Summary

Nested Classes
class Pipe.SinkChannel Writable sink channel used to write to a pipe. 
class Pipe.SourceChannel Readable source channel used to read from a pipe. 
Protected Constructors
Pipe ()
The protected default constructor.
Public Methods
static Pipe open ()
Returns a new pipe from the default .
abstract Pipe.SinkChannel sink ()
Returns the sink channel of the pipe.
abstract Pipe.SourceChannel source ()
Returns the source channel of the pipe.
[Expand]
Inherited Methods
From class java.lang.Object

Protected Constructors

protected Pipe ()

Added in API level 1

The protected default constructor.

Public Methods

public static Pipe open ()

Added in API level 1

Returns a new pipe from the default .

Throws
IOException if an I/O error occurs.

public abstract Pipe.SinkChannel sink ()

Added in API level 1

Returns the sink channel of the pipe.

Returns
  • a writable sink channel of the pipe.

public abstract Pipe.SourceChannel source ()

Added in API level 1

Returns the source channel of the pipe.

Returns
  • a readable source channel of the pipe.