[Devel] exporting pseudo variables

Daniel-Constantin Mierla daniel at voice-system.ro
Fri Apr 28 13:11:21 CEST 2006


Hello,

On 04/28/2006 12:07 PM, Klaus Darilion wrote:

> Klaus Darilion wrote:
>
>> Hi!
>>
>> I'm studying how to export pseudo variables.
>>
>> In tm.c there is this code:
>>
>>         if(xl_add_extra("T_branch_idx", it_get_tm_branch_idx, 100 )!=0)
>
>
> btw: what means type=100 ?

that is an integer ID for each pseudovariable, which helps to identify 
it (for some you cannot rely on the function, since several 
pseudo-variables use same function with different parameters). For 
example, it is used to check if the parameters of some functions are 
only AVP specifiers, when required.

For extra pseudo-variable, this number is added to XL_ITEM_EXTRA, to 
avoid overlapping with the standard types. This number has importance 
only if you plan to use it inside the module, otherwise you can add any 
value there. If you set it to 0, then XL_ITEM_EXTRA will be used.

Cheers,
Daniel

>
> regards
> klaus
>
> _______________________________________________
> Devel mailing list
> Devel at openser.org
> http://openser.org/cgi-bin/mailman/listinfo/devel
>



More information about the Devel mailing list