|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mycore.frontend.cli.MCRAbstractCommands
org.mycore.frontend.cli.MCRAccessCommands
public class MCRAccessCommands
This class provides a set of commands for the org.mycore.access management which can be used by the command line interface.
| Field Summary |
|---|
| Fields inherited from class org.mycore.frontend.cli.MCRAbstractCommands |
|---|
command, CONFIG |
| Constructor Summary | |
|---|---|
MCRAccessCommands()
The constructor. |
|
| Method Summary | |
|---|---|
static void |
createPermissionsFromFile(String filename)
This method sets the new permissions given in a certain file |
static void |
deleteAllPermissions()
delete all permissions |
static void |
deletePermission(String permission)
delete the permission {0} |
static void |
exportAllPermissionsToFile(String filename)
This method just export the permissions to a file |
static void |
listAllPermissions()
This method invokes MCRUserMgr.getAllPrivileges() and retrieves a ArrayList of all privileges stored in the persistent datastore. |
static void |
loadPermissionsFromFile(String filename)
This method deletes the old permissions (if given any) and sets the new permissions given in a certain file |
static void |
permissionDeleteAllForID(String id)
delete all permissions for a given id |
static void |
permissionDeleteAllForSelected()
delete all permissions for all selected objects |
static void |
permissionDeleteForID(String permission,
String id)
delete a given permission for a given id |
static void |
permissionDeleteForSelected(String permission)
delete all permissions for all selected objects |
static void |
permissionUpdateForID(String permission,
String id,
String strFileRule)
updates the permission for a given id and a given permission type with a given rule |
static void |
permissionUpdateForID(String permission,
String id,
String strFileRule,
String description)
updates the permission for a given id and a given permission type with a given rule |
static void |
permissionUpdateForSelected(String permission,
String strFileRule)
updates the permissions for all ids of a given MCRObjectID-Type with a given rule and a given permission |
static void |
permissionUpdateForSelected(String permission,
String strFileRule,
String description)
updates the permissions for all ids of a given MCRObjectID-Type and for a given permission type with a given rule |
| Methods inherited from class org.mycore.frontend.cli.MCRAbstractCommands |
|---|
getPossibleCommands |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MCRAccessCommands()
| Method Detail |
|---|
public static void createPermissionsFromFile(String filename)
filename - the filename of the file that contains the mcrpermissions
public static void loadPermissionsFromFile(String filename)
throws Exception
filename - the filename of the file that contains the mcrpermissions
Exception#updatePermissionsFromFile(String)
public static void deleteAllPermissions()
throws Exception
Exception
public static void deletePermission(String permission)
throws Exception
permission - the name of the permission
Exception
public static void listAllPermissions()
throws MCRException
MCRException
public static final void exportAllPermissionsToFile(String filename)
throws Exception
filename - the file written to
Exception
public static void permissionUpdateForID(String permission,
String id,
String strFileRule)
permission - String type of permission like read, writedb, etc.id - String the id of the object the rule is assigned tostrFileRule - String the path to the xml file, that contains the rule
public static void permissionUpdateForID(String permission,
String id,
String strFileRule,
String description)
permission - String type of permission like read, writedb, etc.id - String the id of the object the rule is assigned tostrFileRule - String the path to the xml file, that contains the ruledescription - String give a special description, if the semantics of your
rule is multiple used
public static void permissionUpdateForSelected(String permission,
String strFileRule)
permission - String type of permission like read, writedb, etc.documentType - String a MCRObjectID-Type like document, disshab, etc.strFileRule - String the path to the xml file, that contains the rule
public static void permissionUpdateForSelected(String permission,
String strFileRule,
String description)
permission - String type of permission like read, writedb, etc.documentType - String a MCRObjectID-Type like document, disshab, etc.strFileRule - String the path to the xml file, that contains the ruledescription - String give a special description, if the semantics of your
rule is multiple used
public static void permissionDeleteForID(String permission,
String id)
permission - String type of permission like read, writedb, etc.id - String the id of the object the rule is assigned topublic static void permissionDeleteAllForID(String id)
id - String the id of the object the rule is assigned topublic static void permissionDeleteForSelected(String permission)
permission - String type of permission like read, writedb, etc.MCRObjectCommands.getSelectedObjectIDs()public static void permissionDeleteAllForSelected()
MCRObjectCommands.getSelectedObjectIDs()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||