classpathhelper.eclipse.ui
Interface IClassPathModel

All Known Implementing Classes:
AbstractClassPathModel

public interface IClassPathModel

Interface that defines an model object that can produce CGClassLoader objects representing a classpath.

This is the plugin interface required to add additional classpath sources to Classpath Helper.

Usage

Implementation Notes

Instances of this interface are introduced using Eclipse's plugin model. Use the classpathhelper.eclipse.ui.classpathmodels extension point.

Since:
1.0
Author:
bharris

Method Summary
 void addClassPathChangeListener(IClassPathChangeListener changeListener)
          Registers a classpath change listener with this model object.
 boolean removeClassPathChangeListener(IClassPathChangeListener changeListener)
          Deregisteres a classpath change listener with this model object.
 void reset()
          Method that requests that this model reset (and resend) its classpath, clearing any internal caching.
 void startClassPathListening()
          Method called to indicate that this model is the selected model and should start sending classpath change events.
 void stopClassPathListening()
          Method called to indicate that this model is nolonger the selected model and can clean up any listeners it has started (as well as any caching.
 

Method Detail

startClassPathListening

public void startClassPathListening()

Method called to indicate that this model is the selected model and should start sending classpath change events. If a model needs to attach any listeners this is a good point to do so.

A model should also use this call send its initial class loader via its IClassPathChangeListener objects.

Since:
1.0

stopClassPathListening

public void stopClassPathListening()
Method called to indicate that this model is nolonger the selected model and can clean up any listeners it has started (as well as any caching.

Since:
1.0

reset

public void reset()
Method that requests that this model reset (and resend) its classpath, clearing any internal caching.

Since:
1.0

addClassPathChangeListener

public void addClassPathChangeListener(IClassPathChangeListener changeListener)
Registers a classpath change listener with this model object. This listener should be immediately notified regarding the current classloader (if there is one) via its callback method. In otherwords calling this method may mean that the listeners callback method is called, only if a class loader already exists.

Parameters:
changeListener - The listener.
Since:
1.0

removeClassPathChangeListener

public boolean removeClassPathChangeListener(IClassPathChangeListener changeListener)
Deregisteres a classpath change listener with this model object.

Parameters:
changeListener - The listener to remove.
Returns:
true If the listener was found, false If the listener was not found.
Since:
1.0