com.ibm.commerce.struts

Class ECActionMapping

  • java.lang.Object
    • org.apache.struts.config.ActionConfig
      • org.apache.struts.action.ActionMapping
        • com.ibm.commerce.struts.ECActionMapping
  • All Implemented Interfaces:
    com.ibm.commerce.adapter.HttpRequestAttributes, java.io.Serializable
    Direct Known Subclasses:
    GiftRegistryActionMapping


    public class ECActionMapping
    extends org.apache.struts.action.ActionMapping
    implements com.ibm.commerce.adapter.HttpRequestAttributes
    This class defines a customized action mapping class for passing custom properties to actions that is required by the BaseAction class. The custom properties are:
    https
    A value of 1 indicates that the request was expected to be received on a secure channel (HTTPS). A redirect to the SSL port will be issued if it has been received on an insecure channel (HTTP).
    authenticate
    This indicates whether the request can be executed by a generic user or only a user who has a discernible identity. In other words, it can be executed by a guest or registered but not generic user.
    defaultProperties
    name/value pairs in the form of an HTTP request query string
    The defaultProperties property provides a generic way to define other properties to be passed to the BaseAction class.
    See Also:
    Serialized Form
    • Constructor Summary

      Constructors 
      Constructor and Description
      ECActionMapping()
      This is the default constructor for this class.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      org.apache.struts.action.ActionForward findForward(java.lang.String name)
      Find and return the ForwardConfig instance defining how forwarding to the specified logical name should be handled.
      java.lang.String getAuthenticate()
      This method gets the value of the authenticate property.
      java.lang.String getCredentialsAccepted()
      This method returns the flag that represents the type of authentication that is required to access the forward.
      java.lang.String getCredentialsAccepted(java.lang.Integer storeId)
      This method returns the flag that represents the type of authentication that is required to access the forward.
      java.lang.String getCsrfProtected()
      This method gets the value of the csrfProtected property.
      java.lang.String getCsrfProtected(java.lang.Integer storeId)
      This method gets the value of the csrfProtected property for a given store.
      java.lang.String getDefaultProperties()
      This method gets the value of the defaultProperties property.
      java.lang.String getDefaultProperties(java.lang.Integer storeId)
      This method gets the value of the defaultProperties property for a given store.
      java.lang.String getGenerateLTPAToken()
      This method gets the value of the generateLTPAToken property.
      java.lang.String getGenerateLTPAToken(java.lang.Integer storeId)
      This method gets the value of the generateLTPAToken property for a given store.
      java.lang.String getHttps()
      This method gets the value of the HTTPS property.
      java.lang.String getHttps(java.lang.Integer storeId)
      This method gets the value of the HTTPS property for a given store.
      int getHttpValue(java.lang.Integer storeId)
      This method returns the value of the HTTPS property for a given store.
      java.lang.String getRemoveLTPAToken()
      This method gets the value of the removeLTPAToken property.
      java.lang.String getRemoveLTPAToken(java.lang.Integer storeId)
      This method gets the value of the removeLTPAToken property for a given store.
      java.lang.String getSaveToken()
      This method gets the value of the saveToken property.
      java.util.List getStoreIdList()
      This method gets the list of the store ID values that are included in this action mapping.
      java.lang.String getValidateToken()
      This method gets the value of the validateToken property.
      java.lang.String getVcProtected()
      This method gets the value of the vcProtected property.
      java.lang.String getVcProtected(java.lang.Integer storeId)
      This method gets the value of the vcProtected property for a given store.
      boolean isAuthenticate(java.lang.Integer storeId)
      This method determines whether the authenticate property is set for a given store.
      boolean isCrossSiteScriptingForgeryProtected(java.lang.Integer storeId)
      This method determines whether the csrfProtected property is set for a given store.
      boolean isGenerateLTPAToken(java.lang.Integer storeId)
      This method determines whether the generateLTPAToken property is set for a given store.
      boolean isHttps(java.lang.Integer storeId)
      This method determines whether the HTTPS property is set for a given store.
      boolean isRemoveLTPAToken(java.lang.Integer storeId)
      This method determines whether the removeLTPAToken property is set for a given store.
      boolean isSaveToken(java.lang.Integer storeId)
      This method checks whether the saveToken property is set for a given store.
      boolean isValidateToken(java.lang.Integer storeId)
      This method determines whether the validateToken property is set for a given store.
      boolean isVerficationCodeProtected(java.lang.Integer storeId)
      This method determines whether the vcProtected property is set for a given store.
      void merge(org.apache.struts.config.ActionConfig actionConfig)
      This method merges the content of the specified action configuration object with the current object.
      void setAuthenticate(java.lang.String value)
      This method sets the value of the authenticate property.
      void setCredentialsAccepted(java.lang.String value)
      This method sets the flag that determines whether or not a user that is partially authenticated is allowed to access this URL.
      void setCsrfProtected(java.lang.String value)
      This method sets the value of the csrfProtected property.
      void setDefaultProperties(java.lang.String value)
      This method sets the value of the defaultProperties property.
      void setGenerateLTPAToken(java.lang.String value)
      This method sets the value of the generateLTPAToken property.
      void setHttps(java.lang.String value)
      This method sets the value of the HTTPS property.
      void setRemoveLTPAToken(java.lang.String value)
      This method sets the value of the removeLTPAToken property.
      void setSaveToken(java.lang.String value)
      This method sets the value of the saveToken property.
      void setValidateToken(java.lang.String value)
      This method sets the value of the validateToken property.
      void setVcProtected(java.lang.String value)
      This method sets the value of the vcProtected property.
      java.lang.String toString()
      This method returns the String representation of this action mapping.
      • Methods inherited from class org.apache.struts.action.ActionMapping

        findForwards, getInputForward
      • Methods inherited from class org.apache.struts.config.ActionConfig

        addExceptionConfig, addForwardConfig, findException, findExceptionConfig, findExceptionConfigs, findForwardConfig, findForwardConfigs, freeze, getAttribute, getCancellable, getForward, getInclude, getInput, getModuleConfig, getMultipartClass, getName, getParameter, getPath, getPrefix, getRoleNames, getRoles, getScope, getSuffix, getType, getUnknown, getValidate, removeExceptionConfig, removeForwardConfig, setAttribute, setCancellable, setForward, setInclude, setInput, setModuleConfig, setMultipartClass, setName, setParameter, setPath, setPrefix, setRoles, setScope, setSuffix, setType, setUnknown, setValidate
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • ECActionMapping

        public ECActionMapping()
        This is the default constructor for this class. It calls the constructor from the superclass.
    • Method Detail

      • getStoreIdList

        public java.util.List getStoreIdList()
        This method gets the list of the store ID values that are included in this action mapping.
        Returns:
        The list of the store ID values that are included in this action mapping.
      • setHttps

        public void setHttps(java.lang.String value)
        This method sets the value of the HTTPS property.
        Parameters:
        value - A value of 1 means "set to true"
      • setAuthenticate

        public void setAuthenticate(java.lang.String value)
        This method sets the value of the authenticate property.
        Parameters:
        value - A value of 1 means "set to true".
      • setValidateToken

        public void setValidateToken(java.lang.String value)
        This method sets the value of the validateToken property.
        Parameters:
        value - A value of 1 means "validate".
      • setCsrfProtected

        public void setCsrfProtected(java.lang.String value)
        This method sets the value of the csrfProtected property.
        Parameters:
        value - A value of 1 means "set to true".
      • setVcProtected

        public void setVcProtected(java.lang.String value)
        This method sets the value of the vcProtected property.
        Parameters:
        value - A value of 1 means "set to true".
      • setGenerateLTPAToken

        public void setGenerateLTPAToken(java.lang.String value)
        This method sets the value of the generateLTPAToken property.
        Parameters:
        value - A value of 1 means "set to true".
      • setRemoveLTPAToken

        public void setRemoveLTPAToken(java.lang.String value)
        This method sets the value of the removeLTPAToken property.
        Parameters:
        value - A value of 1 means "set to true".
      • setDefaultProperties

        public void setDefaultProperties(java.lang.String value)
        This method sets the value of the defaultProperties property.
        Parameters:
        value - The new value of the defaultProperties property.
      • getAuthenticate

        public java.lang.String getAuthenticate()
        This method gets the value of the authenticate property.
        Returns:
        The value of the authenticate property.
      • getDefaultProperties

        public java.lang.String getDefaultProperties()
        This method gets the value of the defaultProperties property.
        Returns:
        The value of the defaultProperties property.
      • getDefaultProperties

        public java.lang.String getDefaultProperties(java.lang.Integer storeId)
        This method gets the value of the defaultProperties property for a given store.
        Parameters:
        storeId - The store ID.
        Returns:
        The value of the defaultProperties property.
      • isValidateToken

        public boolean isValidateToken(java.lang.Integer storeId)
        This method determines whether the validateToken property is set for a given store.
        Parameters:
        storeId - The store ID.
        Returns:
        A boolean value; true if the validateToken property is set and false otherwise.
      • setSaveToken

        public void setSaveToken(java.lang.String value)
        This method sets the value of the saveToken property.
        Parameters:
        value - The new value of the saveToken property.
      • getHttps

        public java.lang.String getHttps()
        This method gets the value of the HTTPS property.
        Returns:
        The value of the HTTPS property.
      • getHttps

        public java.lang.String getHttps(java.lang.Integer storeId)
        This method gets the value of the HTTPS property for a given store.
        Parameters:
        storeId - The store ID
        Returns:
        The value of the HTTPS property.
      • getSaveToken

        public java.lang.String getSaveToken()
        This method gets the value of the saveToken property.
        Returns:
        The value of the saveToken property.
      • getValidateToken

        public java.lang.String getValidateToken()
        This method gets the value of the validateToken property.
        Returns:
        The value of the validateToken property.
      • isAuthenticate

        public boolean isAuthenticate(java.lang.Integer storeId)
        This method determines whether the authenticate property is set for a given store.
        Specified by:
        isAuthenticate in interface com.ibm.commerce.adapter.HttpRequestAttributes
        Parameters:
        storeId - The store ID.
        Returns:
        A boolean value; true if the authenticate property is set and false otherwise (the default).
      • isSaveToken

        public boolean isSaveToken(java.lang.Integer storeId)
        This method checks whether the saveToken property is set for a given store.
        Parameters:
        storeId - The store ID.
        Returns:
        A boolean value; true if the saveToken property is set and false otherwise (the default).
      • isHttps

        public boolean isHttps(java.lang.Integer storeId)
        This method determines whether the HTTPS property is set for a given store.
        Parameters:
        storeId - The store ID.
        Returns:
        A boolean value; true if the HTTPS property is set and false otherwise (the default).
      • toString

        public java.lang.String toString()
        This method returns the String representation of this action mapping.
        Overrides:
        toString in class org.apache.struts.config.ActionConfig
        Returns:
        The String representation of this action mapping.
      • setCredentialsAccepted

        public void setCredentialsAccepted(java.lang.String value)
        This method sets the flag that determines whether or not a user that is partially authenticated is allowed to access this URL.
        • R or null - The partially authenticated user has no access.
        • P - The partially authenticated user can access the URL.
        Unless there is a value of P, a partially authenticated user is not entitled to access any resource by default.
        Parameters:
        value - The flag that represents the type of authentication that is required to access the forward.
      • getCredentialsAccepted

        public java.lang.String getCredentialsAccepted()
        This method returns the flag that represents the type of authentication that is required to access the forward.
        • R or null - The partially authenticated user has no access.
        • P - The partially authenticated user can access the URL.
        Unless there is a value of P, a partially authenticated user is not entitled to access any resource by default.
        Returns:
        The flag that represents the type of authentication that is required to access the forward.
      • getCredentialsAccepted

        public java.lang.String getCredentialsAccepted(java.lang.Integer storeId)
        This method returns the flag that represents the type of authentication that is required to access the forward.
        • R or null - The partially authenticated user has no access.
        • P - The partially authenticated user can access the URL.
        Unless there is a value of P, a partially authenticated user is not entitled to access any resource by default.
        Specified by:
        getCredentialsAccepted in interface com.ibm.commerce.adapter.HttpRequestAttributes
        Parameters:
        storeId - The store identifier of the resources authentication credentials flag.
        Returns:
        The flag that represents the type of authentication that is required to access the forward.
      • getHttpValue

        public int getHttpValue(java.lang.Integer storeId)
        This method returns the value of the HTTPS property for a given store.
        Specified by:
        getHttpValue in interface com.ibm.commerce.adapter.HttpRequestAttributes
        Parameters:
        storeId - The store ID.
        Returns:
        The value of the HTTPS property.
      • getCsrfProtected

        public java.lang.String getCsrfProtected()
        This method gets the value of the csrfProtected property.
        Returns:
        The value of the csrfProtected property.
      • getCsrfProtected

        public java.lang.String getCsrfProtected(java.lang.Integer storeId)
        This method gets the value of the csrfProtected property for a given store.
        Parameters:
        storeId - The store ID
        Returns:
        The value of the csrfProtected property.
      • isCrossSiteScriptingForgeryProtected

        public boolean isCrossSiteScriptingForgeryProtected(java.lang.Integer storeId)
        This method determines whether the csrfProtected property is set for a given store. If it is set to 1 which means true, the request must be passed in with a authToken parameter.
        Specified by:
        isCrossSiteScriptingForgeryProtected in interface com.ibm.commerce.adapter.HttpRequestAttributes
        Parameters:
        storeId - The store ID.
        Returns:
        A boolean value; true if the csrfProtected property is set to 1 and false otherwise (the default).
      • getVcProtected

        public java.lang.String getVcProtected()
        This method gets the value of the vcProtected property.
        Returns:
        The value of the vcProtected property.
      • getVcProtected

        public java.lang.String getVcProtected(java.lang.Integer storeId)
        This method gets the value of the vcProtected property for a given store.
        Parameters:
        storeId - The store ID
        Returns:
        The value of the vcProtected property.
      • isVerficationCodeProtected

        public boolean isVerficationCodeProtected(java.lang.Integer storeId)
        This method determines whether the vcProtected property is set for a given store. If it is set to 1 which means true, the request must be passed in with a verCode parameter.
        Parameters:
        storeId - The store ID.
        Returns:
        A boolean value; true if the vcProtected property is set to 1 and false otherwise (the default).
      • getGenerateLTPAToken

        public java.lang.String getGenerateLTPAToken()
        This method gets the value of the generateLTPAToken property.
        Returns:
        The value of the generateLTPAToken property.
      • getGenerateLTPAToken

        public java.lang.String getGenerateLTPAToken(java.lang.Integer storeId)
        This method gets the value of the generateLTPAToken property for a given store.
        Parameters:
        storeId - The store ID
        Returns:
        The value of the generateLTPAToken property.
      • isGenerateLTPAToken

        public boolean isGenerateLTPAToken(java.lang.Integer storeId)
        This method determines whether the generateLTPAToken property is set for a given store.
        Parameters:
        storeId - The store ID.
        Returns:
        A boolean value; true if the generateLTPAToken property is set to 1 and false otherwise (the default).
      • getRemoveLTPAToken

        public java.lang.String getRemoveLTPAToken()
        This method gets the value of the removeLTPAToken property.
        Returns:
        The value of the removeLTPAToken property.
      • getRemoveLTPAToken

        public java.lang.String getRemoveLTPAToken(java.lang.Integer storeId)
        This method gets the value of the removeLTPAToken property for a given store.
        Parameters:
        storeId - The store ID
        Returns:
        The value of the removeLTPAToken property.
      • isRemoveLTPAToken

        public boolean isRemoveLTPAToken(java.lang.Integer storeId)
        This method determines whether the removeLTPAToken property is set for a given store.
        Parameters:
        storeId - The store ID.
        Returns:
        A boolean value; true if the removeLTPAToken property is set to 1 and false otherwise (the default).
      • merge

        public void merge(org.apache.struts.config.ActionConfig actionConfig)
        This method merges the content of the specified action configuration object with the current object. This handles merging when both objects are instances of ECActionMapping.
        Parameters:
        actionConfig - The action configuration to merge.
      • findForward

        public org.apache.struts.action.ActionForward findForward(java.lang.String name)

        Find and return the ForwardConfig instance defining how forwarding to the specified logical name should be handled. This is performed by checking local and then global configurations for the specified forwarding configuration. If no forwarding configuration can be found, return null.

        Overrides:
        findForward in class org.apache.struts.action.ActionMapping
        Parameters:
        name - Logical name of the forwarding instance to be returned
        Returns:
        The ActionForward object.