org.scijava.text
Class DefaultTextService

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<File,TextFormat>
                          extended by org.scijava.text.DefaultTextService
All Implemented Interfaces:
Comparable<Prioritized>, Contextual, Disposable, HandlerService<File,TextFormat>, HasPluginInfo, PTService<TextFormat>, RichPlugin, SciJavaPlugin, SingletonService<TextFormat>, TypedService<File,TextFormat>, Prioritized, SciJavaService, Service, TextService, Typed<File>

public final class DefaultTextService
extends AbstractHandlerService<File,TextFormat>
implements TextService

Default service for working with text formats.

Author:
Curtis Rueden

Constructor Summary
DefaultTextService()
           
 
Method Summary
 String asHTML(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.
 String open(File file)
          Reads the data from the given file into a string.
 
Methods inherited from class org.scijava.plugin.AbstractHandlerService
getHandler, supports
 
Methods inherited from class org.scijava.plugin.AbstractSingletonService
create, 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.text.TextService
getHandler, getInstances, supports
 
Methods inherited from interface org.scijava.plugin.SingletonService
getInstance
 
Methods inherited from interface org.scijava.plugin.PTService
create, getPlugins, getPluginService
 
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
 

Constructor Detail

DefaultTextService

public DefaultTextService()
Method Detail

open

public String open(File file)
            throws IOException
Description copied from interface: TextService
Reads the data from the given file into a string.

Specified by:
open in interface TextService
Throws:
IOException

asHTML

public String asHTML(File file)
              throws IOException
Description copied from interface: TextService
Expresses the given text string as HTML.

Specified by:
asHTML in interface TextService
Throws:
IOException

getPluginType

public Class<TextFormat> getPluginType()
Description copied from interface: PTService
Gets the type of plugins managed by this service.

Specified by:
getPluginType in interface PTService<TextFormat>

getType

public Class<File> getType()
Description copied from interface: Typed
Gets the type associated with the object.

Specified by:
getType in interface Typed<File>


Copyright © 2009–2015 SciJava. All rights reserved.