public static Properties getEnvVariables ( ) throws EnvironmentException { if ( isUnix ( ) ) { return getUnixShellVariables ( ) ; } if ( isWindows ( ) ) { return getWindowsShellVariables ( ) ; } String message = "Environment operations not supported on unrecognized operatings system" ; UnsupportedOperationException cause = new UnsupportedOperationException ( message ) ; throw new EnvironmentException ( cause ) ; }
Gets all environment variables within a Properties instance where the key is the environment variable name and value is the value of the property .