public class DataSourceDownload extends Object
DataSource for download. This class also
recognizes DateDataSource and provides| Constructor and Description |
|---|
DataSourceDownload(DataSource ds) |
DataSourceDownload(PathDataSource ds,
boolean deletePath) |
| Modifier and Type | Method and Description |
|---|---|
Long |
getContentLength() |
String |
getContentType() |
long |
getExpireTimestamp() |
UUID |
getId() |
InputStream |
getInputStream() |
Instant |
getLastModified() |
String |
getName()
return the name set via
setName(String). |
OutputStream |
getOutputStream() |
void |
setName(String name)
Override the name used for the download.
|
public DataSourceDownload(DataSource ds)
public DataSourceDownload(PathDataSource ds, boolean deletePath)
public void setName(String name)
null
then the DataSource.getName() method of the underlying
DataSource is used.name - namepublic Instant getLastModified()
public String getContentType()
public InputStream getInputStream() throws IOException
IOExceptionpublic String getName()
setName(String). If this is
undefined, returns the DataSource.getName().public OutputStream getOutputStream() throws IOException
IOExceptionpublic Long getContentLength()
public long getExpireTimestamp()
getExpireTimestamp in interface DownloadCopyright © 2014–2019 Uniklinik RWTH Aachen. All rights reserved.