On 10/28/07, Jeromy Evans <[EMAIL PROTECTED]> wrote: > Hi Don, > > Thanks for the quick updates. The update to xwork seems fine as it > supports namespaces like "/animals/*" via the wildcard handling in > findActionConfigInNamespace(String namespace, String name).
Ah, right. I'll fix that. > A separate small issue is that NamedVariablePatterMatcher isn't enabled > yet. The XWorkConfigurationProvider enables only the WildercardHelper. > However, when I do enable it instead of WildcardHelper it works great. > I'm not sure how/if you intended both pattern matchers to be supported > at once? The implementation of PatternMatcher is actually determined by the container config. By default in Struts 2, only the WildcardHelper (need to rename that) is defined, mainly because Struts 2 trunk depends on the released XWork 2.1.0 that doesn't have the new code. Once 2.1.0 is released, I'll make it an option, but probably only the default for the rest plugin. The reason is the named variable pattern matcher doesn't support "**", which allows you to match anything, including slashes. That, and it would immediately break any existing apps that used wildcards. > Anyway, I hope that's helpful feedback. I'm eargerly awaiting these > updates because I think the new rest plugin is an important advance for > struts2. I'd be happy to provide unit tests if it helps. Absolutely, I appreciate the feedback, but perhaps we should take future threads over to the dev@ list as that is where the other Struts devs are. Also, feel free to open tickets and attach patches to fix bugs and/or implement new features. The more help, the better :) Don > > regards, > Jeromy Evans > > Don Brown wrote: > > Doh, thanks. Added. > > > > Don > > > > On 10/28/07, Jeromy Evans <[EMAIL PROTECTED]> wrote: > > > >> Hi Don, > >> I can see your updates to xwork and the rest plugin - look great - but > >> the new classes NamespaceMatcher and NamespaceMatch used by xwork's > >> DefaultConfiguration seem to be missing from svn. Can you please take a > >> look? > >> > >> https://svn.opensymphony.com/svn/xwork/trunk/src/java/com/opensymphony/xwork2/config/impl/ > >> R1663 > >> > >> svn info: > >> https://svn.apache.org/repos/asf/struts/sandbox/trunk/struts2-rest-plugin > >> Revision: 589249 > >> URL: https://svn.opensymphony.com/svn/xwork/trunk > >> Revision: 1663 > >> URL: https://svn.apache.org/repos/asf/struts/struts2/trunk > >> Revision: 589251 > >> > >> Thanks, > >> Jeromy Evans > >> > >> Don Brown wrote: > >> > >>> The code has been checked into XWork, but since the upcoming Struts > >>> 2.1.0 release will depend on XWork 2.1.0 and not XWork 2.1.1 (which > >>> trunk will be when it is released next), the feature won't be > >>> available until Struts 2.1.1. > >>> > >>> Basically how it works is you define your namespace to be: > >>> @Namespace("/states/{state}"), then define a setState() method on your > >>> controller to get the 'state' value. > >>> > >>> Don > >>> > >>> On 10/26/07, Jeromy Evans <[EMAIL PROTECTED]> wrote: > >>> > >>> > >>>> Don Brown wrote: > >>>> > >>>> > >>>>> You are correct, #3 isn't possible right now with the rest plugin, > >>>>> however, it is certainly on the near-term roadmap. What is needed is > >>>>> the ability to define wildcards in the namespace, also known as url > >>>>> templates. For example, you could do something like > >>>>> @Namespace("/states/{state}") on your CitiesController class. > >>>>> > >>>>> > >>>>> > >>>> Thanks Don. That'll be perfect! I'll keep an eye on the xwork trunk and > >>>> dev list. > >>>> > >>>> --------------------------------------------------------------------- > >>>> To unsubscribe, e-mail: [EMAIL PROTECTED] > >>>> For additional commands, e-mail: [EMAIL PROTECTED] > >>>> > >>>> > >>>> > >>>> > >>> --------------------------------------------------------------------- > >>> To unsubscribe, e-mail: [EMAIL PROTECTED] > >>> For additional commands, e-mail: [EMAIL PROTECTED] > >>> > >>> > >>> > >>> > >>> > >>> > >> --------------------------------------------------------------------- > >> To unsubscribe, e-mail: [EMAIL PROTECTED] > >> For additional commands, e-mail: [EMAIL PROTECTED] > >> > >> > >> > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]