DLESE Tools
v1.6.0

org.dlese.dpc.schemedit.action
Class FrameworkConfigAction

java.lang.Object
  extended by org.apache.struts.action.Action
      extended by org.dlese.dpc.schemedit.action.DCSAction
          extended by org.dlese.dpc.schemedit.action.AbstractSchemEditAction
              extended by org.dlese.dpc.schemedit.action.StandAloneSchemEditAction
                  extended by org.dlese.dpc.schemedit.action.FrameworkConfigAction

public final class FrameworkConfigAction
extends StandAloneSchemEditAction

Controller for the DcsDataFramework editor. As a stand-alone schemedit action, this supports framework-config files to be created and edited in a particular directory, and is not connected to the index or repository.

Author:
ostwald

$Id: FrameworkConfigAction.java,v 1.6 2009/03/20 23:33:55 jweather Exp $


Field Summary
 
Fields inherited from class org.dlese.dpc.schemedit.action.StandAloneSchemEditAction
recordsDir
 
Fields inherited from class org.dlese.dpc.schemedit.action.AbstractSchemEditAction
firstPage, homePage, xmlFormat
 
Fields inherited from class org.dlese.dpc.schemedit.action.DCSAction
accessManager, collectionRegistry, dcsDataManager, frameworkRegistry, ndrServiceEnabled, repositoryManager, repositoryService, requiredRole, sessionRegistry, userManager
 
Fields inherited from class org.apache.struts.action.Action
defaultLocale, servlet
 
Constructor Summary
FrameworkConfigAction()
           
 
Method Summary
 org.apache.struts.action.ActionForward execute(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, HttpServletRequest request, HttpServletResponse response)
          Place the name of the edited framework in the request before calling super.execute.
protected  File getFileToEdit(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, HttpServletRequest request, SchemaHelper schemaHelper)
          Gets the fileToEdit attribute of the StandAloneSchemEditAction object
protected  File getRecordsDir()
          Gets the recordsDir attribute of the StandAloneSchemEditAction object
protected  String getXmlFormat()
          Gets the xmlFormat attribute of the StandAloneSchemEditAction object
protected  org.apache.struts.action.ActionForward handleMissingCommand(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, HttpServletRequest request, HttpServletResponse response)
          Requests without a command forward control to the home page for this framework.
protected  void prtln(String s)
          Print a line to standard out.
protected  void putRecord(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, HttpServletRequest request)
          Saves a metadata record either to disk
 
Methods inherited from class org.dlese.dpc.schemedit.action.StandAloneSchemEditAction
getRemoteRecord, handleCancelRequest, handleChangeIdRequest, handleEditRequest, handleNewRecordRequest, handleOtherCommands, handleSaveRequest, saveRecord
 
Methods inherited from class org.dlese.dpc.schemedit.action.AbstractSchemEditAction
attachNewElement, getEditorMapping, getMetaDataFramework, getValidator, handleDeleteElement, handleExitCommand, handleGuardedExit, handleMissingLockException, handleTimedOutGuardedExit, isDocDirty, prtlnErr, uniqueUrlCheck, uniqueValueCheck
 
Methods inherited from class org.dlese.dpc.schemedit.action.DCSAction
getMetaDataFramework, getRequiredContextAttributeValue, getSessionBean, getSessionUser, getSessionUser, getSessionUserName, initializeFromContext
 
Methods 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
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FrameworkConfigAction

public FrameworkConfigAction()
Method Detail

getXmlFormat

protected String getXmlFormat()
Description copied from class: StandAloneSchemEditAction
Gets the xmlFormat attribute of the StandAloneSchemEditAction object

Overrides:
getXmlFormat in class StandAloneSchemEditAction
Returns:
The xmlFormat value

getRecordsDir

protected File getRecordsDir()
Description copied from class: StandAloneSchemEditAction
Gets the recordsDir attribute of the StandAloneSchemEditAction object

Overrides:
getRecordsDir in class StandAloneSchemEditAction
Returns:
The recordsDir value

execute

public org.apache.struts.action.ActionForward execute(org.apache.struts.action.ActionMapping mapping,
                                                      org.apache.struts.action.ActionForm form,
                                                      HttpServletRequest request,
                                                      HttpServletResponse response)
                                               throws IOException,
                                                      ServletException
Place the name of the edited framework in the request before calling super.execute.

Overrides:
execute in class StandAloneSchemEditAction
Parameters:
mapping - Description of the Parameter
form - Description of the Parameter
request - Description of the Parameter
response - Description of the Parameter
Returns:
Description of the Return Value
Throws:
IOException - Description of the Exception
ServletException - 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
Description copied from class: StandAloneSchemEditAction
Gets the fileToEdit attribute of the StandAloneSchemEditAction object

Overrides:
getFileToEdit in class StandAloneSchemEditAction
Parameters:
mapping - Description of the Parameter
form - Description of the Parameter
request - Description of the Parameter
schemaHelper - Description of the Parameter
Returns:
The fileToEdit value
Throws:
Exception - Description of the Exception

putRecord

protected void putRecord(org.apache.struts.action.ActionMapping mapping,
                         org.apache.struts.action.ActionForm form,
                         HttpServletRequest request)
                  throws Exception
Description copied from class: StandAloneSchemEditAction
Saves a metadata record either to disk

Overrides:
putRecord in class StandAloneSchemEditAction
Parameters:
mapping - Description of the Parameter
form - Description of the Parameter
request - Description of the Parameter
Throws:
Exception - if save operation is unsuccessful

handleMissingCommand

protected org.apache.struts.action.ActionForward handleMissingCommand(org.apache.struts.action.ActionMapping mapping,
                                                                      org.apache.struts.action.ActionForm form,
                                                                      HttpServletRequest request,
                                                                      HttpServletResponse response)
                                                               throws ServletException
Description copied from class: StandAloneSchemEditAction
Requests without a command forward control to the home page for this framework.

Overrides:
handleMissingCommand in class StandAloneSchemEditAction
Parameters:
mapping - Description of the Parameter
form - Description of the Parameter
request - Description of the Parameter
response - Description of the Parameter
Returns:
Description of the Return Value
Throws:
ServletException - Description of the Exception

prtln

protected void prtln(String s)
Description copied from class: StandAloneSchemEditAction
Print a line to standard out.

Overrides:
prtln in class StandAloneSchemEditAction
Parameters:
s - The String to print.

DLESE Tools
v1.6.0