|
From: David C N. <dc...@ad...> - 2004-01-12 19:44:27
|
I am trying to do some smarter use of BEEP's config file support in my
application. Is there some easy way for a profile to find out what
"dataname" its configuration came from? I would like to make use of this.
Without knowing the "dataname", how can one reliably know what to load in
for various parameters? config_get seems to require an exact path to
where the parameter you want is. So for example:
<beep ...>
<profiles>
...
</profiles>
<myappname>
<application>
<dataname1>
<criticalitem>foo1</criticalitem>
</dataname1>
<dataname2>
<criticalitem>foo2</criticalitem>
</dataname2>
</application>
</myappname>
</beep>
I'd like the profile to be able to figure out that its dataname is
"dataname1", and to figure out that its criticalitem is "foo1", as opposed
to "foo2". do I need to use the config_search_* functions? Or can I look
for a disembodied <criticalitem> and expect that the tree is pruned to
just the dataname that applies to this profile instance?
-------------------------------------------------------
-- David C. Niemi Adeptech Systems, Inc. --
-- Reston, Virginia, USA http://www.adeptech.com/ --
-------------------------------------------------------
|