org.jclouds.openstack.keystone.v2_0.domain
Class Role

java.lang.Object
  extended by org.jclouds.openstack.keystone.v2_0.domain.Role
All Implemented Interfaces:
Comparable<Role>

public class Role
extends Object
implements Comparable<Role>

A personality that a user assumes when performing a specific set of operations. A role includes a set of right and privileges. A user assuming that role inherits those rights and privileges.

In Keystone, a token that is issued to a user includes the list of roles that user can assume. Services that are being called by that user determine how they interpret the set of roles a user has and which operations or resources each roles grants access to.

Author:
AdrianCole
See Also:

Nested Class Summary
static class Role.Builder
           
 
Field Summary
protected  String id
           
protected  String name
           
protected  String serviceId
           
protected  String tenantId
           
protected  String tenantName
          Deprecated. 
 
Constructor Summary
protected Role(String id, String name, String serviceId, String tenantId)
           
 
Method Summary
static Role.Builder builder()
           
 int compareTo(Role that)
           
 boolean equals(Object object)
           
 String getId()
          When providing an ID, it is assumed that the role exists in the current OpenStack deployment
 String getName()
           
 String getServiceId()
           
 String getTenantId()
           
 int hashCode()
           
 Role.Builder toBuilder()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

id

protected final String id

name

protected final String name

serviceId

protected final String serviceId

tenantName

@Deprecated
protected String tenantName
Deprecated. 

tenantId

protected final String tenantId
Constructor Detail

Role

protected Role(String id,
               String name,
               @Nullable
               String serviceId,
               @Nullable
               String tenantId)
Method Detail

builder

public static Role.Builder builder()

toBuilder

public Role.Builder toBuilder()

getId

public String getId()
When providing an ID, it is assumed that the role exists in the current OpenStack deployment

Returns:
the id of the role in the current OpenStack deployment

getName

public String getName()
Returns:
the name of the role

getServiceId

@Nullable
public String getServiceId()
Returns:
the service id of the role or null, if not present

getTenantId

@Nullable
public String getTenantId()
Returns:
the tenant id of the role or null, if not present

equals

public boolean equals(Object object)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

toString

public String toString()
Overrides:
toString in class Object

compareTo

public int compareTo(Role that)
Specified by:
compareTo in interface Comparable<Role>


Copyright © 2009-2012 jclouds. All Rights Reserved.