Table of Contents
Preface
Chapter 1: Creating and Parsing an XML Document
Chapter 2: Creating an XML Schema
Chapter 3: XML Schema Validation
Chapter 4: XPath
Chapter 5: Transforming XML with XSLT
Chapter 6: JSTL XML Tag Library
Chapter 7: Loading and Saving XML with DOM 3.0 LS
Chapter 8: Validating an XML Document with DOM 3 Validation
Chapter 9: JAXB 2.0
Chapter 10: Comparing XML Documents
Chapter 11: Converting XML to PDF
Chapter 12: Converting XML to MS Excel
Chapter 13: Storing XML in Oracle Berkeley DB XML
Chapter 14: Oracle XML Publisher
Index
- Chapter 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
- Chapter 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
- An overview of XML Schema
- Chapter 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
- Chapter 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
- Chapter 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 XSLT—non-static method
- Storing Java results in XSLT—static method
- Modifying attributes
- Modifying element text
- Stylesheet with extension functions
- Processing the extension functions
- Summary
- Chapter 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
- Chapter 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
- Chapter 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
- Chapter 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
- Chapter 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
- Chapter 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
- Chapter 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
- Chapter 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
- Chapter 14: Oracle XML Publisher
- Setting the environment
- FO Processor Engine
- XSL-FO Utility
- PDF Document Merger
- Data Engine
- Summary



