Example usage for org.springframework.security.oauth.consumer BaseProtectedResourceDetails setAcceptsAuthorizationHeader

List of usage examples for org.springframework.security.oauth.consumer BaseProtectedResourceDetails setAcceptsAuthorizationHeader

Introduction

In this page you can find the example usage for org.springframework.security.oauth.consumer BaseProtectedResourceDetails setAcceptsAuthorizationHeader.

Prototype

public void setAcceptsAuthorizationHeader(boolean acceptsAuthorizationHeader) 

Source Link

Usage

From source file:org.awesomeagile.webapp.config.HackpadConfig.java

@Hackpad
@Bean/*from  w  ww.j a v  a2 s  .c  o  m*/
public OAuthRestTemplate getHackpadRestTemplate() {
    BaseProtectedResourceDetails resource = new BaseProtectedResourceDetails();
    resource.setConsumerKey(hackpadClientId);
    resource.setSharedSecret(new SharedConsumerSecretImpl(hackpadClientSecret));
    resource.setAcceptsAuthorizationHeader(false);
    return new OAuthRestTemplate(resource);
}