tacos also registers a FormComponentEventWorker.
It's responsible for adding 2 more parameters to all form components...
"eventListener" and "formatter"
https://svn.sourceforge.net/svnroot/tacos/tacos-4.0/trunk/tacos-core/src/java/net/sf/tacos/ajax/impl/FormComponentEventWorker.java

Here's their registration
https://svn.sourceforge.net/svnroot/tacos/tacos-4.0/trunk/tacos-core/src/descriptor/META-INF/tacos.enhance.xml

So, my question is why don't you create your own enhancment worker and
contribute it to
tapestry.enhance.EnhancementWorkers configuration point?



Karthik N wrote:
> Hello,
>
> Tacos 4.0.1 - We are contemplating adding an EnhancementWorker to the
> renderComponent method of AbstractComponent.
>
> The idea is to be able to perform certain "Security" operations in a
> (hopefully) elegant fashion.
>
> For eg. we have cases where a Tab should hide/show itself, a TextField
> should hide/show itself.
>
> Here are the thoughts:
>
> 1) Introduce a formal parameter for each component something like
> renderIfUserInRoles ognl:{'ADMIN', 'SUPERVISOR'}
>
> 2) A custom EnhancementWorker to change the IWriter accordingly after
> calling a SecurityContext.isUserInRoles( {'ADMIN', 'SUPERVISOR'} )
> which will check a ThreadLocal etc. (left out the gory details)
>
> 3) If the user is not in roles pass on a NullWriter to the component,
> so that it will not render its content.
>
> So here are the questions:
>
> 1) After some digging we find that InjectAjaxComponentRenderWorker
> already enhances AbstractComponent.renderComponent().   Methods of
> this Worker are protected, so we plan to further override this
> implementation and use the approach described in
> http://hivemind.apache.org/override.html to override the service-point
> id="ComponentRenderInterceptor"
>
> 2) Is this a good idea?!  We would love to hear some feedback.
>
> Thanks, Karthik
> ------------------------------------------------------------------------
>
> -------------------------------------------------------------------------
> 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
> ------------------------------------------------------------------------
>
> _______________________________________________
> Tacos-devel mailing list
> Tacos-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/tacos-devel
>   


-- 
Andreas Andreou - [EMAIL PROTECTED] - http://andyhot.di.uoa.gr
Tapestry / Tacos developer
Open Source / J2EE Consulting 


-------------------------------------------------------------------------
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
_______________________________________________
Tacos-devel mailing list
Tacos-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/tacos-devel

Reply via email to