|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.fcrepo.client.Downloader
public class Downloader
A client for performing HTTP GET requests on a Fedora server (with authentication) or any other server (without authentication). Each kind of request can either request an InputStream or request that the Downloader write the content directly to a provided OutputStream.
| Constructor Summary | |
|---|---|
Downloader(String host,
int port,
String context,
String user,
String pass)
Construct a downloader for a certain repository as a certain user. |
|
| Method Summary | |
|---|---|
InputStream |
get(String url)
Get data via HTTP as an InputStream, following redirects, and supplying credentials if the host is the Fedora server. |
void |
get(String url,
OutputStream out)
Get data via HTTP and write it to an OutputStream, following redirects, and supplying credentials if the host is the Fedora server. |
InputStream |
getDatastreamContent(String pid,
String dsID,
String asOfDateTime)
|
void |
getDatastreamContent(String pid,
String dsID,
String asOfDateTime,
OutputStream out)
|
InputStream |
getDatastreamDissemination(String pid,
String dsId,
String asOfDateTime)
|
void |
getDatastreamDissemination(String pid,
String dsId,
String asOfDateTime,
OutputStream out)
|
static void |
main(String[] args)
Test this class. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Downloader(String host,
int port,
String context,
String user,
String pass)
throws IOException
IOException| Method Detail |
|---|
public void getDatastreamContent(String pid,
String dsID,
String asOfDateTime,
OutputStream out)
throws IOException
IOException
public InputStream getDatastreamContent(String pid,
String dsID,
String asOfDateTime)
throws IOException
IOException
public void getDatastreamDissemination(String pid,
String dsId,
String asOfDateTime,
OutputStream out)
throws IOException
IOException
public InputStream getDatastreamDissemination(String pid,
String dsId,
String asOfDateTime)
throws IOException
IOException
public void get(String url,
OutputStream out)
throws IOException
IOException
public InputStream get(String url)
throws IOException
IOExceptionpublic static void main(String[] args)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||