ShellOutputReceiverStream

public final class ShellOutputReceiverStream
extends Object

java.lang.Object
   ↳ com.android.tradefed.util.ShellOutputReceiverStream


IShellOutputReceiver に書き込む OutputStream のユーティリティ サブクラス。

概要

パブリック コンストラクタ

ShellOutputReceiverStream(IShellOutputReceiver receiver)

指定された IShellOutputReceiver の新しいアダプターを作成します。

ShellOutputReceiverStream(IShellOutputReceiver receiver, FileOutputStream fileOutput)

パブリック メソッド

void close()
void flush()
void write(byte[] b)
void write(byte[] b, int off, int len)
void write(int b)

パブリック コンストラクタ

ShellOutputReceiverStream

public ShellOutputReceiverStream (IShellOutputReceiver receiver)

指定された IShellOutputReceiver の新しいアダプターを作成します。

アダプターを使用するコードを簡素化するために、ここで null レシーバを指定することは有効です。つまり、null レシーバ自体をチェックすることなく、try-with-resources でこれを使用できます。

パラメータ
receiver IShellOutputReceiver

ShellOutputReceiverStream

public ShellOutputReceiverStream (IShellOutputReceiver receiver, 
                FileOutputStream fileOutput)

パラメータ
receiver IShellOutputReceiver

fileOutput FileOutputStream

パブリック メソッド

閉じる

public void close ()

フラッシュ

public void flush ()

文章の作成

public void write (byte[] b)

パラメータ
b byte

文章の作成

public void write (byte[] b, 
                int off, 
                int len)

パラメータ
b byte

off int

len int

文章の作成

public void write (int b)

パラメータ
b int