EventListener . Yeah I think there are some enchancers that run for it (later, not in the annotation src though)... It's kind of up to you if you need to enhance anything or not ;) (Personally I'd probably just use the annotations to provide a global cached sort of data lookup that some other service could then use to do security stuff...Or somethin like that ;) )
On 6/7/06, James Carman <[EMAIL PROTECTED]> wrote:
Which ones? I assume there are enhancers that take care of them, too. :-) -----Original Message----- From: Jesse Kuhnert [mailto:[EMAIL PROTECTED] Sent: Wednesday, June 07, 2006 2:18 PM To: Tapestry development Subject: Re: Permissions Mapping... I just added some method level annotations into tapestry4/trunk if that helps... On 6/7/06, James Carman <[EMAIL PROTECTED]> wrote: > > Howard, > > Cool idea and I was considering it too. But, would there be a nice way to > specify this without using annotations? I'm not really against them, but > some users get turned off by it. Also, do you have some example code > somewhere that I could "borrow"? Javassist isn't the easiest thing in the > world, you know. :-) > > James > > -----Original Message----- > From: Howard Lewis Ship [mailto:[EMAIL PROTECTED] > Sent: Wednesday, June 07, 2006 2:06 PM > To: Tapestry development > Subject: Re: Permissions Mapping... > > What I did was create a @Privileged annotation. The annotation value was > the name of the required role. You could attach this method to classes, or > to methods. @Privileged is inherited, and @Privileged("") means no > special > privilege required. > > For classes, it implemented/extended PageValidateListener to check the > permission. > > For methods, it overrided the method to add a check before invoking > super(). > > I extended Tapestry class and method annotation workers to handle these > annotations. > > Worked like a charm. > > This approach puts the logic right into the pages or methods, which is > where > I think it belongs. > > On 6/7/06, James Carman <[EMAIL PROTECTED]> wrote: > > > > All, > > > > You guys are the experts. I have a design question. I am creating a > > tapestry/acegi integration package (parts of it are already done). What > I > > need to figure out is how to decide what roles an in-coming request > > requires? If it's a PageService request, I can check the page class for > a > > @RequiredRole annotation. If it's a DirectService request, I can check > > the > > method for a @RequiredRole annotation. But, how do I do this in a > general > > way? Any ideas? > > > > James > > > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > -- > Howard M. Lewis Ship > Independent J2EE / Open-Source Java Consultant > Creator and PMC Chair, Apache Tapestry > Creator, Jakarta HiveMind > > Professional Tapestry training, mentoring, support > and project work. http://howardlewisship.com > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- Jesse Kuhnert Tacos/Tapestry, team member/developer Open source based consulting work centered around dojo/tapestry/tacos/hivemind. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
-- Jesse Kuhnert Tacos/Tapestry, team member/developer Open source based consulting work centered around dojo/tapestry/tacos/hivemind.
