org.figure8.join.control.action
Class PhysicalEnvironmentActions

java.lang.Object
  extended by org.apache.struts.action.Action
      extended by org.figure8.join.control.JoinAction
          extended by org.figure8.join.control.action.PhysicalEnvironmentActions

public class PhysicalEnvironmentActions
extends JoinAction

Struts action used for managing physical environments within Join application.

Version:
$Revision: 1.3 $
Author:
Laurent Broudoux

Field Summary
static java.lang.String CHANGES_OP
          Operation code for getting environment configuration changes for tracking period
static java.lang.String CONFIG_OP
          Operation code for getting environment configuration details at specified date
static java.lang.String DETAILS_OP
          Operation code for getting details on a specified PhysicalEnvironment view
static java.lang.String DUPLICATE_ENVIRONMENT_KEY
          The request scope attribute under which is stored the PhysicalEnvironment that has raised a DuplicateEntityException during save of another one.
static java.lang.String ENVIRONMENT_KEY
          The session scope attribute under which the PhysicalEnvironment object currently selected by our logged-in User is stored.
static java.lang.String ENVIRONMENTS_KEY
          The request scope attribute under which the retrieved PhysicalEnvironments list is stored.
static java.lang.String LOAD_OP
          Operation code for loading a specific PhysicalEnvironment
static java.lang.String LOGICAL_ENVIRONMENT_KEY
          The request scope attribute under which the LogicalENvironment object selected is stored.
static java.lang.String SAVE_OP
          Operation code for saving a PhysicalEnvironment (create or update)
static java.lang.String TRACKING_VIEW_KEY
          The request scope attribute under which the configuration changes view for a tracking period is stored.
static java.lang.String VIEW_DATE_KEY
          The request scope attribute under which the date corresponding to environment configuration view is stored.
static java.lang.String VIEW_OP
          Operation code for accessing PhysicalEnvironment view screen
 
Fields inherited from class org.figure8.join.control.JoinAction
BODY_ATTRIBUTE, BODY_PARAMETER, EXCEPTION_KEY, GUI_KEY, OP_PARAMETER, REND_MAIN, REND_NONE, REND_PARAMETER, REND_POPUP, XHR_PARAMETER
 
Fields inherited from class org.apache.struts.action.Action
defaultLocale, servlet
 
Constructor Summary
PhysicalEnvironmentActions()
          Creates a new PhysicalEnvironmentActions.
 
Method Summary
 org.apache.struts.action.ActionForward doExecute(java.lang.String operation, org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Abstract method that subclasses must implement.
protected  org.apache.struts.action.ActionForward getEnvironmentChanges(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Load a specified physical environment from datastore and get its configuration changes during specified period (use startDate and endDate from form).
protected  org.apache.struts.action.ActionForward getEnvironmentConfigAtDate(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Load a specified physical environmnet from datastore ad get its configuration a precise datetime (use startDate, startHour and startMin from form).
protected  org.apache.struts.action.ActionForward getEnvironmentDetails(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Load a specified physical environment from datastore and fill form with it.
protected  org.apache.struts.action.ActionForward loadEnvironment(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Load a specified physical environment from datastore and fill form with it.
protected  org.apache.struts.action.ActionForward saveEnvironment(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Save a physical environment into datastore.
 void setEnvironmentManager(EnvironmentManager envManager)
           
 
Methods inherited from class org.figure8.join.control.JoinAction
execute, getUserContainer, isLoggedIn, isXhrRequest, removeObsoleteForm
 
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, saveMessages, saveMessages, saveToken, setLocale, setServlet
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOAD_OP

public static final java.lang.String LOAD_OP
Operation code for loading a specific PhysicalEnvironment

See Also:
Constant Field Values

SAVE_OP

public static final java.lang.String SAVE_OP
Operation code for saving a PhysicalEnvironment (create or update)

See Also:
Constant Field Values

VIEW_OP

public static final java.lang.String VIEW_OP
Operation code for accessing PhysicalEnvironment view screen

See Also:
Constant Field Values

DETAILS_OP

public static final java.lang.String DETAILS_OP
Operation code for getting details on a specified PhysicalEnvironment view

See Also:
Constant Field Values

CONFIG_OP

public static final java.lang.String CONFIG_OP
Operation code for getting environment configuration details at specified date

See Also:
Constant Field Values

CHANGES_OP

public static final java.lang.String CHANGES_OP
Operation code for getting environment configuration changes for tracking period

See Also:
Constant Field Values

ENVIRONMENT_KEY

public static final java.lang.String ENVIRONMENT_KEY
The session scope attribute under which the PhysicalEnvironment object currently selected by our logged-in User is stored.

See Also:
Constant Field Values

LOGICAL_ENVIRONMENT_KEY

public static final java.lang.String LOGICAL_ENVIRONMENT_KEY
The request scope attribute under which the LogicalENvironment object selected is stored.

See Also:
Constant Field Values

ENVIRONMENTS_KEY

public static final java.lang.String ENVIRONMENTS_KEY
The request scope attribute under which the retrieved PhysicalEnvironments list is stored.

See Also:
Constant Field Values

VIEW_DATE_KEY

public static final java.lang.String VIEW_DATE_KEY
The request scope attribute under which the date corresponding to environment configuration view is stored.

See Also:
Constant Field Values

TRACKING_VIEW_KEY

public static final java.lang.String TRACKING_VIEW_KEY
The request scope attribute under which the configuration changes view for a tracking period is stored.

See Also:
Constant Field Values

DUPLICATE_ENVIRONMENT_KEY

public static final java.lang.String DUPLICATE_ENVIRONMENT_KEY
The request scope attribute under which is stored the PhysicalEnvironment that has raised a DuplicateEntityException during save of another one.

See Also:
Constant Field Values
Constructor Detail

PhysicalEnvironmentActions

public PhysicalEnvironmentActions()
Creates a new PhysicalEnvironmentActions.

Method Detail

setEnvironmentManager

public void setEnvironmentManager(EnvironmentManager envManager)
Parameters:
envManager - The EnvironmentManager implementation instance to use

doExecute

public org.apache.struts.action.ActionForward doExecute(java.lang.String operation,
                                                        org.apache.struts.action.ActionMapping mapping,
                                                        org.apache.struts.action.ActionForm form,
                                                        javax.servlet.http.HttpServletRequest request,
                                                        javax.servlet.http.HttpServletResponse response)
                                                 throws java.lang.Exception
Description copied from class: JoinAction
Abstract method that subclasses must implement. The real execution must be done here according to the specified operation. ActionForward returned by execution should only point on page fragment : this superclass is responsible of including them within a whole page.

Specified by:
doExecute in class JoinAction
Parameters:
operation - String representing the operation to invoke on Action
mapping - Mapping between forwards name and path for this action
form - The form object containing request parameters
request - The servlet container request wrapper
response - The servlet container response wrapper
Returns:
A forward to the next view to render and display
Throws:
java.lang.Exception - such as InfraStructureExceptions ...

loadEnvironment

protected org.apache.struts.action.ActionForward loadEnvironment(org.apache.struts.action.ActionMapping mapping,
                                                                 org.apache.struts.action.ActionForm form,
                                                                 javax.servlet.http.HttpServletRequest request,
                                                                 javax.servlet.http.HttpServletResponse response)
                                                          throws java.lang.Exception
Load a specified physical environment from datastore and fill form with it.

Returns:
A forward to the next view to render and display
Throws:
java.lang.Exception

saveEnvironment

protected org.apache.struts.action.ActionForward saveEnvironment(org.apache.struts.action.ActionMapping mapping,
                                                                 org.apache.struts.action.ActionForm form,
                                                                 javax.servlet.http.HttpServletRequest request,
                                                                 javax.servlet.http.HttpServletResponse response)
                                                          throws java.lang.Exception
Save a physical environment into datastore. The Target may be an already existing one or a new one (this is indeed a create or update method).

Returns:
A forward to the next view to render and display
Throws:
java.lang.Exception

getEnvironmentDetails

protected org.apache.struts.action.ActionForward getEnvironmentDetails(org.apache.struts.action.ActionMapping mapping,
                                                                       org.apache.struts.action.ActionForm form,
                                                                       javax.servlet.http.HttpServletRequest request,
                                                                       javax.servlet.http.HttpServletResponse response)
                                                                throws java.lang.Exception
Load a specified physical environment from datastore and fill form with it.

Returns:
A forward to the next view to render and display
Throws:
java.lang.Exception

getEnvironmentConfigAtDate

protected org.apache.struts.action.ActionForward getEnvironmentConfigAtDate(org.apache.struts.action.ActionMapping mapping,
                                                                            org.apache.struts.action.ActionForm form,
                                                                            javax.servlet.http.HttpServletRequest request,
                                                                            javax.servlet.http.HttpServletResponse response)
                                                                     throws java.lang.Exception
Load a specified physical environmnet from datastore ad get its configuration a precise datetime (use startDate, startHour and startMin from form).

Returns:
A forward to the new view to render and display
Throws:
java.lang.Exception

getEnvironmentChanges

protected org.apache.struts.action.ActionForward getEnvironmentChanges(org.apache.struts.action.ActionMapping mapping,
                                                                       org.apache.struts.action.ActionForm form,
                                                                       javax.servlet.http.HttpServletRequest request,
                                                                       javax.servlet.http.HttpServletResponse response)
                                                                throws java.lang.Exception
Load a specified physical environment from datastore and get its configuration changes during specified period (use startDate and endDate from form).

Returns:
A forward to the next view to render and display
Throws:
java.lang.Exception


Copyright © 2005-2008 Join. All Rights Reserved.