struts-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dale Newfield (JIRA)" <j...@apache.org>
Subject [jira] Updated: (WW-3260) PrefixBasedActionMapper
Date Thu, 24 Sep 2009 15:30:17 GMT

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

Dale Newfield updated WW-3260:
------------------------------

    Attachment: PrefixBasedActionMapper.java

Called "PrefixBasedActionMapper" since it's really just a way to have urls that begin with
different prefixes (not necessarily namespaces, although I've defined "prefix" to mean "prefix
that ends just before a slash") use different action mappers to attempt to map the url to
an action in the same configuration (that includes all packages/namespaces).

Clearly the one constant referred to in this code would need to find a new home, too.

Here are the corresponding struts.xml entries I use, which should illustrate how to use this
thing:

<bean type="org.apache.struts2.dispatcher.mapper.ActionMapper" name="pseudoRestful" class="org.apache.struts2.dispatcher.mapper.PseudoRestfulActionMapper"/>
<constant name="struts.mapper.class" value="org.apache.struts2.dispatcher.mapper.PrefixBasedActionMapper"/>
<constant name="struts.mapper.prefixMapping" value="/show:pseudoRestful,:struts"/>

> PrefixBasedActionMapper
> -----------------------
>
>                 Key: WW-3260
>                 URL: https://issues.apache.org/struts/browse/WW-3260
>             Project: Struts 2
>          Issue Type: New Feature
>            Reporter: Dale Newfield
>            Priority: Minor
>         Attachments: PrefixBasedActionMapper.java
>
>
> There are periodic requests for this on the mailing list, but I've yet to build a set
of test cases, so I offer this code in hopes that someone will massage it into shape that
might be added to the project.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message