DzSystem Class Reference
[General Objects]

DAZ Script's global static object for system services. More...

List of all members.

Methods

String getenv (String environmentVariable)
void print (String expression)
void println (String expression)
void setenv (String environmentVariable, String value)


Detailed Description

DAZ Script's global static object for system services.

The DzSystem object provides functions to access and manipulate environment variables. It is accessible via the System global variable.


Member Function Documentation

String DzSystem::getenv ( String  environmentVariable  ) 

Parameters:
environmentVariable The name of the environment variable to retrieve
Returns:
The String stored in environmentVariable.
Example:
        var sEnv = System.getenv( "DAZSTUDIO" );
        // sEnv == "C:\Program Files\DAZ\Studio"

void DzSystem::print ( String  expression  ) 

Deprecated:
Prints the expression to the console (stdout).
Parameters:
expression The expression to be printed - the argument will automatically be converted to a string (via toString() if necessary.

void DzSystem::println ( String  expression  ) 

Deprecated:
Prints the expression to the console (stdout), followed by a newline.
Parameters:
expression The expression to be printed - the argument will automatically be converted to a string (via toString() if necessary.

void DzSystem::setenv ( String  environmentVariable,
String  value 
)

Sets the value of an environment variable. If environment variable does not exist it is created. The environment is only changed within the context of the script process, for the duration of said process.

Parameters:
environmentVariable The environment variable to set the value of
value The new value of the environment variable.
Example:
        System.setenv( "DAZSTUDIO", App.getHomePath() );
        var sEnv = System.getenv( "DAZSTUDIO" );
        // sEnv == "C:/Program Files/DAZ/Studio"


Generated on Thu Sep 24 12:21:16 2009

Copyright © 2002 - 2009 DAZ 3D, Inc.