Google Data APIs Client Library (1.41.1)



com.google.gdata.client.analytics
Class AnalyticsService

java.lang.Object
  extended by com.google.gdata.client.Service
      extended by com.google.gdata.client.GoogleService
          extended by com.google.gdata.client.analytics.AnalyticsService
All Implemented Interfaces:
AuthTokenFactory.TokenListener

public class AnalyticsService
extends GoogleService

Extends the basic GoogleService abstraction to define a service that is preconfigured for access to the Google Analytics Data Export API.


Nested Class Summary
static class AnalyticsService.Versions
          GData versions supported by the Google Analytics Data Export API.
 
Nested classes/interfaces inherited from class com.google.gdata.client.GoogleService
GoogleService.AccountDeletedException, GoogleService.AccountDisabledException, GoogleService.CaptchaRequiredException, GoogleService.InvalidCredentialsException, GoogleService.NotVerifiedException, GoogleService.ServiceUnavailableException, GoogleService.SessionExpiredException, GoogleService.TermsNotAgreedException
 
Nested classes/interfaces inherited from class com.google.gdata.client.Service
Service.ClientInputProperties, Service.ClientOutputProperties, Service.ClientStreamProperties, Service.GDataRequest, Service.GDataRequestFactory
 
Field Summary
static java.lang.String ANALYTICS_SERVICE
          The abbreviated name of Google Analytics Data Export API recognized by Google.
static java.lang.String ANALYTICS_SERVICE_VERSION
          The version ID of the service.
static Version DEFAULT_VERSION
          Default GData version used by the Google Analytics Data Export API.
 
Fields inherited from class com.google.gdata.client.Service
connectTimeout, extProfile, metadataRegistry, requestFactory
 
Constructor Summary
AnalyticsService(java.lang.String applicationName)
          Constructs an instance connecting to the Google Analytics Data Export API for an application with the name applicationName.
AnalyticsService(java.lang.String applicationName, Service.GDataRequestFactory requestFactory, AuthTokenFactory authTokenFactory)
          Constructs an instance connecting to the Google Analytics Data Export API for an application with the name applicationName and the given GDataRequestFactory and AuthTokenFactory.
AnalyticsService(java.lang.String applicationName, java.lang.String protocol, java.lang.String domainName)
          Constructs an instance connecting to the Google Analytics Data Export API with name serviceName for an application with the name applicationName.
 
Method Summary
 java.lang.String getServiceVersion()
          Returns information about the service version.
static Version getVersion()
          Returns the current GData version used by the Google Analytics Data Export API.
 
Methods inherited from class com.google.gdata.client.GoogleService
addCookie, batch, createRequest, createRequest, delete, delete, getAuthToken, getAuthTokenFactory, getCookieManager, getCookies, getEntry, getEntry, getFeed, getFeed, getFeed, getFeed, handleRedirectException, handlesCookies, handleSessionExpiredException, insert, makePostRequest, setAuthSubToken, setAuthSubToken, setAuthTokenFactory, setCookieManager, setHandlesCookies, setOAuthCredentials, setUserCredentials, setUserCredentials, setUserCredentials, setUserCredentials, setUserToken, tokenChanged, update
 
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, getEntry, getExtensionProfile, getFeed, getFeed, getMetadataRegistry, getProtocolVersion, getRequestFactory, getSchema, getStreamFromLink, initServiceVersion, introspect, parseResponseData, parseResponseData, patch, patch, query, query, query, setAcceptLanguage, setAltRegistry, setConnectTimeout, setContentType, setExtensionProfile, setHeader, setOAuthProxyHeaders, setPrivateHeader, setProtocolVersion, setReadTimeout, setRequestFactory, setTimeouts, startVersionScope, update, useSsl, writeRequestData, writeRequestData
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ANALYTICS_SERVICE

public static final java.lang.String ANALYTICS_SERVICE
The abbreviated name of Google Analytics Data Export API recognized by Google. The service name is used when requesting an authentication token.

See Also:
Constant Field Values

ANALYTICS_SERVICE_VERSION

public static final java.lang.String ANALYTICS_SERVICE_VERSION
The version ID of the service.


DEFAULT_VERSION

public static final Version DEFAULT_VERSION
Default GData version used by the Google Analytics Data Export API.

Constructor Detail

AnalyticsService

public AnalyticsService(java.lang.String applicationName)
Constructs an instance connecting to the Google Analytics Data Export API for an application with the name applicationName.

Parameters:
applicationName - the name of the client application accessing the service. Application names should preferably have the format [company-id]-[app-name]-[app-version]. The name will be used by the Google servers to monitor the source of authentication.

AnalyticsService

public AnalyticsService(java.lang.String applicationName,
                        Service.GDataRequestFactory requestFactory,
                        AuthTokenFactory authTokenFactory)
Constructs an instance connecting to the Google Analytics Data Export API for an application with the name applicationName and the given GDataRequestFactory and AuthTokenFactory. Use this constructor to override the default factories.

Parameters:
applicationName - the name of the client application accessing the service. Application names should preferably have the format [company-id]-[app-name]-[app-version]. The name will be used by the Google servers to monitor the source of authentication.
requestFactory - the request factory that generates gdata request objects
authTokenFactory - the factory that creates auth tokens

AnalyticsService

public AnalyticsService(java.lang.String applicationName,
                        java.lang.String protocol,
                        java.lang.String domainName)
Constructs an instance connecting to the Google Analytics Data Export API with name serviceName for an application with the name applicationName. The service will authenticate at the provided domainName.

Parameters:
applicationName - the name of the client application accessing the service. Application names should preferably have the format [company-id]-[app-name]-[app-version]. The name will be used by the Google servers to monitor the source of authentication.
protocol - name of protocol to use for authentication ("http"/"https")
domainName - the name of the domain hosting the login handler
Method Detail

getServiceVersion

public java.lang.String getServiceVersion()
Description copied from class: Service
Returns information about the service version.

Overrides:
getServiceVersion in class Service

getVersion

public static Version getVersion()
Returns the current GData version used by the Google Analytics Data Export API.