Thanks Jishnu and Albert. now i am overriding doStart and doEnd tag also. here i am getting the visibility value from DB and calling Component.inject if visibility is allowed. your inputs helped to quickly find out the solution,,,
Thanks a lot. On Wed, Sep 24, 2008 at 7:39 PM, Alberto Flores <[EMAIL PROTECTED]> wrote: > Assumming you are talking about Struts 2, I would recommend checking out > the source code and trace how the UIBean delegates to the Component class > (super class). All Struts2 ui objects are subclasses of "Component". > Additionally, UIBean adds a set of methods that are very useful > (particularly the logic on evaluateParams() and evaluateExtraParams(). > These classes add your friend. > > Although not the best solutions, my strategy for hiding a component on > certain criteria was to modify the theme used in the rendering engine (e.g. > override the getTheme() method) You'll then need to create your own template > with blank HTML (or whatever suits your needs). > > Granted, this does not stop processing of the component, you still do > unnecessary operations (loading the template map, doing a bunch of unneeded > comparison). But I think there's little you could do about that other than > possibly throwing you own exception which could arguably be better in > performance that those operations. > > Only a thought! > > > > Narayana S wrote: > >> Hi >> >> i missed my previous email about the same topic, one guy helped me >> to >> implement struts UI tag customization. i could extend the Bean and Tag >> classes to implement the required behavior. >> >> now based on some value from the database i want to stop rendering of the >> control itself. means for example i have a field visible , if it is false >> i >> should not display the control at all.. how can i stop tag rendering can >> any >> one help me to do this... >> >> Thanks in advance. >> >> > -- > -- > Alberto > http://www.linkedin.com/in/aflores > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] >