|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.xerox.amazonws.common.AWSConnection
com.xerox.amazonws.common.AWSQueryConnection
com.xerox.amazonws.sdb.SimpleDB
public class SimpleDB
This class provides an interface with the Amazon SDB service. It provides high level methods for listing and creating and deleting domains.
Field Summary |
---|
Fields inherited from class com.xerox.amazonws.common.AWSConnection |
---|
headers |
Constructor Summary | |
---|---|
SimpleDB(String awsAccessId,
String awsSecretKey)
Initializes the sdb service with your AWS login information. |
|
SimpleDB(String awsAccessId,
String awsSecretKey,
boolean isSecure)
Initializes the sdb service with your AWS login information. |
|
SimpleDB(String awsAccessId,
String awsSecretKey,
boolean isSecure,
String server)
Initializes the sdb service with your AWS login information. |
|
SimpleDB(String awsAccessId,
String awsSecretKey,
boolean isSecure,
String server,
int port)
Initializes the sdb service with your AWS login information. |
Method Summary | ||
---|---|---|
Domain |
createDomain(String name)
Creates a domain. |
|
void |
deleteDomain(Domain domain)
Deletes a domain. |
|
void |
deleteDomain(String name)
Deletes a domain. |
|
Domain |
getDomain(String domainName)
Method for getting a Domain object without getting a list of them. |
|
int |
getSignatureVersion()
This method returns the signature version |
|
ListDomainsResult |
listDomains()
Returns a list of domains for this account. |
|
ListDomainsResult |
listDomains(String nextToken)
Returns a list of domains for this account. |
|
ListDomainsResult |
listDomains(String nextToken,
int maxResults)
Gets a list of domains |
|
protected
|
makeRequestInt(org.apache.http.client.methods.HttpRequestBase method,
String action,
Map<String,String> params,
Class<T> respType)
|
|
void |
setSignatureVersion(int version)
This method sets the signature version used to sign requests (0 or 1). |
Methods inherited from class com.xerox.amazonws.common.AWSQueryConnection |
---|
close, close, getConnectionManagerTimeout, getConnectionTimeout, getHeaders, getHttpClient, getMaxConnections, getMaxRetries, getServerTimeZone, getSoTimeout, getString, httpDate, makeRequest, setConnectionManagerTimeout, setConnectionTimeout, setHttpClient, setMaxConnections, setMaxRetries, setProxyValues, setProxyValues, setProxyValues, setServerTimeZone, setSoTimeout, useSystemProxy |
Methods inherited from class com.xerox.amazonws.common.AWSConnection |
---|
encode, encode, getAlgorithm, getAwsAccessKeyId, getPort, getResourcePrefix, getSecretAccessKey, getServer, getUrl, isSecure, makeURL, setResourcePrefix, setServer, urlencode |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SimpleDB(String awsAccessId, String awsSecretKey)
awsAccessId
- The your user key into AWSawsSecretKey
- The secret string used to generate signatures for authentication.public SimpleDB(String awsAccessId, String awsSecretKey, boolean isSecure)
awsAccessId
- The your user key into AWSawsSecretKey
- The secret string used to generate signatures for authentication.isSecure
- True if the data should be encrypted on the wire on the way to or from SDB.public SimpleDB(String awsAccessId, String awsSecretKey, boolean isSecure, String server)
awsAccessId
- The your user key into AWSawsSecretKey
- The secret string used to generate signatures for authentication.isSecure
- True if the data should be encrypted on the wire on the way to or from SDB.server
- Which host to connect to. Usually, this will be sdb.amazonaws.compublic SimpleDB(String awsAccessId, String awsSecretKey, boolean isSecure, String server, int port)
awsAccessId
- The your user key into AWSawsSecretKey
- The secret string used to generate signatures for authentication.isSecure
- True if the data should be encrypted on the wire on the way to or from SDB.server
- Which host to connect to. Usually, this will be sdb.amazonaws.comport
- Which port to use.Method Detail |
---|
public int getSignatureVersion()
getSignatureVersion
in class AWSConnection
public void setSignatureVersion(int version)
setSignatureVersion
in class AWSConnection
version
- signature versionpublic ListDomainsResult listDomains() throws SDBException
Domain
instances.
SDBException
- wraps checked exceptionspublic ListDomainsResult listDomains(String nextToken) throws SDBException
nextToken
- token to use when retrieving next results
Domain
instances.
SDBException
- wraps checked exceptionspublic Domain createDomain(String name) throws SDBException
name
- name of the new domain
SDBException
- wraps checked exceptionspublic void deleteDomain(Domain domain) throws SDBException
domain
- the domain to be deleted
SDBException
- wraps checked exceptionspublic void deleteDomain(String name) throws SDBException
name
- the name of the domain to be deleted
SDBException
- wraps checked exceptionspublic Domain getDomain(String domainName) throws SDBException
domainName
- the name of the domain to be returned
SDBException
- wraps checked exceptionspublic ListDomainsResult listDomains(String nextToken, int maxResults) throws SDBException
nextToken
- token to use when retrieving next resultsmaxResults
- the max number of results to return (0 means no max defined)
SDBException
- wraps checked exceptionsprotected <T> T makeRequestInt(org.apache.http.client.methods.HttpRequestBase method, String action, Map<String,String> params, Class<T> respType) throws SDBException
SDBException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |