public class ResourceAdapter extends AbstractMongoAdapter<ResourceEntity> implements Resource
invocationContext
Constructor and Description |
---|
ResourceAdapter(ResourceEntity entity,
MongoStoreInvocationContext invocationContext,
AuthorizationProvider authorizationProvider) |
Modifier and Type | Method and Description |
---|---|
String |
getIconUri()
Returns an icon
URI for this resource. |
String |
getId()
Returns the unique identifier for this instance.
|
protected ResourceEntity |
getMongoEntity() |
String |
getName()
Returns the resource's name.
|
String |
getOwner()
Returns the resource's owner, which is usually an identifier that uniquely identifies the resource's owner.
|
ResourceServer |
getResourceServer()
Returns the
ResourceServer to where this resource belongs to. |
List<Scope> |
getScopes()
|
String |
getType()
Returns a string representing the type of this resource.
|
String |
getUri()
Returns a
URI that uniquely identify this resource. |
void |
setIconUri(String iconUri)
Sets an icon
URI for this resource. |
void |
setName(String name)
Sets a name for this resource.
|
void |
setType(String type)
Sets a string representing the type of this resource.
|
void |
setUri(String uri)
Sets a
URI that uniquely identify this resource. |
void |
updateScopes(Set<Scope> scopes) |
equals, getMongoStore, hashCode, updateMongoEntity
public ResourceAdapter(ResourceEntity entity, MongoStoreInvocationContext invocationContext, AuthorizationProvider authorizationProvider)
public String getId()
Resource
public String getName()
Resource
public void setName(String name)
Resource
public String getUri()
Resource
URI
that uniquely identify this resource.public void setUri(String uri)
Resource
URI
that uniquely identify this resource.public String getType()
Resource
public void setType(String type)
Resource
public String getIconUri()
Resource
URI
for this resource.getIconUri
in interface Resource
public void setIconUri(String iconUri)
Resource
URI
for this resource.setIconUri
in interface Resource
public ResourceServer getResourceServer()
Resource
ResourceServer
to where this resource belongs to.getResourceServer
in interface Resource
public String getOwner()
Resource
public void updateScopes(Set<Scope> scopes)
updateScopes
in interface Resource
protected ResourceEntity getMongoEntity()
getMongoEntity
in class AbstractMongoAdapter<ResourceEntity>
Copyright © 2016 JBoss by Red Hat. All rights reserved.