Friday 27 September 2013

XML tools by Example






XLinq Example















XLinq with XML














XLinq with XML Namespace operation



















XLinq Extension method















Defensive XLinq Query with XML Namespace
















XPath



XPath is used to navigate through elements and attributes in an XML document.  XPath is a major element in W3C's XSLT standard - and XQuery and XPointer are both built on XPath expressions. 
XPath is a language for finding information in an XML document.
















































































For more information please visit below site
http://www.w3schools.com/xpath/default.asp




XSL-FO




XSL-FO is about formatting XML data for output.  Styling is both about transforming and formatting information. When the World Wide Web Consortium (W3C) made their first XSL Working Draft, it contained the language syntax for both transforming and formatting XML documents.

Later, the Working Group at W3C split the original draft into separate Recommendations:
  • XSLT, a language for transforming XML documents
  • XSL or XSL-FO, a language for formatting XML documents
  • XPath, a language for navigating in XML documents



Example:

<?xml version="1.0" encoding="ISO-8859-1"?>

<fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format">

<fo:layout-master-set>
  <fo:simple-page-master master-name="A4">
    <!-- Page template goes here -->
  </fo:simple-page-master>
</fo:layout-master-set>

<fo:page-sequence master-reference="A4">
  <!-- Page content goes here -->
</fo:page-sequence>

</fo:root>


For more information please visit below site
http://www.w3schools.com/xslfo/default.asp






XQuery



XQuery is to XML what SQL is to database tables.  XQuery is designed to query XML data - not just XML files, but anything that can appear as XML, including databases.









XQuery Example


We will use the following XML document in the examples below.


<?xml version="1.0" encoding="ISO-8859-1"?>

<bookstore>

<book category="COOKING">
  <title lang="en">Everyday Italian</title>
  <author>Giada De Laurentiis</author>
  <year>2005</year>
  <price>30.00</price>
</book>

<book category="CHILDREN">
  <title lang="en">Harry Potter</title>
  <author>J K. Rowling</author>
  <year>2005</year>
  <price>29.99</price>
</book>

<book category="WEB">
  <title lang="en">XQuery Kick Start</title>
  <author>James McGovern</author>
  <author>Per Bothner</author>
  <author>Kurt Cagle</author>
  <author>James Linn</author>
  <author>Vaidyanathan Nagarajan</author>
  <year>2003</year>
  <price>49.99</price>
</book>

<book category="WEB">
  <title lang="en">Learning XML</title>
  <author>Erik T. Ray</author>
  <year>2003</year>
  <price>39.95</price>
</book>

</bookstore>

















For more information please visit below site
http://www.w3schools.com/xquery/default.asp






XLink and XPointer



XLink defines a standard way of creating hyperlinks in XML documents.  XPointer allows the hyperlinks to point to more specific parts in the XML document.














For more information please visit below site
http://www.w3schools.com/xlink/default.asp



XML Schema



An XML Schema describes the structure of an XML document.  XML Schema is an XML-based alternative to DTD.






For more information please visit below site
http://www.w3schools.com/schema/default.asp







XML DOM



The XML DOM defines a standard way for accessing and manipulating XML documents.  The DOM presents an XML document as a tree-structure.  The XML DOM defines a standard for accessing and manipulating XML.
















XML DOM Parser


Most browsers have a built-in XML parser to read and manipulate XML.  The parser converts XML into a JavaScript accessible object (the XML DOM).


















For more information please visit below site
http://www.w3schools.com/dom/default.asp




XSLT


XSLT debugging in Visual Studio



XSL stands for EXtensible Stylesheet Language, and is a style sheet language for XML documents.
XSLT stands for XSL Transformations.


Example



















XSLT debugging in Visual Studio






































































Debugging facility in VS




















For more information please visit below site
http://www.w3schools.com/xsl/default.asp





























No comments:

Post a Comment