public class AuthzDetailsElement extends Object implements Serializable
authorization_details
which is defined in "OAuth 2.0 Rich Authorization Requests".| Constructor and Description |
|---|
AuthzDetailsElement() |
| Modifier and Type | Method and Description |
|---|---|
static AuthzDetailsElement |
fromJson(String json)
Build an
AuthzDetailsElement instance from a JSON string. |
String[] |
getActions()
Get the actions.
|
String |
getIdentifier()
Get the identifier of a specific resource.
|
String[] |
getLocations()
Get the resources and/or resource servers.
|
String |
getOtherFields()
Get the other fields (than
type, locations,
actions and identifier) as a string in the JSON format. |
Map<?,?> |
getOtherFieldsAsMap()
|
String |
getType()
Get the type of this element.
|
AuthzDetailsElement |
setActions(String[] actions)
Set the actions.
|
AuthzDetailsElement |
setIdentifier(String identifier)
Set the identifier of a specific resource.
|
AuthzDetailsElement |
setLocations(String[] locations)
Set the resources and/or resource servers.
|
AuthzDetailsElement |
setOtherFields(String otherFields)
Set the other fields (than
type, locations,
actions and identifier) as a string in the JSON format. |
AuthzDetailsElement |
setType(String type)
Set the type of this element.
|
String |
toJson()
Convert this instance into a JSON string.
|
public String getType()
From "OAuth 2.0 Rich Authorization Requests":
"The type of resource request as a string. This field MAY define which other elements are allowed in the request. This element is REQUIRED."
public AuthzDetailsElement setType(String type)
From "OAuth 2.0 Rich Authorization Requests":
"The type of resource request as a string. This field MAY define which other elements are allowed in the request. This element is REQUIRED."
type - The type of this element.this object.public String[] getLocations()
From "OAuth 2.0 Rich Authorization Requests":
"An array of strings representing the location of the resource or resource server. This is typically composed of URIs."
public AuthzDetailsElement setLocations(String[] locations)
From "OAuth 2.0 Rich Authorization Requests":
"An array of strings representing the location of the resource or resource server. This is typically composed of URIs."
locations - The resources and/or resource servers.this object.public String[] getActions()
From "OAuth 2.0 Rich Authorization Requests":
"An array of strings representing the kinds of actions to be taken at the resource. The values of the strings are determined by the API being protected."
public AuthzDetailsElement setActions(String[] actions)
From "OAuth 2.0 Rich Authorization Requests":
"An array of strings representing the kinds of actions to be taken at the resource. The values of the strings are determined by the API being protected."
actions - The actions.this object.public String getIdentifier()
From "OAuth 2.0 Rich Authorization Requests":
"A string identifier indicating a specific resource available at the API."
public AuthzDetailsElement setIdentifier(String identifier)
From "OAuth 2.0 Rich Authorization Requests":
"A string identifier indicating a specific resource available at the API."
identifier - The identifier of a specific resource.this object.public String getOtherFields()
type, locations,
actions and identifier) as a string in the JSON format.
The content varies depending on the type field.
null.getOtherFieldsAsMap()public AuthzDetailsElement setOtherFields(String otherFields)
type, locations,
actions and identifier) as a string in the JSON format.
The content varies depending on the type field.
otherFields - Other fields in the JSON format.this object.public Map<?,?> getOtherFieldsAsMap()
type, locations,
actions and identifier) as a Map object.
The content varies depending on the type field.
Map object. This may be null.getOtherFields()public String toJson()
"Other fields" (the string returned from getOtherFields() are
expanded into the output JSON.
public static AuthzDetailsElement fromJson(String json)
AuthzDetailsElement instance from a JSON string.
The following is an example of input JSON.
{
"type" : "my_type",
"locations" : ["loc0", "loc1"],
"actions" : ["act0", "act1"],
"identifier": "my_id",
"prop0" : "a",
"prop1" : ["b", "c"],
"prop2" : {
"sub0": "d",
"sub1": ["e", "f"]
}
}
json - A JSON string.AuthzDetailsElement instance built from the input JSON.Copyright © 2020. All rights reserved.