Package org.scijava.text
Class DefaultTextService
-
- All Implemented Interfaces:
Comparable<Prioritized>,Contextual,Disposable,Identifiable,Initializable,Locatable,Logged,HandlerService<File,TextFormat>,HasPluginInfo,PTService<TextFormat>,RichPlugin,SciJavaPlugin,SingletonService<TextFormat>,TypedService<File,TextFormat>,Prioritized,SciJavaService,Service,TextService,Typed<File>,Versioned
public final class DefaultTextService extends AbstractHandlerService<File,TextFormat> implements TextService
Default service for working with text formats.- Author:
- Curtis Rueden
-
-
Constructor Summary
Constructors Constructor Description DefaultTextService()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringasHTML(File file)Expresses the given text string as HTML.Class<TextFormat>getPluginType()Gets the type of plugins managed by this service.Class<File>getType()Gets the type associated with the object.Stringopen(File file)Reads the data from the given file into a string.-
Methods inherited from class org.scijava.plugin.AbstractSingletonService
getInstance, getInstances, objectService, onEvent, onEvent
-
Methods inherited from class org.scijava.plugin.AbstractPTService
pluginService
-
Methods inherited from class org.scijava.service.AbstractService
getContext, setContext, toString
-
Methods inherited from class org.scijava.plugin.AbstractRichPlugin
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.Contextual
context, getContext, setContext
-
Methods inherited from interface org.scijava.Disposable
dispose
-
Methods inherited from interface org.scijava.plugin.HasPluginInfo
getInfo, setInfo
-
Methods inherited from interface org.scijava.Locatable
getLocation
-
Methods inherited from interface org.scijava.Prioritized
compareTo, getPriority, setPriority
-
Methods inherited from interface org.scijava.plugin.PTService
getPlugins, getPluginService, pluginService
-
Methods inherited from interface org.scijava.plugin.RichPlugin
getIdentifier, log
-
Methods inherited from interface org.scijava.service.Service
registerEventHandlers
-
Methods inherited from interface org.scijava.plugin.SingletonService
create, filterInstances, getInstance, initialize, objectService
-
Methods inherited from interface org.scijava.text.TextService
getHandler, getInstances, supports
-
Methods inherited from interface org.scijava.plugin.TypedService
find
-
Methods inherited from interface org.scijava.Versioned
getVersion
-
-
-
-
Method Detail
-
open
public String open(File file) throws IOException
Description copied from interface:TextServiceReads the data from the given file into a string.- Specified by:
openin interfaceTextService- Throws:
IOException
-
asHTML
public String asHTML(File file) throws IOException
Description copied from interface:TextServiceExpresses the given text string as HTML.- Specified by:
asHTMLin interfaceTextService- Throws:
IOException
-
getPluginType
public Class<TextFormat> getPluginType()
Description copied from interface:PTServiceGets the type of plugins managed by this service.- Specified by:
getPluginTypein interfacePTService<TextFormat>
-
-