net.proxy.sunproxy
Class WinRegistry
java.lang.Object
net.proxy.sunproxy.WinRegistry
public class WinRegistry
- extends java.lang.Object
A simple cover class for the Windows registry. The API is
similar to the Windows C registry API.
Method Summary |
static boolean |
deleteKey(int hKey,
java.lang.String path)
|
static boolean |
doesSubKeyExist(int hKey,
java.lang.String path)
Returns true if the subkey path exists in
hkey . |
static boolean |
doReboot()
|
static java.lang.Object |
get(int hKey,
java.lang.String path,
java.lang.String name)
|
static java.lang.Integer |
getInteger(int hKey,
java.lang.String path,
java.lang.String name)
|
static java.lang.String |
getString(int hKey,
java.lang.String path,
java.lang.String name)
|
static java.lang.String |
getWindowsDirectory()
[TBD] This should move to another class. |
static boolean |
setStringValue(int hKey,
java.lang.String path,
java.lang.String name,
java.lang.String value)
|
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
HKEY_CLASSES_ROOT
public static final int HKEY_CLASSES_ROOT
- See Also:
- Constant Field Values
HKEY_CURRENT_USER
public static final int HKEY_CURRENT_USER
- See Also:
- Constant Field Values
HKEY_LOCAL_MACHINE
public static final int HKEY_LOCAL_MACHINE
- See Also:
- Constant Field Values
HKEY_USERS
public static final int HKEY_USERS
- See Also:
- Constant Field Values
HKEY_PERFORMANCE_DATA
public static final int HKEY_PERFORMANCE_DATA
- See Also:
- Constant Field Values
HKEY_CURRENT_CONFIG
public static final int HKEY_CURRENT_CONFIG
- See Also:
- Constant Field Values
HKEY_DYN_DATA
public static final int HKEY_DYN_DATA
- See Also:
- Constant Field Values
WinRegistry
public WinRegistry()
getWindowsDirectory
public static java.lang.String getWindowsDirectory()
- [TBD] This should move to another class.
get
public static java.lang.Object get(int hKey,
java.lang.String path,
java.lang.String name)
getString
public static java.lang.String getString(int hKey,
java.lang.String path,
java.lang.String name)
getInteger
public static java.lang.Integer getInteger(int hKey,
java.lang.String path,
java.lang.String name)
setStringValue
public static boolean setStringValue(int hKey,
java.lang.String path,
java.lang.String name,
java.lang.String value)
doesSubKeyExist
public static boolean doesSubKeyExist(int hKey,
java.lang.String path)
- Returns true if the subkey
path
exists in
hkey
.
deleteKey
public static boolean deleteKey(int hKey,
java.lang.String path)
doReboot
public static boolean doReboot()