public abstract class AbstractConvertService extends AbstractHandlerService<ConversionRequest,Converter<?,?>> implements ConvertService
ConvertService
implementations. Sets this
service as the active delegate service in ConversionUtils
.Constructor and Description |
---|
AbstractConvertService() |
Modifier and Type | Method and Description |
---|---|
Object |
convert(ConversionRequest request) |
<T> T |
convert(Object src,
Class<T> dest) |
Object |
convert(Object src,
Type dest) |
Collection<Class<?>> |
getCompatibleInputClasses(Class<?> dest) |
Collection<Object> |
getCompatibleInputs(Class<?> dest) |
Collection<Class<?>> |
getCompatibleOutputClasses(Class<?> source) |
Converter<?,?> |
getHandler(Class<?> src,
Class<?> dest) |
Converter<?,?> |
getHandler(Class<?> src,
Type dest) |
Converter<?,?> |
getHandler(Object src,
Class<?> dest) |
Converter<?,?> |
getHandler(Object src,
Type dest) |
Class<Converter<?,?>> |
getPluginType()
Gets the type of plugins managed by this service.
|
Class<ConversionRequest> |
getType()
Gets the type associated with the object.
|
void |
initialize()
Performs any needed initialization when the service is first loaded.
|
boolean |
supports(Class<?> src,
Class<?> dest) |
boolean |
supports(Class<?> src,
Type dest) |
boolean |
supports(Object src,
Class<?> dest) |
boolean |
supports(Object src,
Type dest) |
getInstance, getInstances, objectService, onEvent, onEvent
pluginService
getContext, setContext, toString
getInfo, getPriority, setInfo, setPriority
context
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getHandler, getInstances, supports
create, filterInstances, getInstance, objectService
find
getPlugins, getPluginService, pluginService
registerEventHandlers
getIdentifier, log
context, getContext, setContext
compareTo, getPriority, setPriority
getInfo, setInfo
getLocation
getVersion
dispose
public Class<Converter<?,?>> getPluginType()
PTService
getPluginType
in interface PTService<Converter<?,?>>
public Class<ConversionRequest> getType()
Typed
getType
in interface Typed<ConversionRequest>
public Converter<?,?> getHandler(Object src, Class<?> dest)
getHandler
in interface ConvertService
HandlerService.supports(Object)
public Converter<?,?> getHandler(Class<?> src, Class<?> dest)
getHandler
in interface ConvertService
HandlerService.getHandler(Object)
public Converter<?,?> getHandler(Object src, Type dest)
getHandler
in interface ConvertService
HandlerService.supports(Object)
public Converter<?,?> getHandler(Class<?> src, Type dest)
getHandler
in interface ConvertService
HandlerService.getHandler(Object)
public boolean supports(Object src, Class<?> dest)
supports
in interface ConvertService
HandlerService.supports(Object)
public boolean supports(Class<?> src, Class<?> dest)
supports
in interface ConvertService
HandlerService.supports(Object)
public boolean supports(Object src, Type dest)
supports
in interface ConvertService
HandlerService.supports(Object)
public boolean supports(Class<?> src, Type dest)
supports
in interface ConvertService
HandlerService.supports(Object)
public Collection<Object> getCompatibleInputs(Class<?> dest)
getCompatibleInputs
in interface ConvertService
public Object convert(Object src, Type dest)
convert
in interface ConvertService
Converter.convert(Object, Type)
public <T> T convert(Object src, Class<T> dest)
convert
in interface ConvertService
Converter.convert(Object, Class)
public Object convert(ConversionRequest request)
convert
in interface ConvertService
Converter.convert(ConversionRequest)
public Collection<Class<?>> getCompatibleInputClasses(Class<?> dest)
getCompatibleInputClasses
in interface ConvertService
public Collection<Class<?>> getCompatibleOutputClasses(Class<?> source)
getCompatibleOutputClasses
in interface ConvertService
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 Initializable
initialize
in interface SingletonService<Converter<?,?>>
initialize
in interface Service
Copyright © 2015–2022 SciJava. All rights reserved.