Package com.streamreduce.connections

Examples of com.streamreduce.connections.GoogleAnalyticsProvider


        return allProfileMetrics;
    }

    private Analytics initializeAnalytics() {
        if (analytics == null) {
            GoogleAnalyticsProvider provider = new GoogleAnalyticsProvider();
            TokenResponse tokenResponse = new TokenResponse().setRefreshToken(getConnectionCredentials().getOauthRefreshToken());
            GoogleCredential credential = new GoogleCredential.Builder()
                    .setJsonFactory(jsonFactory)
                    .setTransport(transport)
                    .setClientSecrets(provider.getClientId(), provider.getClientSecret())
                    .build()
                    .setFromTokenResponse(tokenResponse);
            analytics = new Analytics.Builder(transport, jsonFactory, credential).build();
        }
        return analytics;
View Full Code Here

TOP

Related Classes of com.streamreduce.connections.GoogleAnalyticsProvider

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.