Package javax.imageio.metadata

Examples of javax.imageio.metadata.IIOInvalidTreeException


    }

    // Shorthand for throwing an IIOInvalidTreeException
    private static void fatal(Node node, String reason)
        throws IIOInvalidTreeException {
        throw new IIOInvalidTreeException(reason, node);
    }
View Full Code Here


        Node gceNode = null;
        for (int i = 0, len = nodeList.getLength(); i < len; i++) {
            Node curNode = nodeList.item(i);
            if (curNode.getNodeName().equals(gceNodeName)) {gceNode = curNode; break;}
        }
        if (gceNode == null) throw new IIOInvalidTreeException("Invalid image metadata, could not find " + gceNodeName + "node.", null, tree);
        Node delayNode = gceNode.getAttributes().getNamedItem(delayNodeName);
        if (delayNode == null) {
            delayNode = tree.getOwnerDocument().createAttribute(delayNodeName);
            gceNode.appendChild(delayNode);
        }
View Full Code Here

            } else if (name.equals("Text")) {
                createXMLBoxFromStandardNode(node);
            } else if (name.equals("Transparency")) {
                createChannelDefinitionFromStandardNode(node);
            } else {
                throw new IIOInvalidTreeException(I18N.getString("J2KMetadata3")
          + " " + name, node);
            }
        }
    }
View Full Code Here

    }

    private void mergeStandardTree(Node root) throws IIOInvalidTreeException {
        Node node = root;
        if (!node.getNodeName().equals(IIOMetadataFormatImpl.standardMetadataFormatName))
            throw new IIOInvalidTreeException("Root must be " +
                                              IIOMetadataFormatImpl.standardMetadataFormatName,
                                              node);

        node = node.getFirstChild();
        while (node != null) {
View Full Code Here

    }

    // Shorthand for throwing an IIOInvalidTreeException
    private void fatal(Node node, String reason)
        throws IIOInvalidTreeException {
        throw new IIOInvalidTreeException(reason, node);
    }
View Full Code Here

                    }
                }
            } else if (name.equals("Transparency")) {
                // Do nothing.
            } else {
                throw new IIOInvalidTreeException(I18N.getString("PNMMetadata3") + " " +
            name, node);
            }
        }

        // Go from higher to lower: PPM > PGM > PBM.
View Full Code Here

TOP

Related Classes of javax.imageio.metadata.IIOInvalidTreeException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.