Package org.anchoranalysis.mpp.io.input
Class MultiInput
Object
MultiInput
- All Implemented Interfaces:
ProvidesStackInput,InputFromManager,ExportSharedObjects
An input to an experiment that combines a particular
Stack with other types of entities.
These entities each have a unique name, and must be one of the following types:
Stack(in addition to the primary stack that forms the input).MarkCollection.ObjectCollection.Dictionary.Histogram.Path.
- Author:
- Owen Feehan
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionMultiInput(String mainObjectName, ProvidesStackInput mainInputObject) Creates a newMultiInputwith a specified name for the main input object.MultiInput(ProvidesStackInput mainInputObject) Creates a newMultiInputwith a default name for the main input object. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddToStoreInferNames(NamedProviderStore<TimeSeries> stacks, int seriesIndex, Logger logger) Adds any stacks exposed by the current element to a named-store of stacks - inferring the names of theStacks.voidaddToStoreWithName(String name, NamedProviderStore<TimeSeries> stacks, int seriesIndex, Logger logger) Adds any stacks exposed by the current element to a named-store of stacks - with a particular name.voidclose(ErrorReporter errorReporter) Performs all tidying up, file-closing etc. after we are finished using theInputFromManagervoidcopyTo(SharedObjects target, Logger logger) Adds any exported shared objects to the target container.Gets the map ofDictionarys.filePath()Gets the map ofPaths.Gets the name of the main input object.Gets the map ofHistograms.A unique name associated with the input.marks()Gets the map ofMarkCollections.intThe number of time-frames in the underlying input image.objects()Gets the map ofObjectCollections.A path to a file from which this input originated.stack()Gets the map ofTimeSeries(stacks).Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.anchoranalysis.io.input.InputFromManager
allAssociatedPaths, asFile, identifierAsPath, pathForBindingRequiredMethods inherited from interface org.anchoranalysis.image.io.stack.input.ProvidesStackInput
addToStoreInferNames, asSet, asStack
-
Field Details
-
DEFAULT_IMAGE_INPUT_NAME
The default name for the input image stack.- See Also:
-
-
Constructor Details
-
MultiInput
Creates a newMultiInputwith a default name for the main input object.- Parameters:
mainInputObject- the main input object that provides the stack
-
MultiInput
Creates a newMultiInputwith a specified name for the main input object.- Parameters:
mainObjectName- the name for the main input objectmainInputObject- the main input object that provides the stack
-
-
Method Details
-
addToStoreInferNames
public void addToStoreInferNames(NamedProviderStore<TimeSeries> stacks, int seriesIndex, Logger logger) throws OperationFailedException Description copied from interface:ProvidesStackInputAdds any stacks exposed by the current element to a named-store of stacks - inferring the names of theStacks.- Specified by:
addToStoreInferNamesin interfaceProvidesStackInput- Parameters:
stacks- the named-store of stacks.seriesIndex- the index of the series (beginning at 0) to retrieve stacks from theTimeSeries.logger- a logger for any non-fatal errors. Fatal errors throw an exception.- Throws:
OperationFailedException- if the operation cannot successfully complete.
-
addToStoreWithName
public void addToStoreWithName(String name, NamedProviderStore<TimeSeries> stacks, int seriesIndex, Logger logger) throws OperationFailedException Description copied from interface:ProvidesStackInputAdds any stacks exposed by the current element to a named-store of stacks - with a particular name.- Specified by:
addToStoreWithNamein interfaceProvidesStackInput- Parameters:
name- the name to use for the added stack.stacks- the named-store of stacks.seriesIndex- the index of the series (beginning at 0) to retrieve stacks from theTimeSeries.logger- a logger for any non-fatal errors. Fatal errors throw an exception.- Throws:
OperationFailedException- if the operation cannot successfully complete.
-
identifier
Description copied from interface:InputFromManagerA unique name associated with the input.The name should never begin with or end with whitespace.
It should never contain backslashes, but forward-slashes are permitted.
- Specified by:
identifierin interfaceInputFromManager- Returns:
- a string uniquely (in the current dataset) identifying the input in a meaningful way.
-
pathForBinding
Description copied from interface:InputFromManagerA path to a file from which this input originated.This path is not guaranteed to be unique for each input i.e. multiple inputs may originate from the same path.
- Specified by:
pathForBindingin interfaceInputFromManager- Returns:
- the primary path associated with the input, if it exists.
-
close
Description copied from interface:InputFromManagerPerforms all tidying up, file-closing etc. after we are finished using theInputFromManager- Specified by:
closein interfaceInputFromManager- Parameters:
errorReporter- whether errors are reported to.
-
marks
Gets the map ofMarkCollections.- Returns:
- the
MultiInputSubMapofMarkCollections
-
objects
Gets the map ofObjectCollections.- Returns:
- the
MultiInputSubMapofObjectCollections
-
dictionary
Gets the map ofDictionarys.- Returns:
- the
MultiInputSubMapofDictionarys
-
histogram
Gets the map ofHistograms.- Returns:
- the
MultiInputSubMapofHistograms
-
filePath
Gets the map ofPaths.- Returns:
- the
MultiInputSubMapofPaths
-
stack
Gets the map ofTimeSeries(stacks).- Returns:
- the
MultiInputSubMapofTimeSeries
-
getMainObjectName
Gets the name of the main input object.- Returns:
- the name of the main input object
-
numberFrames
Description copied from interface:ProvidesStackInputThe number of time-frames in the underlying input image.- Specified by:
numberFramesin interfaceProvidesStackInput- Returns:
- the number of time-frames.
- Throws:
OperationFailedException- if the operation cannot successfully complete.
-