XML310 :: Java APIs for XML
- Pricing: Tier I
- Duration: 3 Days
Summary:
This course covers how to manipulate XML data in Java applications. It covers the 3 major Java APIs for XML: DOM, SAX and JAXP, as well as the Java Architecture for XML Binding, JAXB. It emphasizes creating parser-independent code for maximum code portability and maintainability. The course is an even mix of lecture and lab, providing several realistic examples of converting XML data to and from Java object data.
Audience:
- Java Programmers/Developers wanting to use XML in web applications
Objectives:
- Review basic XML: DTDs, namespaces, XML Schema, XPath, and XSL
- Use the JAXP API to initialize XML parsers in a vendor-independent way
- Using the DOM API to read and manipulate XML data
- Use the SAX API for optimized XML data interpretation and error handling
- Convert XML data to and from Java objects
- Discover numerous \"Gotchas\" along the way
Topics:
- Java APIs for XML
- Using XML in Java
- XML Parsers
- Overview of API?s
- DOM
- Specifications
- Language Bindings
- DOM Object Hierarchy
- Node Objects
- Node Methods
- Node Types
- Node Name and Values
- Node Children and Parents
- Element Methods
- Navigation
- Retrieving Data
- Advanced DOM
- Creating Documents
- Creating and Altering Data
- Outputting Data
- Copying Data
- String Data
- SAX
- DOM vs. SAX
- Event Handlers
- Start and End of Documents
- Start and End of Elements
- Character Data
- Advanced SAX
- The Locator Object
- Errors - types, handlers, and behavior
- Input Sources
- The XMLReader
- JAXP
- Java Classes for JAXP
- Creating Factories and Parsers
- JAXP Error Handling
- DOM and SAX Factory Methods
- DOM Builder Methods
- SAX Parser Methodsv
- Validation
- Advanced DOM errors
- Thread Safety
- Installation and Configuration
- XSL Transformation
- Detailed Error and URI control
- JAXB
- Architecture of JAXB
- Advantages of JAXB
- The JAXB Process
- The xjc Stub Compiler
- Schema Binding
- Unmarshalling an XML Document
- Marshalling an XML Document
- Updating an XML Document
- JAXB Validation
- Customizing JAXB Bindings
- Annotating the XML Schema
- Using a Binding File