|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.dspace.app.xmlui.aspect.administrative.FlowContainerUtils
public class FlowContainerUtils
Utility methods to processes actions on Communities and Collections.
| Field Summary | |
|---|---|
static String |
ROLE_ADMIN
Possible Collection roles |
static String |
ROLE_DEFAULT_READ
|
static String |
ROLE_SUBMIT
|
static String |
ROLE_WF_STEP1
|
static String |
ROLE_WF_STEP2
|
static String |
ROLE_WF_STEP3
|
| Constructor Summary | |
|---|---|
FlowContainerUtils()
|
|
| Method Summary | |
|---|---|
static FlowResult |
changeCollectionDefaultReadToAnonymous(Context context,
int collectionID)
Change the default read priveleges to the anonymous group. |
static String |
checkXMLFragment(String value)
Check whether this metadata value is a proper XML fragment. |
static int |
createCollectionDefaultReadGroup(Context context,
int collectionID)
Change default privleges from the anonymous group to a new group that will be created and approrpate privleges assigned. |
static String |
escapeXMLEntities(String value)
Sanatize any XML that was inputed by the user, this will clean up any unescaped characters so that they can be stored as proper XML. |
static int |
getCollectionDefaultRead(Context context,
int collectionID)
Look up the id of a group authorized for one of the given roles. |
static int |
getCollectionRole(Context context,
int collectionID,
String roleName)
Look up the id of a group authorized for one of the given roles. |
static int |
getCommunityRole(Context context,
int communityID,
String roleName)
Look up the id of a group authorized for one of the given roles. |
static int |
getTemplateItemID(Context context,
int collectionID)
Look up the id of the template item for a given collection. |
static FlowResult |
processCreateCollection(Context context,
int communityID,
org.apache.cocoon.environment.Request request)
Create a new collection |
static FlowResult |
processCreateCommunity(Context context,
int communityID,
org.apache.cocoon.environment.Request request)
Create a new community |
static FlowResult |
processDeleteCollection(Context context,
int collectionID)
Delete collection itself |
static FlowResult |
processDeleteCollectionRole(Context context,
int collectionID,
String roleName,
int groupID)
Delete one of collection's roles |
static FlowResult |
processDeleteCommunity(Context context,
int communityID)
Delete community itself |
static FlowResult |
processDeleteCommunityRole(Context context,
int communityID,
String roleName,
int groupID)
Delete one of a community's roles |
static FlowResult |
processDeleteTemplateItem(Context context,
int collectionID)
Delete a collection's template item (which is not a member of the collection). |
static FlowResult |
processEditCollection(Context context,
int collectionID,
boolean deleteLogo,
org.apache.cocoon.environment.Request request)
Process the collection metadata edit form. |
static FlowResult |
processEditCommunity(Context context,
int communityID,
boolean deleteLogo,
org.apache.cocoon.environment.Request request)
Process the community metadata edit form. |
static FlowResult |
processReimportCollection(Context context,
int collectionID,
org.apache.cocoon.environment.Request request)
Purge the collection of all items, then run a fresh harvest cycle. |
static FlowResult |
processRunCollectionHarvest(Context context,
int collectionID,
org.apache.cocoon.environment.Request request)
Use the collection's harvest settings to immediately perform a harvest cycle. |
static FlowResult |
processSetupCollectionHarvesting(Context context,
int collectionID,
org.apache.cocoon.environment.Request request)
Process the collection harvesting options form. |
static FlowResult |
testOAISettings(Context context,
org.apache.cocoon.environment.Request request)
Test the supplied OAI settings. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String ROLE_ADMIN
public static final String ROLE_WF_STEP1
public static final String ROLE_WF_STEP2
public static final String ROLE_WF_STEP3
public static final String ROLE_SUBMIT
public static final String ROLE_DEFAULT_READ
| Constructor Detail |
|---|
public FlowContainerUtils()
| Method Detail |
|---|
public static FlowResult processEditCollection(Context context,
int collectionID,
boolean deleteLogo,
org.apache.cocoon.environment.Request request)
throws SQLException,
IOException,
AuthorizeException
context - The current DSpace context.collectionID - The collection id.deleteLogo - Determines if the logo should be deleted along with the metadata editing action.request - the Cocoon request object
SQLException
IOException
AuthorizeException
public static FlowResult processSetupCollectionHarvesting(Context context,
int collectionID,
org.apache.cocoon.environment.Request request)
throws SQLException,
IOException,
AuthorizeException
context - The current DSpace context.collectionID - The collection id.request - the Cocoon request object
SQLException
IOException
AuthorizeException
public static FlowResult processRunCollectionHarvest(Context context,
int collectionID,
org.apache.cocoon.environment.Request request)
throws SQLException,
IOException,
AuthorizeException,
CrosswalkException,
ParserConfigurationException,
SAXException,
TransformerException
context - The current DSpace context.collectionID - The collection id.request - the Cocoon request object
TransformerException
SAXException
ParserConfigurationException
CrosswalkException
SQLException
IOException
AuthorizeException
public static FlowResult processReimportCollection(Context context,
int collectionID,
org.apache.cocoon.environment.Request request)
throws SQLException,
IOException,
AuthorizeException,
CrosswalkException,
ParserConfigurationException,
SAXException,
TransformerException,
BrowseException
context - The current DSpace context.collectionID - The collection id.request - the Cocoon request object
TransformerException
SAXException
ParserConfigurationException
CrosswalkException
BrowseException
SQLException
IOException
AuthorizeException
public static FlowResult testOAISettings(Context context,
org.apache.cocoon.environment.Request request)
context - request -
public static int getTemplateItemID(Context context,
int collectionID)
throws SQLException,
AuthorizeException,
IOException
context - The current DSpace context.collectionID - The collection id.
IOException
SQLException
AuthorizeException
public static int getCollectionRole(Context context,
int collectionID,
String roleName)
throws SQLException,
AuthorizeException,
IOException
context - The current DSpace context.collectionID - The collection id.roleName - ADMIN, WF_STEP1, WF_STEP2, WF_STEP3, SUBMIT, DEFAULT_READ.
SQLException
AuthorizeException
IOException
public static FlowResult processDeleteCollectionRole(Context context,
int collectionID,
String roleName,
int groupID)
throws SQLException,
UIException,
IOException,
AuthorizeException
context - The current DSpace context.collectionID - The collection id.roleName - ADMIN, WF_STEP1, WF_STEP2, WF_STEP3, SUBMIT, DEFAULT_READ.groupID - The id of the group associated with this role.
SQLException
UIException
IOException
AuthorizeException
public static int getCollectionDefaultRead(Context context,
int collectionID)
throws SQLException,
AuthorizeException
context - The current DSpace context.collectionID - The collection id.roleName - ADMIN, WF_STEP1, WF_STEP2, WF_STEP3, SUBMIT, DEFAULT_READ.
SQLException
AuthorizeException
public static int createCollectionDefaultReadGroup(Context context,
int collectionID)
throws SQLException,
AuthorizeException,
UIException
context - The current DSpace context.collectionID - The collection id.
SQLException
AuthorizeException
UIException
public static FlowResult changeCollectionDefaultReadToAnonymous(Context context,
int collectionID)
throws SQLException,
AuthorizeException,
UIException
context - The current DSpace context.collectionID - The collection id.
SQLException
AuthorizeException
UIException
public static FlowResult processDeleteCollection(Context context,
int collectionID)
throws SQLException,
AuthorizeException,
IOException
context - The current DSpace context.collectionID - The collection id.
SQLException
AuthorizeException
IOException
public static FlowResult processCreateCollection(Context context,
int communityID,
org.apache.cocoon.environment.Request request)
throws SQLException,
AuthorizeException,
IOException
context - The current DSpace context.communityID - The id of the parent community.
SQLException
AuthorizeException
IOException
public static FlowResult processCreateCommunity(Context context,
int communityID,
org.apache.cocoon.environment.Request request)
throws AuthorizeException,
IOException,
SQLException
context - The current DSpace context.communityID - The id of the parent community (-1 for a top-level community).
AuthorizeException
IOException
SQLException
public static FlowResult processEditCommunity(Context context,
int communityID,
boolean deleteLogo,
org.apache.cocoon.environment.Request request)
throws AuthorizeException,
IOException,
SQLException
context - The current DSpace context.communityID - The community id.deleteLogo - Determines if the logo should be deleted along with the metadata editing action.request - the Cocoon request object
AuthorizeException
IOException
SQLException
public static FlowResult processDeleteCommunity(Context context,
int communityID)
throws SQLException,
AuthorizeException,
IOException
context - The current DSpace context.communityID - The community id.
SQLException
AuthorizeException
IOException
public static int getCommunityRole(Context context,
int communityID,
String roleName)
throws SQLException,
AuthorizeException,
IOException
context - The current DSpace context.collectionID - The collection id.roleName - ADMIN.
SQLException
AuthorizeException
IOException
public static FlowResult processDeleteCommunityRole(Context context,
int communityID,
String roleName,
int groupID)
throws SQLException,
UIException,
IOException,
AuthorizeException
context - The current DSpace context.communityID - The community id.roleName - ADMIN.groupID - The id of the group associated with this role.
SQLException
UIException
IOException
AuthorizeException
public static FlowResult processDeleteTemplateItem(Context context,
int collectionID)
throws SQLException,
AuthorizeException,
IOException
context - collectionID -
SQLException
AuthorizeException
IOExceptionpublic static String checkXMLFragment(String value)
value - The metadat's value
public static String escapeXMLEntities(String value)
value - The unsantized value
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||