DT
- Base data type wrapped by the wrappers.PT
- Plugin type of the wrappers.public abstract class AbstractWrapperService<DT,PT extends WrapperPlugin<DT>> extends AbstractTypedService<DT,PT> implements WrapperService<DT,PT>
WrapperService
s.Constructor and Description |
---|
AbstractWrapperService() |
Modifier and Type | Method and Description |
---|---|
<D extends DT> |
create(D data)
Creates a new plugin instance wrapping the given associated data object.
|
void |
initialize()
Performs any needed initialization when the service is first loaded.
|
boolean |
supports(DT data)
Gets whether this object is compatible with the given data object.
|
create, getPlugins, getPluginService
dispose, getContext, registerEventHandlers, setContext, toString
compareTo, getInfo, getPriority, setInfo, setPriority
context
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
create, getPlugins, getPluginService, getPluginType
registerEventHandlers
context, getContext, setContext
getPriority, setPriority
compareTo
getInfo, setInfo
dispose
public <D extends DT> PT create(D data)
WrapperService
create
in interface WrapperService<DT,PT extends WrapperPlugin<DT>>
public void initialize()
Service
NB: This method is not intended to be called directly. It is called by
the service framework itself (specifically by the ServiceHelper
)
when initializing the service. It should not be called a second time.
initialize
in interface Service
initialize
in class AbstractService
public boolean supports(DT data)
Typed
By default, this method will return true
always, since the type is
known to be compatible. But individual implementations may have other
requirements beyond class assignability.
Copyright © 2009–2015 SciJava. All rights reserved.