public interface DataManager
| Modifier and Type | Method and Description | 
|---|---|
void | 
addAndConfigureProcessor(ProcessorPlugin plugin)
Add a new instance of the given ProcessorPlugin to the current
 application image processing pipeline. 
 | 
void | 
addConfiguredProcessor(ProcessorConfigurator config,
                      ProcessorPlugin plugin)
Add the provide ProcessorConfigurator onto the end of the application
 image processing pipeline. 
 | 
void | 
clearPipeline()
Clear the current application pipeline, so that no on-the-fly image
 processing is performed. 
 | 
Image | 
convertTaggedImage(mmcorej.TaggedImage tagged)
Given a TaggedImage input, output an Image based on the TaggedImage. 
 | 
Image | 
convertTaggedImage(mmcorej.TaggedImage tagged,
                  Coords coords,
                  Metadata metadata)
Given a TaggedImage input, output an Image based on the TaggedImage,
 but with the Coords and/or Metadata optionally overridden. 
 | 
Coords.Builder | 
coordsBuilder()
Generate a "blank" CoordsBuilder for use in constructing new Coords
 instances. 
 | 
Pipeline | 
copyApplicationPipeline(Datastore store,
                       boolean isSynchronous)
Create a copy of the current application Pipeline as configured in the
 "Data Processing Pipeline" window. 
 | 
Pipeline | 
copyLivePipeline(Datastore store,
                boolean isSynchronous)
Create a copy of the current Live Pipeline as configured in the
 "Data Processing Pipeline" window. 
 | 
Coords | 
createCoords(java.lang.String def)
Deprecated. 
 
use of Strings for Coords is discouraged 
 | 
Image | 
createImage(java.lang.Object pixels,
           int width,
           int height,
           int bytesPerPixel,
           int numComponents,
           Coords coords,
           Metadata metadata)
Generate a new Image with the provided pixel data, rules for interpreting
 that pixel data, coordinates, and metadata. 
 | 
Datastore | 
createMultipageTIFFDatastore(Datastore storeToCopy,
                            java.lang.String directory,
                            boolean shouldGenerateSeparateMetadata,
                            boolean shouldSplitPositions)  | 
Datastore | 
createMultipageTIFFDatastore(java.lang.String directory,
                            boolean shouldGenerateSeparateMetadata,
                            boolean shouldSplitPositions)
Generate a new, "blank" Datastore with multipage TIFF-based Storage and
 return it. 
 | 
Pipeline | 
createPipeline(java.util.List<ProcessorFactory> factories,
              Datastore store,
              boolean isSynchronous)
Create a new Pipeline using the provided list of ProcessorFactories. 
 | 
Datastore | 
createRAMDatastore()
Generate a new, "blank" Datastore with RAM-based Storage and return it. 
 | 
Datastore | 
createRAMDatastore(Datastore storeToCopy)  | 
RewritableDatastore | 
createRewritableRAMDatastore()
Generate a new, "blank" RewritableDatastore with RAM-based Storage and
 return it. 
 | 
RewritableDatastore | 
createRewritableRAMDatastore(Datastore storeToCopy)  | 
Datastore | 
createSinglePlaneTIFFSeriesDatastore(Datastore storeToCopy,
                                    java.lang.String directory)  | 
Datastore | 
createSinglePlaneTIFFSeriesDatastore(java.lang.String directory)
Generate a new, "blank" Datastore whose Storage is a series of
 single-plane TIFF files. 
 | 
java.util.List<ProcessorConfigurator> | 
getApplicationPipelineConfigurators(boolean includeDisabled)
Return a list of the ProcessorConfigurators currently being used by the
 application pipeline interface. 
 | 
Coords.Builder | 
getCoordsBuilder()
Deprecated. 
 
Use  
coordsBuilder() instead | 
ImageJConverter | 
getImageJConverter()
Provide access to the ImageJConverter() object. 
 | 
java.util.List<ProcessorConfigurator> | 
getLivePipelineConfigurators(boolean includeDisabled)
Return a list of the ProcessorConfigurators currently being used by the
 live pipeline interface. 
 | 
Metadata.Builder | 
getMetadataBuilder()
Deprecated. 
 
Use  
metadataBuilder() instead | 
Datastore.SaveMode | 
getPreferredSaveMode()
Return the save mode that the user prefers to use. 
 | 
PropertyMap.Builder | 
getPropertyMapBuilder()
Deprecated. 
 
Use PropertyMaps.builder() instead 
 | 
SummaryMetadata.Builder | 
getSummaryMetadataBuilder()
Deprecated. 
 
Use  
summaryMetadataBuilder() instead | 
java.lang.String | 
getUniqueSaveDirectory(java.lang.String path)
Given a path string, create a unique string with that name. 
 | 
ImageJConverter | 
ij()
Provide access to the ImageJConverter() object. 
 | 
boolean | 
isApplicationPipelineStepEnabled(int index)
Checks whether or not the plugin at position `index` in the list is enabled
 for the application pipeline. 
 | 
boolean | 
isLivePipelineStepEnabled(int index)
Checks whether or not the plugin at position `index` in the list is enabled
 for the live pipeline. 
 | 
Datastore | 
loadData(java.awt.Component parent,
        java.lang.String directory,
        boolean isVirtual)
Load the image data at the specified location on disk, and return a
 Datastore for that data. 
 | 
Datastore | 
loadData(java.lang.String directory,
        boolean isVirtual)
Load the image data at the specified location on disk, and return a
 Datastore for that data. 
 | 
PropertyMap | 
loadPropertyMap(java.lang.String path)
Deprecated. 
 
use  
PropertyMaps.loadJSON(File) instead | 
Metadata.Builder | 
metadataBuilder()
Generate a "blank" MetadataBuilder for use in constructing new
 Metadata instances. 
 | 
void | 
notifyPipelineChanged()
Notify the application that the state of one of the processors in the
 pipeline has changed, and thus that entities that use the application
 pipeline should grab a new copy of it. 
 | 
Datastore | 
promptForDataToLoad(java.awt.Window parent,
                   boolean isVirtual)
Display a dialog prompting the user to select a location on disk, and
 invoke loadData() on that selection. 
 | 
void | 
setApplicationPipeline(java.util.List<ProcessorPlugin> plugins)
Set the current application pipeline to be the provided list of
 ProcessorPlugins. 
 | 
void | 
setApplicationPipelineStepEnabled(int index,
                                 boolean enabled)
Sets whether or not the plugin at position `index` in the list is enabled
 for the application pipeline. 
 | 
void | 
setLivePipelineStepEnabled(int index,
                          boolean enabled)
Sets whether or not the plugin at position `index` in the list is enabled
 for the live pipeline. 
 | 
SummaryMetadata.Builder | 
summaryMetadataBuilder()
Generate a "blank" SummaryMetadataBuilder for use in constructing new
 SummaryMetadata instances. 
 | 
Image | 
wrapImage(java.lang.Object pixels,
         int width,
         int height,
         int bytesPerPixel,
         int numComponents,
         Coords coords,
         Metadata metadata)
Generate a new Image with the provided pixel data, rules for interpreting
 that pixel data, coordinates, and metadata. 
 | 
Coords.Builder coordsBuilder()
@Deprecated Coords.Builder getCoordsBuilder()
coordsBuilder() instead@Deprecated Coords createCoords(java.lang.String def) throws java.lang.IllegalArgumentException
def - Normalized coordinate definition string.java.lang.IllegalArgumentException - if the definition string is
         malformatted.Datastore createRAMDatastore()
RewritableDatastore createRewritableRAMDatastore()
RewritableDatastore createRewritableRAMDatastore(Datastore storeToCopy)
Datastore createMultipageTIFFDatastore(java.lang.String directory, boolean shouldGenerateSeparateMetadata, boolean shouldSplitPositions) throws java.io.IOException
directory - Location on disk to store the file(s).shouldGenerateSeparateMetadata - if true, a separate metadata.txt
        file will be generated.shouldSplitPositions - if true, then each stage position (per
        Coords.STAGE_POSITION) will be in a separate file.java.io.IOException - if any errors occur while opening files for writing.Datastore createMultipageTIFFDatastore(Datastore storeToCopy, java.lang.String directory, boolean shouldGenerateSeparateMetadata, boolean shouldSplitPositions) throws java.io.IOException
java.io.IOExceptionDatastore createSinglePlaneTIFFSeriesDatastore(java.lang.String directory) throws java.io.IOException
directory - Location on disk to store the files.java.io.IOException - If the directory already exists.Datastore createSinglePlaneTIFFSeriesDatastore(Datastore storeToCopy, java.lang.String directory) throws java.io.IOException
java.io.IOExceptionjava.lang.String getUniqueSaveDirectory(java.lang.String path)
path - String used to create a unique nameDatastore promptForDataToLoad(java.awt.Window parent, boolean isVirtual) throws java.io.IOException
parent - Window to show the dialog on top of. May be null.isVirtual - if true, then only the data required will be loaded from
        disk; otherwise the entire dataset will be loaded. See note on
        loadData.java.io.IOException - if loadData() encountered difficulties.Datastore loadData(java.lang.String directory, boolean isVirtual) throws java.io.IOException
directory - Location on disk from which to pull image data.isVirtual - If true, then only load images into RAM as they are
        requested. This reduces RAM utilization and has a lesser delay
        at the start of image viewing, but has worse performance if the
        entire dataset needs to be viewed or manipulated.java.io.IOException - if there was any error in reading the data.Datastore loadData(java.awt.Component parent, java.lang.String directory, boolean isVirtual) throws java.io.IOException
parent - GUI object over which to place progress indicators
                When null, center of the screen will be useddirectory - Location on disk from which to pull image data.isVirtual - If true, then only load images into RAM as they are
        requested. This reduces RAM utilization and has a lesser delay
        at the start of image viewing, but has worse performance if the
        entire dataset needs to be viewed or manipulated.java.io.IOException - if there was any error in reading the data.Datastore.SaveMode getPreferredSaveMode()
Image createImage(java.lang.Object pixels, int width, int height, int bytesPerPixel, int numComponents, Coords coords, Metadata metadata)
pixels - A byte[] or short[] array of unsigned pixel data. This array
               will be copied, so changes in this array will not be propagated
               to the Imagewidth - Width of the image, in pixelsheight - Height of the image, in pixelsbytesPerPixel - How many bytes are allocated to each pixel in the
        image. Currently only 1, 2, and 4-byte images are supported.numComponents - How many colors are encoded into each pixel.
        Currently only 1-component (grayscale) and 3-component (RGB)
        images are supported.coords - Coordinates defining the position of the Image within a
        larger dataset.metadata - Image metadata.java.lang.IllegalArgumentException - if the pixels array has length less than
         width * height.Image wrapImage(java.lang.Object pixels, int width, int height, int bytesPerPixel, int numComponents, Coords coords, Metadata metadata)
pixels - A byte[] or short[] array of unsigned pixel data. This array will
               be used as provided, so changes in pixel values will result in
               changes to this imagewidth - Width of the image, in pixelsheight - Height of the image, in pixelsbytesPerPixel - How many bytes are allocated to each pixel in the
        image. Currently only 1, 2, and 4-byte images are supported.numComponents - How many colors are encoded into each pixel.
        Currently only 1-component (grayscale) and 3-component (RGB)
        images are supported.coords - Coordinates defining the position of the Image within a
        larger dataset.metadata - Image metadata.java.lang.IllegalArgumentException - if the pixels array has length less than
         width * height.Image convertTaggedImage(mmcorej.TaggedImage tagged) throws mmcorej.org.json.JSONException, java.lang.IllegalArgumentException
tagged - TaggedImage to be convertedmmcorej.org.json.JSONException - if the TaggedImage's metadata cannot be readjava.lang.IllegalArgumentException - if portions of the TaggedImage's
         metadata are malformed.Image convertTaggedImage(mmcorej.TaggedImage tagged, Coords coords, Metadata metadata) throws mmcorej.org.json.JSONException, java.lang.IllegalArgumentException
tagged - TaggedImage to be convertedcoords - Coords at which the new image is located. If null, then
        the coordinate information in the TaggedImage will be used.metadata - Metadata for the new image. If null, then the metadata
        will be derived from the TaggedImage instead.mmcorej.org.json.JSONException - if the TaggedImage's metadata cannot be readjava.lang.IllegalArgumentException - if portions of the TaggedImage's metadata are
         malformed.@Deprecated Metadata.Builder getMetadataBuilder()
metadataBuilder() insteadMetadata.Builder metadataBuilder()
@Deprecated SummaryMetadata.Builder getSummaryMetadataBuilder()
summaryMetadataBuilder() insteadSummaryMetadata.Builder summaryMetadataBuilder()
@Deprecated PropertyMap.Builder getPropertyMapBuilder()
@Deprecated PropertyMap loadPropertyMap(java.lang.String path) throws java.io.FileNotFoundException, java.io.IOException
PropertyMaps.loadJSON(File) insteadpath - Path to the file to load.java.io.FileNotFoundException - if the path does not point to a file.java.io.IOException - if there was an error reading the file.Pipeline createPipeline(java.util.List<ProcessorFactory> factories, Datastore store, boolean isSynchronous)
factories - List of ProcessorFactories which will each be used, in
        order, to create a Processor for the new Pipeline.store - Datastore in which Images should be stored after making
        their way through the Pipeline.isSynchronous - If true, then every call to Pipeline.insertImage()
        will block until the input Image has been "fully consumed" by
        the pipeline (any result Image(s) have been added to the Datastore
        the Pipeline is connected to). If false, then a separate thread
        is created for each Processor in the Pipeline, in which that
        Processor's work is done, and any call to Pipeline.insertImage()
        will return as soon as the first processor in the pipeline begins
        processing the image. The output images from the pipeline will
        arrive in the Datastore at some indeterminate later time.Pipeline copyApplicationPipeline(Datastore store, boolean isSynchronous)
store - Datastore in which Images should be stored after making
        their way through the Pipeline.isSynchronous - If true, then every call to Pipeline.insertImage()
        will block until the input Image has been "fully consumed" by
        the pipeline (any result Image(s), if any, have been added to the
        Datastore the Pipeline is connected to). If false,
        Pipeline.insertImage() will return immediately and the Images will
        arrive in the Datastore at some indeterminate later time.Pipeline copyLivePipeline(Datastore store, boolean isSynchronous)
store - Datastore in which Images should be stored after making
        their way through the Pipeline.isSynchronous - If true, then every call to Pipeline.insertImage()
        will block until the input Image has been "fully consumed" by
        the pipeline (any result Image(s), if any, have been added to the
        Datastore the Pipeline is connected to). If false,
        Pipeline.insertImage() will return immediately and the Images will
        arrive in the Datastore at some indeterminate later time.java.util.List<ProcessorConfigurator> getApplicationPipelineConfigurators(boolean includeDisabled)
includeDisabled - determines whether or not to include configurators that are not currently enabled.java.util.List<ProcessorConfigurator> getLivePipelineConfigurators(boolean includeDisabled)
includeDisabled - determines whether or not to include configurators that are not currently enabled.void clearPipeline()
void addAndConfigureProcessor(ProcessorPlugin plugin)
ProcessorConfigurator for that plugin
 will be run.plugin - instance of a ProcessorPlugin that will be
        added to the current application image processing pipelinevoid addConfiguredProcessor(ProcessorConfigurator config, ProcessorPlugin plugin)
config - The ProcessorConfigurator that is responsible for
        configuring this processor.plugin - The ProcessorPlugin that the ProcessorConfigurator came
        from.void setApplicationPipeline(java.util.List<ProcessorPlugin> plugins)
plugins - List of ProcessorPlugins that will henceforth be used as
        the application's processor pipelineboolean isApplicationPipelineStepEnabled(int index)
index - an int determining which position in the list to checkvoid setApplicationPipelineStepEnabled(int index,
                                       boolean enabled)
index - an int determining which position in the list to checkenabled - of whether or not the plugin should be enabled.boolean isLivePipelineStepEnabled(int index)
index - an int determining which position in the list to checkvoid setLivePipelineStepEnabled(int index,
                                boolean enabled)
index - an int determining which position in the list to checkenabled - of whether or not the plugin should be enabled.void notifyPipelineChanged()
ImageJConverter ij()
ImageJConverter getImageJConverter()