7.12.2012

Android Api : How to get the system environment variables


System.getenv(String name) : Returns the value of the environment variable with the given name .

Parameter :  name -> the name of the environment variable.


How to know all of the environment variables:

Enter adb shell command line . Then key in "export" and you will get all of the environment variables.
By the way, if you want to add a environment variable,you just key in "exprot variable-name="variable-value".