Package oauth.thirdparty

Examples of oauth.thirdparty.OAuthClientManager


          new RestaurantReservationService();
        WebClient socialService =
          WebClient.create("http://localhost:8080/thirdPartyAccess/calendar");
        reserveService.setSocialService(socialService);
       
        OAuthClientManager manager = new OAuthClientManager();
        manager.setAuthorizationURI("http://localhost:8080/social/authorize");
        WebClient rts =
          WebClient.create("http://localhost:8080/oauth/initiate");
        rts.accept(MediaType.APPLICATION_FORM_URLENCODED_TYPE);
        WebClient.getConfig(rts).getHttpConduit().getClient().setReceiveTimeout(1000000L);
        manager.setRequestTokenService(rts);
        WebClient ats =
          WebClient.create("http://localhost:8080/oauth/token");
        ats.accept(MediaType.APPLICATION_FORM_URLENCODED_TYPE);
        WebClient.getConfig(ats).getHttpConduit().getClient().setReceiveTimeout(1000000L);
        manager.setAccessTokenService(ats);
       
        reserveService.setOAuthClientManager(manager);
       
        SecurityContextFilter filter = new SecurityContextFilter();
        filter.setUsers(Collections.singletonMap("barry@restaurant.com", "5678"));
View Full Code Here

TOP

Related Classes of oauth.thirdparty.OAuthClientManager

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.