tango.sys.Environment
License:
BSD style:
Version:
Feb 2007: Initial release
author:
Deewiant, Maxter, Gregor, Kris
- struct Environment;
- Exposes the system Environment settings, along with some handy
utilities
- static char[] toAbsolute(char[] path);
- Returns an absolute version of the provided path, where cwd is used
as the prefix.
The provided path is returned as is if already absolute.
- static FilePath exePath(char[] file);
- Returns the full path location of the provided executable
file, rifling through the PATH as necessary.
Returns null if the provided filename was not found
- static char[] get(const(char)[] variable, char[] def = null);
- Returns the provided 'def' value if the variable
does not exist
Posix implementation
- static void set(const(char)[] variable, const(char)[] value = null);
- clears the variable, if value is null or empty
Posix implementation
- static char[][const(char)[]] get();
- Get all set environment variables as an associative
array.
Posix implementation
- static void cwd(const(char)[] path);
- Set the current working directory
Posix implementation
- static char[] cwd();
- Get the current working directory
Posix implementation
Page generated by Ddoc. Copyright (c) 2007 Tango. All rights reserved