|
||||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||
java.lang.Objectrydeen.io.AbstractDestination
rydeen.io.DirectoryDestination
public class DirectoryDestination
ディレクトリを出力先とするの実装クラスです.
Destination
| コンストラクタの概要 | |
|---|---|
DirectoryDestination(File base)
基準となるディレクトリを指定してオブジェクトを構築します. |
|
| メソッドの概要 | |
|---|---|
void |
close()
何も行いません. |
OutputStream |
getOutput(ProcessTarget target)
引数で与えられたProcessTargetを出力するための出力ストリームを作成して,返します. |
OutputStream |
getOutput(String name)
引数で与えられた文字列に出力するための出力ストリームを作成して,返します. |
| クラス rydeen.io.AbstractDestination から継承されたメソッド |
|---|
isClosed, output |
| クラス java.lang.Object から継承されたメソッド |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| コンストラクタの詳細 |
|---|
public DirectoryDestination(File base)
throws IOException
IOException| メソッドの詳細 |
|---|
public OutputStream getOutput(String name)
throws IOException
引数で与えられた文字列に出力するための出力ストリームを作成して,返します.
引数にFile.separatorが含まれていれば,ディレクトリ階層として扱われます. ディレクトリが存在しない場合は,自動的に作成されます.
ディレクトリ作成に失敗した場合はIOExceptionが投げられます. 引数にnullが与えられた場合はNullPointerExceptionが投げられます.
Destination 内の getOutputAbstractDestination 内の getOutputname - 出力先のファイル名.
IOException - ディレクトリ作成に失敗した場合
public OutputStream getOutput(ProcessTarget target)
throws IOException
引数で与えられたProcessTargetを出力するための出力ストリームを作成して,返します.
targetの
メソッドで得られる文字列をもとに出力先が決められます.
その文字列にFile.separatorが含まれていれば,ディレクトリ階層として扱われます.
ディレクトリが存在しない場合は,自動的に作成されます.
getName
ディレクトリ作成に失敗した場合はIOExceptionが投げられます. 引数にnullが与えられた場合はNullPointerExceptionが投げられます.
Destination 内の getOutputAbstractDestination 内の getOutputtarget - 出力するProcessTarget.
IOException - 既にcloseメソッドが呼ばれ,出力ストリームが閉じれているとき.public void close()
Destination 内の closeAbstractDestination 内の close
|
||||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||