Friday, January 1, 2010

Kates Playground 2010 Képek



Well in this short article we will talk about
struts actions, a class action is a normal java
, in which we have methods, attributes
, etc. but we

respect the rules of the JavaBean.

as the first observation Podem
say that if we have a constructor overload is necessary to write the constructor
implied, because if we do not
problem of execution, an action can be called by multiple
actions and
as another detail we can say that Struts2
default does not create an HttpSession object, but adding

in jsp page the next tag


\u0026lt;% @ page session = "false"%>

we have solved

our action class must inherit from Class
ActionSupport
, this class provides a
static fields that are used in our configuration
constatementes struts.xml,
these fields are important because at first we can see
in the configuration file and do not know that
reference.

SUCCESS: The process is a success and is accessed

the request of the user.

NONE: Indicates that the implementation of the action was successful,

but the result is displayed to the user.

ERROR: Indicates that the implementation of the action failed.


INPUT: not for the validation and entry

user denuevo be taken.


LOGIN: indicates that the action could not execute

because the user has not logged.


these parameters are used in the configuration file

struts.xml



0 comments:

Post a Comment