-
- All Superinterfaces:
Comparable<org.scijava.Prioritized>,org.scijava.Contextual,org.scijava.plugin.HasPluginInfo,org.scijava.Identifiable,org.scijava.Locatable,org.scijava.log.Logged,org.scijava.Prioritized,org.scijava.plugin.RichPlugin,SCIFIOPlugin,org.scijava.plugin.SciJavaPlugin,org.scijava.plugin.SingletonPlugin,org.scijava.Versioned
- All Known Implementing Classes:
AbstractFormat,APNGFormat,AVIFormat,BMPFormat,DICOMFormat,EPSFormat,FITSFormat,GIFFormat,ICSFormat,ImageIOFormat,JPEG2000Format,JPEGFormat,JPEGTileFormat,KontronFormat,LegacyQTFormat,MicromanagerFormat,MinimalTIFFFormat,MNGFormat,NativeQTFormat,NRRDFormat,PCXFormat,PGMFormat,PICTFormat,ScancoISQFormat,StratecPQCTFormat,TestImgFormat,TIFFFormat,TIFFJAIFormat
public interface Format extends SCIFIOPlugin, org.scijava.plugin.SingletonPlugin
Interface for all SCIFIO formats.The
Formatis a bag for all other SCIFIO components associated with image IO in a given image format. It acts as a bridge and a black box for creating components, and facilitates component intercommunication.Formatsare typically accessed through theFormatService, which maintains a list of singletonFormatsand has many convenience methods relating to their use.- Author:
- Mark Hiner
- See Also:
SCIFIO,FormatService
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description CheckercreateChecker()Create an instance of the Checker associated with this format.MetadatacreateMetadata()Create an instance of the Metadata associated with this format.ParsercreateParser()Create an instance of the Parser associated with this format.ReadercreateReader()Creates an instance of the Reader associated with this format.WritercreateWriter()Creates an instance of the Writer associated with this format.Class<?>getCheckerClass()StringgetFormatName()Gets the name of this file format.Class<?>getMetadataClass()Class<?>getParserClass()Class<?>getReaderClass()String[]getSuffixes()Gets the default file suffixes for this file format.Class<?>getWriterClass()booleanisEnabled()default booleanownsLocationType(org.scijava.io.location.Location outputLocation)This is only needed by Format that depend on their own Location types (e.g.voidsetEnabled(boolean enabled)Toggle whether this Format should be used when checking image compatibility.-
Methods inherited from interface org.scijava.Contextual
context, getContext, setContext
-
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.RichPlugin
getIdentifier
-
Methods inherited from interface io.scif.SCIFIOPlugin
getVersion, log
-
-
-
-
Method Detail
-
setEnabled
void setEnabled(boolean enabled)
Toggle whether this Format should be used when checking image compatibility.- Parameters:
enabled- - if true, this Format will be used in image/IO. Default: true
-
isEnabled
boolean isEnabled()
- Returns:
- True if this Format is active when checking image compatibility.
-
getFormatName
String getFormatName()
Gets the name of this file format.- Returns:
- a String representation of this Format's name
-
getSuffixes
String[] getSuffixes()
Gets the default file suffixes for this file format.Sample valid suffixes:
- png
- avi
- bmp
- Returns:
- an array of extensions associated with this Format
-
createMetadata
Metadata createMetadata() throws FormatException
Create an instance of the Metadata associated with this format.- Returns:
- A new
Metadatainstance compatible with this Format's components - Throws:
FormatException
-
createChecker
Checker createChecker() throws FormatException
Create an instance of the Checker associated with this format.- Returns:
- A new
Checkerinstance which can determine if sources are compatible with this Format. - Throws:
FormatException
-
createParser
Parser createParser() throws FormatException
Create an instance of the Parser associated with this format.- Returns:
- A new
Parserinstance capable of populating Metadata compatible with this Format. - Throws:
FormatException
-
createReader
Reader createReader() throws FormatException
Creates an instance of the Reader associated with this format.- Returns:
- A new
Readerinstance capable of reading datasets of this Format. - Throws:
FormatException
-
createWriter
Writer createWriter() throws FormatException
Creates an instance of the Writer associated with this format.- Returns:
- A new
Writerinstance capable of writing datasets of this Format. - Throws:
FormatException
-
getMetadataClass
Class<?> getMetadataClass()
- Returns:
- The class of the Metadata associated with this format
-
getCheckerClass
Class<?> getCheckerClass()
- Returns:
- The class of the Checker associated with this format
-
getParserClass
Class<?> getParserClass()
- Returns:
- The class of the Parser associated with this format
-
getReaderClass
Class<?> getReaderClass()
- Returns:
- The class of the Reader associated with this format
-
getWriterClass
Class<?> getWriterClass()
- Returns:
- The class of the Writer associated with this format
-
ownsLocationType
default boolean ownsLocationType(org.scijava.io.location.Location outputLocation)
This is only needed by Format that depend on their own Location types (e.g. OMEROFormat)- Parameters:
outputLocation-- Returns:
- if this LocationType is owned by this format
-
-