Top Constructors Methods
org.apache.derby.impl.sql.execute

public abstract Class PrivilegeInfo

extends Object
Class Inheritance
Known Direct Subclasses
org.apache.derby.impl.sql.execute.RoutinePrivilegeInfo, org.apache.derby.impl.sql.execute.TablePrivilegeInfo, org.apache.derby.impl.sql.execute.GenericPrivilegeInfo
Imports
org.apache.derby.catalog.UUID, org.apache.derby.iapi.sql.dictionary.TupleDescriptor, .SchemaDescriptor, .DataDictionary, org.apache.derby.shared.common.sanity.SanityManager, org.apache.derby.iapi.sql.Activation, org.apache.derby.shared.common.reference.SQLState, org.apache.derby.shared.common.error.StandardException, java.util.List

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
protected void
addWarningIfPrivilegeNotRevoked(Activation activation, boolean
true if grant, false if revoke
grant
,
boolean
true, if at least one privilege has been revoked from a grantee, false otherwise
privileges_revoked
,
String
authorization id of the user
grantee
)

This method adds a warning if a revoke statement has not revoked any privileges from a grantee.

protected void
checkOwnership(String
authorizationId of current user
user
,
TupleDescriptor
object being checked against
objectDescriptor
,
SchemaDescriptor
SchemaDescriptor
sd
,
DataDictionary
DataDictionary
dd
)

Determines whether a user is the owner of an object (table, function, or procedure).

public abstract void
executeGrantRevoke(Activation activation, boolean
true if grant, false if revoke
grant
,
List<E>
a list of authorization ids (strings)
grantees
)

This is the guts of the Execution-time logic for GRANT/REVOKE

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

PrivilegeInfoback to summary
public PrivilegeInfo()

Method Detail

addWarningIfPrivilegeNotRevokedback to summary
protected void addWarningIfPrivilegeNotRevoked(Activation activation, boolean grant, boolean privileges_revoked, String grantee)

This method adds a warning if a revoke statement has not revoked any privileges from a grantee.

Parameters
grant:boolean

true if grant, false if revoke

privileges_revoked:boolean

true, if at least one privilege has been revoked from a grantee, false otherwise

grantee:String

authorization id of the user

checkOwnershipback to summary
protected void checkOwnership(String user, TupleDescriptor objectDescriptor, SchemaDescriptor sd, DataDictionary dd) throws StandardException

Determines whether a user is the owner of an object (table, function, or procedure). Note that Database Owner can access database objects without needing to be their owner

Parameters
user:String

authorizationId of current user

objectDescriptor:TupleDescriptor

object being checked against

sd:SchemaDescriptor

SchemaDescriptor

dd:DataDictionary

DataDictionary

Exceptions
StandardException:
if user does not own the object
executeGrantRevokeback to summary
public abstract void executeGrantRevoke(Activation activation, boolean grant, List<E> grantees) throws StandardException

This is the guts of the Execution-time logic for GRANT/REVOKE

Parameters
grant:boolean

true if grant, false if revoke

grantees:List<E>

a list of authorization ids (strings)

Exceptions
StandardException:
Thrown on failure