com.google.gdata.client.appsforyourdomain.adminsettings
Class SingleSignOnService
java.lang.Object
com.google.gdata.client.Service
com.google.gdata.client.GoogleService
com.google.gdata.client.appsforyourdomain.AppsForYourDomainService
com.google.gdata.client.appsforyourdomain.AppsPropertyService
com.google.gdata.client.appsforyourdomain.adminsettings.SingleSignOnService
- All Implemented Interfaces:
- AuthTokenFactory.TokenListener
public class SingleSignOnService
- extends AppsPropertyService
Specialization of AppsPropertyService
for managing SSO related
settings of a domain.
Constructor Summary |
SingleSignOnService(java.lang.String domain,
java.lang.String applicationName)
Parameterized constructor to setup a Service object which can be used to
initialize the service without obtaining a token. |
SingleSignOnService(java.lang.String adminEmail,
java.lang.String password,
java.lang.String domain,
java.lang.String applicationName)
Parameterized constructor for service authentication. |
Methods inherited from class com.google.gdata.client.GoogleService |
addCookie, batch, createRequest, createRequest, delete, getAuthToken, getAuthTokenFactory, getCookieManager, getCookies, getEntry, getFeed, getFeed, getFeed, handleRedirectException, handlesCookies, handleSessionExpiredException, makePostRequest, setAuthSubToken, setAuthSubToken, setAuthTokenFactory, setCookieManager, setHandlesCookies, setOAuthCredentials, setUserCredentials, setUserCredentials, setUserCredentials, setUserCredentials, setUserToken, tokenChanged |
Methods inherited from class com.google.gdata.client.Service |
classOf, createBatchRequest, createDeleteRequest, createEntryRequest, createFeedRequest, createFeedRequest, createInsertRequest, createLinkQueryRequest, createPatchRequest, createUpdateRequest, delete, delete, endVersionScope, getAltRegistry, getContentType, getDefaultAltRegistry, getExtensionProfile, getFeed, getMetadataRegistry, getProtocolVersion, getRequestFactory, getSchema, getServiceVersion, getStreamFromLink, getStrictValidation, getVersion, initServiceVersion, introspect, parseResponseData, parseResponseData, patch, patch, query, query, setAcceptLanguage, setAltRegistry, setConnectTimeout, setContentType, setExtensionProfile, setHeader, setOAuthProxyHeaders, setPrivateHeader, setProtocolVersion, setReadTimeout, setRequestFactory, setStrictValidation, setTimeouts, startVersionScope, update, useSsl, writeRequestData, writeRequestData |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ssoSettingsUrl
protected java.lang.String ssoSettingsUrl
ssoSigningKeyUrl
protected java.lang.String ssoSigningKeyUrl
domainUrlBase
protected java.lang.String domainUrlBase
SingleSignOnService
public SingleSignOnService(java.lang.String domain,
java.lang.String applicationName)
- Parameterized constructor to setup a Service object which can be used to
initialize the service without obtaining a token. The user should
explicitly authorize the service by calling either
setUserCredentials
or setUserToken
when using this constructor.
- Parameters:
domain
- Domain being configuredapplicationName
- Application name consuming the API
SingleSignOnService
public SingleSignOnService(java.lang.String adminEmail,
java.lang.String password,
java.lang.String domain,
java.lang.String applicationName)
throws AuthenticationException
- Parameterized constructor for service authentication.
- Parameters:
adminEmail
- the email id of the administrator.password
- the administrator password.domain
- the domain name to be configured.applicationName
- the calling client application name.for e.g.
mycompany-java
- Throws:
AuthenticationException
- if an authentication related error occurs.
updateSSOSettings
public GenericEntry updateSSOSettings(GenericEntry entry)
throws AppsForYourDomainException,
java.io.IOException,
ServiceException
- Updates the SSO properties with the GenericEntry values.
- Parameters:
entry
- a GenericEntry object with SSO properties
- Returns:
- a GenericEntry with the updated properties
- Throws:
java.io.IOException
- if an error occurs while communicating with the GData
service.
AppsForYourDomainException
- if an Apps for your domain API error
occurred.
ServiceException
- if the insert request failed due to system error.
updateSsoSigningKey
public GenericEntry updateSsoSigningKey(java.lang.String base64EncodedKey)
throws java.io.IOException,
AppsForYourDomainException,
ServiceException
- Updates the public key used for SSO.
- Parameters:
base64EncodedKey
-
- Returns:
- a GenericEntry object with the updated SSO signing key.
- Throws:
java.io.IOException
- if an error occurs while communicating with the GData
service.
AppsForYourDomainException
- if an Apps for your domain API error
occurred.
ServiceException
- if the fetch request failed due to system error.
getSsoSigningKey
public GenericEntry getSsoSigningKey()
throws AppsForYourDomainException,
java.io.IOException,
ServiceException
- Retrieves the certificate uploaded to the domain for SSO.
- Returns:
- A GenericEntry with one or more of the following properties
depending on the key format: {exponent, yValue, format, modulus,
algorithm}
- Throws:
AppsForYourDomainException
- if an Apps for your domain API error
occurred.
java.io.IOException
- if an error occurs while communicating with the GData
service.
ServiceException
- if the fetch request failed due to system error.
getSsoSettings
public GenericEntry getSsoSettings()
throws AppsForYourDomainException,
java.io.IOException,
ServiceException
- Retrieves the SSO properties configured for the domain.
- Returns:
- a GenericEntry object with all the SSO properties.
- Throws:
AppsForYourDomainException
- if an Apps for your domain API error
occurred.
java.io.IOException
- if an error occurs while communicating with the GData
service.
ServiceException
- if the fetch request failed due to system error.