<?xml version="1.0" encoding="UTF-8"?>
<!--
  Licensed to the Apache Software Foundation (ASF) under one or more
  contributor license agreements.  See the NOTICE file distributed with
  this work for additional information regarding copyright ownership.
  The ASF licenses this file to You under the Apache License, Version 2.0
  (the "License"); you may not use this file except in compliance with
  the License.  You may obtain a copy of the License at

      http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
-->
<!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
<document>
    <header>
        <title>XQueryXPath Sample</title>
    </header>
    <body>
        <section>
            <title>Description</title>
            <p>Author: Steve Traut</p>
            <p>Available: 2005-07-08</p>
            <p>Versions: xmlbeans-v2</p>
            <p>This sample illustrates how you can use the XMLBeans API to execute
XPath and XQuery expressions. The sample illustrates these features:</p>
<ul>
<li>Using the XmlObject.selectPath and XmlCursor.selectPath methods
to execute XPath expressions. The selectPath method's results (if
any) are always chunks of the instance queried against. In other
words, changes to query results change the original instance.
However, you work with results differently depending on whether
selectPath was called from an XmlObject or XmlCursor instance. See
the SelectPath class for more information.</li>

<li>Using the XmlObject.execQuery and XmlCursor.execQuery methods
to execute XQuery expressions. Results of these queries are copied
into new XML, meaning that changes to results do not change the 
original instance. Here again, you work with results differently
depending how which method you used to query. See the ExecQuery
class for more information.</li>
</ul>
        </section>
        <section>
            <title>Files</title>
            <ul>
              <li><a href="XQueryXPath.zip">Zip of all files (XQueryXPath.zip)</a></li>
              <li><a href="XQueryXPath.tgz">Tar gzip of all files (XQueryXPath.tgz)</a></li>
            </ul>
            <ul>
                <li><a href="https://svn.apache.org/viewcvs.cgi/*checkout*/xmlbeans/trunk/samples/XQueryXPath/README.txt">Readme file</a></li>
                <li><a href="https://svn.apache.org/viewcvs.cgi/*checkout*/xmlbeans/trunk/samples/XQueryXPath/src/org/apache/xmlbeans/samples/xquery/ExecQuery.java">ExecQuery.java</a></li>
                <li><a href="https://svn.apache.org/viewcvs.cgi/*checkout*/xmlbeans/trunk/samples/XQueryXPath/src/org/apache/xmlbeans/samples/xquery/SelectPath.java">SelectPath.java</a></li>
                <li><a href="https://svn.apache.org/viewcvs.cgi/*checkout*/xmlbeans/trunk/samples/XQueryXPath/src/org/apache/xmlbeans/samples/xquery/XQueryXPath.java">XQueryXPath.java</a></li>
                <li><a href="https://svn.apache.org/viewcvs.cgi/*checkout*/xmlbeans/trunk/samples/XQueryXPath/src/org/apache/xmlbeans/samples/xquery/XQueryXPathTest.java">XQueryXPathTest.java</a></li>
                <li><a href="https://svn.apache.org/viewcvs.cgi/*checkout*/xmlbeans/trunk/samples/XQueryXPath/schemas/employeeschema.xsd">employeeschema.xsd</a></li>
                <li><a href="https://svn.apache.org/viewcvs.cgi/*checkout*/xmlbeans/trunk/samples/XQueryXPath/xml/employees.xml">employees.xml</a></li>
                <li><a href="https://svn.apache.org/viewcvs.cgi/*checkout*/xmlbeans/trunk/samples/XQueryXPath/build.xml">build.xml</a></li>
            </ul>
        </section>
    </body>
</document>
