[Asterisk-cvs] asterisk/doc README.variables,1.51,1.52

markster markster
Tue Oct 18 15:22:20 CDT 2005


Update of /usr/cvsroot/asterisk/doc
In directory mongoose.digium.com:/tmp/cvs-serv7691/doc

Modified Files:
	README.variables 
Log Message:
The amazing disappearing and reappearing patch...  This time with documentation explaining it.


Index: README.variables
===================================================================
RCS file: /usr/cvsroot/asterisk/doc/README.variables,v
retrieving revision 1.51
retrieving revision 1.52
diff -u -d -r1.51 -r1.52
--- README.variables	1 Sep 2005 23:01:54 -0000	1.51
+++ README.variables	18 Oct 2005 19:16:13 -0000	1.52
@@ -66,6 +66,34 @@
 In fact, everything contained ${here} is just replaced with the value of 
 the variable "here". 
 
+____________________
+VARIABLE INHERITANCE
+--------------------
+
+Variable names which are prefixed by "_" will be inherited to channels 
+that are created in the process of servicing the original channel in 
+which the variable was set.  When the inheritance takes place, the 
+prefix will be removed in the channel inheriting the variable.  If the 
+name is prefixed by "__" in the channel, then the variable is 
+inherited and the "__" will remain intact in the new channel.
+
+In the dialplan, all references to these variables refer to the same 
+variable, regardless of having a prefix or not.  Note that setting any 
+version of the variable removes any other version of the variable, 
+regardless of prefix.
+
+Example:
+
+Set(__FOO=bar) ; Sets an inherited version of "FOO" variable 
+Set(FOO=bar)   ; Removes the inherited version and sets a local 
+               ; variable.
+
+However,
+
+NoOp(${__FOO}) is identical to NoOp(${FOO})
+
+
+
 _______________________________
 REMOVING CHARACTERS FROM STRING
 -------------------------------




More information about the svn-commits mailing list