Damn it! I was this close <holds fingers a hair-width apart>. I modified my MetaDataComponentProtector class (very close to the MetaDataRoleAuthorizationStrategy, but I need to store a Predicate (commons-collections) with the action for dynamic evaluation) to be an IAuthorizationStrategy removed the onBeforeRender and it worked nearly the same way. I had trouble my first pass through using the Auth strategy but I'm sure it was with other stuff I was doing.
I wasn't actually using the List to mark components as protected, I was basically using it to limit the components that I evaluated. That's why I didn't have to make too many changes... sweet! Thanks Chuck Eelco Hillenius wrote: > > Concerning your case, I would still do it a bit differently. It's the > old push vs pull thing. You decided to push the info you need by > overriding onBeforeRender (also consider onAttach btw), visiting the > children and push any state in them that will be accessed again when > rendering. Why not turn that around? When the components are being > rendered (which works as visiting in itself btw), you should have the > same information available as with your visit action. Why not, instead > of having that visit method interpret the authorization, convert it to > the proper meta data, which is then interpreted by the auth strategy, > just let the auth strategy interpret directly? The advantages of that > is that it keeps everything more simple (you don't need the meta > data), cheap in CPU and memory, and you'll only evaluate the > components that are actually rendered (otherwise, your visit should > filter on visible and enabled). > > Just my 2c, > > Eelco > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Wicket-user mailing list > Wicket-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wicket-user > > -- View this message in context: http://www.nabble.com/Role-authorization-per-page-tf2453766.html#a7010177 Sent from the Wicket - User mailing list archive at Nabble.com. ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user