E-book details

Processing XML documents with Oracle JDeveloper 11g

Processing XML documents with Oracle JDeveloper 11g

Deepak Vohra, Deepak Vohra

Ebook
XML is an open standard for creating markup languages and exchanging structured documents and data over the Internet. JDeveloper 11g presents an effective, quick, and easy-to-use means of processing XML documents.
Inspired by the author's previous XML articles for the Oracle community, this expanded hands-on tutorial guides newcomers and intermediate users through JDeveloper 11g and XML document development. It offers up-to-date information on working with the latest version of JDeveloper, and brand new information on JAXB 2.0 support in JDeveloper 11g. Filled with illustrations, explanatory tables, and comprehensive instructions, this book walks the reader through the wide assortment of JDeveloper's capabilities.
Oracle's JDeveloper 11g is an Integrated Development Environment that provides a visual and declarative approach to application development. Over the course of 14 chapters, readers will get hands-on with JDeveloper as the comprehensive and self-contained tutorials provide clear instruction on the key XML tasks that JDeveloper can accomplish.
Filled with practical information and illustrated examples, this book shows the reader how to create, parse, and store XML documents quickly, as well as providing step-by-step instructions on how to construct an XML schema and use the schema to validate an XML document.
Oracle's XML Developer Kit (XDK) offers a set of components, tools, and utilities for developing XML-based applications, and developers will find the detailed XDK coverage invaluable. Later chapters are given over to using XPath, transforming XML with XSLT, and using the JSTL XML Tag Library.
Moving through the book, a chapter on the JAXB 2.0 API shows you how to bind, marshal and unmarshal XML documents, before we finally delve into comparing XML documents, and converting them into PDF and Excel formats. In all, this book will enable the reader to gain a good and wide-ranging understanding of what JDeveloper has to offer for XML processing.
  • Processing XML documents with Oracle JDeveloper 11g
    • Table of Contents
    • Processing XML documents with Oracle JDeveloper 11g
    • Credits
    • About the Author
    • About the Reviewers
    • Preface
      • What this book covers
      • What you need for this book
      • Who is this book for?
      • Conventions
      • Reader feedback
      • Customer support
        • Downloading the example code for the book
        • Errata
        • Piracy
        • Questions
        • Copyright credit
    • 1. Creating and Parsing an XML Document
      • Setting the environment
      • Generating an XML document
        • Creating the factory
        • Creating the DOM document object
        • Creating the root element
        • Constructing the DOM document
        • Outputting the DOM document
        • Running the Java application
      • Parsing an XML document with the DOM API
        • Creating the factory
        • Creating a DOM document object
        • Outputting the XML document components values
        • Running the Java application
      • Parsing an XML document with the SAX API
        • Creating the factory
        • Parsing the XML document
        • Running the Java application
      • Summary
    • 2. Creating an XML Schema
      • An overview of XML Schema
        • Root element
        • Element component
        • SimpleType component
        • ComplexType component
      • Setting the environment
      • Creating an XML schema
      • Registering an XML schema
      • Creating an XML document from the XML schema
      • Summary
    • 3. XML Schema Validation
      • JDeveloper built-in schema validation
      • Schema validation in XDK 11g
      • Setting the environment
      • Schema validation with XSDValidator
        • Creating a schema validator
        • Setting the error handler
        • Validating the XML document
        • Running the Java application
      • Schema validation with a SAX parser
        • Creating a SAX parser
        • Setting the error handler
        • Validating the XML document
        • Running the Java application
      • Schema validation with a DOM parser
        • Creating a DOM parser
        • Setting the error handler
        • Parsing the XML document
        • Running the Java application
      • Summary
    • 4. XPath
      • What is XPath?
      • XPath support in Oracle XDK 11g
      • Setting the environment
      • XPath search
        • Selecting nodes with absolute location paths
        • Selecting nodes with relative location paths
        • Selecting namespace nodes
      • Selecting nodes with XPath API
        • Creating the DOM parser
        • Method selectSingleNode(String)
        • Method selectNodes(String)
        • Method selectSingleNode(String,NSResolver)
        • Method selectNodes(String,NSResolver)
        • Running the Java application
      • Summary
    • 5. Transforming XML with XSLT
      • What we will cover in this chapter
      • Setting the environment for XSLT transformation
      • Transforming an XML document
        • Parsing the XML document
        • Creating the TransformerFactory
        • Creating the Transformer
        • Running the application
      • XSLT extension functions
        • Setting the environment for XSLT extension functions
        • Creating the stylesheet containing the extension functions
          • Instantiating Java classes
          • Parsing the XML
          • Storing Java results in XSLTnon-static method
          • Storing Java results in XSLTstatic method
          • Modifying attributes
          • Modifying element text
          • Stylesheet with extension functions
        • Processing the extension functions
      • Summary
    • 6. JSTL XML Tag Library
      • Overview of the JSTL XML tag library
      • Setting the environment
      • Parsing with the JSTL XML tag library
      • Transforming with the JSTL XML tag library
      • Summary
    • 7. Loading and Saving XML with DOM 3.0 LS
      • Background
      • The API
      • Setting the environment
      • Loading an XML document
        • Creating the LSParser
        • Adding event handling
        • Parsing the XML document
      • Saving an XML document
        • Creating a document object
        • Creating an LSSerializer
        • Outputting the document object
      • Filtering an XML document
        • Filtering the input
        • Filtering the output
      • Summary
    • 8. Validating an XML Document with DOM 3 Validation
      • Setting the environment
      • Constructing and validating an XML document
        • Parsing XML document and setting XML schema
        • Global elements
        • The catalog element
        • Adding journal attributes
        • Adding article attributes
        • Adding article subelements
        • Adding a journal element
        • Validating a document
        • Running the DOM 3 Validation application
        • XDK 11g limitations
      • Summary
    • 9. JAXB 2.0
      • Setting the environment
      • Compiling an XML schema
      • Marshalling an XML document
      • Unmarshalling an XML document
      • Mapping Java to XML using annotations
      • Summary
    • 10. Comparing XML Documents
      • Setting the environment
      • Comparing XML documents with the XMLDiff class
        • Parsing the XML files
        • Comparing the XML files
        • Generating an XSLT stylesheet
        • Running the Java application
      • Summary
    • 11. Converting XML to PDF
      • Setting the environment
      • Converting XML to XSL-FO
      • Parsing the XML document
        • Generating the XSL-FO document
      • Converting XSL-FO to PDF
        • Creating the FOP driver
        • Generating the PDF document
        • Running the Java application
      • Summary
    • 12. Converting XML to MS Excel
      • Setting the environment
      • Converting an XML document to an Excel spreadsheet
        • Creating a spreadsheet
        • Parsing the XML document
        • Adding XML data to the spreadsheet
        • Outputting the spreadsheet
        • Running the Java application
      • Converting an Excel spreadsheet to an XML document
        • Creating the XML document
        • Parsing the Excel spreadsheet
        • Constructing the XML DOM tree
        • Running the Java application
      • Summary
    • 13. Storing XML in Oracle Berkeley DB XML
      • Installing Oracle Berkeley DB XML
      • Using the command shell
        • Adding XML documents
        • Querying XML documents with XQuery
        • Modifying XML documents
        • Replacing/deleting XML document nodes
      • Using the Berkeley DB XML API in JDeveloper
        • Setting the environment
        • Creating a container
        • Adding XML documents
        • Querying XML documents with XQuery
        • Modifying XML documents
        • Updating/renaming in XML documents
      • Summary
    • 14. Oracle XML Publisher
      • Setting the environment
      • FO Processor Engine
      • XSL-FO Utility
      • PDF Document Merger
      • Data Engine
      • Summary
    • Index
  • Title: Processing XML documents with Oracle JDeveloper 11g
  • Author: Deepak Vohra, Deepak Vohra
  • Original title: Processing XML documents with Oracle JDeveloper 11g.
  • ISBN: 9781847196675, 9781847196675
  • Date of issue: 2009-05-15
  • Format: Ebook
  • Item ID: e_3c7l
  • Publisher: Packt Publishing