org.apache.commons.discovery.jdk

Class JDKHooks

public abstract class JDKHooks extends Object

Author: Richard A. Sitze

Constructor Summary
protected JDKHooks()
Method Summary
static JDKHooksgetJDKHooks()
Return singleton object representing JVM hooks/tools.
abstract EnumerationgetResources(ClassLoader loader, String resourceName)
abstract ClassLoadergetSystemClassLoader()
The system class loader is available for JDK 1.2 or later, if certain security conditions are met.
abstract ClassLoadergetThreadContextClassLoader()
The thread context class loader is available for JDK 1.2 or later, if certain security conditions are met.

Constructor Detail

JDKHooks

protected JDKHooks()

Method Detail

getJDKHooks

public static final JDKHooks getJDKHooks()
Return singleton object representing JVM hooks/tools. TODO: add logic to detect JDK level.

getResources

public abstract Enumeration getResources(ClassLoader loader, String resourceName)

getSystemClassLoader

public abstract ClassLoader getSystemClassLoader()
The system class loader is available for JDK 1.2 or later, if certain security conditions are met.

Returns: The system class loader, if available. Otherwise return null.

getThreadContextClassLoader

public abstract ClassLoader getThreadContextClassLoader()
The thread context class loader is available for JDK 1.2 or later, if certain security conditions are met.

Returns: The thread context class loader, if available. Otherwise return null.

Copyright (c) 2002 - Apache Software Foundation