Package ru.bgcrm.struts.action
Class BaseAction
java.lang.Object
org.apache.struts.action.Action
org.apache.struts.actions.BaseAction
org.apache.struts.actions.DispatchAction
ru.bgcrm.struts.action.BaseAction
- Direct Known Subclasses:
ActionBalance
,ActionLogAction
,AppAction
,BackupAction
,BaseAction
,BaseAction
,BoardAction
,BoardAction
,ChannelAction
,CleanupAction
,ConfigAction
,ConfigAction
,CredentialAction
,CustomAction
,CustomerAction
,CustomerAction
,CustomerAction
,DatabaseAction
,DirectoryAction
,DirectoryAddressAction
,DispatchAction
,DispatchAction
,DocumentAction
,DynamicAction
,EMailAction
,EmptyAction
,FileAction
,GitAction
,GroupLoadAction
,HelpDeskAction
,InvoiceAction
,LinkAction
,LockAction
,LogAction
,LoginAction
,MessageAction
,MessageAction
,MessageCallAction
,NewsAction
,ParameterAction
,PhoneAction
,PoolAction
,ProcessAction
,ProcessAction
,ProcessAction
,ProcessQueueAction
,ProfileAction
,ProfileAction
,ReportAction
,ReportActionBase
,RunAction
,SearchAction
,SearchAction
,SubscriptionAction
,TaskAction
,TestAction
,TestAction
,UserAction
,UserAction
,UserAction
,WorkAction
public class BaseAction
extends org.apache.struts.actions.DispatchAction
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final String
protected Localizer
protected final Log
static final com.fasterxml.jackson.databind.ObjectMapper
protected static final String
static final String
static final String
static final String
protected final Setup
Fields inherited from class org.apache.struts.actions.DispatchAction
clazz, methods, types
Fields inherited from class org.apache.struts.actions.BaseAction
messages
Fields inherited from class org.apache.struts.action.Action
servlet
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected void
checkModified
(LastModify lastModify, DynActionForm form) protected org.apache.struts.action.ActionForward
dispatchMethod
(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm actionForm, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, String name) protected boolean
protected org.apache.struts.action.ActionForward
html
(Connection con, org.apache.struts.action.ActionMapping mapping, DynActionForm form) Deprecated.protected org.apache.struts.action.ActionForward
html
(Connection con, org.apache.struts.action.ActionMapping mapping, DynActionForm form, String name) Deprecated.protected org.apache.struts.action.ActionForward
html
(Connection con, DynActionForm form, String path) JSP forward file path.protected org.apache.struts.action.ActionForward
html
(Connection con, DynActionForm form, Map<String, String> mapping) JSP forward file path calculated usinggetForwardJspPath(DynActionForm, Map)
function.protected org.apache.struts.action.ActionForward
html
(ConnectionSet conSet, org.apache.struts.action.ActionMapping mapping, DynActionForm form) Deprecated.protected org.apache.struts.action.ActionForward
html
(ConnectionSet conSet, org.apache.struts.action.ActionMapping mapping, DynActionForm form, String name) Deprecated.protected org.apache.struts.action.ActionForward
html
(ConnectionSet conSet, DynActionForm form, String path) JSP forward file path.protected org.apache.struts.action.ActionForward
json
(Connection con, DynActionForm form) Sends response result in JSON format.protected org.apache.struts.action.ActionForward
json
(ConnectionSet conSet, DynActionForm form) Sends response result in JSON format.protected org.apache.struts.action.ActionForward
processJsonForward
(Connection con, DynActionForm form) Deprecated.protected org.apache.struts.action.ActionForward
processJsonForward
(Connection con, DynActionForm form, javax.servlet.http.HttpServletResponse response) Deprecated.protected org.apache.struts.action.ActionForward
processJsonForward
(ConnectionSet conSet, DynActionForm form) Deprecated.protected org.apache.struts.action.ActionForward
processJsonForward
(ConnectionSet conSet, DynActionForm form, javax.servlet.http.HttpServletResponse response) Deprecated.protected org.apache.struts.action.ActionForward
processUserTypedForward
(Connection con, org.apache.struts.action.ActionMapping mapping, DynActionForm form, String htmlForwardName) Deprecated.protected org.apache.struts.action.ActionForward
processUserTypedForward
(Connection con, org.apache.struts.action.ActionMapping mapping, DynActionForm form, javax.servlet.http.HttpServletResponse response, String htmlForwardName) Deprecated.protected org.apache.struts.action.ActionForward
processUserTypedForward
(ConnectionSet conSet, org.apache.struts.action.ActionMapping mapping, DynActionForm form, String htmlForwardName) Deprecated.protected org.apache.struts.action.ActionForward
processUserTypedForward
(ConnectionSet conSet, org.apache.struts.action.ActionMapping mapping, DynActionForm form, javax.servlet.http.HttpServletResponse response, String htmlForwardName) Deprecated.protected void
restoreRequestParams
(Connection con, DynActionForm form, boolean get, boolean set, String... params) Saves and restores HTTP request parameters.protected final org.apache.struts.action.ActionForward
unspecified
(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) Standard Struts method, shouldn't be used.protected org.apache.struts.action.ActionForward
unspecified
(org.apache.struts.action.ActionMapping mapping, DynActionForm form, Connection con) Deprecated.protected org.apache.struts.action.ActionForward
unspecified
(org.apache.struts.action.ActionMapping mapping, DynActionForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, Connection con) Deprecated.protected org.apache.struts.action.ActionForward
unspecified
(org.apache.struts.action.ActionMapping mapping, DynActionForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, ConnectionSet conSet) Deprecated.protected org.apache.struts.action.ActionForward
unspecified
(org.apache.struts.action.ActionMapping mapping, DynActionForm form, ConnectionSet conSet) Deprecated.org.apache.struts.action.ActionForward
unspecified
(DynActionForm form, Connection con) Default action method if no parameter 'action' passed.org.apache.struts.action.ActionForward
unspecified
(DynActionForm form, ConnectionSet conSet) Default action method if no parameter 'action' passed.protected void
updatePersonalization
(DynActionForm form, Connection con, Consumer<Preferences> setFunction) Stores new values in personalization map and update it if changed.Methods inherited from class org.apache.struts.actions.DispatchAction
cancelled, execute, getMethod, getMethodName, getParameter
Methods inherited from class org.apache.struts.action.Action
addErrors, addMessages, execute, generateToken, getErrors, getLocale, getMessages, getResources, getResources, getServlet, isCancelled, isTokenValid, isTokenValid, resetToken, saveErrors, saveErrors, saveMessages, saveMessages, saveToken, setLocale, setServlet
-
Field Details
-
MAPPER
public static final com.fasterxml.jackson.databind.ObjectMapper MAPPER -
PATH_JSP
- See Also:
-
PATH_JSP_ADMIN
- See Also:
-
PATH_JSP_USER
- See Also:
-
PATH_JSP_OPEN
- See Also:
-
FORWARD_DEFAULT
- See Also:
-
log
-
setup
-
l
-
-
Constructor Details
-
BaseAction
protected BaseAction()
-
-
Method Details
-
unspecified
protected final org.apache.struts.action.ActionForward unspecified(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws Exception Standard Struts method, shouldn't be used.- Overrides:
unspecified
in classorg.apache.struts.actions.DispatchAction
- Throws:
Exception
-
unspecified
@Deprecated protected org.apache.struts.action.ActionForward unspecified(org.apache.struts.action.ActionMapping mapping, DynActionForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, Connection con) throws Exception Deprecated.- Throws:
Exception
-
unspecified
@Deprecated protected org.apache.struts.action.ActionForward unspecified(org.apache.struts.action.ActionMapping mapping, DynActionForm form, Connection con) throws Exception Deprecated.- Throws:
Exception
-
unspecified
@Deprecated protected org.apache.struts.action.ActionForward unspecified(org.apache.struts.action.ActionMapping mapping, DynActionForm form, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, ConnectionSet conSet) throws Exception Deprecated.- Throws:
Exception
-
unspecified
@Deprecated protected org.apache.struts.action.ActionForward unspecified(org.apache.struts.action.ActionMapping mapping, DynActionForm form, ConnectionSet conSet) throws Exception Deprecated.- Throws:
Exception
-
unspecified
public org.apache.struts.action.ActionForward unspecified(DynActionForm form, ConnectionSet conSet) throws Exception Default action method if no parameter 'action' passed. Overwrite and implement.- Parameters:
form
-conSet
-- Returns:
- Throws:
Exception
-
unspecified
public org.apache.struts.action.ActionForward unspecified(DynActionForm form, Connection con) throws Exception Default action method if no parameter 'action' passed. Overwrite and implement.- Parameters:
form
-con
-- Returns:
- Throws:
Exception
-
dispatchMethod
protected org.apache.struts.action.ActionForward dispatchMethod(org.apache.struts.action.ActionMapping mapping, org.apache.struts.action.ActionForm actionForm, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, String name) throws Exception - Overrides:
dispatchMethod
in classorg.apache.struts.actions.DispatchAction
- Throws:
Exception
-
html
protected org.apache.struts.action.ActionForward html(Connection con, DynActionForm form, Map<String, String> mapping) JSP forward file path calculated usinggetForwardJspPath(DynActionForm, Map)
function.- Parameters:
con
-form
-mapping
-- Returns:
-
html
protected org.apache.struts.action.ActionForward html(Connection con, DynActionForm form, String path) JSP forward file path.- Parameters:
con
-form
- must be 'null' for open interface.path
- JSP path.- Returns:
-
html
protected org.apache.struts.action.ActionForward html(ConnectionSet conSet, DynActionForm form, String path) JSP forward file path.- Parameters:
conSet
-form
-path
- JSP path.- Returns:
-
html
@Deprecated protected org.apache.struts.action.ActionForward html(Connection con, org.apache.struts.action.ActionMapping mapping, DynActionForm form) Deprecated.Usehtml(Connection, DynActionForm, String)
. Returns Struts forward with name=form.getAction().- Parameters:
con
-mapping
-form
-- Returns:
-
html
@Deprecated protected org.apache.struts.action.ActionForward html(Connection con, org.apache.struts.action.ActionMapping mapping, DynActionForm form, String name) Deprecated.Usehtml(Connection, DynActionForm, String)
. Returns Struts forward by name.- Parameters:
con
-mapping
-form
-name
- forward's name.- Returns:
-
html
@Deprecated protected org.apache.struts.action.ActionForward html(ConnectionSet conSet, org.apache.struts.action.ActionMapping mapping, DynActionForm form) Deprecated.Usehtml(ConnectionSet, DynActionForm, String)
. Returns Struts forward with name=form.getAction().- Parameters:
conSet
-mapping
-form
-- Returns:
-
html
@Deprecated protected org.apache.struts.action.ActionForward html(ConnectionSet conSet, org.apache.struts.action.ActionMapping mapping, DynActionForm form, String name) Deprecated.Usehtml(ConnectionSet, DynActionForm, String)
. Returns Struts forward by name.- Parameters:
conSet
-mapping
-form
-name
- forward's name.- Returns:
-
processUserTypedForward
@Deprecated protected org.apache.struts.action.ActionForward processUserTypedForward(Connection con, org.apache.struts.action.ActionMapping mapping, DynActionForm form, javax.servlet.http.HttpServletResponse response, String htmlForwardName) Deprecated. -
processUserTypedForward
@Deprecated protected org.apache.struts.action.ActionForward processUserTypedForward(Connection con, org.apache.struts.action.ActionMapping mapping, DynActionForm form, String htmlForwardName) Deprecated. -
processUserTypedForward
@Deprecated protected org.apache.struts.action.ActionForward processUserTypedForward(ConnectionSet conSet, org.apache.struts.action.ActionMapping mapping, DynActionForm form, javax.servlet.http.HttpServletResponse response, String htmlForwardName) Deprecated. -
processUserTypedForward
@Deprecated protected org.apache.struts.action.ActionForward processUserTypedForward(ConnectionSet conSet, org.apache.struts.action.ActionMapping mapping, DynActionForm form, String htmlForwardName) Deprecated. -
json
Sends response result in JSON format.- Parameters:
con
-form
-- Returns:
-
json
Sends response result in JSON format.- Parameters:
conSet
-form
-- Returns:
-
processJsonForward
@Deprecated protected org.apache.struts.action.ActionForward processJsonForward(ConnectionSet conSet, DynActionForm form) Deprecated. -
processJsonForward
@Deprecated protected org.apache.struts.action.ActionForward processJsonForward(Connection con, DynActionForm form) Deprecated. -
processJsonForward
@Deprecated protected org.apache.struts.action.ActionForward processJsonForward(Connection con, DynActionForm form, javax.servlet.http.HttpServletResponse response) Deprecated. -
processJsonForward
@Deprecated protected org.apache.struts.action.ActionForward processJsonForward(ConnectionSet conSet, DynActionForm form, javax.servlet.http.HttpServletResponse response) Deprecated. -
getAccess
-
checkModified
- Throws:
BGException
-
restoreRequestParams
protected void restoreRequestParams(Connection con, DynActionForm form, boolean get, boolean set, String... params) throws BGException Saves and restores HTTP request parameters. As storage usedUser.getPersonalizationMap()
, key is 'param.' + digest fromDynActionForm.getAreaId()
.- Parameters:
con
-form
- there params are taken and restored, also contains 'areaId' param.get
- restoreset
- savesparams
- parameter names- Throws:
BGException
-
updatePersonalization
protected void updatePersonalization(DynActionForm form, Connection con, Consumer<Preferences> setFunction) throws Exception Stores new values in personalization map and update it if changed.- Parameters:
form
-con
-setFunction
-- Throws:
Exception
-