Package com.nimbusds.oauth2.sdk
Class ProtectedResourceRequest
- java.lang.Object
-
- com.nimbusds.oauth2.sdk.AbstractRequest
-
- com.nimbusds.oauth2.sdk.ProtectedResourceRequest
-
- Direct Known Subclasses:
ClientDeleteRequest
,ClientReadRequest
,ClientRegistrationRequest
,ClientUpdateRequest
,UserInfoRequest
public abstract class ProtectedResourceRequest extends AbstractRequest
Base abstract class for protected resource requests using an OAuth 2.0 access token.Related specifications:
- RFC 6749
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
ProtectedResourceRequest(URI uri, AccessToken accessToken)
Creates a new protected resource request.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AccessToken
getAccessToken()
Gets the OAuth 2.0 access token for this protected resource request.-
Methods inherited from class com.nimbusds.oauth2.sdk.AbstractRequest
getEndpointURI
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.nimbusds.oauth2.sdk.Request
toHTTPRequest
-
-
-
-
Constructor Detail
-
ProtectedResourceRequest
protected ProtectedResourceRequest(URI uri, AccessToken accessToken)
Creates a new protected resource request.- Parameters:
uri
- The URI of the protected resource. May benull
if theRequest.toHTTPRequest()
method will not be used.accessToken
- An OAuth 2.0 access token for the request,null
if none.
-
-
Method Detail
-
getAccessToken
public AccessToken getAccessToken()
Gets the OAuth 2.0 access token for this protected resource request.- Returns:
- The OAuth 2.0 access token,
null
if none.
-
-