Package org.dlese.dpc.schemedit.action
Class CollectionConfigAction
java.lang.Object
org.apache.struts.action.Action
org.dlese.dpc.schemedit.action.DCSAction
org.dlese.dpc.schemedit.action.AbstractSchemEditAction
org.dlese.dpc.schemedit.action.StandAloneSchemEditAction
org.dlese.dpc.schemedit.action.CollectionConfigAction
Controller for the Collection Settings editor. Automatically reloads saved
config file so that changes take effect immediately.
- Author:
- ostwald
-
Field Summary
Fields inherited from class org.dlese.dpc.schemedit.action.StandAloneSchemEditAction
recordsDirFields inherited from class org.dlese.dpc.schemedit.action.AbstractSchemEditAction
firstPage, homePage, xmlFormatFields inherited from class org.dlese.dpc.schemedit.action.DCSAction
accessManager, collectionRegistry, dcsDataManager, frameworkRegistry, ndrServiceEnabled, repositoryManager, repositoryService, requiredRole, sessionRegistry, userManagerFields inherited from class org.apache.struts.action.Action
defaultLocale, servlet -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected FilegetFileToEdit(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, HttpServletRequest request, SchemaHelper schemaHelper) Gets the fileToEdit attribute of the CollectionConfigAction objectprotected FileGets the recordsDir attribute of the CollectionConfigAction objectprotected SchemEditValidatorgetValidator(org.apache.struts.action.ActionForm form, org.apache.struts.action.ActionMapping mapping, HttpServletRequest request) Gets the validator attribute of the CollectionConfigAction objectprotected StringGets the xmlFormat attribute of the CollectionConfigAction objectprotected org.apache.struts.action.ActionForwardhandleOtherCommands(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, HttpServletRequest request, HttpServletResponse response) handle commands specific to this controller, call the superclasses handleOtherCommands method if a command is not recognizedprotected org.apache.struts.action.ActionForwardhandleSaveRequest(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, HttpServletRequest request, HttpServletResponse response, SchemEditValidator validator) Write the saved config file to disk, and update NDR if this collection is registered with the NDR.protected voidPrint a line to standard out.protected voidNOT YET DOCUMENTEDMethods inherited from class org.dlese.dpc.schemedit.action.StandAloneSchemEditAction
execute, getRemoteRecord, handleCancelRequest, handleChangeIdRequest, handleEditRequest, handleMissingCommand, handleNewRecordRequest, putRecord, saveRecordMethods inherited from class org.dlese.dpc.schemedit.action.AbstractSchemEditAction
attachNewElement, getEditorMapping, getMetaDataFramework, handleDeleteElement, handleExitCommand, handleGuardedExit, handleMissingLockException, handleTimedOutGuardedExit, isDocDirty, uniqueUrlCheck, uniqueValueCheckMethods inherited from class org.dlese.dpc.schemedit.action.DCSAction
getMetaDataFramework, getRequiredContextAttributeValue, getSessionBean, getSessionUser, getSessionUser, getSessionUserName, initializeFromContextMethods inherited from class org.apache.struts.action.Action
addErrors, addMessages, execute, generateToken, getDataSource, getDataSource, getErrors, getLocale, getMessages, getResources, getResources, getServlet, isCancelled, isTokenValid, isTokenValid, resetToken, saveErrors, saveErrors, saveErrors, saveMessages, saveMessages, saveToken, setLocale, setServlet
-
Constructor Details
-
CollectionConfigAction
public CollectionConfigAction()
-
-
Method Details
-
getValidator
protected SchemEditValidator getValidator(org.apache.struts.action.ActionForm form, org.apache.struts.action.ActionMapping mapping, HttpServletRequest request) Gets the validator attribute of the CollectionConfigAction object- Overrides:
getValidatorin classAbstractSchemEditAction- Parameters:
form- Description of the Parametermapping- Description of the Parameterrequest- Description of the Parameter- Returns:
- The validator value
-
getRecordsDir
Gets the recordsDir attribute of the CollectionConfigAction object- Overrides:
getRecordsDirin classStandAloneSchemEditAction- Returns:
- The recordsDir value
-
getXmlFormat
Gets the xmlFormat attribute of the CollectionConfigAction object- Overrides:
getXmlFormatin classStandAloneSchemEditAction- Returns:
- The xmlFormat value
-
handleSaveRequest
protected org.apache.struts.action.ActionForward handleSaveRequest(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, HttpServletRequest request, HttpServletResponse response, SchemEditValidator validator) throws ServletException, MissingLockException Write the saved config file to disk, and update NDR if this collection is registered with the NDR.- Overrides:
handleSaveRequestin classStandAloneSchemEditAction- Parameters:
mapping- the ActionMappingform- the ActionFormrequest- the Requestresponse- the Responsevalidator- the special validator for configs- Returns:
- Description of the Return Value
- Throws:
ServletException- Description of the ExceptionMissingLockException- if this config is currently being edited by someone else
-
handleOtherCommands
protected org.apache.struts.action.ActionForward handleOtherCommands(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, HttpServletRequest request, HttpServletResponse response) throws ServletException, MissingLockException handle commands specific to this controller, call the superclasses handleOtherCommands method if a command is not recognized- Overrides:
handleOtherCommandsin classStandAloneSchemEditAction- Parameters:
mapping- Description of the Parameterform- Description of the Parameterrequest- Description of the Parameterresponse- Description of the Parameter- Returns:
- Description of the Return Value
- Throws:
ServletException- Description of the ExceptionMissingLockException- Description of the Exception
-
getFileToEdit
protected File getFileToEdit(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, HttpServletRequest request, SchemaHelper schemaHelper) throws Exception Gets the fileToEdit attribute of the CollectionConfigAction object- Overrides:
getFileToEditin classStandAloneSchemEditAction- Parameters:
mapping- Description of the Parameterform- Description of the Parameterrequest- Description of the ParameterschemaHelper- Description of the Parameter- Returns:
- The fileToEdit value
- Throws:
Exception- Description of the Exception
-
prtln
Print a line to standard out.- Overrides:
prtlnin classStandAloneSchemEditAction- Parameters:
s- The String to print.
-
prtlnErr
NOT YET DOCUMENTED- Overrides:
prtlnErrin classAbstractSchemEditAction- Parameters:
s- NOT YET DOCUMENTED
-