com.sas.hls.security.privilege
Class Privilege

java.lang.Object
  extended by com.sas.hls.security.privilege.Privilege
All Implemented Interfaces:
Serializable, Comparable<Privilege>

public class Privilege
extends Object
implements Serializable, Comparable<Privilege>

A privilege represents a capability to perform some function or action in the system. A principal can be granted a privilege directly, or privileges can be combined into roles which are then associated with principals who are granted all the privileges in that role.

See Also:
Serialized Form

Constructor Summary
Privilege()
          Zero-arg constructor.
Privilege(String identifier, String name)
          Constructor specifying the name and identifier of this privilege.
 
Method Summary
 int compareTo(Privilege p)
           
 boolean equals(Object obj)
          Indicate whether some other object is "equal to" this one.
 String getIdentifier()
          Get the identifier value of this privilege.
 String getName()
          Get the name of this privilege.
 String getObjectType()
          Get the objectType of this privilege object.
 int hashCode()
          Return a hash code value for the object.
 void setIdentifier(String identifier)
          Set the identifier value of this privilege.
 void setName(String name)
          Set the name of this privilege.
 void setObjectType(String objectType)
          Set the objectType of this privilege object.
 String toString()
          Return a string representation of the object.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Privilege

public Privilege()
Zero-arg constructor.


Privilege

public Privilege(String identifier,
                 String name)
Constructor specifying the name and identifier of this privilege.

Parameters:
identifier - the identifier to user for this privilege
name - the name to use for this privilege
Method Detail

getIdentifier

public String getIdentifier()
Get the identifier value of this privilege.

Returns:
the identifier value of this privilege.

setIdentifier

public void setIdentifier(String identifier)
Set the identifier value of this privilege.

Parameters:
identifier - the identifier value of this privilege.

getName

public String getName()
Get the name of this privilege.

Returns:
the name of this privilege.

setName

public void setName(String name)
Set the name of this privilege.

Parameters:
name - the name to assign to this privilege.

getObjectType

public String getObjectType()
Get the objectType of this privilege object.

Returns:
the objectType

setObjectType

public void setObjectType(String objectType)
Set the objectType of this privilege object.

Parameters:
objectType - the objectType to set

hashCode

public int hashCode()
Return a hash code value for the object.

Overrides:
hashCode in class Object
See Also:
Object.hashCode()

equals

public boolean equals(Object obj)
Indicate whether some other object is "equal to" this one.

Overrides:
equals in class Object
See Also:
Object.equals(java.lang.Object)

toString

public String toString()
Return a string representation of the object.

Overrides:
toString in class Object
See Also:
Object.toString()

compareTo

public int compareTo(Privilege p)
Specified by:
compareTo in interface Comparable<Privilege>


Copyright (c) 2012, SAS Institute Inc., Cary, NC, USA