Class ResourceRepresentation
- java.lang.Object
-
- org.keycloak.representations.idm.authorization.ResourceRepresentation
-
- Direct Known Subclasses:
AbstractResourceService.Resource
,UmaResourceRepresentation
public class ResourceRepresentation extends Object
One or more resources that the resource server manages as a set of protected resources.
For more details, OAuth-resource-reg.
- Author:
- Pedro Igor
-
-
Constructor Summary
Constructors Constructor Description ResourceRepresentation()
Creates a new instance.ResourceRepresentation(String name, String... scopes)
ResourceRepresentation(String name, Set<ScopeRepresentation> scopes)
Creates a new instance.ResourceRepresentation(String name, Set<ScopeRepresentation> scopes, String uri, String type)
ResourceRepresentation(String name, Set<ScopeRepresentation> scopes, String uri, String type, String iconUri)
ResourceRepresentation(String name, Set<ScopeRepresentation> scopes, Set<String> uris, String type)
Creates a new instance.ResourceRepresentation(String name, Set<ScopeRepresentation> scopes, Set<String> uris, String type, String iconUri)
Creates a new instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description void
addScope(String... scopeNames)
void
addScope(ScopeRepresentation scope)
boolean
equals(Object o)
Map<String,List<String>>
getAttributes()
String
getDisplayName()
String
getIconUri()
String
getId()
String
getName()
ResourceOwnerRepresentation
getOwner()
Boolean
getOwnerManagedAccess()
Set<ScopeRepresentation>
getScopes()
String
getType()
String
getUri()
Deprecated.Set<String>
getUris()
int
hashCode()
void
setAttributes(Map<String,List<String>> attributes)
void
setDisplayName(String displayName)
void
setIconUri(String iconUri)
void
setId(String id)
void
setName(String name)
void
setOwner(String ownerId)
void
setOwner(ResourceOwnerRepresentation owner)
void
setOwnerManagedAccess(Boolean ownerManagedAccess)
void
setScopes(Set<ScopeRepresentation> scopes)
void
setType(String type)
void
setUri(String uri)
Deprecated.void
setUris(Set<String> uris)
-
-
-
Constructor Detail
-
ResourceRepresentation
public ResourceRepresentation(String name, Set<ScopeRepresentation> scopes, Set<String> uris, String type, String iconUri)
Creates a new instance.- Parameters:
name
- a human-readable string describing a set of one or more resourcesuris
- aList
ofURI
that provides network locations for the resource set being registeredtype
- a string uniquely identifying the semantics of the resource setscopes
- the available scopes for this resource seticonUri
- aURI
for a graphic icon representing the resource set
-
ResourceRepresentation
public ResourceRepresentation(String name, Set<ScopeRepresentation> scopes, String uri, String type, String iconUri)
-
ResourceRepresentation
public ResourceRepresentation(String name, Set<ScopeRepresentation> scopes, Set<String> uris, String type)
Creates a new instance.- Parameters:
name
- a human-readable string describing a set of one or more resourcesuris
- aList
ofURI
that provides the network location for the resource set being registeredtype
- a string uniquely identifying the semantics of the resource setscopes
- the available scopes for this resource set
-
ResourceRepresentation
public ResourceRepresentation(String name, Set<ScopeRepresentation> scopes, String uri, String type)
-
ResourceRepresentation
public ResourceRepresentation(String name, Set<ScopeRepresentation> scopes)
Creates a new instance.- Parameters:
name
- a human-readable string describing a set of one or more resourcesserverUri
- aURI
that identifies this resource serverscopes
- the available scopes for this resource set
-
ResourceRepresentation
public ResourceRepresentation()
Creates a new instance.
-
-
Method Detail
-
setId
public void setId(String id)
-
getId
public String getId()
-
getName
public String getName()
-
getDisplayName
public String getDisplayName()
-
getUri
@Deprecated public String getUri()
Deprecated.
-
getType
public String getType()
-
getScopes
public Set<ScopeRepresentation> getScopes()
-
getIconUri
public String getIconUri()
-
setName
public void setName(String name)
-
setDisplayName
public void setDisplayName(String displayName)
-
setUri
@Deprecated public void setUri(String uri)
Deprecated.
-
setType
public void setType(String type)
-
setScopes
public void setScopes(Set<ScopeRepresentation> scopes)
-
setIconUri
public void setIconUri(String iconUri)
-
getOwner
public ResourceOwnerRepresentation getOwner()
-
setOwner
public void setOwner(ResourceOwnerRepresentation owner)
-
setOwner
public void setOwner(String ownerId)
-
getOwnerManagedAccess
public Boolean getOwnerManagedAccess()
-
setOwnerManagedAccess
public void setOwnerManagedAccess(Boolean ownerManagedAccess)
-
addScope
public void addScope(String... scopeNames)
-
addScope
public void addScope(ScopeRepresentation scope)
-
-