Class AbstractMetadata

  • All Implemented Interfaces:
    java.lang.Cloneable

    public abstract class AbstractMetadata
    extends javax.imageio.metadata.IIOMetadata
    implements java.lang.Cloneable
    AbstractMetadata
    Version:
    $Id: AbstractMetadata.java,v 1.0 Nov 13, 2009 1:02:12 AM haraldk Exp$
    Author:
    Harald Kuhr, last modified by $Author: haraldk$
    • Field Summary

      • Fields inherited from class javax.imageio.metadata.IIOMetadata

        controller, defaultController, extraMetadataFormatClassNames, extraMetadataFormatNames, nativeMetadataFormatClassName, nativeMetadataFormatName, standardFormatSupported
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      protected AbstractMetadata()  
      protected AbstractMetadata​(boolean standardFormatSupported, java.lang.String nativeFormatName, java.lang.String nativeFormatClassName, java.lang.String[] extraFormatNames, java.lang.String[] extraFormatClassNames)  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected void assertMutable()
      Asserts that this meta data is mutable.
      org.w3c.dom.Node getAsTree​(java.lang.String formatName)  
      protected org.w3c.dom.Node getNativeTree()
      Default implementation that throws UnsupportedOperationException.
      boolean isReadOnly()
      Default implementation returns true.
      void mergeTree​(java.lang.String formatName, org.w3c.dom.Node root)  
      void reset()  
      protected static java.lang.String toListString​(short[] values)  
      protected void validateFormatName​(java.lang.String formatName)  
      • Methods inherited from class javax.imageio.metadata.IIOMetadata

        activateController, getController, getDefaultController, getExtraMetadataFormatNames, getMetadataFormat, getMetadataFormatNames, getNativeMetadataFormatName, getStandardChromaNode, getStandardCompressionNode, getStandardDataNode, getStandardDimensionNode, getStandardDocumentNode, getStandardTextNode, getStandardTileNode, getStandardTransparencyNode, getStandardTree, hasController, isStandardMetadataFormatSupported, setController, setFromTree
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • AbstractMetadata

        protected AbstractMetadata​(boolean standardFormatSupported,
                                   java.lang.String nativeFormatName,
                                   java.lang.String nativeFormatClassName,
                                   java.lang.String[] extraFormatNames,
                                   java.lang.String[] extraFormatClassNames)
      • AbstractMetadata

        protected AbstractMetadata()
    • Method Detail

      • isReadOnly

        public boolean isReadOnly()
        Default implementation returns true. Mutable subclasses should override this method.
        Specified by:
        isReadOnly in class javax.imageio.metadata.IIOMetadata
        Returns:
        true.
      • getAsTree

        public org.w3c.dom.Node getAsTree​(java.lang.String formatName)
        Specified by:
        getAsTree in class javax.imageio.metadata.IIOMetadata
      • getNativeTree

        protected org.w3c.dom.Node getNativeTree()
        Default implementation that throws UnsupportedOperationException. Subclasses that supports formats other than standard metadata should override this method.
        Throws:
        java.lang.UnsupportedOperationException
      • mergeTree

        public void mergeTree​(java.lang.String formatName,
                              org.w3c.dom.Node root)
                       throws javax.imageio.metadata.IIOInvalidTreeException
        Specified by:
        mergeTree in class javax.imageio.metadata.IIOMetadata
        Throws:
        javax.imageio.metadata.IIOInvalidTreeException
      • reset

        public void reset()
        Specified by:
        reset in class javax.imageio.metadata.IIOMetadata
      • assertMutable

        protected final void assertMutable()
        Asserts that this meta data is mutable.
        Throws:
        java.lang.IllegalStateException - if isReadOnly() returns true.
      • validateFormatName

        protected final void validateFormatName​(java.lang.String formatName)
      • toListString

        protected static java.lang.String toListString​(short[] values)