|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.mckoi.database.Privileges
public class Privileges
A set of privileges to grant a user for an object.
Field Summary | |
---|---|
static int |
ALL
The priv to allow full access to the database object. |
static int |
ALTER
The priv to alter objects (only applicable for SCHEMA grant objects). |
static int |
COMPACT
The priv to compact a database object. |
static int |
CREATE
The priv to create objects (only applicable for SCHEMA grant objects). |
static int |
DELETE
The priv to DELETE from a database object. |
static int |
DROP
The priv to drop objects (only applicable for SCHEMA grant objects). |
static Privileges |
EMPTY_PRIVS
No privileges. |
static int |
INSERT
The priv to INSERT to a database object. |
static int |
LIST
The priv to view objects in a schema (only applicable for SCHEMA grant objects). |
static Privileges |
PROCEDURE_ALL_PRIVS
All access (execute/update/delete/etc) privs for a procedure object. |
static Privileges |
PROCEDURE_EXECUTE_PRIVS
Execute access privs for a procedure object. |
static int |
REFERENCES
The priv to REFERENCE a database object. |
static Privileges |
SCHEMA_ALL_PRIVS
All access privs for a schema object. |
static Privileges |
SCHEMA_READ_PRIVS
Read access privs for a schema object. |
static int |
SELECT
The priv to SELECT from a database object. |
static Privileges |
TABLE_ALL_PRIVS
Enable all privs for the object. |
static Privileges |
TABLE_READ_PRIVS
Read privs for the object. |
static int |
UPDATE
The priv to UPDATE a database object. |
static int |
USAGE
The priv to see statistics on a database object. |
Constructor Summary | |
---|---|
Privileges()
|
Method Summary | |
---|---|
Privileges |
add(int priv)
Adds a privilege and returns a new Privileges object with the new priv set. |
boolean |
equals(java.lang.Object ob)
|
boolean |
isEmpty()
Returns true if this Privileges object contains no priv entries. |
Privileges |
merge(Privileges in_privs)
Merges privs from the given privilege object with this set of privs. |
static int |
parseString(java.lang.String priv)
Given a string, returns the priv bit for it. |
boolean |
permits(int priv)
Returns true if this privileges permits the given priv. |
Privileges |
remove(int priv)
Removes a privilege with a column list parameter. |
Privileges |
remove(Privileges privs)
Removes the given privileges from this privileges object and returns the new privileges object. |
java.lang.String |
toEncodedString()
Converts this privilege to an encoded string. |
int |
toInt()
Returns this Privileges object as an encoded int bit array. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int ALL
public static final int SELECT
public static final int DELETE
public static final int UPDATE
public static final int INSERT
public static final int REFERENCES
public static final int USAGE
public static final int COMPACT
public static final int CREATE
public static final int ALTER
public static final int DROP
public static final int LIST
public static final Privileges EMPTY_PRIVS
public static final Privileges TABLE_ALL_PRIVS
public static final Privileges TABLE_READ_PRIVS
public static final Privileges SCHEMA_ALL_PRIVS
public static final Privileges SCHEMA_READ_PRIVS
public static final Privileges PROCEDURE_ALL_PRIVS
public static final Privileges PROCEDURE_EXECUTE_PRIVS
Constructor Detail |
---|
public Privileges()
Method Detail |
---|
public Privileges add(int priv)
public Privileges remove(int priv)
public Privileges remove(Privileges privs)
public boolean permits(int priv)
public Privileges merge(Privileges in_privs)
public boolean isEmpty()
public static int parseString(java.lang.String priv)
public int toInt()
public java.lang.String toEncodedString()
public java.lang.String toString()
toString
in class java.lang.Object
public boolean equals(java.lang.Object ob)
equals
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |