Addded capability to read parameters from main engine config file.
git-svn-id: http://voip.null.ro/svn/yate@4640 acf43c95-373e-0410-b603-e72c3f656dc1
This commit is contained in:
parent
2dc0283ae6
commit
e00cce62b9
|
@ -47,6 +47,7 @@
|
|||
; $(random,STRING) = STRING with each ? character replaced with a random digit
|
||||
; $(index,N,ITEM1,ITEM2,...) = N-th (modulo length of list) item in list
|
||||
; $(rotate,N,ITEM1,ITEM2,...) = list rotated N (modulo length of list) times
|
||||
; $(config,SECTION,KEY) = value of KEY= in [SECTION] of main config file (yate.conf, yate-qt4.conf)
|
||||
; $(engine,NAME) = value of Engine's runtime parameter NAME
|
||||
; $(runid) = the current Engine run identifier
|
||||
; $(nodename) = the node name the Engine runs as, may be empty
|
||||
|
|
|
@ -287,6 +287,11 @@ static void evalFunc(String& str)
|
|||
}
|
||||
lst->destruct();
|
||||
}
|
||||
else if ((sep >= 0) && (str == "config")) {
|
||||
str = par.substr(0,sep).trimBlanks();
|
||||
par = par.substr(sep+1).trimBlanks();
|
||||
str = Engine::config().getValue(str,par);
|
||||
}
|
||||
else if (str == "engine")
|
||||
str = Engine::runParams().getValue(vars(par));
|
||||
else if (str == "runid") {
|
||||
|
|
Loading…
Reference in New Issue