Package org.eclipse.ui
Class AbstractSourceProvider
java.lang.Object
org.eclipse.ui.AbstractSourceProvider
- All Implemented Interfaces:
- ISourceProvider
 An implementation of ISourceProvider that provides listener
 support. Subclasses need only call fireSourceChanged whenever
 appropriate.
 
- Since:
- 3.1
- 
Field SummaryFieldsModifier and TypeFieldDescriptionprotected static booleanWhether source providers should print out debugging information to the console when events arrive.
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionfinal voidAdds a listener to this source provider.protected final voidfireSourceChanged(int sourcePriority, String sourceName, Object sourceValue) Notifies all listeners that a single source has changed.protected final voidfireSourceChanged(int sourcePriority, Map sourceValuesByName) Notifies all listeners that multiple sources have changed.voidinitialize(IServiceLocator locator) This method is called when the source provider is instantiated byorg.eclipse.ui.services.protected final voidlogDebuggingInfo(String message) Logs a debugging message in an appropriate manner.final voidRemoves a listener from this source provider.Methods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.eclipse.ui.ISourceProviderdispose, getCurrentState, getProvidedSourceNames
- 
Field Details- 
DEBUGprotected static boolean DEBUGWhether source providers should print out debugging information to the console when events arrive.- Since:
- 3.2
 
 
- 
- 
Constructor Details- 
AbstractSourceProviderpublic AbstractSourceProvider()
 
- 
- 
Method Details- 
addSourceProviderListenerDescription copied from interface:ISourceProviderAdds a listener to this source provider. This listener will be notified whenever the corresponding source changes.- Specified by:
- addSourceProviderListenerin interface- ISourceProvider
- Parameters:
- listener- The listener to add; must not be- null.
 
- 
fireSourceChangedNotifies all listeners that a single source has changed.- Parameters:
- sourcePriority- The source priority that has changed.
- sourceName- The name of the source that has changed; must not be- null.
- sourceValue- The new value for the source; may be- null.
 
- 
fireSourceChangedNotifies all listeners that multiple sources have changed.- Parameters:
- sourcePriority- The source priority that has changed.
- sourceValuesByName- The map of source names (- String) to source values (- Object) that have changed; must not be- null. The names must not be- null, but the values may be- null.
 
- 
logDebuggingInfoLogs a debugging message in an appropriate manner. If the message isnullor theDEBUGisfalse, then this method does nothing.- Parameters:
- message- The debugging message to log; if- null, then nothing is logged.
- Since:
- 3.2
 
- 
removeSourceProviderListenerDescription copied from interface:ISourceProviderRemoves a listener from this source provider. This listener will be notified whenever the corresponding source changes.- Specified by:
- removeSourceProviderListenerin interface- ISourceProvider
- Parameters:
- listener- The listener to remove; must not be- null.
 
- 
initializeThis method is called when the source provider is instantiated byorg.eclipse.ui.services. Clients may override this method to perform initialization.- Parameters:
- locator- The global service locator. It can be used to retrieve services like the IContextService
- Since:
- 3.4
 
 
-