public class StreamSource extends AbstractSource
uri
Constructor and Description |
---|
StreamSource(URI uri,
InputStream in) |
StreamSource(URI uri,
InputStream in,
String mimeType) |
StreamSource(URI uri,
InputStream in,
String mimeType,
long length) |
StreamSource(URI uri,
InputStream in,
String mimeType,
String encoding) |
StreamSource(URI uri,
InputStream in,
String mimeType,
String encoding,
long length) |
StreamSource(URI uri,
Reader reader) |
StreamSource(URI uri,
Reader reader,
String mimeType) |
StreamSource(URI uri,
Reader reader,
String mimeType,
String encoding) |
StreamSource(URI uri,
Reader reader,
String mimeType,
String encoding,
long length) |
Modifier and Type | Method and Description |
---|---|
boolean |
exists()
データが存在すればtrueを返します。
|
String |
getEncoding()
キャラクタ・エンコーディングを返します。未定の場合はnullです。
|
File |
getFile()
ファイルとして返します。
|
InputStream |
getInputStream()
バイナリストリームを返します。
|
long |
getLength()
データのサイズを返します。不明な場合は-1を返します。
|
String |
getMimeType()
データのMIME型を返します。不確定な場合はnull。
|
Reader |
getReader()
テキストストリームを返します。
|
URI |
getURI()
データのURIを返します。
|
SourceValidity |
getValidity()
データの変更情報を返します。
|
boolean |
isInputStream()
バイナリデータとして取得可能ならtrueを返します。
|
boolean |
isReader()
テキストデータとして取得可能ならtrueを返します。
|
close, isFile
public StreamSource(URI uri, InputStream in, String mimeType, String encoding, long length) throws UnsupportedEncodingException
UnsupportedEncodingException
public StreamSource(URI uri, InputStream in, String mimeType, long length)
public StreamSource(URI uri, Reader reader, String mimeType, String encoding, long length) throws IOException
IOException
public StreamSource(URI uri, InputStream in, String mimeType, String encoding) throws UnsupportedEncodingException
UnsupportedEncodingException
public StreamSource(URI uri, InputStream in, String mimeType)
public StreamSource(URI uri, InputStream in)
public StreamSource(URI uri, Reader reader, String mimeType, String encoding) throws IOException
IOException
public StreamSource(URI uri, Reader reader, String mimeType) throws IOException
IOException
public StreamSource(URI uri, Reader reader) throws IOException
IOException
public URI getURI()
Source
getURI
in interface MetaSource
getURI
in interface Source
getURI
in class AbstractSource
public String getMimeType()
Source
public boolean exists()
Source
public String getEncoding()
Source
public boolean isInputStream()
Source
isInputStream
in interface Source
isInputStream
in class AbstractSource
public boolean isReader()
Source
isReader
in interface Source
isReader
in class AbstractSource
public InputStream getInputStream() throws IOException
Source
IOException
public Reader getReader() throws IOException
Source
IOException
public File getFile()
Source
public long getLength() throws IOException
Source
IOException
public SourceValidity getValidity()
Source
Copyright © 2018 座間ソフト. All rights reserved.