Package play.libs.OAuth

Examples of play.libs.OAuth.ServiceInfo


                    String encoded = encodeParam(entry.getValue());
                    fullUrl.append(entry.getKey()).append("=").append(encoded);
                    any = true;
                }
            }
            ServiceInfo serviceInfo = Dropbox.OAUTH;
            return WS.url(fullUrl.toString()).oauth(serviceInfo, token, secret);
        }
View Full Code Here


    }

    public static void authCallback() throws Exception {
        String token = session.get(SessionKeys.TOKEN);
        String secret = session.get(SessionKeys.SECRET);
        ServiceInfo serviceInfo = Dropbox.OAUTH;
        OAuth.Response oauthResponse = OAuth.service(serviceInfo).retrieveAccessToken(token, secret);
        if (oauthResponse.error == null) {
            Logger.info("Succesfully authenticated with Dropbox.");
            User u = upsertUser(oauthResponse.token, oauthResponse.secret);
            session.put(SessionKeys.TYPE, AccountType.DROPBOX.name());
View Full Code Here

        }
    }

    public static void auth() throws Exception {
        flash.keep(REDIRECT_URL);
        ServiceInfo serviceInfo = Dropbox.OAUTH;
        OAuth oauth = OAuth.service(serviceInfo);
        OAuth.Response oauthResponse = oauth.retrieveRequestToken();
        if (oauthResponse.error == null) {
            Logger.info("Redirecting to Dropbox for auth.");
            session.put(SessionKeys.TOKEN, oauthResponse.token);
View Full Code Here

TOP

Related Classes of play.libs.OAuth.ServiceInfo

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.