public class DefaultOMEMetadataService extends AbstractService implements OMEMetadataService
OMEMetadataService.| Constructor and Description |
|---|
DefaultOMEMetadataService() |
| Modifier and Type | Method and Description |
|---|---|
String |
createLSID(String type,
int... indices)
Constructs an LSID, given the object type and indices.
|
AxisType[] |
findDimensionList(String dimensionOrder)
Converts the given String to a list of AxisTypes suitable for Metadata
construction.
|
String |
findDimensionOrder(ImageMetadata imageMeta)
Extracts a standard 5-D dimension order from an N-dimensional ImageMetadata
object.
|
String |
findDimensionOrder(Metadata meta,
int imageIndex)
Extracts a standard 5-D dimension order from an N-dimensional ImageMetadata
object.
|
ome.xml.model.enums.Binning |
getBinning(String value)
Retrieves an
Binning enumeration value for the
given String. |
ome.xml.model.enums.Correction |
getCorrection(String value)
Retrieves an
Correction enumeration value for
the given String. |
ome.xml.model.enums.DetectorType |
getDetectorType(String value)
Retrieves an
DetectorType enumeration value for
the given String. |
ome.xml.model.enums.ExperimentType |
getExperimentType(String value)
Retrieves an
ExperimentType enumeration value
for the given String. |
ome.xml.model.enums.Immersion |
getImmersion(String value)
Retrieves an
Immersion enumeration value for
the given String. |
ome.xml.model.enums.LaserMedium |
getLaserMedium(String value)
Retrieves an
LaserMedium enumeration value for
the given String. |
ome.xml.model.enums.LaserType |
getLaserType(String value)
Retrieves an
LaserType enumeration value for
the given String. |
String |
makeSaneDimensionOrder(String dimensionOrder)
Adjusts the given dimension order as needed so that it contains exactly one
of each of the following characters: 'X', 'Y', 'Z', 'C', 'T'.
|
void |
populateImageMetadata(MetadataRetrieve retrieve,
int imageIndex,
ImageMetadata iMeta)
Populates the provided ImageMetadata object using the specified image index
into the MetadataRetrieve.
|
void |
populateMetadata(MetadataRetrieve retrieve,
Metadata meta)
Uses the provided MetadataRetrieve to populate the format-agnostic image
information in the provided Metadata object (that is, the ImageMetadata).
|
void |
populateMetadata(MetadataStore store,
int imageIndex,
String imageName,
boolean littleEndian,
String dimensionOrder,
String pixelType,
int sizeX,
int sizeY,
int sizeZ,
int sizeC,
int sizeT,
double calX,
double calY,
double calZ,
double calC,
double calT,
int samplesPerPixel)
Populates the given
MetadataStore, for the specified imageIndex,
using the provided values. |
void |
populateMetadata(MetadataStore store,
int imageIndex,
String imageName,
ImageMetadata iMeta)
Populates the given
MetadataStore, for the specified imageIndex,
using the values from the provided ImageMetadata. |
void |
populateMetadata(MetadataStore store,
int imageIndex,
String imageName,
Metadata meta)
Populates the given
MetadataStore, for the specified imageIndex,
using the values from the provided Metadata. |
void |
populateMetadata(MetadataStore store,
String file,
int imageIndex,
String imageName,
boolean littleEndian,
String dimensionOrder,
String pixelType,
int sizeX,
int sizeY,
int sizeZ,
int sizeC,
int sizeT,
double calX,
double calY,
double calZ,
double calC,
double calT,
int samplesPerPixel)
Populates the given
MetadataStore, for the specified imageIndex,
using the provided values. |
void |
populatePixels(MetadataStore store,
List<ImageMetadata> imageMeta,
boolean doPlane,
String imageName)
Populates the 'pixels' element of the given metadata store, using the
provided
ImageMetadata. |
void |
populatePixels(MetadataStore store,
Metadata meta)
Populates the 'pixels' element of the given metadata store, using core
metadata from the given reader.
|
void |
populatePixels(MetadataStore store,
Metadata meta,
boolean doPlane)
Populates the 'pixels' element of the given metadata store, using core
metadata from the given reader.
|
void |
populatePixels(MetadataStore store,
Metadata meta,
boolean doPlane,
boolean doImageName)
Populates the 'pixels' element of the given metadata store, using core
metadata from the given metadata.
|
void |
populatePixelsOnly(MetadataStore store,
int imageIndex,
boolean littleEndian,
String dimensionOrder,
String pixelType,
int sizeX,
int sizeY,
int sizeZ,
int sizeC,
int sizeT,
double calX,
double calY,
double calZ,
double calC,
double calT,
int samplesPerPixel) |
void |
populatePixelsOnly(MetadataStore store,
Reader r) |
void |
setDefaultCreationDate(MetadataStore store,
String id,
int imageIndex)
Sets a default creation date.
|
void |
setDefaultDateEnabled(boolean enabled)
Disables the setting of a default creation date.
|
void |
verifyMinimumPopulated(MetadataRetrieve src) |
void |
verifyMinimumPopulated(MetadataRetrieve src,
int n) |
long[] |
zctToArray(String order,
int z,
int c,
int t)
Given a String dimension order, places the given z, c and t indices in the
correct relative positions in a long array, which is returned.
|
getContext, setContext, toStringgetInfo, getPriority, setInfo, setPrioritycontextclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitinitialize, registerEventHandlersgetIdentifier, logcontext, getContext, setContextcompareTo, getPriority, setPrioritygetInfo, setInfogetLocationgetVersiondisposepublic void populatePixels(MetadataStore store, Metadata meta)
OMEMetadataServicepopulatePixels in interface OMEMetadataServicepublic void populatePixels(MetadataStore store, Metadata meta, boolean doPlane)
OMEMetadataServicepopulatePixels in interface OMEMetadataServicepublic void populatePixels(MetadataStore store, Metadata meta, boolean doPlane, boolean doImageName)
OMEMetadataServicepopulatePixels in interface OMEMetadataServicepublic void populatePixels(MetadataStore store, List<ImageMetadata> imageMeta, boolean doPlane, String imageName)
OMEMetadataServiceImageMetadata. If the 'doPlane' flag is set, then the
'plane' elements will be populated as well. If the 'imageName' field is
non-null, then the image name will be populated as well.populatePixels in interface OMEMetadataServicepublic void populateMetadata(MetadataStore store, int imageIndex, String imageName, boolean littleEndian, String dimensionOrder, String pixelType, int sizeX, int sizeY, int sizeZ, int sizeC, int sizeT, double calX, double calY, double calZ, double calC, double calT, int samplesPerPixel)
OMEMetadataServiceMetadataStore, for the specified imageIndex,
using the provided values.
After calling this method, the metadata store will be sufficiently
populated for use with an IFormatWriter (assuming it is also a
MetadataRetrieve).
populateMetadata in interface OMEMetadataServicepublic void populateMetadata(MetadataStore store, int imageIndex, String imageName, Metadata meta)
OMEMetadataServiceMetadataStore, for the specified imageIndex,
using the values from the provided Metadata.
After calling this method, the metadata store will be sufficiently
populated for use with an IFormatWriter (assuming it is also a
MetadataRetrieve).
populateMetadata in interface OMEMetadataServicepublic void populateMetadata(MetadataStore store, int imageIndex, String imageName, ImageMetadata iMeta)
OMEMetadataServiceMetadataStore, for the specified imageIndex,
using the values from the provided ImageMetadata.
After calling this method, the metadata store will be sufficiently
populated for use with an IFormatWriter (assuming it is also a
MetadataRetrieve).
populateMetadata in interface OMEMetadataServicepublic void populateMetadata(MetadataStore store, String file, int imageIndex, String imageName, boolean littleEndian, String dimensionOrder, String pixelType, int sizeX, int sizeY, int sizeZ, int sizeC, int sizeT, double calX, double calY, double calZ, double calC, double calT, int samplesPerPixel)
OMEMetadataServiceMetadataStore, for the specified imageIndex,
using the provided values.
After calling this method, the metadata store will be sufficiently
populated for use with an IFormatWriter (assuming it is also a
MetadataRetrieve).
populateMetadata in interface OMEMetadataServicepublic void populatePixelsOnly(MetadataStore store, Reader r)
populatePixelsOnly in interface OMEMetadataServicepublic void populatePixelsOnly(MetadataStore store, int imageIndex, boolean littleEndian, String dimensionOrder, String pixelType, int sizeX, int sizeY, int sizeZ, int sizeC, int sizeT, double calX, double calY, double calZ, double calC, double calT, int samplesPerPixel)
populatePixelsOnly in interface OMEMetadataServicepublic void setDefaultDateEnabled(boolean enabled)
OMEMetadataServicesetDefaultDateEnabled in interface OMEMetadataServiceenabled - See above.OMEMetadataService.setDefaultCreationDate(MetadataStore, String, int)public void setDefaultCreationDate(MetadataStore store, String id, int imageIndex)
OMEMetadataServicesetDefaultCreationDate in interface OMEMetadataServiceOMEMetadataService.setDefaultDateEnabled(boolean)public void verifyMinimumPopulated(MetadataRetrieve src) throws FormatException
verifyMinimumPopulated in interface OMEMetadataServiceFormatException - if there is a missing metadata field, or the
metadata object is uninitializedpublic void verifyMinimumPopulated(MetadataRetrieve src, int n) throws FormatException
verifyMinimumPopulated in interface OMEMetadataServiceFormatException - if there is a missing metadata field, or the
metadata object is uninitializedpublic String findDimensionOrder(Metadata meta, int imageIndex)
OMEMetadataServicefindDimensionOrder in interface OMEMetadataServicepublic String findDimensionOrder(ImageMetadata imageMeta)
OMEMetadataServicefindDimensionOrder in interface OMEMetadataServicepublic AxisType[] findDimensionList(String dimensionOrder)
OMEMetadataServicefindDimensionList in interface OMEMetadataServicepublic long[] zctToArray(String order, int z, int c, int t)
OMEMetadataServicezctToArray in interface OMEMetadataServicepublic String makeSaneDimensionOrder(String dimensionOrder)
OMEMetadataServicemakeSaneDimensionOrder in interface OMEMetadataServicepublic String createLSID(String type, int... indices)
OMEMetadataServicecreateLSID in interface OMEMetadataServicepublic ome.xml.model.enums.ExperimentType getExperimentType(String value) throws FormatException
OMEMetadataServiceExperimentType enumeration value
for the given String.getExperimentType in interface OMEMetadataServiceFormatException - if an appropriate enumeration value is not found.public ome.xml.model.enums.LaserType getLaserType(String value) throws FormatException
OMEMetadataServiceLaserType enumeration value for
the given String.getLaserType in interface OMEMetadataServiceFormatException - if an appropriate enumeration value is not found.public ome.xml.model.enums.LaserMedium getLaserMedium(String value) throws FormatException
OMEMetadataServiceLaserMedium enumeration value for
the given String.getLaserMedium in interface OMEMetadataServiceFormatException - if an appropriate enumeration value is not found.public ome.xml.model.enums.Immersion getImmersion(String value) throws FormatException
OMEMetadataServiceImmersion enumeration value for
the given String.getImmersion in interface OMEMetadataServiceFormatException - if an appropriate enumeration value is not found.public ome.xml.model.enums.Correction getCorrection(String value) throws FormatException
OMEMetadataServiceCorrection enumeration value for
the given String.getCorrection in interface OMEMetadataServiceFormatException - if an appropriate enumeration value is not found.public ome.xml.model.enums.DetectorType getDetectorType(String value) throws FormatException
OMEMetadataServiceDetectorType enumeration value for
the given String.getDetectorType in interface OMEMetadataServiceFormatException - if an appropriate enumeration value is not found.public ome.xml.model.enums.Binning getBinning(String value) throws FormatException
OMEMetadataServiceBinning enumeration value for the
given String.getBinning in interface OMEMetadataServiceFormatException - if an appropriate enumeration value is not found.public void populateMetadata(MetadataRetrieve retrieve, Metadata meta)
OMEMetadataServicepopulateMetadata in interface OMEMetadataServicepublic void populateImageMetadata(MetadataRetrieve retrieve, int imageIndex, ImageMetadata iMeta)
OMEMetadataServicepopulateImageMetadata in interface OMEMetadataServiceCopyright © 2015–2022 SCIFIO. All rights reserved.