Package org.esa.snap.core.dataio
Interface ProductReaderPlugIn
-
- All Superinterfaces:
ProductIOPlugIn
- All Known Implementing Classes:
DimapProductReaderPlugIn
,ImageProductReaderPlugIn
public interface ProductReaderPlugIn extends ProductIOPlugIn
TheProductReaderPlugIn
interface is implemented by data product reader plug-ins.ProductReaderPlugIn plug-ins are used to provide meta-information about a particular data format and to create instances of the actual reader objects.
A plug-in can register itself in the
ProductIO
plug-in registry or it is automatically found during a classpath scan.Consider reading the developer guide when implementing a new product reader in the wiki:
How to create a new product reader- See Also:
ProductWriterPlugIn
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description ProductReader
createReaderInstance()
Creates an instance of the actual product reader class.DecodeQualification
getDecodeQualification(Object input)
Gets the qualification of the product reader to decode a given input object.Class[]
getInputTypes()
Returns an array containing the classes that represent valid input types for this reader.default MetadataInspector
getMetadataInspector()
-
Methods inherited from interface org.esa.snap.core.dataio.ProductIOPlugIn
getDefaultFileExtensions, getDescription, getFormatNames, getProductFileFilter
-
-
-
-
Method Detail
-
getDecodeQualification
DecodeQualification getDecodeQualification(Object input)
Gets the qualification of the product reader to decode a given input object. Things to consider when implementing this method:- make sure method always succeeds; ensure that no exception is thrown
- make sure that it is fast (terminates within milliseconds)
- make sure method is thread safe
- use the INTENDED qualification with care; generic readers shall return SUITABLE at most
- Parameters:
input
- the input object- Returns:
- the decode qualification
-
getInputTypes
Class[] getInputTypes()
Returns an array containing the classes that represent valid input types for this reader.Instances of the classes returned in this array are valid objects for the
setInput
method of theProductReader
interface (the method will not throw anInvalidArgumentException
in this case).- Returns:
- an array containing valid input types, never
null
-
createReaderInstance
ProductReader createReaderInstance()
Creates an instance of the actual product reader class. This method should never returnnull
.- Returns:
- a new reader instance, never
null
-
getMetadataInspector
default MetadataInspector getMetadataInspector()
-
-