Class AbstractSocialNetwork

    • Constructor Detail

      • AbstractSocialNetwork

        public AbstractSocialNetwork()
    • Method Detail

      • getAuthzEndpoint

        public abstract String getAuthzEndpoint()
      • getTokenEndpoint

        public abstract String getTokenEndpoint()
      • createAuthenticationRequest

        protected org.apache.oltu.oauth2.client.request.OAuthClientRequest.AuthenticationRequestBuilder createAuthenticationRequest()
      • configureAuthenticationRequest

        protected void configureAuthenticationRequest​(org.apache.oltu.oauth2.client.request.OAuthClientRequest.AuthenticationRequestBuilder builder,
                                                      String clientId,
                                                      ContentContext ctx,
                                                      boolean popup)
                                               throws Exception
        Throws:
        Exception
      • buildAuthenticationRequest

        protected org.apache.oltu.oauth2.client.request.OAuthClientRequest buildAuthenticationRequest​(org.apache.oltu.oauth2.client.request.OAuthClientRequest.AuthenticationRequestBuilder builder)
                                                                                               throws org.apache.oltu.oauth2.common.exception.OAuthSystemException
        Throws:
        org.apache.oltu.oauth2.common.exception.OAuthSystemException
      • performRedirect

        public void performRedirect​(javax.servlet.http.HttpServletRequest request,
                                    javax.servlet.http.HttpServletResponse response,
                                    boolean admin)
        Specified by:
        performRedirect in interface ISocialNetwork
      • getAccessToken

        public String getAccessToken​(String code,
                                     org.apache.oltu.oauth2.client.OAuthClient oAuthClient)
                              throws org.apache.oltu.oauth2.common.exception.OAuthSystemException,
                                     org.apache.oltu.oauth2.common.exception.OAuthProblemException
        Throws:
        org.apache.oltu.oauth2.common.exception.OAuthSystemException
        org.apache.oltu.oauth2.common.exception.OAuthProblemException
      • executeTokenRequest

        protected org.apache.oltu.oauth2.client.response.OAuthAccessTokenResponse executeTokenRequest​(org.apache.oltu.oauth2.client.OAuthClient oAuthClient,
                                                                                                      org.apache.oltu.oauth2.client.request.OAuthClientRequest request)
                                                                                               throws org.apache.oltu.oauth2.common.exception.OAuthSystemException,
                                                                                                      org.apache.oltu.oauth2.common.exception.OAuthProblemException
        Throws:
        org.apache.oltu.oauth2.common.exception.OAuthSystemException
        org.apache.oltu.oauth2.common.exception.OAuthProblemException
      • createTokenRequest

        protected org.apache.oltu.oauth2.client.request.OAuthClientRequest.TokenRequestBuilder createTokenRequest()
      • configureTokenRequest

        protected void configureTokenRequest​(org.apache.oltu.oauth2.client.request.OAuthClientRequest.TokenRequestBuilder builder,
                                             String clientId,
                                             String clientSecret,
                                             String code)
      • buildTokenRequest

        protected org.apache.oltu.oauth2.client.request.OAuthClientRequest buildTokenRequest​(org.apache.oltu.oauth2.client.request.OAuthClientRequest.TokenRequestBuilder builder)
                                                                                      throws org.apache.oltu.oauth2.common.exception.OAuthSystemException
        Throws:
        org.apache.oltu.oauth2.common.exception.OAuthSystemException
      • fillUserInfo

        protected void fillUserInfo​(UserInfo userInfo,
                                    SocialUser socialUser)
      • getLoginURL

        public String getLoginURL()