I think I must first find out if I understand you correctly.
Are you saying that your menu can be personalized by your user ? And it is rendered dynamically according to data from a datasource ?
Personally, I think tiles provides layouts where component tiles can be dynamically rendered. If I were in your case, I would generalize the possible forms the menu could manifest itself, and then create tiles definition for each of the generalized menu. I would then create an Action subclass that will forward to the right generalized menu accordingly.
Then, I would enter decision making logics in the JSPs that are component tiles within each definition.
This would be what I would do in your position.
Originally posted by Alvin chew:
thank you ken for reply , my problem actually simple ..if i make a web menu component which allow each user can have their own menu(something like tree menu), and the different menu will locate into header.jsp, so my component suppose to have many different header.jsp for each user.
now, if i predefine in tile-def.xml, it would be fine, because we can use some concept like inheritance to write it into tile-def.xml ,
my problem is assume we have one default set of definition in tile-def.xml, now if new definition need to be add into tile-def.xml, what i suppose to do ? do i need to write it into tile-def.xml or any other way to make new definition inherit the predefine definition ? if yes, can i simply using xml parser to write it to tile-def.xml ? so we need to restart the tomcat everytime?