Package net.sf.basedb.core
Class Job.SignalKeyring
java.lang.Object
net.sf.basedb.core.Keyring
net.sf.basedb.core.Job.SignalKeyring
- Enclosing class:
- Job
Our own keyring containing the permissions signal handlers may need
to update job status, eq. WRITE permission for JOBS. We also need
CREATE for MESSAGE and READ for USER.
All other permissions are denied.
-
Field Summary
Modifier and TypeFieldDescriptionprivate final int
private final int
private final int
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescription(package private) int
getAllPermissions
(Item itemType, UserData owner, ItemKeyData itemKey, ProjectKeyData projectKey) Return 0.Return empty set.Return empty set.Return empty set.Return empty map.(package private) boolean
Never reload since everything is static.(package private) int
getRolePermissions
(Item itemType) ReturnPermission.WRITE
ifitemType
=Item.JOB
,Permission.READ
ifItem.USER
andPermission.CREATE
ifItem.MESSAGE
or 0 otherwise.getRoles()
Return empty set.(package private) int
getSharedPermissions
(ShareableData sharableData) Return 0.getUsers()
Return empty set.Methods inherited from class net.sf.basedb.core.Keyring
getGroups, getInactiveRoles, getItemKeys, getMaxProjectPermission, getPluginPermissions, getProjectKeys, init, setActiveProject, setReload, setRoleInactive, unload
-
Field Details
-
createPermissions
private final int createPermissions -
readPermissions
private final int readPermissions -
writePermissions
private final int writePermissions -
emptySet
-
emptyMap
-
-
Constructor Details
-
SignalKeyring
SignalKeyring()
-
-
Method Details
-
getReload
boolean getReload()Never reload since everything is static. -
getRolePermissions
ReturnPermission.WRITE
ifitemType
=Item.JOB
,Permission.READ
ifItem.USER
andPermission.CREATE
ifItem.MESSAGE
or 0 otherwise.- Overrides:
getRolePermissions
in classKeyring
- Parameters:
itemType
- The item type as defined by theItem
class- Returns:
- The permission
-
getAllPermissions
int getAllPermissions(Item itemType, UserData owner, ItemKeyData itemKey, ProjectKeyData projectKey) Return 0.- Overrides:
getAllPermissions
in classKeyring
-
getRoles
Return empty set. -
getGroups
Return empty set. -
getUsers
Return empty set. -
getProjects
Return empty map.- Overrides:
getProjects
in classKeyring
-
getItemKeys
Return empty set. -
getProjectKeys
Return empty set.
-