org.dspace.sword.client
Class DSpaceSwordClient
java.lang.Object
org.dspace.sword.client.DSpaceSwordClient
public class DSpaceSwordClient
- extends Object
User: Robin Taylor
Date: 15/02/11
Time: 21:12
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DSpaceSwordClient
public DSpaceSwordClient()
setFilename
public void setFilename()
setRemoteServer
public void setRemoteServer(String chosenUrl)
throws MalformedURLException
- Throws:
MalformedURLException
setCredentials
public void setCredentials(String username,
String password,
String onBehalfOf)
getServiceDocument
public ServiceDocument getServiceDocument()
throws HttpException,
SWORDClientException
- Throws:
HttpException
SWORDClientException
setCollection
public void setCollection(String destination)
setFileType
public void setFileType(String fileType)
setPackageFormat
public void setPackageFormat(String packageFormat)
throws PackageFormatException
- Throws:
PackageFormatException
deposit
public void deposit(Context context,
String handle)
throws InvalidHandleException,
PackagerException,
SWORDClientException,
PackageFormatException,
HttpException
- Throws:
InvalidHandleException
PackagerException
SWORDClientException
PackageFormatException
HttpException
createPackage
public void createPackage(Context context,
String handle,
File file)
throws InvalidHandleException,
PackagerException,
PackageFormatException
- Create the package and write it to disk.
- Throws:
InvalidHandleException
PackagerException
PackageFormatException
sendMessage
public String sendMessage()
throws SWORDClientException,
HttpException
- Reads the file, probably a zipped package, and sends it to the Sword server.
- Returns:
- A unique ID returned by a successful deposit
- Throws:
SWORDClientException
HttpException
Copyright © 2013 DuraSpace. All Rights Reserved.