org.jlab.coda.jevio
Class Environment

java.lang.Object
  extended by org.jlab.coda.jevio.Environment

public class Environment
extends java.lang.Object

This is a utility class employing a singleton to obtain environment information, such as user name, home directory, OS name, etc.

Author:
heddle

Method Summary
 java.lang.String getClassPath()
          Get the current class path.
 java.lang.String getCurrentWorkingDirectory()
          Get the current working directory.
 java.lang.String getHomeDirectory()
          Get the user's home directory.
 java.lang.String getHostName()
          Get the host name.
static Environment getInstance()
          Accessor for the singleton.
 java.lang.String getOsName()
          Get the operating system name.
 java.lang.String getTempDirectory()
          Get the temp directory.
 java.lang.String getUserName()
          Get the user name.
static void main(java.lang.String[] args)
          Main program used for testing only.
 java.lang.String toString()
          Convert to a string for diagnostics
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

getInstance

public static Environment getInstance()
Accessor for the singleton.

Returns:
the singleton Environment object.

getClassPath

public java.lang.String getClassPath()
Get the current class path.

Returns:
the current class path.

getCurrentWorkingDirectory

public java.lang.String getCurrentWorkingDirectory()
Get the current working directory.

Returns:
the current WorkingDirectory.

getHomeDirectory

public java.lang.String getHomeDirectory()
Get the user's home directory.

Returns:
the home directory.

getOsName

public java.lang.String getOsName()
Get the operating system name.

Returns:
the operating system name.

getTempDirectory

public java.lang.String getTempDirectory()
Get the temp directory.

Returns:
the temp directory.

getUserName

public java.lang.String getUserName()
Get the user name.

Returns:
the userName.

getHostName

public java.lang.String getHostName()
Get the host name.

Returns:
the host name.

toString

public java.lang.String toString()
Convert to a string for diagnostics

Overrides:
toString in class java.lang.Object
Returns:
The string

main

public static void main(java.lang.String[] args)
Main program used for testing only.

Parameters:
args -