To provide a simple possibility to customize the functionality of MDL files without editing it is possible to use and modify environment variables as string values. The following syntax is used to specify the value of an environment variable:
set $variable_name = stringExpression ;
The stringExpression may itself contain environment variables which will be resolved when the .mdl file is parsed as shown in Example 3.2.
set $VMODELPATH = ".:$VPROJECT/modeltest/mdldefs";
Example 3.2: Setting environment variables
Environment variables can be used in any context where values of the type MdlString are expected:
Parameter<MdlString> inputFileName = $VPROJECT + "/promisnt/exa/test.mdl";
Example 3.3: Usage of environment variables in MdlString expressions
Table 3.1 lists environment variables with direct influence to the behavior of the MDL interpreter.
|VMODELPATH||search path for .mdl files (Section 3.1.5)|
|VLIBRARYPATH||search path for dynamically loaded C++ libraries (Section 3.1.6)|
|MDLPREFIXSTRING||prefix used for the definition of MDL classes (Section 3.6)|