org.scijava.plugin
Class AbstractHandlerService<DT,PT extends HandlerPlugin<DT>>

java.lang.Object
  extended by org.scijava.AbstractContextual
      extended by org.scijava.plugin.AbstractRichPlugin
          extended by org.scijava.service.AbstractService
              extended by org.scijava.plugin.AbstractPTService<PT>
                  extended by org.scijava.plugin.AbstractSingletonService<PT>
                      extended by org.scijava.plugin.AbstractHandlerService<DT,PT>
Type Parameters:
DT - Base data type handled by the handlers.
PT - Plugin type of the handlers.
All Implemented Interfaces:
Comparable<Prioritized>, Contextual, Disposable, HandlerService<DT,PT>, HasPluginInfo, PTService<PT>, RichPlugin, SciJavaPlugin, SingletonService<PT>, TypedService<DT,PT>, Prioritized, Service, Typed<DT>
Direct Known Subclasses:
DefaultConsoleService, DefaultDragAndDropService, DefaultIOService, DefaultTextService

public abstract class AbstractHandlerService<DT,PT extends HandlerPlugin<DT>>
extends AbstractSingletonService<PT>
implements HandlerService<DT,PT>

Abstract base class for HandlerServices.

Author:
Curtis Rueden

Constructor Summary
AbstractHandlerService()
           
 
Method Summary
 PT getHandler(DT data)
          Gets the most appropriate handler for the given data object, or null if no handler supports it.
 boolean supports(DT data)
          Gets whether the given data object is supported.
 
Methods inherited from class org.scijava.plugin.AbstractSingletonService
filterInstances, getInstance, getInstances, initialize
 
Methods inherited from class org.scijava.plugin.AbstractPTService
getPlugins, getPluginService
 
Methods inherited from class org.scijava.service.AbstractService
dispose, getContext, registerEventHandlers, setContext, toString
 
Methods inherited from class org.scijava.plugin.AbstractRichPlugin
compareTo, getInfo, getPriority, setInfo, setPriority
 
Methods inherited from class org.scijava.AbstractContextual
context
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.scijava.plugin.HandlerService
getInstances
 
Methods inherited from interface org.scijava.plugin.SingletonService
getInstance
 
Methods inherited from interface org.scijava.plugin.PTService
getPlugins, getPluginService, getPluginType
 
Methods inherited from interface org.scijava.service.Service
initialize, registerEventHandlers
 
Methods inherited from interface org.scijava.Contextual
context, getContext, setContext
 
Methods inherited from interface org.scijava.Prioritized
getPriority, setPriority
 
Methods inherited from interface java.lang.Comparable
compareTo
 
Methods inherited from interface org.scijava.plugin.HasPluginInfo
getInfo, setInfo
 
Methods inherited from interface org.scijava.Disposable
dispose
 
Methods inherited from interface org.scijava.Typed
getType
 

Constructor Detail

AbstractHandlerService

public AbstractHandlerService()
Method Detail

getHandler

public PT getHandler(DT data)
Description copied from interface: HandlerService
Gets the most appropriate handler for the given data object, or null if no handler supports it.

Specified by:
getHandler in interface HandlerService<DT,PT extends HandlerPlugin<DT>>

supports

public boolean supports(DT data)
Description copied from interface: HandlerService
Gets whether the given data object is supported.

Specified by:
supports in interface HandlerService<DT,PT extends HandlerPlugin<DT>>
Specified by:
supports in interface Typed<DT>


Copyright © 2009–2014 SciJava. All rights reserved.