org.apache.catalina
Interface Loader

All Known Implementing Classes:
WebappLoader

public interface Loader

A Loader represents a Java ClassLoader implementation that can be used by a Container to load class files (within a repository associated with the Loader) that are designed to be reloaded upon request, as well as a mechanism to detect whether changes have occurred in the underlying repository.

In order for a Loader implementation to successfully operate with a Context implementation that implements reloading, it must obey the following constraints:

Version:
$Revision: 1.6 $ $Date: 2002/09/19 22:55:47 $
Author:
Craig R. McClanahan

Method Summary
 void addPropertyChangeListener(java.beans.PropertyChangeListener listener)
          Add a property change listener to this component.
 void addRepository(java.lang.String repository)
          Add a new repository to the set of repositories for this class loader.
 java.lang.String[] findRepositories()
          Return the set of repositories defined for this class loader.
 java.lang.ClassLoader getClassLoader()
          Return the Java class loader to be used by this Container.
 Container getContainer()
          Return the Container with which this Loader has been associated.
 DefaultContext getDefaultContext()
          Return the DefaultContext with which this Manager is associated.
 boolean getDelegate()
          Return the "follow standard delegation model" flag used to configure our ClassLoader.
 java.lang.String getInfo()
          Return descriptive information about this Loader implementation and the corresponding version number, in the format <description>/<version>.
 boolean getReloadable()
          Return the reloadable flag for this Loader.
 boolean modified()
          Has the internal repository associated with this Loader been modified, such that the loaded classes should be reloaded?
 void removePropertyChangeListener(java.beans.PropertyChangeListener listener)
          Remove a property change listener from this component.
 void setContainer(Container container)
          Set the Container with which this Loader has been associated.
 void setDefaultContext(DefaultContext defaultContext)
          Set the DefaultContext with which this Manager is associated.
 void setDelegate(boolean delegate)
          Set the "follow standard delegation model" flag used to configure our ClassLoader.
 void setReloadable(boolean reloadable)
          Set the reloadable flag for this Loader.
 

Method Detail

getClassLoader

public java.lang.ClassLoader getClassLoader()
Return the Java class loader to be used by this Container.


getContainer

public Container getContainer()
Return the Container with which this Loader has been associated.


setContainer

public void setContainer(Container container)
Set the Container with which this Loader has been associated.

Parameters:
container - The associated Container

getDefaultContext

public DefaultContext getDefaultContext()
Return the DefaultContext with which this Manager is associated.


setDefaultContext

public void setDefaultContext(DefaultContext defaultContext)
Set the DefaultContext with which this Manager is associated.

Parameters:
defaultContext - The newly associated DefaultContext

getDelegate

public boolean getDelegate()
Return the "follow standard delegation model" flag used to configure our ClassLoader.


setDelegate

public void setDelegate(boolean delegate)
Set the "follow standard delegation model" flag used to configure our ClassLoader.

Parameters:
delegate - The new flag

getInfo

public java.lang.String getInfo()
Return descriptive information about this Loader implementation and the corresponding version number, in the format <description>/<version>.


getReloadable

public boolean getReloadable()
Return the reloadable flag for this Loader.


setReloadable

public void setReloadable(boolean reloadable)
Set the reloadable flag for this Loader.

Parameters:
reloadable - The new reloadable flag

addPropertyChangeListener

public void addPropertyChangeListener(java.beans.PropertyChangeListener listener)
Add a property change listener to this component.

Parameters:
listener - The listener to add

addRepository

public void addRepository(java.lang.String repository)
Add a new repository to the set of repositories for this class loader.

Parameters:
repository - Repository to be added

findRepositories

public java.lang.String[] findRepositories()
Return the set of repositories defined for this class loader. If none are defined, a zero-length array is returned.


modified

public boolean modified()
Has the internal repository associated with this Loader been modified, such that the loaded classes should be reloaded?


removePropertyChangeListener

public void removePropertyChangeListener(java.beans.PropertyChangeListener listener)
Remove a property change listener from this component.

Parameters:
listener - The listener to remove


Copyright © 2000-2002 Apache Software Foundation. All Rights Reserved.