I have a requirement where I need to create a tree structure for an xml using Struts menu component and display that in ui. But problem is if XML contains any tags such as "type_org" then i am getting an error stating MenuComponent id cannot be null, not contain '*' or '_'.
Is there any solution to generate a tree structure which can contain such tags with underscore symbol
We are using Struts Layout API for this purpose. In Struts Layout there is a class called MenuComponent. This component allows us to create hierarchical tree structure which is used to navigate between the nodes and xml.
This xml will be converted to a directory tree
if "+" symbol is clicked on it has to expand and show the rest of the contents. But since <type_org> contains the underscore symbol in it, it's raising an exception.
Here is a fragment of the code that is used for tree creation.
JDK Version: 1.6.0_17
Struts Jars being used:
Tag Library Descriptors:
Development Server: Apache Tomcat 6.0
Deployment Server: Jboss 5.0 GA, and Jboss AS 7.0
One of the things you should consider before choosing a dependency is how well supported the library is. I've never heard of this library, but it looks like the latest release, 1.4.0, was in July 2009. There are mailing lists, but that page says to use the forums, the latest post being nearly a year ago. I don't think I would trust my application on a dependency that has that little activity.
If you want to proceed, look through the list of issues and see if someone has had the same problem and posted a work around. Search the mailing lists for the same. Last, try posting a message to the forums or mailing list.