org.rhq.core.system
Class WindowsNativeSystemInfo

java.lang.Object
  extended by org.rhq.core.system.NativeSystemInfo
      extended by org.rhq.core.system.WindowsNativeSystemInfo
All Implemented Interfaces:
SystemInfo

public class WindowsNativeSystemInfo
extends NativeSystemInfo

SystemInfo implementation for the Microsoft Windows operating system platform. This class is used mainly to obtain information found in the Windows Registry.


Constructor Summary
WindowsNativeSystemInfo()
           
 
Method Summary
 List<ServiceInfo> getAllServices()
          Returns the information on all installed services found in the services manager.
 List<String> getRegistryChildKeys(RegistryEntry.Root root, String key)
          Gets a list of all the sub-keys that are direct children of the given registry key.
 List<RegistryEntry> getRegistryEntries(RegistryEntry.Root root, String key)
          Gets a list of all the value entries of the given registry key.
 RegistryEntry getRegistryEntry(RegistryEntry.Root root, String key, String name)
          Returns a registry entry (which includes its value) where the key is located under either the LOCAL_MACHINE or CURRENT_USER root registry node.
 List<String> getRegistryValueNames(RegistryEntry.Root root, String key)
          Gets a list of all the names of values of the given registry key.
 
Methods inherited from class org.rhq.core.system.NativeSystemInfo
executeProcess, getAllNetworkAdapters, getAllProcesses, getCpu, getFileSystem, getFileSystems, getHostname, getMemoryInfo, getNetworkAdapterStats, getNetworkStats, getNumberOfCpus, getOperatingSystemName, getOperatingSystemType, getOperatingSystemVersion, getProcesses, getSwapInfo, getSystemArchitecture, getThisProcess, isNative, readLineFromConsole, writeLineToConsole
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WindowsNativeSystemInfo

public WindowsNativeSystemInfo()
Method Detail

getAllServices

public List<ServiceInfo> getAllServices()
                                 throws SystemInfoException
Description copied from interface: SystemInfo
Returns the information on all installed services found in the services manager.

Specified by:
getAllServices in interface SystemInfo
Overrides:
getAllServices in class NativeSystemInfo
Returns:
list container information on all services currently installed
Throws:
SystemInfoException

getRegistryChildKeys

public List<String> getRegistryChildKeys(RegistryEntry.Root root,
                                         String key)
                                  throws SystemInfoException
Gets a list of all the sub-keys that are direct children of the given registry key. You can use the key names found in the returned list of strings as values to the key parameter for calls to #getRegistryEntry(Root, String, String).

Parameters:
root -
key -
Returns:
list of child keys
Throws:
SystemInfoException

getRegistryValueNames

public List<String> getRegistryValueNames(RegistryEntry.Root root,
                                          String key)
                                   throws SystemInfoException
Gets a list of all the names of values of the given registry key. You can use the value names found in the returned list of strings as values to the name parameter for calls to #getRegistryEntry(Root, String, String).

Parameters:
root -
key -
Returns:
list of names of values found in that registry key
Throws:
SystemInfoException

getRegistryEntries

public List<RegistryEntry> getRegistryEntries(RegistryEntry.Root root,
                                              String key)
                                       throws SystemInfoException
Gets a list of all the value entries of the given registry key.

Parameters:
root -
key -
Returns:
list of registry entries for the given registry key
Throws:
SystemInfoException

getRegistryEntry

public RegistryEntry getRegistryEntry(RegistryEntry.Root root,
                                      String key,
                                      String name)
                               throws SystemInfoException
Returns a registry entry (which includes its value) where the key is located under either the LOCAL_MACHINE or CURRENT_USER root registry node.

Parameters:
root - the root of the registry tree where the registry key is found
key - the name of the registry key
name - the name of the key entry value
Returns:
the value of the registry entry
Throws:
SystemInfoException


Copyright © 2008-2009 RHQ Project Advisory Board (Red Hat, Inc.). All Rights Reserved.