Class SignatureBox
- java.lang.Object
-
- com.sun.media.imageioimpl.plugins.jpeg2000.Box
-
- com.sun.media.imageioimpl.plugins.jpeg2000.SignatureBox
-
public class SignatureBox extends Box
This class is defined to represent a Signature Box of JPEG JP2 file format. This type of box has a fixed length of 12, a type of "jP " and a four byte content of 0x0D0A870A, which is used to detects of the common file transmission errors which substituteswith or vice versa.
-
-
Field Summary
-
Fields inherited from class com.sun.media.imageioimpl.plugins.jpeg2000.Box
data, extraLength, length, type
-
-
Constructor Summary
Constructors Constructor Description SignatureBox()
Constructs aSignatureBox
.SignatureBox(byte[] data)
Constructs aSignatureBox
based on the provided byte array.SignatureBox(Node node)
Constructs aSignatureBox
based on the providedorg.w3c.dom.Node
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
compose()
Composes the content byte array from the data elements.IIOMetadataNode
getNativeNode()
Creates anIIOMetadataNode
from this signature box.-
Methods inherited from class com.sun.media.imageioimpl.plugins.jpeg2000.Box
copyInt, createBox, getAttribute, getBoxClass, getByteArrayElementValue, getByteElementValue, getContent, getExtraLength, getIntArrayElementValue, getIntElementValue, getLength, getName, getNativeNodeForSimpleBox, getShortElementValue, getStringElementValue, getType, getTypeByName, getTypeInt, getTypeString, parse, parseByteArray, parseIntArray, read, setContent, setDefaultAttributes, setExtraLength, setLength, write
-
-
-
-
Constructor Detail
-
SignatureBox
public SignatureBox()
Constructs aSignatureBox
.
-
SignatureBox
public SignatureBox(Node node) throws IIOInvalidTreeException
Constructs aSignatureBox
based on the providedorg.w3c.dom.Node
.- Throws:
IIOInvalidTreeException
-
SignatureBox
public SignatureBox(byte[] data) throws IIOInvalidTreeException
Constructs aSignatureBox
based on the provided byte array.- Throws:
IIOInvalidTreeException
-
-
Method Detail
-
getNativeNode
public IIOMetadataNode getNativeNode()
Creates anIIOMetadataNode
from this signature box. The format of this node is defined in the XML dtd and xsd for the JP2 image file.- Overrides:
getNativeNode
in classBox
-
-