Class Policy
- java.lang.Object
-
- com.adyen.model.sessionauthentication.Policy
-
public class Policy extends Object
Policy
-
-
Field Summary
Fields Modifier and Type Field Description static StringJSON_PROPERTY_RESOURCESstatic StringJSON_PROPERTY_ROLES
-
Constructor Summary
Constructors Constructor Description Policy()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description PolicyaddResourcesItem(Resource resourcesItem)PolicyaddRolesItem(String rolesItem)booleanequals(Object o)Return true if this Policy object is equal to o.static PolicyfromJson(String jsonString)Create an instance of Policy given an JSON stringSet<Resource>getResources()An object containing the type and the unique identifier of the user of the component.Set<String>getRoles()The name of the role required to use the component.inthashCode()Policyresources(Set<Resource> resources)An object containing the type and the unique identifier of the user of the component.Policyroles(Set<String> roles)The name of the role required to use the component.voidsetResources(Set<Resource> resources)An object containing the type and the unique identifier of the user of the component.voidsetRoles(Set<String> roles)The name of the role required to use the component.StringtoJson()Convert an instance of Policy to an JSON stringStringtoString()
-
-
-
Field Detail
-
JSON_PROPERTY_RESOURCES
public static final String JSON_PROPERTY_RESOURCES
- See Also:
- Constant Field Values
-
JSON_PROPERTY_ROLES
public static final String JSON_PROPERTY_ROLES
- See Also:
- Constant Field Values
-
-
Method Detail
-
resources
public Policy resources(Set<Resource> resources)
An object containing the type and the unique identifier of the user of the component. For [Onboarding components](https://docs.adyen.com/platforms/onboard-users/components), this is the ID of the legal entity that has a contractual relationship with your platform. For sole proprietorships, use the ID of the legal entity of the individual owner. For [Platform Experience components](https://docs.adyen.com/platforms/build-user-dashboards), this is the ID of the account holder that is associated with the balance account shown in the component.- Parameters:
resources-- Returns:
- the current
Policyinstance, allowing for method chaining
-
getResources
public Set<Resource> getResources()
An object containing the type and the unique identifier of the user of the component. For [Onboarding components](https://docs.adyen.com/platforms/onboard-users/components), this is the ID of the legal entity that has a contractual relationship with your platform. For sole proprietorships, use the ID of the legal entity of the individual owner. For [Platform Experience components](https://docs.adyen.com/platforms/build-user-dashboards), this is the ID of the account holder that is associated with the balance account shown in the component.- Returns:
- resources
-
setResources
public void setResources(Set<Resource> resources)
An object containing the type and the unique identifier of the user of the component. For [Onboarding components](https://docs.adyen.com/platforms/onboard-users/components), this is the ID of the legal entity that has a contractual relationship with your platform. For sole proprietorships, use the ID of the legal entity of the individual owner. For [Platform Experience components](https://docs.adyen.com/platforms/build-user-dashboards), this is the ID of the account holder that is associated with the balance account shown in the component.- Parameters:
resources-
-
roles
public Policy roles(Set<String> roles)
The name of the role required to use the component.- Parameters:
roles-- Returns:
- the current
Policyinstance, allowing for method chaining
-
getRoles
public Set<String> getRoles()
The name of the role required to use the component.- Returns:
- roles
-
setRoles
public void setRoles(Set<String> roles)
The name of the role required to use the component.- Parameters:
roles-
-
equals
public boolean equals(Object o)
Return true if this Policy object is equal to o.
-
fromJson
public static Policy fromJson(String jsonString) throws com.fasterxml.jackson.core.JsonProcessingException
Create an instance of Policy given an JSON string- Parameters:
jsonString- JSON string- Returns:
- An instance of Policy
- Throws:
com.fasterxml.jackson.core.JsonProcessingException- if the JSON string is invalid with respect to Policy
-
toJson
public String toJson() throws com.fasterxml.jackson.core.JsonProcessingException
Convert an instance of Policy to an JSON string- Returns:
- JSON string
- Throws:
com.fasterxml.jackson.core.JsonProcessingException
-
-