public class StringRemoteFile extends Object implements RemoteFile
Constructor and Description |
---|
StringRemoteFile(String s) |
StringRemoteFile(String filename,
String s) |
Modifier and Type | Method and Description |
---|---|
void |
appendTo(OutputStream out)
Write the contents of this remote file to an output stream.
|
void |
cleanup()
Deletes the local file to which this remote file refers.
|
void |
copyTo(File destFile)
Copy remotefile to local disk storage.
|
String |
getChecksum()
Returns a MD5 Checksum on the file.
|
InputStream |
getInputStream()
Get an inputstream that contains the data transferred in this RemoteFile.
|
String |
getName()
Return the file name.
|
long |
getSize()
Returns the total size of the remote file.
|
public StringRemoteFile(String s)
public StringRemoteFile(String filename, String s)
public void copyTo(File destFile)
copyTo
in interface RemoteFile
destFile
- local Filepublic void appendTo(OutputStream out)
appendTo
in interface RemoteFile
out
- OutputStream that the data will be written to. This stream will not be closed by this operation.IOFailure
- If append operation failspublic InputStream getInputStream()
RemoteFile
getInputStream
in interface RemoteFile
public String getName()
getName
in interface RemoteFile
public String getChecksum()
getChecksum
in interface RemoteFile
public void cleanup()
cleanup
in interface RemoteFile
public long getSize()
getSize
in interface RemoteFile
Copyright © 2005–2016 The Royal Danish Library, the Danish State and University Library, the National Library of France and the Austrian National Library.. All rights reserved.