Example usage for org.springframework.security.oauth2.client.resource OAuth2ProtectedResourceDetails getGrantType

List of usage examples for org.springframework.security.oauth2.client.resource OAuth2ProtectedResourceDetails getGrantType

Introduction

In this page you can find the example usage for org.springframework.security.oauth2.client.resource OAuth2ProtectedResourceDetails getGrantType.

Prototype

String getGrantType();

Source Link

Document

The grant type for obtaining an acces token for this resource.

Usage

From source file:com.zhm.config.MyAuthorizationCodeAccessTokenProvider.java

public boolean supportsResource(OAuth2ProtectedResourceDetails resource) {
    return resource instanceof AuthorizationCodeResourceDetails
            && "authorization_code".equals(resource.getGrantType());
}

From source file:com.emergya.spring.security.oauth.google.GoogleAuthorizationCodeAccessTokenProvider.java

@Override
public final boolean supportsResource(final OAuth2ProtectedResourceDetails resource) {
    return resource instanceof AuthorizationCodeResourceDetails
            && "authorization_code".equals(resource.getGrantType());
}

From source file:org.opentestsystem.shared.security.oauth.client.grant.samlbearer.SamlAssertionAccessTokenProvider.java

@Override
public boolean supportsResource(final OAuth2ProtectedResourceDetails resource) {
    return SamlAssertionResourceDetails.GRANT_TYPE_SAML_ASSERTION.equals(resource.getGrantType());
}