hudson.util.jna
Class RegistryKey

java.lang.Object
  extended by hudson.util.jna.RegistryKey

public class RegistryKey
extends Object

Represents a Win32 registry key.

Author:
Kohsuke Kawaguchi

Field Summary
static RegistryKey CLASSES_ROOT
           
static RegistryKey CURRENT_USER
           
static RegistryKey LOCAL_MACHINE
           
static RegistryKey USERS
           
 
Method Summary
 void delete()
          Deletes this key (and disposes the key.)
 void deleteValue(String valueName)
           
 void dispose()
           
protected  void finalize()
           
 int getIntValue(String valueName)
          Read an int value.
 String getStringValue(String valueName)
           
 Collection<String> getSubKeys()
          Get all sub keys of a key.
 TreeMap<String,Object> getValues()
          Get all values under a key.
 RegistryKey open(String subKeyName)
           
 RegistryKey open(String subKeyName, int access)
           
 RegistryKey openReadonly(String subKeyName)
           
 void setValue(String name, int value)
          Writes a DWORD value.
 void setValue(String name, String value)
          Writes a String value.
 boolean valueExists(String name)
          Does a specified value exist?
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CLASSES_ROOT

public static final RegistryKey CLASSES_ROOT

CURRENT_USER

public static final RegistryKey CURRENT_USER

LOCAL_MACHINE

public static final RegistryKey LOCAL_MACHINE

USERS

public static final RegistryKey USERS
Method Detail

getStringValue

public String getStringValue(String valueName)

getIntValue

public int getIntValue(String valueName)
Read an int value.


deleteValue

public void deleteValue(String valueName)

setValue

public void setValue(String name,
                     String value)
Writes a String value.


setValue

public void setValue(String name,
                     int value)
Writes a DWORD value.


valueExists

public boolean valueExists(String name)
Does a specified value exist?


delete

public void delete()
Deletes this key (and disposes the key.)


getSubKeys

public Collection<String> getSubKeys()
Get all sub keys of a key.

Returns:
array with all sub key names

open

public RegistryKey open(String subKeyName)

openReadonly

public RegistryKey openReadonly(String subKeyName)

open

public RegistryKey open(String subKeyName,
                        int access)

getValues

public TreeMap<String,Object> getValues()
Get all values under a key.

Returns:
TreeMap with name and value pairs

finalize

protected void finalize()
                 throws Throwable
Overrides:
finalize in class Object
Throws:
Throwable

dispose

public void dispose()


Copyright © 2004-2013. All Rights Reserved.