public class FileSource extends AbstractSource
uri| コンストラクタと説明 |
|---|
FileSource(File file) |
FileSource(File file,
String mimeType) |
FileSource(File file,
String mimeType,
String encoding) |
FileSource(File file,
URI uri,
String mimeType,
String encoding) |
FileSource(URI uri) |
| 修飾子とタイプ | メソッドと説明 |
|---|---|
boolean |
exists()
データが存在すればtrueを返します。
|
String |
getEncoding()
キャラクタ・エンコーディングを返します。
|
File |
getFile()
ファイルとして返します。
|
InputStream |
getInputStream()
バイナリストリームを返します。
|
long |
getLength()
データのサイズを返します。
|
String |
getMimeType()
データのMIME型を返します。
|
Reader |
getReader()
テキストストリームを返します。
|
SourceValidity |
getValidity()
データの変更情報を返します。
|
boolean |
isFile()
ファイルならtrueを返します。
|
boolean |
isInputStream()
バイナリデータとして取得可能ならtrueを返します。
|
boolean |
isReader()
テキストデータとして取得可能ならtrueを返します。
|
close, getURI, toStringpublic FileSource(URI uri) throws IOException
IOExceptionpublic FileSource(File file)
public String getMimeType() throws IOException
SourceIOExceptionpublic String getEncoding()
Sourcepublic boolean exists()
throws IOException
SourceIOExceptionpublic boolean isFile()
throws IOException
SourceisFile インタフェース内 SourceisFile クラス内 AbstractSourceIOExceptionpublic boolean isInputStream()
throws IOException
SourceisInputStream インタフェース内 SourceisInputStream クラス内 AbstractSourceIOExceptionpublic boolean isReader()
throws IOException
SourceisReader インタフェース内 SourceisReader クラス内 AbstractSourceIOExceptionpublic InputStream getInputStream() throws IOException
SourceIOExceptionpublic Reader getReader() throws IOException
SourceIOExceptionpublic long getLength()
throws IOException
SourceIOExceptionpublic SourceValidity getValidity() throws IOException
SourceIOExceptionCopyright © 2024 座間ソフト. All rights reserved.