XML Training Overview
This course provides the student who knows the fundamentals of XML with an in-depth study of XPath and XSLT. It is geared towards students who desire a working knowledge of XML and XSLT for the purpose of managing XML documents and transformation paths as part of enterprise software development. There is some in-browser presentation as a means of immediate feedback in lab exercises, but the module focuses on server-side development.
A basic knowledge of XML. Some familiarity with HTML, browsers, and web presentation will be beneficial.
The course presents what might be called “Pure XML”, by which we mean two things. Firstly, everything in the course is based strictly on W3C specifications, without any vendor-specific extensions. Secondly, no knowledge of any particular programming language or other external technology is required to participate fully in the course. Thus the hands-on exercises, and the knowledge that is developed, are portable and applicable to any XML authoring or development effort.
This first module introduces students to the XPath and XSLT specifications. Students develop fluency in the exacting but powerful XPath syntax, and then build a number of XSLT transformations. Study of XSLT is arranged first to develop control over output production, including a solid understanding of the sometimes mysterious built-in template rules, template matching, priority and modes, and control of whitespace production. Then students turn towards the source document and learn to extract single values, to make shallow and deep copies of source elements, and to use flow-control constructs to effect conditional processing and loops.
The second module builds on students knowledge of XSLT. It treats advanced transformation problems – such as grouping output, managing structural transformations, and dealing with multiple source documents. Techniques are developed for advanced transformation solutions: use of XSLT variables, parameters and callable templates; sorting, and grouping using XSLT keys or previous-sibling comparisons; auto-numbering, formatting numbers and dates, calculating aggregate values over keys or groups, and callable-template tail recursion; and use of external documents and transforms.
XML Training LEARNING OBJECTIVES
XML Training Prerequisites
Module 1: Introduction to XML Transformations | |
1. XPath | |
Use of XPath in Other XML Technologies XPath Expressions The Axis The Node Test The Predicate XPath Types XPath Functions Implied Context Querying with XPath | |
2. Templates and Production | |
XSL and XSLT Rule-Based Transformations Templates and Template Matching Built-In Template Rules Recursion Through Templates Template Context Output Methods Controlling Whitespace Literal Replacement Elements Formalizing Text, Elements and Attributes Defining Target Vocabulary Generating Processing Instructions | |
3. Dynamic Content and Flow Control | |
Deriving Source Content Getting Source Values Attribute Value Templates Copying Source Elements and Trees Looping Conditionals | |
Module 2: Advanced XML Transformations
| |
1. Variables and Template Management | |
Variables Using Variables to Capture Context Information Result Tree Fragments Parameters Applying Templates with Parameters Calling Templates Explicitly | |
2. Sorting and Grouping | |
Sorting Data Type for Sorting Grouping Uses for Grouping Using the Preceding-Sibling Axis Using XSLT Keys Iterating Over Groups Iterating Within a Group | |
3. Advanced Production Techniques | |
Extrapolating Information from the Source Document Auto-Numbering Number Formatting String Parsing and Manipulation Computing Aggregate Values Using Tail Recursion | |
4. Multiple Documents and Transforms | |
Merging Multiple Source Documents The XSLT Document Function Reusing Transformation Logic Including Transforms Importing Transforms Multiple Template Modes | |
Appendix A. Learning Resources Appendix B. Quick Reference: XPath and XSLT Constructs Appendix C. Quick Reference: W3C Namespaces |
Software for this course can be installed and run on Windows or Linux systems. A variety of command-line XML tools must be installed for parsing, transformation, and schema validation. These are all free downloadable tools and all can be installed and run on Windows or Linux. See the appropriate course Setup Guide for details.
Hardware requirements are not great; a good minimal system for this course would have a Pentium 200MHz or equivalent CPU, 64 meg of RAM and at least 50 megabytes of free disk space for tools installation (and most of this is for the web browser).