public class Dataset extends ImageTransform
Other configurations are certainly possible, and Dataset provides an interface for multidimensional image data of any organization.
Dataset keeps no data in memory itself, leaving that management to the application, and just loads data as necessary to return whatever the application requests, according to the DataTransform API.
Modifier and Type | Field and Description |
---|---|
protected RealType[] |
color
Types mapped to color components (RGBA).
|
protected DatasetWidget |
controls
Controls for this dataset.
|
protected loci.common.StatusListener |
listener
Optional listener for constructor progress.
|
protected String |
pattern
A string pattern describing this dataset.
|
protected BufferedImageReader |
reader
Data reader.
|
protected RealType[] |
spatial
Types mapped to spatial components (X, Y).
|
MICRON, micronHeight, micronStep, micronWidth, xType, yType, zType
Constructor and Description |
---|
Dataset()
Constructs an uninitialized multidimensional data object.
|
Dataset(String name,
String pattern)
Constructs a multidimensional data object.
|
Dataset(String name,
String pattern,
loci.common.StatusListener listener)
Constructs a new multidimensional data object from the given file pattern.
|
Modifier and Type | Method and Description |
---|---|
void |
close()
Close all open ids.
|
String |
getCacheId(int[] pos,
boolean global)
Gets a string id uniquely describing this data transform at the given
dimensional position, for the purposes of thumbnail caching.
|
JComponent |
getControls()
Gets associated GUI controls for this transform.
|
String |
getFileFormat()
Gets a description of the source files' file format.
|
String[] |
getFilenames()
Gets filenames of all files in dataset.
|
String |
getHTMLDescription()
Gets a description of this dataset, with HTML markup.
|
BufferedImage |
getImage(int[] pos)
Obtains an image from the source(s) at the given dimensional position.
|
int |
getImageHeight()
Gets height of each image.
|
int |
getImageWidth()
Gets width of each image.
|
Hashtable |
getMetadata()
Gets metadata associated with the dataset.
|
String |
getOMEXML()
Gets an OME-XML string for the dataset.
|
ome.xml.model.OME |
getOMEXMLRoot()
Gets an OME-XML root for the dataset.
|
String |
getPattern()
Gets the string pattern describing this dataset.
|
int |
getRangeCount()
Gets number of range components at each pixel.
|
void |
initState(Dynamic dyn)
Modifies this object's state to match that of the given object.
|
boolean |
isCompatible(Dynamic dyn)
Tests whether the given dynamic object can be used as an argument to
initState, for initializing this dynamic object.
|
static boolean |
isParentRequired()
Indicates whether this transform type requires a parent transform.
|
boolean |
isValidDimension(int dim)
Gets whether this transform provides data of the given dimensionality.
|
static boolean |
isValidParent(DataTransform data)
Indicates whether this transform type would accept the given transform as
its parent transform.
|
static DataTransform |
makeTransform(DataManager dm)
Creates a new dataset, with user interaction.
|
static DataTransform |
makeTransform(DataManager dm,
File file,
Component parent)
Creates a new dataset, with user interaction, with the given default file.
|
boolean |
matches(Dynamic dyn)
Tests whether two dynamic objects have matching states.
|
void |
restoreState(Element el)
Restores the current state from the given DOM element ("Dataset").
|
void |
saveState(Element el)
Writes the current state to the given DOM element ("DataTransforms").
|
canDisplay3D, getData, getImageUnits, getMicronHeight, getMicronStep, getMicronStep, getMicronWidth, getRangeTypes, getSuggestedMaps, getType, getXType, getYType, getZType, getZUnit, isImmediate
addTransformListener, canDisplay2D, discard, displayChanged, getDimTypes, getFont, getLabels, getLengths, getName, getParent, getThumbHandler, getTransformId, getUnitDescription, makeLabels, notifyListeners, removeTransformListener, setFont, toString
protected String pattern
protected loci.common.StatusListener listener
protected BufferedImageReader reader
protected DatasetWidget controls
protected RealType[] spatial
protected RealType[] color
public Dataset()
public Dataset(String name, String pattern)
public Dataset(String name, String pattern, loci.common.StatusListener listener)
name
- Label for the dataset.pattern
- File pattern identifying the dataset.listener
- Listener object to be informed of construction progress.public void close() throws FormatException, IOException
FormatException
IOException
public String getPattern()
public String[] getFilenames()
public String getFileFormat()
public Hashtable getMetadata()
public ome.xml.model.OME getOMEXMLRoot()
public String getOMEXML()
public BufferedImage getImage(int[] pos)
getImage
in class ImageTransform
public int getImageWidth()
getImageWidth
in class ImageTransform
public int getImageHeight()
getImageHeight
in class ImageTransform
public int getRangeCount()
getRangeCount
in class ImageTransform
public static DataTransform makeTransform(DataManager dm)
public static DataTransform makeTransform(DataManager dm, File file, Component parent)
public static boolean isValidParent(DataTransform data)
public static boolean isParentRequired()
public boolean isValidDimension(int dim)
isValidDimension
in class DataTransform
public String getCacheId(int[] pos, boolean global)
getCacheId
in class DataTransform
public String getHTMLDescription()
getHTMLDescription
in class ImageTransform
public JComponent getControls()
getControls
in class DataTransform
public boolean matches(Dynamic dyn)
matches
in interface Dynamic
matches
in class DataTransform
public boolean isCompatible(Dynamic dyn)
isCompatible
in interface Dynamic
isCompatible
in class DataTransform
public void initState(Dynamic dyn)
initState
in interface Dynamic
initState
in class DataTransform
public void saveState(Element el) throws SaveException
saveState
in interface Saveable
saveState
in class ImageTransform
SaveException
public void restoreState(Element el) throws SaveException
restoreState
in interface Saveable
restoreState
in class ImageTransform
SaveException
Copyright © 2015–2022 SciJava. All rights reserved.