I am trying to figure out how to set the default class that is executed when
a class is not specified on an <action> declaration.  When you specify
something like:

<action name="home">
 <result>/home.jsp</result>
</action>

Struts automatically runs com.opensymphony.xwork2.ActionSupport.  But I am
trying to figure out how to accomplish this:

<action name="home">
 <param name="role">user</param>
 <result>/home.jsp</result>
</action>

Since ActionSupport doesn't have a setRole method, this won't work out of
the box, so I created a simple extension of ActionSupport to hold the role
value.  After a bit of googling, I got the idea that this should work:

<action name="default" class="my.package.BaseAction"/>

<default-action-ref name="default"/>

but that doesn't seem to do the job.  Is it possible?  Is there another way
to specify this type of information on a per Action basis?  Any insights
would be appreciated.
 (*Chris*)

Reply via email to