Package ome.specification
Class XMLWriter
- java.lang.Object
-
- ome.specification.XMLWriter
-
public class XMLWriter extends java.lang.ObjectMethods to write the XML tags to the files.- Since:
- 3.0-Beta4
- Version:
- 3.0 (Internal version: $Revision: $Date: $)
- Author:
- Jean-Marie Burel j.burel@dundee.ac.uk, Donald MacDonald donald@lifesci.dundee.ac.uk
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringBIG_ENDIAN_ATTRIBUTEIdentifies theBigEndianattribute.static java.lang.StringBIN_DATA_TAGIdentifies theBinDatatag.static java.lang.StringCOMPRESSION_ATTRIBUTEIdentifies theCompressionattribute.static java.lang.StringDIMENSION_ORDER_ATTRIBUTEIdentifies theDimensionOrderattribute.static java.lang.StringID_ATTRIBUTEIdentifies theIDattribute.static java.lang.StringIMAGE_TAGIdentifies theImagetag.static java.lang.StringLENGTH_ATTRIBUTEIdentifies theLengthattribute.static java.lang.StringNAME_ATTRIBUTEIdentifies theNameattribute.static java.lang.StringOME_TAGIdentifies theOMEtag.static java.lang.StringPIXELS_TAGIdentifies thePixelstag.static java.lang.StringPIXELS_TYPE_ATTRIBUTEIdentifies thePixelTypeattribute.static java.lang.StringSIZE_C_ATTRIBUTEIdentifies theSizeCattribute.static java.lang.StringSIZE_T_ATTRIBUTEIdentifies theSizeTattribute.static java.lang.StringSIZE_X_ATTRIBUTEIdentifies theSizeXattribute.static java.lang.StringSIZE_Y_ATTRIBUTEIdentifies theSizeYattribute.static java.lang.StringSIZE_Z_ATTRIBUTEIdentifies theSizeZattribute.
-
Constructor Summary
Constructors Constructor Description XMLWriter()Creates a new instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidwriteFile(java.io.File file, OME ome)Writes the data to the file.voidwriteFile(java.io.File file, OME ome, boolean binaryData)Writes the data to the file.
-
-
-
Field Detail
-
ID_ATTRIBUTE
public static final java.lang.String ID_ATTRIBUTE
Identifies theIDattribute.- See Also:
- Constant Field Values
-
NAME_ATTRIBUTE
public static final java.lang.String NAME_ATTRIBUTE
Identifies theNameattribute.- See Also:
- Constant Field Values
-
DIMENSION_ORDER_ATTRIBUTE
public static final java.lang.String DIMENSION_ORDER_ATTRIBUTE
Identifies theDimensionOrderattribute.- See Also:
- Constant Field Values
-
PIXELS_TYPE_ATTRIBUTE
public static final java.lang.String PIXELS_TYPE_ATTRIBUTE
Identifies thePixelTypeattribute.- See Also:
- Constant Field Values
-
SIZE_C_ATTRIBUTE
public static final java.lang.String SIZE_C_ATTRIBUTE
Identifies theSizeCattribute.- See Also:
- Constant Field Values
-
SIZE_T_ATTRIBUTE
public static final java.lang.String SIZE_T_ATTRIBUTE
Identifies theSizeTattribute.- See Also:
- Constant Field Values
-
SIZE_Z_ATTRIBUTE
public static final java.lang.String SIZE_Z_ATTRIBUTE
Identifies theSizeZattribute.- See Also:
- Constant Field Values
-
SIZE_X_ATTRIBUTE
public static final java.lang.String SIZE_X_ATTRIBUTE
Identifies theSizeXattribute.- See Also:
- Constant Field Values
-
SIZE_Y_ATTRIBUTE
public static final java.lang.String SIZE_Y_ATTRIBUTE
Identifies theSizeYattribute.- See Also:
- Constant Field Values
-
COMPRESSION_ATTRIBUTE
public static final java.lang.String COMPRESSION_ATTRIBUTE
Identifies theCompressionattribute.- See Also:
- Constant Field Values
-
BIG_ENDIAN_ATTRIBUTE
public static final java.lang.String BIG_ENDIAN_ATTRIBUTE
Identifies theBigEndianattribute.- See Also:
- Constant Field Values
-
LENGTH_ATTRIBUTE
public static final java.lang.String LENGTH_ATTRIBUTE
Identifies theLengthattribute.- See Also:
- Constant Field Values
-
OME_TAG
public static final java.lang.String OME_TAG
Identifies theOMEtag.- See Also:
- Constant Field Values
-
IMAGE_TAG
public static final java.lang.String IMAGE_TAG
Identifies theImagetag.- See Also:
- Constant Field Values
-
PIXELS_TAG
public static final java.lang.String PIXELS_TAG
Identifies thePixelstag.- See Also:
- Constant Field Values
-
BIN_DATA_TAG
public static final java.lang.String BIN_DATA_TAG
Identifies theBinDatatag.- See Also:
- Constant Field Values
-
-
Method Detail
-
writeFile
public void writeFile(java.io.File file, OME ome) throws java.lang.ExceptionWrites the data to the file. Binary data will be added.- Parameters:
file- The file to handle.ome- The element to write to the file.- Throws:
java.lang.Exception- Thrown if an error occurred while writing the XML file.
-
writeFile
public void writeFile(java.io.File file, OME ome, boolean binaryData) throws java.lang.ExceptionWrites the data to the file.- Parameters:
file- The file to handle.ome- The element to write to the file.binaryData- Passtrueto add the binary data,falseotherwise.- Throws:
java.lang.Exception- Thrown if an error occurred while writing the XML file.
-
-