Hi,

To my big surprise the following does not work:

        // The item page is mounted on /tips, but only for urls that have an 
item id.
        mount(new MixedParamUrlCodingStrategy("tips", ItemPage.class, new 
String[]{ParameterConstants.PARAM_ITEM_ID}) {
            @Override
            public boolean matches(String path) {
                return super.matches(path) && Pattern.compile(getMountPath() + 
"^/[0-9z-z]{3,}_[^/]*$").matcher(path).matches();
            }
        });

        // All other URLs starting with /tips go to the tip page.
        mount(new MixedParamUrlCodingStrategy("tips", TipPage.class, 
ParameterConstants.URL_PARAMS));


This piece of code is greeted with:

    org.apache.wicket.WicketRuntimeException: tips is already mounted
    for BookmarkablePageEncoder

Would it not be more logical to try every url strategy on the same mount
path, in the order they were mounted?


Regards,
    Erik.


--
Erik van Oosten
http://day-to-day-stuff.blogspot.com/

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to