You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@struts.apache.org by "Lukasz Lenart (Jira)" <ji...@apache.org> on 2022/09/14 19:04:00 UTC

[jira] [Closed] (WW-2392) Handle additional actionName formats for ActionChainResult

     [ https://issues.apache.org/jira/browse/WW-2392?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Lukasz Lenart closed WW-2392.
-----------------------------
    Resolution: Won't Fix

> Handle additional actionName formats for ActionChainResult
> ----------------------------------------------------------
>
>                 Key: WW-2392
>                 URL: https://issues.apache.org/jira/browse/WW-2392
>             Project: Struts 2
>          Issue Type: Improvement
>          Components: Core Actions
>    Affects Versions: 2.0.11
>            Reporter: Richard  T. Feak
>            Priority: Minor
>             Fix For: 6.1.0
>
>         Attachments: SmartActionChainResult.java
>
>
> Currently it's simple to define a chain result for an action in the same package, with a method of execute(). However, to chain to an action in a different namespace, or a method other then execute() requires additional XML markup that seems unnecessary.
> We already have a defined string format for referring to namespaces and methods. Could we use that format to simplify the definition of chain results?
> For example:
> <result name="success" type="chain">foo!bar</result> - Should refer to the bar() method in action "foo" in the same namespace.
> <result name="success" type="chain">/foo/bar</result> - Should refer to the "bar" action in the "foo" namespace
> <result name="success" type="chain">/foo/bar!baz</result> - Should refer to the baz() method on the "bar" action" in the "foo" namespace.
> As you can see, this format is much more intuitive and concise when compared against the current syntax for defining chain results.
> I'm assuming that somewhere there is common code for parsing such strings. it should be easy to re-use that code to prepopulate the variables in the ActionChainResult correctly.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)