commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mark R. Diggory" <mdigg...@latte.harvard.edu>
Subject [configuration][digester] Other XML file formats...
Date Wed, 11 Feb 2004 18:52:48 GMT
I have an XML config file format I'm trying to read into Configurator or 
Digester which is not the standard format expected (and which I cannot 
change), it looks like:

<Config name="user_config">
     <Variable type="option" key="DEBUG" value="1" />
     <Variable type="option" key="SQUID_DIR_SIZE" value="750" />
     <Variable type="option" key="auto" value="1" />
     <Variable type="option" key="build_all" value="0" />
     <Variable type="option" key="help" value="0" />

which I'd like to get handled as
value = user_config.<type>.<key> or value = user_config.<type>[<key>]

my ultimate goal is to plug it into the tomcat JNDI Resources as to 
attain something more like this in the long run:

Context ctx = new InitialContext();
ctx.lookup("java:comp/env/userconfig/<type>/<key>

Is there a quick way I can get to this format using using digester or 
configuration?

thx,
Mark

-- 
Mark Diggory
Software Developer
Harvard MIT Data Center
http://www.hmdc.harvard.edu

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message