Package org.eurekastreams.server.action.response.opensocial

Examples of org.eurekastreams.server.action.response.opensocial.ConsumerInfoResponse


                oneOf(consumerMapper).execute(with(any(OAuthConsumerRequest.class)));
                will(returnValue(new OAuthConsumer("", "", "", "", "")));
            }
        });
        ConsumerInfoResponse response = (ConsumerInfoResponse) sut.execute(actionContext);
        Assert.assertNotNull("Consumer was not found", response.getConsumerInfo());
        context.assertIsSatisfied();
    }
View Full Code Here


        context.checking(new Expectations()
        {
            {
                oneOf(serviceActionControllerMock).execute(with(any(ServiceActionContext.class)),
                        with(any(ServiceAction.class)));
                will(returnValue(new ConsumerInfoResponse(new ConsumerInfo(null, null, null))));
            }
        });

        sut.getConsumerKeyAndSecret(securityToken, "serviceName", provider);
        context.assertIsSatisfied();
View Full Code Here

        }
        net.oauth.OAuthConsumer consumer = new net.oauth.OAuthConsumer(oauthConsumer.getCallbackURL(), oauthConsumer
                .getConsumerKey(), oauthConsumer.getConsumerSecret(), request.getProvider());
        consumer.setProperty(OAuth.OAUTH_SIGNATURE_METHOD, oauthConsumer.getSignatureMethod());
        ConsumerInfo consumerInfo = new ConsumerInfo(consumer, null, oauthConsumer.getCallbackURL());
        return new ConsumerInfoResponse(consumerInfo);
    }
View Full Code Here

        ConsumerInfo consumerInfo = null;
        try
        {
            GetConsumerInfoRequest request = new GetConsumerInfoRequest(securityToken, serviceName, provider);
            ServiceActionContext currentContext = new ServiceActionContext(request, null);
            ConsumerInfoResponse response = (ConsumerInfoResponse) actionController.execute(currentContext,
                    getConsumerInfoAction);
            consumerInfo = response.getConsumerInfo();
        }
        catch (Exception ex)
        {
            logger.error("Error occurred getting consumer info.", ex);
            throw new GadgetException(GadgetException.Code.INTERNAL_SERVER_ERROR, ex.getMessage());
View Full Code Here

TOP

Related Classes of org.eurekastreams.server.action.response.opensocial.ConsumerInfoResponse

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.