| Author |
Getting the list of roles defined in web.xml
|
Junilu Lacar
Bartender
Joined: Feb 26, 2001
Posts: 4118
|
|
Apart from reading and parsing the web.xml, is there a way to get the list of roles defined under the <auth-constraint> element in web.xml? I want to avoid hard-coding role names in my application. If I could get the list and iterate over it, I can write my additional role-based checking/processing code just once, keeping all the variables as properties in an application config file. I could put the list of roles in the application config file as well but that would mean that we would have to remember to change both web.xml and appconfig.properties when a new role is created (yeah, I know about comments but there's no guarantee that everyone reads them). I've waded through the JavaDocs and Googled but found no joy and would appreciate if someone could point me in the right direction, even if it's to say that I'm way out in left field on this. TIA
|
Junilu - [How to Ask Questions] [How to Answer Questions] [MiH]
|
 |
 |
|
|
subject: Getting the list of roles defined in web.xml
|
|
|