StrutsJspLogic.java

// license-header java merge-point
//
// Attention: generated code (by MetafacadeLogic.vsl) - do not modify!
//
package org.andromda.cartridges.bpm4struts.metafacades;

import java.util.Collection;
import java.util.List;
import org.andromda.core.common.Introspector;
import org.andromda.core.metafacade.MetafacadeBase;
import org.andromda.core.metafacade.MetafacadeFactory;
import org.andromda.core.metafacade.ModelValidationMessage;
import org.andromda.metafacades.uml.ActionFacade;
import org.andromda.metafacades.uml.ConstraintFacade;
import org.andromda.metafacades.uml.DependencyFacade;
import org.andromda.metafacades.uml.EventFacade;
import org.andromda.metafacades.uml.FrontEndAction;
import org.andromda.metafacades.uml.FrontEndExceptionHandler;
import org.andromda.metafacades.uml.FrontEndForward;
import org.andromda.metafacades.uml.FrontEndParameter;
import org.andromda.metafacades.uml.FrontEndUseCase;
import org.andromda.metafacades.uml.FrontEndView;
import org.andromda.metafacades.uml.ModelElementFacade;
import org.andromda.metafacades.uml.ModelFacade;
import org.andromda.metafacades.uml.OperationFacade;
import org.andromda.metafacades.uml.PackageFacade;
import org.andromda.metafacades.uml.PartitionFacade;
import org.andromda.metafacades.uml.StateFacade;
import org.andromda.metafacades.uml.StateMachineFacade;
import org.andromda.metafacades.uml.StereotypeFacade;
import org.andromda.metafacades.uml.TaggedValueFacade;
import org.andromda.metafacades.uml.TemplateParameterFacade;
import org.andromda.metafacades.uml.TransitionFacade;
import org.andromda.metafacades.uml.TypeMappings;
import org.apache.log4j.Logger;

/**
 * A Struts JSP represents a page in the web application. A page possibly contains several forms and
 * triggers (either buttons or hyperlinks) that call actions.
 * MetafacadeLogic for StrutsJsp
 *
 * @see StrutsJsp
 */
public abstract class StrutsJspLogic
    extends MetafacadeBase
    implements StrutsJsp
{
    /**
     * The underlying UML object
     * @see Object
     */
    protected Object metaObject;

    /** Create Metafacade implementation instance using the MetafacadeFactory from the context
     * @param metaObjectIn
     * @param context
     */
    protected StrutsJspLogic(Object metaObjectIn, String context)
    {
        super(metaObjectIn, getContext(context));
        this.superStrutsActionState =
           (StrutsActionState)
            MetafacadeFactory.getInstance().createFacadeImpl(
                    "org.andromda.cartridges.bpm4struts.metafacades.StrutsActionState",
                    metaObjectIn,
                    getContext(context));
        this.superFrontEndView =
           (FrontEndView)
            MetafacadeFactory.getInstance().createFacadeImpl(
                    "org.andromda.metafacades.uml.FrontEndView",
                    metaObjectIn,
                    getContext(context));
        this.metaObject = metaObjectIn;
    }

    /**
     * The logger instance.
     */
    private static final Logger logger = Logger.getLogger(StrutsJspLogic.class);

    /**
     * Gets the context for this metafacade logic instance.
     * @param context String. Set to StrutsJsp if null
     * @return context String
     */
    private static String getContext(String context)
    {
        if (context == null)
        {
            context = "org.andromda.cartridges.bpm4struts.metafacades.StrutsJsp";
        }
        return context;
    }

    private StrutsActionState superStrutsActionState;
    private boolean superStrutsActionStateInitialized = false;

    /**
     * Gets the StrutsActionState parent instance.
     * @return this.superStrutsActionState StrutsActionState
     */
    protected StrutsActionState getSuperStrutsActionState()
    {
        if (!this.superStrutsActionStateInitialized)
        {
            ((MetafacadeBase)this.superStrutsActionState).setMetafacadeContext(this.getMetafacadeContext());
            this.superStrutsActionStateInitialized = true;
        }
        return this.superStrutsActionState;
    }

    private FrontEndView superFrontEndView;
    private boolean superFrontEndViewInitialized = false;

    /**
     * Gets the FrontEndView parent instance.
     * @return this.superFrontEndView FrontEndView
     */
    protected FrontEndView getSuperFrontEndView()
    {
        if (!this.superFrontEndViewInitialized)
        {
            ((MetafacadeBase)this.superFrontEndView).setMetafacadeContext(this.getMetafacadeContext());
            this.superFrontEndViewInitialized = true;
        }
        return this.superFrontEndView;
    }

    /** Reset context only for non-root metafacades
     * @param context
     * @see org.andromda.core.metafacade.MetafacadeBase#resetMetafacadeContext(String context)
     */
    @Override
    public void resetMetafacadeContext(String context)
    {
        if (!this.contextRoot) // reset context only for non-root metafacades
        {
            context = getContext(context);  // to have same value as in original constructor call
            setMetafacadeContext (context);
            if (this.superStrutsActionStateInitialized)
            {
                ((MetafacadeBase)this.superStrutsActionState).resetMetafacadeContext(context);
            }
            if (this.superFrontEndViewInitialized)
            {
                ((MetafacadeBase)this.superFrontEndView).resetMetafacadeContext(context);
            }
        }
    }

    /**
     * @return boolean true always
     * @see StrutsJsp
     */
    public boolean isStrutsJspMetaType()
    {
        return true;
    }

    // --------------- attributes ---------------------

   /**
    * @see org.andromda.cartridges.bpm4struts.metafacades.StrutsJsp#getFullPath()
    * @return String
    */
    protected abstract String handleGetFullPath();

    private String __fullPath1a;
    private boolean __fullPath1aSet = false;

    /**
     * The full path to this JSP page. the returned String does not have a suffix such as '.jsp'.
     * @return (String)handleGetFullPath()
     */
    public final String getFullPath()
    {
        String fullPath1a = this.__fullPath1a;
        if (!this.__fullPath1aSet)
        {
            // fullPath has no pre constraints
            fullPath1a = handleGetFullPath();
            // fullPath has no post constraints
            this.__fullPath1a = fullPath1a;
            if (isMetafacadePropertyCachingEnabled())
            {
                this.__fullPath1aSet = true;
            }
        }
        return fullPath1a;
    }

   /**
    * @see org.andromda.cartridges.bpm4struts.metafacades.StrutsJsp#getTitleKey()
    * @return String
    */
    protected abstract String handleGetTitleKey();

    private String __titleKey2a;
    private boolean __titleKey2aSet = false;

    /**
     * A resource message key suited for the page's title.
     * @return (String)handleGetTitleKey()
     */
    public final String getTitleKey()
    {
        String titleKey2a = this.__titleKey2a;
        if (!this.__titleKey2aSet)
        {
            // titleKey has no pre constraints
            titleKey2a = handleGetTitleKey();
            // titleKey has no post constraints
            this.__titleKey2a = titleKey2a;
            if (isMetafacadePropertyCachingEnabled())
            {
                this.__titleKey2aSet = true;
            }
        }
        return titleKey2a;
    }

   /**
    * @see org.andromda.cartridges.bpm4struts.metafacades.StrutsJsp#getTitleValue()
    * @return String
    */
    protected abstract String handleGetTitleValue();

    private String __titleValue3a;
    private boolean __titleValue3aSet = false;

    /**
     * A default resource message value suited for the page's title.
     * @return (String)handleGetTitleValue()
     */
    public final String getTitleValue()
    {
        String titleValue3a = this.__titleValue3a;
        if (!this.__titleValue3aSet)
        {
            // titleValue has no pre constraints
            titleValue3a = handleGetTitleValue();
            // titleValue has no post constraints
            this.__titleValue3a = titleValue3a;
            if (isMetafacadePropertyCachingEnabled())
            {
                this.__titleValue3aSet = true;
            }
        }
        return titleValue3a;
    }

   /**
    * @see org.andromda.cartridges.bpm4struts.metafacades.StrutsJsp#getMessageKey()
    * @return String
    */
    protected abstract String handleGetMessageKey();

    private String __messageKey4a;
    private boolean __messageKey4aSet = false;

    /**
     * The default resource message key.
     * @return (String)handleGetMessageKey()
     */
    public final String getMessageKey()
    {
        String messageKey4a = this.__messageKey4a;
        if (!this.__messageKey4aSet)
        {
            // messageKey has no pre constraints
            messageKey4a = handleGetMessageKey();
            // messageKey has no post constraints
            this.__messageKey4a = messageKey4a;
            if (isMetafacadePropertyCachingEnabled())
            {
                this.__messageKey4aSet = true;
            }
        }
        return messageKey4a;
    }

   /**
    * @see org.andromda.cartridges.bpm4struts.metafacades.StrutsJsp#getDocumentationKey()
    * @return String
    */
    protected abstract String handleGetDocumentationKey();

    private String __documentationKey5a;
    private boolean __documentationKey5aSet = false;

    /**
     * A resource message key suited for the page's documentation.
     * @return (String)handleGetDocumentationKey()
     */
    public final String getDocumentationKey()
    {
        String documentationKey5a = this.__documentationKey5a;
        if (!this.__documentationKey5aSet)
        {
            // documentationKey has no pre constraints
            documentationKey5a = handleGetDocumentationKey();
            // documentationKey has no post constraints
            this.__documentationKey5a = documentationKey5a;
            if (isMetafacadePropertyCachingEnabled())
            {
                this.__documentationKey5aSet = true;
            }
        }
        return documentationKey5a;
    }

   /**
    * @see org.andromda.cartridges.bpm4struts.metafacades.StrutsJsp#getDocumentationValue()
    * @return String
    */
    protected abstract String handleGetDocumentationValue();

    private String __documentationValue6a;
    private boolean __documentationValue6aSet = false;

    /**
     * A resource message value suited for the page's documentation.
     * @return (String)handleGetDocumentationValue()
     */
    public final String getDocumentationValue()
    {
        String documentationValue6a = this.__documentationValue6a;
        if (!this.__documentationValue6aSet)
        {
            // documentationValue has no pre constraints
            documentationValue6a = handleGetDocumentationValue();
            // documentationValue has no post constraints
            this.__documentationValue6a = documentationValue6a;
            if (isMetafacadePropertyCachingEnabled())
            {
                this.__documentationValue6aSet = true;
            }
        }
        return documentationValue6a;
    }

   /**
    * @see org.andromda.cartridges.bpm4struts.metafacades.StrutsJsp#isValidationRequired()
    * @return boolean
    */
    protected abstract boolean handleIsValidationRequired();

    private boolean __validationRequired7a;
    private boolean __validationRequired7aSet = false;

    /**
     * True if at least one client/server parameter requires validation.
     * @return (boolean)handleIsValidationRequired()
     */
    public final boolean isValidationRequired()
    {
        boolean validationRequired7a = this.__validationRequired7a;
        if (!this.__validationRequired7aSet)
        {
            // validationRequired has no pre constraints
            validationRequired7a = handleIsValidationRequired();
            // validationRequired has no post constraints
            this.__validationRequired7a = validationRequired7a;
            if (isMetafacadePropertyCachingEnabled())
            {
                this.__validationRequired7aSet = true;
            }
        }
        return validationRequired7a;
    }

   /**
    * @see org.andromda.cartridges.bpm4struts.metafacades.StrutsJsp#isDateFieldPresent()
    * @return boolean
    */
    protected abstract boolean handleIsDateFieldPresent();

    private boolean __dateFieldPresent8a;
    private boolean __dateFieldPresent8aSet = false;

    /**
     * True if any of the actions have a parameter of type Date.
     * @return (boolean)handleIsDateFieldPresent()
     */
    public final boolean isDateFieldPresent()
    {
        boolean dateFieldPresent8a = this.__dateFieldPresent8a;
        if (!this.__dateFieldPresent8aSet)
        {
            // dateFieldPresent has no pre constraints
            dateFieldPresent8a = handleIsDateFieldPresent();
            // dateFieldPresent has no post constraints
            this.__dateFieldPresent8a = dateFieldPresent8a;
            if (isMetafacadePropertyCachingEnabled())
            {
                this.__dateFieldPresent8aSet = true;
            }
        }
        return dateFieldPresent8a;
    }

   /**
    * @see org.andromda.cartridges.bpm4struts.metafacades.StrutsJsp#isCalendarRequired()
    * @return boolean
    */
    protected abstract boolean handleIsCalendarRequired();

    private boolean __calendarRequired9a;
    private boolean __calendarRequired9aSet = false;

    /**
     * True if this JSP contains a date field which requires a calendar popup.
     * @return (boolean)handleIsCalendarRequired()
     */
    public final boolean isCalendarRequired()
    {
        boolean calendarRequired9a = this.__calendarRequired9a;
        if (!this.__calendarRequired9aSet)
        {
            // calendarRequired has no pre constraints
            calendarRequired9a = handleIsCalendarRequired();
            // calendarRequired has no post constraints
            this.__calendarRequired9a = calendarRequired9a;
            if (isMetafacadePropertyCachingEnabled())
            {
                this.__calendarRequired9aSet = true;
            }
        }
        return calendarRequired9a;
    }

   /**
    * @see org.andromda.cartridges.bpm4struts.metafacades.StrutsJsp#getOnlineHelpKey()
    * @return String
    */
    protected abstract String handleGetOnlineHelpKey();

    private String __onlineHelpKey10a;
    private boolean __onlineHelpKey10aSet = false;

    /**
     * The key to lookup the online help documentation. This documentation is gathered from the
     * documentation entered by the user, as well as analyzing the model.
     * @return (String)handleGetOnlineHelpKey()
     */
    public final String getOnlineHelpKey()
    {
        String onlineHelpKey10a = this.__onlineHelpKey10a;
        if (!this.__onlineHelpKey10aSet)
        {
            // onlineHelpKey has no pre constraints
            onlineHelpKey10a = handleGetOnlineHelpKey();
            // onlineHelpKey has no post constraints
            this.__onlineHelpKey10a = onlineHelpKey10a;
            if (isMetafacadePropertyCachingEnabled())
            {
                this.__onlineHelpKey10aSet = true;
            }
        }
        return onlineHelpKey10a;
    }

   /**
    * @see org.andromda.cartridges.bpm4struts.metafacades.StrutsJsp#getOnlineHelpValue()
    * @return String
    */
    protected abstract String handleGetOnlineHelpValue();

    private String __onlineHelpValue11a;
    private boolean __onlineHelpValue11aSet = false;

    /**
     * The online help documentation. This documentation is gathered from the documentation entered
     * by the user, as well as analyzing the model. The format is HTML without any style.
     * @return (String)handleGetOnlineHelpValue()
     */
    public final String getOnlineHelpValue()
    {
        String onlineHelpValue11a = this.__onlineHelpValue11a;
        if (!this.__onlineHelpValue11aSet)
        {
            // onlineHelpValue has no pre constraints
            onlineHelpValue11a = handleGetOnlineHelpValue();
            // onlineHelpValue has no post constraints
            this.__onlineHelpValue11a = onlineHelpValue11a;
            if (isMetafacadePropertyCachingEnabled())
            {
                this.__onlineHelpValue11aSet = true;
            }
        }
        return onlineHelpValue11a;
    }

   /**
    * @see org.andromda.cartridges.bpm4struts.metafacades.StrutsJsp#getMessageValue()
    * @return String
    */
    protected abstract String handleGetMessageValue();

    private String __messageValue12a;
    private boolean __messageValue12aSet = false;

    /**
     * A displayable version of this page's name.
     * @return (String)handleGetMessageValue()
     */
    public final String getMessageValue()
    {
        String messageValue12a = this.__messageValue12a;
        if (!this.__messageValue12aSet)
        {
            // messageValue has no pre constraints
            messageValue12a = handleGetMessageValue();
            // messageValue has no post constraints
            this.__messageValue12a = messageValue12a;
            if (isMetafacadePropertyCachingEnabled())
            {
                this.__messageValue12aSet = true;
            }
        }
        return messageValue12a;
    }

   /**
    * @see org.andromda.cartridges.bpm4struts.metafacades.StrutsJsp#getCssFileName()
    * @return String
    */
    protected abstract String handleGetCssFileName();

    private String __cssFileName13a;
    private boolean __cssFileName13aSet = false;

    /**
     * The name of the file containing specific styles for this page only.
     * @return (String)handleGetCssFileName()
     */
    public final String getCssFileName()
    {
        String cssFileName13a = this.__cssFileName13a;
        if (!this.__cssFileName13aSet)
        {
            // cssFileName has no pre constraints
            cssFileName13a = handleGetCssFileName();
            // cssFileName has no post constraints
            this.__cssFileName13a = cssFileName13a;
            if (isMetafacadePropertyCachingEnabled())
            {
                this.__cssFileName13aSet = true;
            }
        }
        return cssFileName13a;
    }

   /**
    * @see org.andromda.cartridges.bpm4struts.metafacades.StrutsJsp#getOnlineHelpActionPath()
    * @return String
    */
    protected abstract String handleGetOnlineHelpActionPath();

    private String __onlineHelpActionPath14a;
    private boolean __onlineHelpActionPath14aSet = false;

    /**
     * The full path to this JSP's online help action. The returned String does not have a suffix
     * such as '.do'.
     * @return (String)handleGetOnlineHelpActionPath()
     */
    public final String getOnlineHelpActionPath()
    {
        String onlineHelpActionPath14a = this.__onlineHelpActionPath14a;
        if (!this.__onlineHelpActionPath14aSet)
        {
            // onlineHelpActionPath has no pre constraints
            onlineHelpActionPath14a = handleGetOnlineHelpActionPath();
            // onlineHelpActionPath has no post constraints
            this.__onlineHelpActionPath14a = onlineHelpActionPath14a;
            if (isMetafacadePropertyCachingEnabled())
            {
                this.__onlineHelpActionPath14aSet = true;
            }
        }
        return onlineHelpActionPath14a;
    }

   /**
    * @see org.andromda.cartridges.bpm4struts.metafacades.StrutsJsp#getOnlineHelpPagePath()
    * @return String
    */
    protected abstract String handleGetOnlineHelpPagePath();

    private String __onlineHelpPagePath15a;
    private boolean __onlineHelpPagePath15aSet = false;

    /**
     * The full path to this JSP's online help page. The returned String does not have a suffix such
     * as '.jsp'.
     * @return (String)handleGetOnlineHelpPagePath()
     */
    public final String getOnlineHelpPagePath()
    {
        String onlineHelpPagePath15a = this.__onlineHelpPagePath15a;
        if (!this.__onlineHelpPagePath15aSet)
        {
            // onlineHelpPagePath has no pre constraints
            onlineHelpPagePath15a = handleGetOnlineHelpPagePath();
            // onlineHelpPagePath has no post constraints
            this.__onlineHelpPagePath15a = onlineHelpPagePath15a;
            if (isMetafacadePropertyCachingEnabled())
            {
                this.__onlineHelpPagePath15aSet = true;
            }
        }
        return onlineHelpPagePath15a;
    }

    // ------------- associations ------------------

    private List<StrutsForward> __getNonActionForwards1r;
    private boolean __getNonActionForwards1rSet = false;

    /**
     * A Struts JSP represents a page in the web application. A page possibly contains several forms
     * and
     * triggers (either buttons or hyperlinks) that call actions.
     * @return (List<StrutsForward>)handleGetNonActionForwards()
     */
    public final List<StrutsForward> getNonActionForwards()
    {
        List<StrutsForward> getNonActionForwards1r = this.__getNonActionForwards1r;
        if (!this.__getNonActionForwards1rSet)
        {
            // strutsJsp has no pre constraints
            List result = handleGetNonActionForwards();
            List shieldedResult = this.shieldedElements(result);
            try
            {
                getNonActionForwards1r = (List<StrutsForward>)shieldedResult;
            }
            catch (ClassCastException ex)
            {
                // Bad things happen if the metafacade type mapping in metafacades.xml is wrong - Warn
                StrutsJspLogic.logger.warn("incorrect metafacade cast for StrutsJspLogic.getNonActionForwards List<StrutsForward> " + result + ": " + shieldedResult);
            }
            // strutsJsp has no post constraints
            this.__getNonActionForwards1r = getNonActionForwards1r;
            if (isMetafacadePropertyCachingEnabled())
            {
                this.__getNonActionForwards1rSet = true;
            }
        }
        return getNonActionForwards1r;
    }

    /**
     * UML Specific type is returned in Collection, transformed by shieldedElements to AndroMDA Metafacade type
     * @return  List
     */
    protected abstract List handleGetNonActionForwards();

    private List<StrutsAction> __getIncomingActions2r;
    private boolean __getIncomingActions2rSet = false;

    /**
     * The set of pages that are a possible target of the triggering of this action.
     * @return (List<StrutsAction>)handleGetIncomingActions()
     */
    public final List<StrutsAction> getIncomingActions()
    {
        List<StrutsAction> getIncomingActions2r = this.__getIncomingActions2r;
        if (!this.__getIncomingActions2rSet)
        {
            // targetPages has no pre constraints
            List result = handleGetIncomingActions();
            List shieldedResult = this.shieldedElements(result);
            try
            {
                getIncomingActions2r = (List<StrutsAction>)shieldedResult;
            }
            catch (ClassCastException ex)
            {
                // Bad things happen if the metafacade type mapping in metafacades.xml is wrong - Warn
                StrutsJspLogic.logger.warn("incorrect metafacade cast for StrutsJspLogic.getIncomingActions List<StrutsAction> " + result + ": " + shieldedResult);
            }
            // targetPages has no post constraints
            this.__getIncomingActions2r = getIncomingActions2r;
            if (isMetafacadePropertyCachingEnabled())
            {
                this.__getIncomingActions2rSet = true;
            }
        }
        return getIncomingActions2r;
    }

    /**
     * UML Specific type is returned in Collection, transformed by shieldedElements to AndroMDA Metafacade type
     * @return  List
     */
    protected abstract List handleGetIncomingActions();

    private List<StrutsParameter> __getPageVariables3r;
    private boolean __getPageVariables3rSet = false;

    /**
     * A Struts JSP represents a page in the web application. A page possibly contains several forms
     * and
     * triggers (either buttons or hyperlinks) that call actions.
     * @return (List<StrutsParameter>)handleGetPageVariables()
     */
    public final List<StrutsParameter> getPageVariables()
    {
        List<StrutsParameter> getPageVariables3r = this.__getPageVariables3r;
        if (!this.__getPageVariables3rSet)
        {
            // strutsJsp has no pre constraints
            List result = handleGetPageVariables();
            List shieldedResult = this.shieldedElements(result);
            try
            {
                getPageVariables3r = (List<StrutsParameter>)shieldedResult;
            }
            catch (ClassCastException ex)
            {
                // Bad things happen if the metafacade type mapping in metafacades.xml is wrong - Warn
                StrutsJspLogic.logger.warn("incorrect metafacade cast for StrutsJspLogic.getPageVariables List<StrutsParameter> " + result + ": " + shieldedResult);
            }
            // strutsJsp has no post constraints
            this.__getPageVariables3r = getPageVariables3r;
            if (isMetafacadePropertyCachingEnabled())
            {
                this.__getPageVariables3rSet = true;
            }
        }
        return getPageVariables3r;
    }

    /**
     * UML Specific type is returned in Collection, transformed by shieldedElements to AndroMDA Metafacade type
     * @return  List
     */
    protected abstract List handleGetPageVariables();

    /**
     * @return true
     * @see StrutsActionState
     */
    public boolean isStrutsActionStateMetaType()
    {
        return true;
    }

    /**
     * @return true
     * @see FrontEndView
     */
    public boolean isFrontEndViewMetaType()
    {
        return true;
    }

    /**
     * @return true
     * @see org.andromda.metafacades.uml.FrontEndActionState
     */
    public boolean isFrontEndActionStateMetaType()
    {
        return true;
    }

    /**
     * @return true
     * @see org.andromda.metafacades.uml.ActionStateFacade
     */
    public boolean isActionStateFacadeMetaType()
    {
        return true;
    }

    /**
     * @return true
     * @see StateFacade
     */
    public boolean isStateFacadeMetaType()
    {
        return true;
    }

    /**
     * @return true
     * @see org.andromda.metafacades.uml.StateVertexFacade
     */
    public boolean isStateVertexFacadeMetaType()
    {
        return true;
    }

    /**
     * @return true
     * @see ModelElementFacade
     */
    public boolean isModelElementFacadeMetaType()
    {
        return true;
    }

    // ----------- delegates to StrutsActionState ------------
    /**
     * The entry action for this action state (if any).
     * @see org.andromda.metafacades.uml.ActionStateFacade#getEntry()
     */
    public ActionFacade getEntry()
    {
        return this.getSuperStrutsActionState().getEntry();
    }

    /**
     * The method name representing this action state.
     * @see org.andromda.metafacades.uml.FrontEndActionState#getActionMethodName()
     */
    public String getActionMethodName()
    {
        return this.getSuperStrutsActionState().getActionMethodName();
    }

    /**
     * The actions that pass through this action state.
     * @see org.andromda.metafacades.uml.FrontEndActionState#getContainerActions()
     */
    public List<FrontEndAction> getContainerActions()
    {
        return this.getSuperStrutsActionState().getContainerActions();
    }

    /**
     * All calls deferred to the controller by this action state.
     * @see org.andromda.metafacades.uml.FrontEndActionState#getControllerCalls()
     */
    public List<OperationFacade> getControllerCalls()
    {
        return this.getSuperStrutsActionState().getControllerCalls();
    }

    /**
     * All exceptions modelled on this action state.
     * @see org.andromda.metafacades.uml.FrontEndActionState#getExceptions()
     */
    public List<FrontEndExceptionHandler> getExceptions()
    {
        return this.getSuperStrutsActionState().getExceptions();
    }

    /**
     * The next transition, there can be only one transition going out of an action state, otherwise
     * decision points should be used (triggers are not supported at the server-side).
     * @see org.andromda.metafacades.uml.FrontEndActionState#getForward()
     */
    public FrontEndForward getForward()
    {
        return this.getSuperStrutsActionState().getForward();
    }

    /**
     * All calls deferred to the services by this action state.
     * @see org.andromda.metafacades.uml.FrontEndActionState#getServiceCalls()
     */
    public List<OperationFacade> getServiceCalls()
    {
        return this.getSuperStrutsActionState().getServiceCalls();
    }

    /**
     * True if this element is contained in a FrontEndUseCase.
     * @see org.andromda.metafacades.uml.FrontEndActionState#isContainedInFrontEndUseCase()
     */
    public boolean isContainedInFrontEndUseCase()
    {
        return this.getSuperStrutsActionState().isContainedInFrontEndUseCase();
    }

    /**
     * Indicates whether or not this front end action state is server side. Pages, for example, are
     * also action states but they return control to the client.
     * @see org.andromda.metafacades.uml.FrontEndActionState#isServerSide()
     */
    public boolean isServerSide()
    {
        return this.getSuperStrutsActionState().isServerSide();
    }

    /**
     * Copies all tagged values from the given ModelElementFacade to this model element facade.
     * @see ModelElementFacade#copyTaggedValues(ModelElementFacade element)
     */
    public void copyTaggedValues(ModelElementFacade element)
    {
        this.getSuperStrutsActionState().copyTaggedValues(element);
    }

    /**
     * Finds the tagged value with the specified 'tagName'. In case there are more values the first
     * one found will be returned.
     * @see ModelElementFacade#findTaggedValue(String tagName)
     */
    public Object findTaggedValue(String tagName)
    {
        return this.getSuperStrutsActionState().findTaggedValue(tagName);
    }

    /**
     * Returns all the values for the tagged value with the specified name. The returned collection
     * will contains only String instances, or will be empty. Never null.
     * @see ModelElementFacade#findTaggedValues(String tagName)
     */
    public Collection<Object> findTaggedValues(String tagName)
    {
        return this.getSuperStrutsActionState().findTaggedValues(tagName);
    }

    /**
     * Returns the fully qualified name of the model element. The fully qualified name includes
     * complete package qualified name of the underlying model element. The templates parameter will
     * be replaced by the correct one given the binding relation of the parameter to this element.
     * @see ModelElementFacade#getBindedFullyQualifiedName(ModelElementFacade bindedElement)
     */
    public String getBindedFullyQualifiedName(ModelElementFacade bindedElement)
    {
        return this.getSuperStrutsActionState().getBindedFullyQualifiedName(bindedElement);
    }

    /**
     * Gets all constraints belonging to the model element.
     * @see ModelElementFacade#getConstraints()
     */
    public Collection<ConstraintFacade> getConstraints()
    {
        return this.getSuperStrutsActionState().getConstraints();
    }

    /**
     * Returns the constraints of the argument kind that have been placed onto this model. Typical
     * kinds are "inv", "pre" and "post". Other kinds are possible.
     * @see ModelElementFacade#getConstraints(String kind)
     */
    public Collection<ConstraintFacade> getConstraints(String kind)
    {
        return this.getSuperStrutsActionState().getConstraints(kind);
    }

    /**
     * Gets the documentation for the model element, The indent argument is prefixed to each line.
     * By default this method wraps lines after 64 characters.
     * This method is equivalent to <code>getDocumentation(indent, 64)</code>.
     * @see ModelElementFacade#getDocumentation(String indent)
     */
    public String getDocumentation(String indent)
    {
        return this.getSuperStrutsActionState().getDocumentation(indent);
    }

    /**
     * This method returns the documentation for this model element, with the lines wrapped after
     * the specified number of characters, values of less than 1 will indicate no line wrapping is
     * required. By default paragraphs are returned as HTML.
     * This method is equivalent to <code>getDocumentation(indent, lineLength, true)</code>.
     * @see ModelElementFacade#getDocumentation(String indent, int lineLength)
     */
    public String getDocumentation(String indent, int lineLength)
    {
        return this.getSuperStrutsActionState().getDocumentation(indent, lineLength);
    }

    /**
     * This method returns the documentation for this model element, with the lines wrapped after
     * the specified number of characters, values of less than 1 will indicate no line wrapping is
     * required. HTML style determines if HTML Escaping is applied.
     * @see ModelElementFacade#getDocumentation(String indent, int lineLength, boolean htmlStyle)
     */
    public String getDocumentation(String indent, int lineLength, boolean htmlStyle)
    {
        return this.getSuperStrutsActionState().getDocumentation(indent, lineLength, htmlStyle);
    }

    /**
     * The fully qualified name of this model element.
     * @see ModelElementFacade#getFullyQualifiedName()
     */
    public String getFullyQualifiedName()
    {
        return this.getSuperStrutsActionState().getFullyQualifiedName();
    }

    /**
     * Returns the fully qualified name of the model element. The fully qualified name includes
     * complete package qualified name of the underlying model element.  If modelName is true, then
     * the original name of the model element (the name contained within the model) will be the name
     * returned, otherwise a name from a language mapping will be returned.
     * @see ModelElementFacade#getFullyQualifiedName(boolean modelName)
     */
    public String getFullyQualifiedName(boolean modelName)
    {
        return this.getSuperStrutsActionState().getFullyQualifiedName(modelName);
    }

    /**
     * Returns the fully qualified name as a path, the returned value always starts with out a slash
     * '/'.
     * @see ModelElementFacade#getFullyQualifiedNamePath()
     */
    public String getFullyQualifiedNamePath()
    {
        return this.getSuperStrutsActionState().getFullyQualifiedNamePath();
    }

    /**
     * Gets the unique identifier of the underlying model element.
     * @see ModelElementFacade#getId()
     */
    public String getId()
    {
        return this.getSuperStrutsActionState().getId();
    }

    /**
     * UML2: Retrieves the keywords for this element. Used to modify implementation properties which
     * are not represented by other properties, i.e. native, transient, volatile, synchronized,
     * (added annotations) override, deprecated. Can also be used to suppress compiler warnings:
     * (added annotations) unchecked, fallthrough, path, serial, finally, all. Annotations require
     * JDK5 compiler level.
     * @see ModelElementFacade#getKeywords()
     */
    public Collection<String> getKeywords()
    {
        return this.getSuperStrutsActionState().getKeywords();
    }

    /**
     * UML2: Retrieves a localized label for this named element.
     * @see ModelElementFacade#getLabel()
     */
    public String getLabel()
    {
        return this.getSuperStrutsActionState().getLabel();
    }

    /**
     * The language mappings that have been set for this model element.
     * @see ModelElementFacade#getLanguageMappings()
     */
    public TypeMappings getLanguageMappings()
    {
        return this.getSuperStrutsActionState().getLanguageMappings();
    }

    /**
     * Return the model containing this model element (multiple models may be loaded and processed
     * at the same time).
     * @see ModelElementFacade#getModel()
     */
    public ModelFacade getModel()
    {
        return this.getSuperStrutsActionState().getModel();
    }

    /**
     * The name of the model element.
     * @see ModelElementFacade#getName()
     */
    public String getName()
    {
        return this.getSuperStrutsActionState().getName();
    }

    /**
     * Gets the package to which this model element belongs.
     * @see ModelElementFacade#getPackage()
     */
    public ModelElementFacade getPackage()
    {
        return this.getSuperStrutsActionState().getPackage();
    }

    /**
     * The name of this model element's package.
     * @see ModelElementFacade#getPackageName()
     */
    public String getPackageName()
    {
        return this.getSuperStrutsActionState().getPackageName();
    }

    /**
     * Gets the package name (optionally providing the ability to retrieve the model name and not
     * the mapped name).
     * @see ModelElementFacade#getPackageName(boolean modelName)
     */
    public String getPackageName(boolean modelName)
    {
        return this.getSuperStrutsActionState().getPackageName(modelName);
    }

    /**
     * Returns the package as a path, the returned value always starts with out a slash '/'.
     * @see ModelElementFacade#getPackagePath()
     */
    public String getPackagePath()
    {
        return this.getSuperStrutsActionState().getPackagePath();
    }

    /**
     * UML2: Returns the value of the 'Qualified Name' attribute. A name which allows the
     * NamedElement to be identified within a hierarchy of nested Namespaces. It is constructed from
     * the names of the containing namespaces starting at the root of the hierarchy and ending with
     * the name of the NamedElement itself.
     * @see ModelElementFacade#getQualifiedName()
     */
    public String getQualifiedName()
    {
        return this.getSuperStrutsActionState().getQualifiedName();
    }

    /**
     * Gets the root package for the model element.
     * @see ModelElementFacade#getRootPackage()
     */
    public PackageFacade getRootPackage()
    {
        return this.getSuperStrutsActionState().getRootPackage();
    }

    /**
     * Gets the dependencies for which this model element is the source.
     * @see ModelElementFacade#getSourceDependencies()
     */
    public Collection<DependencyFacade> getSourceDependencies()
    {
        return this.getSuperStrutsActionState().getSourceDependencies();
    }

    /**
     * If this model element is the context of an activity graph, this represents that activity
     * graph.
     * @see ModelElementFacade#getStateMachineContext()
     */
    public StateMachineFacade getStateMachineContext()
    {
        return this.getSuperStrutsActionState().getStateMachineContext();
    }

    /**
     * The collection of ALL stereotype names for this model element.
     * @see ModelElementFacade#getStereotypeNames()
     */
    public Collection<String> getStereotypeNames()
    {
        return this.getSuperStrutsActionState().getStereotypeNames();
    }

    /**
     * Gets all stereotypes for this model element.
     * @see ModelElementFacade#getStereotypes()
     */
    public Collection<StereotypeFacade> getStereotypes()
    {
        return this.getSuperStrutsActionState().getStereotypes();
    }

    /**
     * Return the TaggedValues associated with this model element, under all stereotypes.
     * @see ModelElementFacade#getTaggedValues()
     */
    public Collection<TaggedValueFacade> getTaggedValues()
    {
        return this.getSuperStrutsActionState().getTaggedValues();
    }

    /**
     * Gets the dependencies for which this model element is the target.
     * @see ModelElementFacade#getTargetDependencies()
     */
    public Collection<DependencyFacade> getTargetDependencies()
    {
        return this.getSuperStrutsActionState().getTargetDependencies();
    }

    /**
     * Get the template parameter for this model element having the parameterName
     * @see ModelElementFacade#getTemplateParameter(String parameterName)
     */
    public Object getTemplateParameter(String parameterName)
    {
        return this.getSuperStrutsActionState().getTemplateParameter(parameterName);
    }

    /**
     * Get the template parameters for this model element
     * @see ModelElementFacade#getTemplateParameters()
     */
    public Collection<TemplateParameterFacade> getTemplateParameters()
    {
        return this.getSuperStrutsActionState().getTemplateParameters();
    }

    /**
     * The visibility (i.e. public, private, protected or package) of the model element, will
     * attempt a lookup for these values in the language mappings (if any).
     * @see ModelElementFacade#getVisibility()
     */
    public String getVisibility()
    {
        return this.getSuperStrutsActionState().getVisibility();
    }

    /**
     * Returns true if the model element has the exact stereotype (meaning no stereotype inheritance
     * is taken into account when searching for the stereotype), false otherwise.
     * @see ModelElementFacade#hasExactStereotype(String stereotypeName)
     */
    public boolean hasExactStereotype(String stereotypeName)
    {
        return this.getSuperStrutsActionState().hasExactStereotype(stereotypeName);
    }

    /**
     * Does the UML Element contain the named Keyword? Keywords can be separated by space, comma,
     * pipe, semicolon, or << >>
     * @see ModelElementFacade#hasKeyword(String keywordName)
     */
    public boolean hasKeyword(String keywordName)
    {
        return this.getSuperStrutsActionState().hasKeyword(keywordName);
    }

    /**
     * Returns true if the model element has the specified stereotype.  If the stereotype itself
     * does not match, then a search will be made up the stereotype inheritance hierarchy, and if
     * one of the stereotype's ancestors has a matching name this method will return true, false
     * otherwise.
     * For example, if we have a certain stereotype called <<exception>> and a model element has a
     * stereotype called <<applicationException>> which extends <<exception>>, when calling this
     * method with 'stereotypeName' defined as 'exception' the method would return true since
     * <<applicationException>> inherits from <<exception>>.  If you want to check if the model
     * element has the exact stereotype, then use the method 'hasExactStereotype' instead.
     * @see ModelElementFacade#hasStereotype(String stereotypeName)
     */
    public boolean hasStereotype(String stereotypeName)
    {
        return this.getSuperStrutsActionState().hasStereotype(stereotypeName);
    }

    /**
     * True if there are target dependencies from this element that are instances of BindingFacade.
     * Deprecated in UML2: Use TemplateBinding parameters instead of dependencies.
     * @see ModelElementFacade#isBindingDependenciesPresent()
     */
    public boolean isBindingDependenciesPresent()
    {
        return this.getSuperStrutsActionState().isBindingDependenciesPresent();
    }

    /**
     * Indicates if any constraints are present on this model element.
     * @see ModelElementFacade#isConstraintsPresent()
     */
    public boolean isConstraintsPresent()
    {
        return this.getSuperStrutsActionState().isConstraintsPresent();
    }

    /**
     * Indicates if any documentation is present on this model element.
     * @see ModelElementFacade#isDocumentationPresent()
     */
    public boolean isDocumentationPresent()
    {
        return this.getSuperStrutsActionState().isDocumentationPresent();
    }

    /**
     * True if this element name is a reserved word in Java, C#, ANSI or ISO C, C++, JavaScript.
     * @see ModelElementFacade#isReservedWord()
     */
    public boolean isReservedWord()
    {
        return this.getSuperStrutsActionState().isReservedWord();
    }

    /**
     * True is there are template parameters on this model element. For UML2, applies to Class,
     * Operation, Property, and Parameter.
     * @see ModelElementFacade#isTemplateParametersPresent()
     */
    public boolean isTemplateParametersPresent()
    {
        return this.getSuperStrutsActionState().isTemplateParametersPresent();
    }

    /**
     * True if this element name is a valid identifier name in Java, C#, ANSI or ISO C, C++,
     * JavaScript. Contains no spaces, special characters etc. Constraint always applied on
     * Enumerations and Interfaces, optionally applies on other model elements.
     * @see ModelElementFacade#isValidIdentifierName()
     */
    public boolean isValidIdentifierName()
    {
        return this.getSuperStrutsActionState().isValidIdentifierName();
    }

    /**
     * Searches for the constraint with the specified 'name' on this model element, and if found
     * translates it using the specified 'translation' from a translation library discovered by the
     * framework.
     * @see ModelElementFacade#translateConstraint(String name, String translation)
     */
    public String translateConstraint(String name, String translation)
    {
        return this.getSuperStrutsActionState().translateConstraint(name, translation);
    }

    /**
     * Translates all constraints belonging to this model element with the given 'translation'.
     * @see ModelElementFacade#translateConstraints(String translation)
     */
    public String[] translateConstraints(String translation)
    {
        return this.getSuperStrutsActionState().translateConstraints(translation);
    }

    /**
     * Translates the constraints of the specified 'kind' belonging to this model element.
     * @see ModelElementFacade#translateConstraints(String kind, String translation)
     */
    public String[] translateConstraints(String kind, String translation)
    {
        return this.getSuperStrutsActionState().translateConstraints(kind, translation);
    }

    /**
     * Events to which is being deferred in this action state.
     * @see StateFacade#getDeferrableEvents()
     */
    public Collection<EventFacade> getDeferrableEvents()
    {
        return this.getSuperStrutsActionState().getDeferrableEvents();
    }

    /**
     * Models a situation during which some (usually implicit) invariant condition holds. The states
     * of
     * protocol state machines are exposed to the users of their context classifiers. A protocol
     * state
     * represents an exposed stable situation of its context classifier: when an instance of the
     * classifier
     * is not processing any operation, users of this instance can always know its state
     * configuration.
     * @see org.andromda.metafacades.uml.StateVertexFacade#getContainer()
     */
    public StateFacade getContainer()
    {
        return this.getSuperStrutsActionState().getContainer();
    }

    /**
     * A directed relationship between a source vertex and a target vertex. It may be part of a
     * compound
     * transition, which takes the state machine from one state configuration to another,
     * representing the
     * complete response of the state machine to an occurrence of an event of a particular type.
     * @see org.andromda.metafacades.uml.StateVertexFacade#getIncomings()
     */
    public Collection<TransitionFacade> getIncomings()
    {
        return this.getSuperStrutsActionState().getIncomings();
    }

    /**
     * A directed relationship between a source vertex and a target vertex. It may be part of a
     * compound
     * transition, which takes the state machine from one state configuration to another,
     * representing the
     * complete response of the state machine to an occurrence of an event of a particular type.
     * @see org.andromda.metafacades.uml.StateVertexFacade#getOutgoings()
     */
    public Collection<TransitionFacade> getOutgoings()
    {
        return this.getSuperStrutsActionState().getOutgoings();
    }

    /**
     * The partition (if any) to which this vertex belongs.
     * @see org.andromda.metafacades.uml.StateVertexFacade#getPartition()
     */
    public PartitionFacade getPartition()
    {
        return this.getSuperStrutsActionState().getPartition();
    }

    /**
     * State machines can be used to express the behavior of part of a system. Behavior is modeled
     * as a
     * traversal of a graph of state nodes interconnected by one or more joined transition arcs that
     * are
     * triggered by the dispatching of series of (event) occurrences. During this traversal, the
     * state
     * machine executes a series of activities associated with various elements of the state
     * machine.
     * @see org.andromda.metafacades.uml.StateVertexFacade#getStateMachine()
     */
    public StateMachineFacade getStateMachine()
    {
        return this.getSuperStrutsActionState().getStateMachine();
    }

    // ----------- delegates to FrontEndView ------------
    /**
     * All actions that can be triggered on this view.
     * @see FrontEndView#getActions()
     */
    public List<FrontEndAction> getActions()
    {
        return this.getSuperFrontEndView().getActions();
    }

    /**
     * All parameters for each action going out of this view.
     * @see FrontEndView#getAllActionParameters()
     */
    public List<FrontEndParameter> getAllActionParameters()
    {
        return this.getSuperFrontEndView().getAllActionParameters();
    }

    /**
     * All fields from all forms on the given view.
     * @see FrontEndView#getAllFormFields()
     */
    public List<FrontEndParameter> getAllFormFields()
    {
        return this.getSuperFrontEndView().getAllFormFields();
    }

    /**
     * All tables belonging to the front end view.
     * @see FrontEndView#getTables()
     */
    public List<FrontEndParameter> getTables()
    {
        return this.getSuperFrontEndView().getTables();
    }

    /**
     * The use-case of which this view is a member.
     * @see FrontEndView#getUseCase()
     */
    public FrontEndUseCase getUseCase()
    {
        return this.getSuperFrontEndView().getUseCase();
    }

    /**
     * All those variables that will be present as variables in the target view. These are the
     * trigger parameters on the incoming transitions.
     * @see FrontEndView#getVariables()
     */
    public List<FrontEndParameter> getVariables()
    {
        return this.getSuperFrontEndView().getVariables();
    }

    /**
     * True if this element carries the FrontEndView stereotype.
     * @see FrontEndView#isFrontEndView()
     */
    public boolean isFrontEndView()
    {
        return this.getSuperFrontEndView().isFrontEndView();
    }

    /**
     * @see org.andromda.core.metafacade.MetafacadeBase#initialize()
     */
    @Override
    public void initialize()
    {
        this.getSuperStrutsActionState().initialize();
        this.getSuperFrontEndView().initialize();
    }

    /**
     * @return Object getSuperStrutsActionState().getValidationOwner()
     * @see org.andromda.core.metafacade.MetafacadeBase#getValidationOwner()
     */
    @Override
    public Object getValidationOwner()
    {
        Object owner = this.getSuperStrutsActionState().getValidationOwner();
        if (owner == null)
        {
            owner = this.getSuperFrontEndView().getValidationOwner();
        }
        return owner;
    }

    /**
     * @return String getSuperStrutsActionState().getValidationName()
     * @see org.andromda.core.metafacade.MetafacadeBase#getValidationName()
     */
    @Override
    public String getValidationName()
    {
        String name = this.getSuperStrutsActionState().getValidationName();
        if (name == null)
        {
            name = this.getSuperFrontEndView().getValidationName();
        }
        return name;
    }

    /**
     * @param validationMessages Collection<ModelValidationMessage>
     * @see org.andromda.core.metafacade.MetafacadeBase#validateInvariants(Collection validationMessages)
     */
    @Override
    public void validateInvariants(Collection<ModelValidationMessage> validationMessages)
    {
        this.getSuperStrutsActionState().validateInvariants(validationMessages);
        this.getSuperFrontEndView().validateInvariants(validationMessages);
    }

    /**
     * The property that stores the name of the metafacade.
     */
    private static final String NAME_PROPERTY = "name";
    private static final String FQNAME_PROPERTY = "fullyQualifiedName";

    /**
     * @see Object#toString()
     */
    @Override
    public String toString()
    {
        final StringBuilder toString = new StringBuilder(this.getClass().getName());
        toString.append("[");
        try
        {
            toString.append(Introspector.instance().getProperty(this, FQNAME_PROPERTY));
        }
        catch (final Throwable tryAgain)
        {
            try
            {
                toString.append(Introspector.instance().getProperty(this, NAME_PROPERTY));
            }
            catch (final Throwable ignore)
            {
                // - just ignore when the metafacade doesn't have a name or fullyQualifiedName property
            }
        }
        toString.append("]");
        return toString.toString();
    }
}