This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Struts and the fly likes List of all action mappings in struts config.xml Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "List of all action mappings in struts config.xml" Watch "List of all action mappings in struts config.xml" New topic
Author

List of all action mappings in struts config.xml

Lakshmi Ashok
Greenhorn

Joined: Jun 06, 2006
Posts: 5
I have a struts-config.xml file with
<action-mappings>
<action path="/path1" ....></action>
<action path="/path2" ....></action>
<action path="/path3" ....></action>
</action-mappings>

Is there a way I can get a list of all the paths I have mentioned in my struts config file?

In the above case, I want to dynamically get path1,path2 and path3 as a complete listing of the mappings I have added.

Whenever I make any changes to the mapping, say, a deletion
<action-mappings>
<action path="/path2" ....></action>
<action path="/path3" ....></action>
</action-mappings>

I want to dynamically get path1 and path3 as a complete listing of the mappings I have added.

IS this possible at all?
Merrill Higginson
Ranch Hand

Joined: Feb 15, 2005
Posts: 4864
This question was answered recently in this thread.


Merrill
Consultant, Sima Solutions
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: List of all action mappings in struts config.xml
 
Similar Threads
How to pass a dynamic parameter in struts-config.xml?
Jsp refering to itself
How are sessions created in struts?
classpath
Struts with tiles - Urgent help needed.