Class AbstractEntryTypeSession

  • All Implemented Interfaces:
    IEntryTypeService

    public abstract class AbstractEntryTypeSession
    extends EntryTypeService
    Abstract entry type for sessions attributes This entry is used to fetch the value of a session's attribute. One example is when coupling form with crm, the module-crm-form will put in session the ID demand and the user GUID. This entry will be able to fetch the ID demand and user GUID when validating the form. Then, it is easier to export the value to directory with the module-form-exportdirectory.
    • Constructor Detail

      • AbstractEntryTypeSession

        public AbstractEntryTypeSession()
    • Method Detail

      • getRequestData

        public java.lang.String getRequestData​(Entry entry,
                                               javax.servlet.http.HttpServletRequest request,
                                               java.util.Locale locale)
        Get the request data
        Specified by:
        getRequestData in interface IEntryTypeService
        Overrides:
        getRequestData in class EntryTypeService
        Parameters:
        entry - The entry
        request - HttpRequest
        locale - the locale
        Returns:
        null if all data required are in the request else the url of jsp error
      • getRequestData

        public java.lang.String getRequestData​(Entry entry,
                                               javax.servlet.http.HttpServletRequest request,
                                               java.util.Locale locale,
                                               java.lang.String errorReturnUrl)
        Get the request data
        Specified by:
        getRequestData in interface IEntryTypeService
        Overrides:
        getRequestData in class EntryTypeService
        Parameters:
        entry - The entry
        request - HttpRequest
        locale - the locale
        errorReturnUrl - url to go to after displaying a message when an error occurs
        Returns:
        null if all data required are in the request else the url of jsp error
      • getResponseData

        public GenericAttributeError getResponseData​(Entry entry,
                                                     javax.servlet.http.HttpServletRequest request,
                                                     java.util.List<Response> listResponse,
                                                     java.util.Locale locale)
        Generate the list of responses associated with the given entry from the request, and saved it into the Entry object.
        Specified by:
        getResponseData in interface IEntryTypeService
        Overrides:
        getResponseData in class EntryTypeService
        Parameters:
        entry - The entry
        request - HttpRequest
        listResponse - the list of response associate to the entry. Newly created response will be inserted in this list.
        locale - the locale
        Returns:
        a GenericAttributeError object if there is an error in the response
      • getResponseValueForExport

        public java.lang.String getResponseValueForExport​(Entry entry,
                                                          javax.servlet.http.HttpServletRequest request,
                                                          Response response,
                                                          java.util.Locale locale)
        Get the response value associate to the entry to export in the file export
        Specified by:
        getResponseValueForExport in interface IEntryTypeService
        Overrides:
        getResponseValueForExport in class EntryTypeService
        Parameters:
        entry - The entry
        request - the request
        response - the response associate to the entry
        locale - the locale
        Returns:
        the response value associate to the entry to export in the file export
      • getResponseValueForRecap

        public java.lang.String getResponseValueForRecap​(Entry entry,
                                                         javax.servlet.http.HttpServletRequest request,
                                                         Response response,
                                                         java.util.Locale locale)
        Get the response value associate to the entry to write in the recap
        Specified by:
        getResponseValueForRecap in interface IEntryTypeService
        Overrides:
        getResponseValueForRecap in class EntryTypeService
        Parameters:
        entry - The entry
        request - the request
        response - the response associate to the entry
        locale - the locale
        Returns:
        the response value associate to the entry to write in the recap