<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-199347374923183082</id><updated>2012-01-29T08:52:01.769-08:00</updated><category term='Grails'/><category term='UML'/><category term='XML'/><category term='Spring'/><category term='Java'/><category term='Database'/><category term='Groovy'/><category term='Linux'/><title type='text'>Kibo world</title><subtitle type='html'>Blog about Linux, Java and another nice thinks.</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://tomasjurman.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://tomasjurman.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Tom Jurman</name><uri>http://www.blogger.com/profile/00104562212599535461</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://3.bp.blogspot.com/_lsyyvFurh9s/SuQdL_1dwJI/AAAAAAAAAAc/anR56lMKBDc/S220/p1010102.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>29</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-199347374923183082.post-862182571230088717</id><published>2011-04-25T07:07:00.000-07:00</published><updated>2011-04-25T07:17:50.040-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Linux'/><title type='text'>DCS-950G streaming in Linux</title><content type='html'>&lt;span id="internal-source-marker_0.26758444174216156" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Yesterday I got IPcam DCS-950G. I wanted to connect camera to &lt;/span&gt;&lt;a href="http://www.lavrsen.dk/foswiki/bin/view/Motion/WebHome"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;Motion&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;  but it did not get stream. I had to use stupid IE only. I was angry and  looking for solution. I found people just as disappointed as I am. I  decided to solve this problem.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;I went to &lt;/span&gt;&lt;a href="http://tsd.dlink.com.tw/downloads2008detail.asp"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;D-Link&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; and study specification. After that I downgrade camera to &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;DCS-950G_ A1_Firmware_v1.00&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;  because the camera with this old firmware does not need admin  authentication for streaming. It's so convenient. I do not have to send  with each request the password. &lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;I  wanted to write a Groovy script, but I wanted to control the camera  from the router, which I do not have Java. That's why I chose &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Bash&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;After hours of testing, I had written a working script:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre class="sh" name="code"&gt;#!/bin/bash&lt;br /&gt;#&lt;br /&gt;&lt;br /&gt;WEBCAM_IP="192.168.0.20"&lt;br /&gt;&lt;br /&gt;#######################################################################&lt;br /&gt;&lt;br /&gt;#init&lt;br /&gt;{ exec 3&amp;lt;&amp;gt;/dev/tcp/${WEBCAM_IP}/5000; echo -n "ARAGORN_INIT" &amp;gt;&amp;amp;3; cat &amp;lt;&amp;amp;3&amp;gt; /dev/null; } &amp;amp;&lt;br /&gt;&lt;br /&gt;sleep 2&lt;br /&gt;&lt;br /&gt;#start&lt;br /&gt;exec 3&amp;lt;&amp;gt;/dev/tcp/${WEBCAM_IP}/5001&lt;br /&gt;echo -n "ARAGORN_START#255055293901165#0#1#0" &amp;gt;&amp;amp;3&lt;br /&gt;&lt;br /&gt;#data&lt;br /&gt;while :&lt;br /&gt;do&lt;br /&gt; &lt;br /&gt;    head -c 40 &amp;lt;&amp;amp;3 &amp;gt; header.hex&lt;br /&gt;    BYTES=( `hexdump -v -s 24 -n 4 -e ' 1/1 "%02X " ' header.hex` )      &lt;br /&gt;    HEX="${BYTES[3]}${BYTES[2]}${BYTES[1]}${BYTES[0]}"   &lt;br /&gt;    DATA_LENGTH=`echo "obase=10; ibase=16; ${HEX}" | bc`  &lt;br /&gt;    head -v -c "${DATA_LENGTH}" &amp;lt;&amp;amp;3&lt;br /&gt;                                &lt;br /&gt;done&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;With MPlayer I can play the stream directly from the camera. Mplayer takes around 5% CPU on a single camera.&lt;/span&gt;&amp;nbsp;  &lt;br /&gt;&lt;pre class="sh" name="code"&gt;./dcs-950G.bash | mplayer - -demuxer mpeg4es&lt;br /&gt;&lt;/pre&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="313px;" src="https://lh4.googleusercontent.com/WUlXCu_QTxaCDjiv9FLVm3ylo-cIaA53OKT2Coz7rM10aMA8WDKfNqFRqpfDohv29YJXs_AgWCh1c5TiUHASu8yE7DY4cFiHv-ZPVqGuNUIKyiOToA" width="500px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt; &lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt; &lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;With ffmpeg I got every second &amp;nbsp;actual jpeg for Motion. &lt;/span&gt; &lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt; &lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/199347374923183082-862182571230088717?l=tomasjurman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tomasjurman.blogspot.com/feeds/862182571230088717/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tomasjurman.blogspot.com/2011/04/dcs-950g-streaming-in-linux.html#comment-form' title='8 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/862182571230088717'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/862182571230088717'/><link rel='alternate' type='text/html' href='http://tomasjurman.blogspot.com/2011/04/dcs-950g-streaming-in-linux.html' title='DCS-950G streaming in Linux'/><author><name>Tom Jurman</name><uri>http://www.blogger.com/profile/00104562212599535461</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://3.bp.blogspot.com/_lsyyvFurh9s/SuQdL_1dwJI/AAAAAAAAAAc/anR56lMKBDc/S220/p1010102.jpg'/></author><thr:total>8</thr:total></entry><entry><id>tag:blogger.com,1999:blog-199347374923183082.post-4370524509570769968</id><published>2010-09-05T11:26:00.000-07:00</published><updated>2010-09-08T02:03:58.196-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Java'/><title type='text'>Google Web Toolkit RPC</title><content type='html'>&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Google Web Toolkit &lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;GWT Java-to-JavaScript Compiler&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;JRE emulation library&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;a href="http://gwt.google.com/samples/Showcase/Showcase.html"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;GWT web UI&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Development tools (Hosted web browser, shell,..)&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;RPC&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Communicating with the server&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;RPC&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;JSON&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Packages&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="382px;" src="https://lh5.googleusercontent.com/_6S2Yl16yJBIl1-JO0I8JWpjpydomrZ94mh-pZpmPUEpuE5u0sot5ajwEhdbrEvr31g8eH4CaY_FNPcIh7M_YgQE0D7swYqCOK5HouGDw9DpaKwa-g" width="248px;" /&gt;&lt;/h3&gt;&lt;hr /&gt;&lt;h3 id="internal-source-marker_0.3850367759789911"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Making GWT Remote Procedure Calls&lt;/span&gt;&lt;/h3&gt;&lt;h3 id="internal-source-marker_0.3850367759789911"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="248px;" src="https://lh3.googleusercontent.com/V37TxoSAhv1tI5h_0wxasviHXdO-R95KbbvyjASVt3EReJ652pGCzdmu0Ehb7caMOaQ8pRHMiPssvZRSX8-TExRDWqLIeFFZMxcy3Lg-RIY8lyPESQ" width="312px;" /&gt;&lt;/h3&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3 id="internal-source-marker_0.3850367759789911"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Modul&lt;/span&gt;&lt;/h3&gt;&lt;h3 id="internal-source-marker_0.3850367759789911"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="87px;" src="https://lh5.googleusercontent.com/cgDh6Qk_lLP2a8gz2QxfvfzjFxdZhDPoC94lg2k91te9-uF4sbQwfs1JkYkeAACkv2c0M-PG-rWhS3qLEizmCQ_uzo2nmHCgd25AQZP9JU1muOJimg" width="622px;" /&gt;&lt;/h3&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;UI&lt;/span&gt;&lt;/h3&gt;&lt;pre class="java" name="code"&gt;package cz.kibo.client;&lt;br /&gt;&lt;br /&gt;import com.google.gwt.core.client.EntryPoint;&lt;br /&gt;import com.google.gwt.core.client.GWT;&lt;br /&gt;import com.google.gwt.user.client.ui.Button;&lt;br /&gt;import com.google.gwt.user.client.ui.Label;&lt;br /&gt;import com.google.gwt.user.client.ui.RootPanel;&lt;br /&gt;import com.google.gwt.event.dom.client.ClickEvent;&lt;br /&gt;import com.google.gwt.event.dom.client.ClickHandler;&lt;br /&gt;import com.google.gwt.user.client.rpc.AsyncCallback;&lt;br /&gt;import com.google.gwt.user.client.rpc.ServiceDefTarget;&lt;br /&gt;import com.google.gwt.user.client.ui.TextBox;&lt;br /&gt;&lt;br /&gt;public class SayHelloEntryPoint implements EntryPoint {&lt;br /&gt;&lt;br /&gt;    private TextBox name = new TextBox();  &lt;br /&gt;    private Label response = new Label();&lt;br /&gt;    private Button button = new Button("Send");&lt;br /&gt;&lt;br /&gt;    private HelloServiceAsync service;&lt;br /&gt;    private AsyncCallback serviceCallback = new AsyncCallback() {&lt;br /&gt;           public void onSuccess(Object result) {&lt;br /&gt;              String string = (String) result;               &lt;br /&gt;              response.setText(string);&lt;br /&gt;           }&lt;br /&gt;&lt;br /&gt;           public void onFailure(Throwable caught) {&lt;br /&gt;               response.setText("There was an error: " + caught.toString());&lt;br /&gt;           }&lt;br /&gt;    };&lt;br /&gt;&lt;br /&gt;    /**&lt;br /&gt;    * Creates a new instance of MainEntryPoint&lt;br /&gt;    */&lt;br /&gt;    public SayHelloEntryPoint() {&lt;br /&gt;    }&lt;br /&gt;&lt;br /&gt;    /**&lt;br /&gt;    * The entry point method, called automatically by loading a module&lt;br /&gt;    * that declares an implementing class as an entry-point&lt;br /&gt;    */&lt;br /&gt;    public void onModuleLoad() {&lt;br /&gt;     &lt;br /&gt;       //Obtain Async service for interface&lt;br /&gt;       service = GWT.create(HelloService.class);&lt;br /&gt;&lt;br /&gt;       //go to URL&lt;br /&gt;       //or use @RemoteServiceRelativePath("hello")&lt;br /&gt;       ServiceDefTarget endpoint = (ServiceDefTarget) service;&lt;br /&gt;       endpoint.setServiceEntryPoint(GWT.getModuleBaseURL() + "hello");&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;       RootPanel root = RootPanel.get("content");       &lt;br /&gt;       root.add(new Label("Name"));&lt;br /&gt;       root.add(name);     &lt;br /&gt;&lt;br /&gt;       // Listen for mouse events on the Add button.&lt;br /&gt;       button.addClickHandler(new ClickHandler() {&lt;br /&gt;             public void onClick(ClickEvent event) {&lt;br /&gt;                   service.sayHello(new Person(name.getText()), serviceCallback);&lt;br /&gt;             }&lt;br /&gt;       });&lt;br /&gt;&lt;br /&gt;       root.add(button);&lt;br /&gt;       root.add(response);&lt;br /&gt;&lt;br /&gt;    }&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;hr id="internal-source-marker_0.3850367759789911" /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Service&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;extends RemoteService&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;pre class="java" name="code"&gt;package cz.kibo.client;&lt;br /&gt;&lt;br /&gt;import com.google.gwt.user.client.rpc.RemoteService;&lt;br /&gt;import com.google.gwt.user.client.rpc.RemoteServiceRelativePath;&lt;br /&gt;&lt;br /&gt;//@RemoteServiceRelativePath("hello")&lt;br /&gt;public interface HelloService extends RemoteService&lt;br /&gt;{&lt;br /&gt;    String sayHello(Person p);&lt;br /&gt;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;span id="internal-source-marker_0.3850367759789911" style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;AsyncService&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;return void&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;have last param AsyncCallback&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;pre class="java" name="code"&gt;package cz.kibo.client;&lt;br /&gt;&lt;br /&gt;import com.google.gwt.user.client.rpc.AsyncCallback;&lt;br /&gt;&lt;br /&gt;public interface HelloServiceAsync {&lt;br /&gt;    void sayHello(Person p, AsyncCallback callback);&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;h3 id="internal-source-marker_0.3850367759789911"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Service implementation&lt;/span&gt;&lt;/h3&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;can extends RemoteServiceServlet&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;or you have to implements HelloServlet yet &lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;pre class="java" name="code"&gt;package cz.kibo.server;&lt;br /&gt;&lt;br /&gt;import com.google.gwt.user.server.rpc.RemoteServiceServlet;&lt;br /&gt;import cz.kibo.client.HelloService;&lt;br /&gt;import cz.kibo.client.Person;&lt;br /&gt;&lt;br /&gt;public class HelloServiceImpl extends RemoteServiceServlet implements HelloService{&lt;br /&gt;&lt;br /&gt;    public String sayHello(Person p) {&lt;br /&gt;       return "Hello " + p.name;&lt;br /&gt;    }&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;div style="font-family: Arial,Helvetica,sans-serif;"&gt;&lt;b&gt;RemoteServiceServlet&lt;/b&gt;&lt;/div&gt;&lt;ul&gt;&lt;li&gt;getThreadLocalRequest()&amp;nbsp;&lt;/li&gt;&lt;li&gt;getThreadLocalResponse() &lt;/li&gt;&lt;li&gt;onBeforeRequestDeserialized (String)&amp;nbsp;&lt;/li&gt;&lt;li&gt;onAfterResponseSerialized (String)&amp;nbsp;&lt;/li&gt;&lt;li&gt;shouldCompressResponse (HttpServletRequest, HttpServletResponse, String) &lt;/li&gt;&lt;li&gt;processCall(String) &lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;br /&gt;&lt;hr id="internal-source-marker_0.3850367759789911" /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Model&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;implements Serializable or IsSerializable &lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;pre class="java" name="code"&gt;package cz.kibo.client;&lt;br /&gt;&lt;br /&gt;import java.io.Serializable;&lt;br /&gt;&lt;br /&gt;public class Person implements Serializable{&lt;br /&gt;&lt;br /&gt;    public String name;&lt;br /&gt;  &lt;br /&gt;    public Person(){&lt;br /&gt;              this(null);&lt;br /&gt;    }&lt;br /&gt;&lt;br /&gt;    public Person(String name) {&lt;br /&gt;          super();&lt;br /&gt;          this.name = name;      &lt;br /&gt;    }&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;hr id="internal-source-marker_0.3850367759789911" /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Netbeans project&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;a href="http://downloads.kibo.cz/blog/HelloWorld.zip"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;source&lt;/span&gt;&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/199347374923183082-4370524509570769968?l=tomasjurman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tomasjurman.blogspot.com/feeds/4370524509570769968/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tomasjurman.blogspot.com/2010/09/google-web-toolkit-rpc.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/4370524509570769968'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/4370524509570769968'/><link rel='alternate' type='text/html' href='http://tomasjurman.blogspot.com/2010/09/google-web-toolkit-rpc.html' title='Google Web Toolkit RPC'/><author><name>Tom Jurman</name><uri>http://www.blogger.com/profile/00104562212599535461</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://3.bp.blogspot.com/_lsyyvFurh9s/SuQdL_1dwJI/AAAAAAAAAAc/anR56lMKBDc/S220/p1010102.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-199347374923183082.post-8235932257552250733</id><published>2010-08-18T02:05:00.000-07:00</published><updated>2010-08-18T02:07:26.381-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='XML'/><title type='text'>XSLT</title><content type='html'>&lt;span id="internal-source-marker_0.2299002538341478" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Text are from &lt;/span&gt;&lt;a href="http://www.w3schools.com/xsl/"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;http://www.w3schools.com/xsl/&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XSL stands for E&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;X&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;tensible &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;S&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;tylesheet &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;L&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;anguage.&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;CSS - Style Sheet for HTML&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XSL - Style Sheet fot XML&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XSL describes how the XML document should be displayed!&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XSL consists of three parts:&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XSLT - a language for transforming XML documents&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;a href="http://tomasjurman.blogspot.com/2010/07/xpath.html"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;XPath&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; - a language for navigating in XML documents&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XSL-FO - a language for formatting XML documents&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;hr /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;XSLT&lt;/span&gt;&lt;/h3&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XSLT stands for XSL Transformations&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XSLT is the most important part of XSL&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XSLT transforms an XML document into another XML document&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XSLT uses XPath to navigate in XML documents&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;All major browsers have support for XML and XSLT. &lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;hr /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;XSLT - Transformation&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Declaration&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The  root element that declares the document to be an XSL style sheet is  &amp;lt;xsl:stylesheet&amp;gt; or &amp;lt;xsl:transform&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;or&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xsl:transform version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example transformation&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Source &lt;/span&gt;&lt;a href="http://www.w3schools.com/xsl/cdcatalog.xml"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;xml&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; file. &lt;/span&gt;&lt;br /&gt;&lt;img height="180px;" src="https://lh5.googleusercontent.com/jdtnTagxmpDbEvrkuB6oygE1J6XduLklDNDo2OmCo7_8KM5ddXlZmq7souvtomI93Le7s2V8R-McBnfgNgTFXutjVOJcIfwvV0lDLoIPl9DRY_Hg_w" width="320px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Source &lt;/span&gt;&lt;a href="http://www.w3schools.com/xsl/cdcatalog.xsl"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;XSL Style Sheet &lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;file.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="365px;" src="https://lh3.googleusercontent.com/RwuEHp2xYoApqasPNnzVTBm3LH-rtmmz3xPWZdigNnyFBc1cN8IR_-5s55vv6URg77clW_6liVbK28-Ps_gbGUW91lSdjuT4E51SkVqT-FLkXr_wew" width="367px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;a href="http://www.w3schools.com/xsl/cdcatalog_with_xsl.xml"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;Result&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; of transformation.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="198px;" src="https://lh3.googleusercontent.com/PLxY8PRaBRegHYZYZSo2qigGo_YSNplz_TDHtcL9fagXK_YaxIZf9atduEsrrvAHo_G_04vLybItXRibc0BravTm1NYmCPesSIJes0cY8Rx8FL2rew" width="410px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xsl:template&amp;gt;&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The &amp;lt;xsl:template&amp;gt; element is used to build templates.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;match&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;  attribute is used to associate a template with an XML element. The  match attribute can also be used to define a template for the entire XML  document. The value of the match attribute is an XPath expression (i.e.  match="/" defines the whole document).&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="321px;" src="https://lh5.googleusercontent.com/M6QeOAxcNWg84TuPcqQcGJbSEOB8fbefqzXo2dKJ09sbsXgSKdih0DmVwvAqA35qyfNd1GchixerZ2IbYi8kXXIoc2HvltsZPh8TfZWikBiuzdfrHg" width="369px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xsl:value-of&amp;gt;&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The  &amp;lt;xsl:value-of&amp;gt; element can be used to extract the value  of an XML element and add it to the output stream of the transformation:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="324px;" src="https://lh3.googleusercontent.com/JxVZ8SvDINO_IPOwfCx33D8TYVvsUs6vHFCzZyX9Q-wg0E9QTBH2SY_r0w-0WkN5jg0CUJJ0Z30oSIO9dGUqIEe45IU1g8WJFd07j58Q_tTY-Yu6kQ" width="423px;" /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xsl:for-each&amp;gt;&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The XSL &amp;lt;xsl:for-each&amp;gt; element can be used to select every XML element of a specified node-set:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="355px;" src="https://lh3.googleusercontent.com/wydQH47IOz1-j0JeEb0pNiBRiG33jbLBjTSQq4sRdRPi0qRLEo-a4py74YUO2lgxf2jIlQzit4SumRSiQ9UIQPyt_GvfQiafxfT23bDrDe6vuyoFSg" width="372px;" /&gt;&lt;br /&gt;&lt;h4&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 12pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Filtering&lt;/span&gt;&lt;/h4&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;We  can also filter the output from the XML file by adding a criterion to  the select attribute in the &amp;lt;xsl:for-each&amp;gt; element.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="350px;" src="https://lh3.googleusercontent.com/cRmTBbbm1GQG4bu9uksmPSWZ2jEUH7B6KIVN3rQIJsb_0Mo26WVWsJciJpTKleuCHNDaDZQahO7b3JVCYd7Lbwnl_ze98ItLaeSqXdrlo1L3J5Bpxg" width="431px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xsl:sort&amp;gt;&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The &amp;lt;xsl:sort&amp;gt; element is used to sort the output.&lt;/span&gt;&lt;img height="363px;" src="https://lh6.googleusercontent.com/0yByElKY4RQZQXE3lnXTY6x2YarWD4mM66mdb2-2eeZrbzpaWs0MtLacQi3oQlT6KoqwH0mXIAM1TzlzDWPlU37NRajzwxRPm1LTbt5Af1wushEs-g" width="378px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xsl:if&amp;gt;&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The &amp;lt;xsl:if&amp;gt; element is used to put a conditional test against the content of the XML file.&lt;/span&gt;&lt;img height="379px;" src="https://lh6.googleusercontent.com/7zrmWRDXUnbH0i5WlCSwjEvhUW3XG_tLCfSE5fV-liGNd_b-ifjULG235_5yuIzJY2r7k5oN8ZLqR0BNqJgKEegK_ZaumTCoSTWYamIl3PFgq1iWNQ" width="381px;" /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xsl:choose&amp;gt;&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The  &amp;lt;xsl:choose&amp;gt; element is used in conjunction with  &amp;lt;xsl:when&amp;gt; and &amp;lt;xsl:otherwise&amp;gt; to express  multiple conditional tests.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="462px;" src="https://lh4.googleusercontent.com/aUd_BruSw3q8USKK3S0SDZph-9qjy5aqhSMZfbNesTUtxit7qnp-zlJnJKZWWO8WNA0mqxQxIVGQr4_9YMAFEwvVDq8WmZSWQRCbiqQZU6g9nxkUdQ" width="376px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xsl:apply-templates&amp;gt;&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The  &amp;lt;xsl:apply-templates&amp;gt; element applies a template to the  current element or to the current element's child nodes.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;If  we add a select attribute to the &amp;lt;xsl:apply-templates&amp;gt;  element it will process only the child element that matches the value of  the attribute. We can use the select attribute to specify the order in  which the child nodes are processed.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="466px;" src="https://lh5.googleusercontent.com/c41pJJJyOfNhcWmScqy0JugrrvmPPmIaRyZ2oJjKHz0cVrHuk4bH5ifzLBFFzqCW4X3k-FNRANXu-Bvf0_Yc8o2a_orq1rbZHGjN6cKAavQNtrIThQ" width="364px;" /&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/199347374923183082-8235932257552250733?l=tomasjurman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tomasjurman.blogspot.com/feeds/8235932257552250733/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tomasjurman.blogspot.com/2010/08/xslt.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/8235932257552250733'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/8235932257552250733'/><link rel='alternate' type='text/html' href='http://tomasjurman.blogspot.com/2010/08/xslt.html' title='XSLT'/><author><name>Tom Jurman</name><uri>http://www.blogger.com/profile/00104562212599535461</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://3.bp.blogspot.com/_lsyyvFurh9s/SuQdL_1dwJI/AAAAAAAAAAc/anR56lMKBDc/S220/p1010102.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-199347374923183082.post-2909183595314352354</id><published>2010-08-06T08:08:00.000-07:00</published><updated>2010-08-07T11:51:39.521-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Grails'/><title type='text'>Grails: Unit testing</title><content type='html'>&lt;span id="internal-source-marker_0.2050209198836913" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Source:&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; &lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;a href="http://grails.org/doc/latest/"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;Grails Doc&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;a href="http://www.manning.com/gsmith/"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;Grails in Action&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; - book&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;a href="http://apress.com/book/view/9781590597583"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;The Definitive Guide to Grails&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; - book&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The core of the testing plugin is the &lt;/span&gt;&lt;a href="http://www.grails.org/doc/1.1.x/api/grails/test/GrailsUnitTestCase.html"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;grails.test.GrailsUnitTestCase&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; class.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;mockDomain(class, testInstances)&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Takes a class and makes mock implementations of all the domain class methods.&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example:&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;void testSomething() {&lt;br /&gt;  def testInstances=[]&lt;br /&gt;  mockDomain(Song, testInstances)&lt;br /&gt;  assertEquals(0, Song.count())&lt;br /&gt;  new Song(name:"Supper's Ready").save()&lt;br /&gt;  assertEquals(1, Song.count())&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;span id="internal-source-marker_0.2050209198836913" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example:&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;def testInstances = [ new Item(code: "NH-4273997", name: "Laptop"),&lt;br /&gt;                new Item(code: "EC-4395734", name: "Lamp"),&lt;br /&gt;                new Item(code: "TF-4927324", name: "Laptop") ]&lt;br /&gt;mockDomain(Item, testInstances)&lt;/pre&gt;&lt;h3 id="internal-source-marker_0.2050209198836913"&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;mockForConstraintsTests(class, testInstances)&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Highly  specialised mocking for domain classes and command objects that allows  you to check whether the constraints are behaving as you expect them to.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example:&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;class Book {&lt;br /&gt;  String title&lt;br /&gt;  String author&lt;br /&gt;    static constraints = {&lt;br /&gt;        title(blank: false, unique: true)&lt;br /&gt;        author(blank: false, minSize: 5)&lt;br /&gt;    }&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;class BookTests extends GrailsUnitTestCase {&lt;br /&gt;  void testConstraints() {&lt;br /&gt;      def existingBook = new Book(title: "Misery", author: "Stephen King")&lt;br /&gt;      mockForConstraintsTests(Book, [ existingBook ])&lt;br /&gt;        // Validation should fail if both properties are null.&lt;br /&gt;        def book = new Book()&lt;br /&gt;        assertFalse book.validate()&lt;br /&gt;        assertEquals "nullable", book.errors["title"]&lt;br /&gt;        assertEquals "nullable", book.errors["author"]&lt;br /&gt;        // So let's demonstrate the unique and minSize constraints.&lt;br /&gt;        book = new Book(title: "Misery", author: "JK")&lt;br /&gt;        assertFalse book.validate()&lt;br /&gt;        assertEquals "unique",     book.errors["title"]&lt;br /&gt;        assertEquals "minSize", book.errors["author"]&lt;br /&gt;        // Validation should pass!&lt;br /&gt;        book = new Book(title: "The Shining", author: "Stephen King")&lt;br /&gt;        assertTrue book.validate()&lt;br /&gt;    }&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;hr id="internal-source-marker_0.2050209198836913" /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;mockFor(class)&lt;/span&gt;&lt;/h3&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="188px;" src="https://lh5.googleusercontent.com/siZn1HKVDbaW2vQVr7SlWAYO9yucgqvm7_6JNJFugmBfbWocAmVON5IfagTBmQnoketJThxd1NJ5J2TcLScPsRKr99CdbYqRgqsYDmzYbMMmtVz8RQ" width="472px;" /&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;This  range determines how many times you expect the method to be called, so  if the number of invocations falls outside of that range then an  assertion error will be thrown. If no range is specified, a default of  "1..1" is assumed.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The  closure arguments should match the number and types of the mocked  method, but otherwise you are free to add whatever you want in the body.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example:&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;def strictControl = mockFor(MyService)&lt;br /&gt;strictControl.demand.someMethod(0..2) { String arg1, int arg2 -&amp;gt; … }&lt;br /&gt;strictControl.demand.static.aStaticMethod {-&amp;gt; … }&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;span id="internal-source-marker_0.2050209198836913" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example:&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;class MyService { def otherService&lt;br /&gt;    String createSomething() {        &lt;br /&gt;        def stringId = otherService.newIdentifier()        &lt;br /&gt;        def item = new Item(code: stringId, name: "Bangle")        &lt;br /&gt;        item.save()        &lt;br /&gt;        return stringId      &lt;br /&gt;   }&lt;br /&gt;   &lt;br /&gt;   int countItems(String name) {        &lt;br /&gt;        def items = Item.findAllByName(name)        &lt;br /&gt;        return items.size()    &lt;br /&gt;   }&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;import grails.test.GrailsUnitTestCase&lt;br /&gt;class MyServiceTests extends GrailsUnitTestCase {&lt;br /&gt;    void testCreateSomething() {&lt;br /&gt;        // Mock the domain class.&lt;br /&gt;        mockDomain(Item)&lt;br /&gt;&lt;br /&gt;        // Mock the "other" service.&lt;br /&gt;        String testId = "NH-12347686"&lt;br /&gt;        def otherControl = mockFor(OtherService)&lt;br /&gt;        otherControl.demand.newIdentifier(1..1) {-&amp;gt; return testId }&lt;br /&gt;&lt;br /&gt;        // Initialise the service and test the target method.&lt;br /&gt;        def testService = new MyService()&lt;br /&gt;        testService.otherService = otherControl.createMock()&lt;br /&gt;&lt;br /&gt;        def retval = testService.createSomething()&lt;br /&gt;&lt;br /&gt;        // Check that the method returns the identifier returned by the&lt;br /&gt;        // mock "other" service and also that a new Item instance has&lt;br /&gt;        // been saved.&lt;br /&gt;        def testInstances = Item.list()        &lt;br /&gt;        assertEquals testId, retval&lt;br /&gt;        assertEquals 1, testInstances.size()&lt;br /&gt;        assertTrue testInstances[0] instanceof Item&lt;br /&gt;    }&lt;br /&gt;&lt;br /&gt;    void testCountItems() {&lt;br /&gt;        // Mock the domain class, this time providing a list of test&lt;br /&gt;        // Item instances that can be searched.&lt;br /&gt;        def testInstances = [ new Item(code: "NH-4273997", name: "Laptop"),&lt;br /&gt;                         new Item(code: "EC-4395734", name: "Lamp"),&lt;br /&gt;                         new Item(code: "TF-4927324", name: "Laptop") ]&lt;br /&gt;        mockDomain(Item, testInstances)&lt;br /&gt;       &lt;br /&gt;&lt;br /&gt;// Initialise the service and test the target method.&lt;br /&gt;&lt;br /&gt;def testService = new MyService()&lt;br /&gt;        assertEquals 2, testService.countItems("Laptop")&lt;br /&gt;        assertEquals 1, testService.countItems("Lamp")&lt;br /&gt;        assertEquals 0, testService.countItems("Chair")&lt;br /&gt;    }&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;hr id="internal-source-marker_0.2050209198836913" /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;mockLogging(class, enableDebug = false)&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Adds a mock "log" property to a class. Any messages passed to the mock logger are echoed to the console.&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;br /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;mockController(class)&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Adds  mock versions of the dynamic controller properties and methods to the  given class. This is typically used in conjunction with the  ControllerUnitTestCase class.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Mock controller properties available in unit tests&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;request&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;response&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;session&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;flash&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;params&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;redirectArgs&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;renderArgs&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;template&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;modelAndView&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example:&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;class PostControllerUnitTests extends grails.test.ControllerUnitTestCase {&lt;br /&gt;     void testShow() {&lt;br /&gt;          mockDomain(User, [&lt;br /&gt;                    new User(userId: "glen"),&lt;br /&gt;                    new User(userId: "peter") ]&lt;br /&gt;          this.controller.params.id = "peter"&lt;br /&gt;          def model = this.controller.show()&lt;br /&gt;          assertEquals "peter", model["viewUser"]?.userId&lt;br /&gt;     }&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;span id="internal-source-marker_0.2050209198836913" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example - action returns a model:&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;void testList() {&lt;br /&gt;     mockDomain(Album, [ new Album(title: "Odelay"),&lt;br /&gt;     new Album(title: "Abbey Road"] )&lt;br /&gt;     def model = controller.list()&lt;br /&gt;     assertEquals 2, model.albumList.size()&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;span id="internal-source-marker_0.2050209198836913" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example - Testing the Contents of the Response:&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;void testIndex() {&lt;br /&gt;     controller.index()&lt;br /&gt;     assertEquals "Welcome to the gTunes store!", controller.response.contentAsString&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;span id="internal-source-marker_0.2050209198836913" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example - contents of render args&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;render(view: "show", model:[album:Album.get(params.id)])&lt;br /&gt;&lt;br /&gt;void testShow() {&lt;br /&gt;     mockDomain(Album, new Album(id:1, title: "Aha Shake Heartbreak"))&lt;br /&gt;     mockParams.id = 1&lt;br /&gt;     controller.show()&lt;br /&gt;     assertEquals "show", renderArgs.view&lt;br /&gt;     assertEquals 1, renderArgs.model.album.id&lt;br /&gt;     assertEquals "Aha Shake Heartbreak", renderArgs.model.album.title&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;span id="internal-source-marker_0.2050209198836913" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;mockParams&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;:  this property provides a mock implementation of the params object that  you can populate with values before calling the controller. In addition  to a mock implementation of the params object, the  ControllerUnitTestCase class provides the following properties that mock  various aspects of the controller API:&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;mockRequest&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;mockResponse&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;mockSession&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;mockParams&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;mockFlash&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;span id="internal-source-marker_0.5810118844734445" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;note:&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;ControllerUnitTestCase &lt;b&gt;not support some dynamic method&lt;/b&gt;. For instance: &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;bindData().&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; Then is better use integration testing, or you can add this method to controller:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;example:&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;this.controller.metaClass.bindData = { obj, params -&amp;gt;&lt;br /&gt;           params.each { key, value -&amp;gt;&lt;br /&gt;                       obj."$key" = value&lt;br /&gt;               }&lt;br /&gt;       }&lt;br /&gt;&lt;br /&gt;this.controller.metaClass.getGrailsApplication = {-&amp;gt; return [config: [:]] }&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example - redirect&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;:&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;//in controller&lt;br /&gt;redirect(controller: "post", action: "list")&lt;br /&gt;&lt;br /&gt;// in test&lt;br /&gt;assertEquals "post", this.controller.redirectArgs["controller"]&lt;br /&gt;assertEquals "list", this.controller.redirectArgs["action"]&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;span id="internal-source-marker_0.2050209198836913" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example - testing action:&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;def register = {&lt;br /&gt;     if(request.method == 'POST') {&lt;br /&gt;          def u = new User(params)&lt;br /&gt;          if(u.password != params.confirm) {&lt;br /&gt;                u.errors.rejectValue("password", "user.password.dontmatch")&lt;br /&gt;                return [user:u]&lt;br /&gt;          }else if(u.save()) {&lt;br /&gt;                session.user = u&lt;br /&gt;                redirect(controller:"store")&lt;br /&gt;          }else {&lt;br /&gt;                return [user:u]&lt;br /&gt;          }&lt;br /&gt;&lt;br /&gt;     }&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;void testRegistrationFailed() {&lt;br /&gt;     mockRequest.method = 'POST'&lt;br /&gt;     mockDomain(User)&lt;br /&gt;&lt;br /&gt;     mockParams.login = ""&lt;br /&gt;     def model = controller.register()&lt;br /&gt;&lt;br /&gt;     assertNull mockSession.user&lt;br /&gt;     assert model&lt;br /&gt;     def user = model.user&lt;br /&gt;     assert user.hasErrors()&lt;br /&gt;     assertEquals "blank", user.errors.login&lt;br /&gt;     assertEquals "nullable", user.errors.password&lt;br /&gt;     assertEquals "nullable",&lt;br /&gt;     user.errors.firstName&lt;br /&gt;     assertEquals "nullable", user.errors.firstName&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;void testRegistrationSuccess() {&lt;br /&gt;     mockRequest.method = 'POST'&lt;br /&gt;     mockDomain(User)&lt;br /&gt;&lt;br /&gt;     mockParams.login = "joebloggs"&lt;br /&gt;     mockParams.password = "password"&lt;br /&gt;     mockParams.confirm = "password"&lt;br /&gt;     mockParams.firstName = "Joe"&lt;br /&gt;     mockParams.lastName = "Blogs"&lt;br /&gt;&lt;br /&gt;     def model = controller.register()&lt;br /&gt;&lt;br /&gt;     assertEquals 'store',redirectArgs.controller&lt;br /&gt;     assertNotNull mockSession.user&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;span id="internal-source-marker_0.2050209198836913" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example - test Command&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;def login = { LoginCommand cmd -&amp;gt;&lt;br /&gt;     if(request.method == 'POST') {&lt;br /&gt;        if(!cmd.hasErrors()) {&lt;br /&gt;             session.user = cmd.getUser()&lt;br /&gt;             redirect(controller:'store')&lt;br /&gt;        }else {&lt;br /&gt;             render(view:'/store/index', model:[loginCmd:cmd])&lt;br /&gt;        }&lt;br /&gt;     }else {&lt;br /&gt;            render(view:'/store/index')&lt;br /&gt;     }&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;void testLoginUserNotFound() {&lt;br /&gt;     mockRequest.method = 'POST'&lt;br /&gt;     mockDomain(User)&lt;br /&gt;     MockUtils.prepareForConstraintsTests(LoginCommand)&lt;br /&gt;     def cmd = new LoginCommand(login:"fred", password:"letmein")&lt;br /&gt;     cmd.validate()&lt;br /&gt;     controller.login(cmd)&lt;br /&gt;     assertTrue cmd.hasErrors()&lt;br /&gt;     assertEquals "user.not.found", cmd.errors.login&lt;br /&gt;     assertEquals "/store/index", renderArgs.view&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;void testLoginPasswordInvalid() {&lt;br /&gt;     mockRequest.method = 'POST'&lt;br /&gt;     mockDomain(User, [new User(login:"fred", password:"realpassword")])&lt;br /&gt;     MockUtils.prepareForConstraintsTests(LoginCommand)&lt;br /&gt;     def cmd = new LoginCommand(login:"fred", password:"letmein")&lt;br /&gt;     cmd.validate()&lt;br /&gt;     controller.login(cmd)&lt;br /&gt;     assertTrue cmd.hasErrors()&lt;br /&gt;     assertEquals "user.password.invalid", cmd.errors.password&lt;br /&gt;     assertEquals "/store/index", renderArgs.view&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;void testLoginSuccess() {&lt;br /&gt;     mockRequest.method = 'POST'&lt;br /&gt;     mockDomain(User, [new User(login:"fred", password:"letmein")])&lt;br /&gt;     MockUtils.prepareForConstraintsTests(LoginCommand)&lt;br /&gt;     def cmd = new LoginCommand(login:"fred", password:"letmein")&lt;br /&gt;     cmd.validate()&lt;br /&gt;     controller.login(cmd)&lt;br /&gt;     assertFalse cmd.hasErrors()&lt;br /&gt;     assertNotNull mockSession.user&lt;br /&gt;     assertEquals "store", redirectArgs.controller&lt;br /&gt;}&lt;/pre&gt;&lt;h3 id="internal-source-marker_0.2050209198836913"&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;mockTagLib(class)&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Adds  mock versions of the dynamic taglib properties and methods to the given  class. This is typically used in conjunction with the  TagLibUnitTestCase class.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example:&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;class MyTagLib {&lt;br /&gt;     def repeat = { attrs, body -&amp;gt;&lt;br /&gt;            attrs.times?.toInteger().times { n -&amp;gt;&lt;br /&gt;                      body(n)&lt;br /&gt;             }&lt;br /&gt;      }&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&amp;lt;g:repeat times="3"&amp;gt;Hello number ${it}&amp;lt;/g:repeat&amp;gt;&lt;br /&gt;&lt;br /&gt;import grails.test.*&lt;br /&gt;class MyTagLibTests extends TagLibUnitTestCase {&lt;br /&gt;&lt;br /&gt;     MyTagLibTests() {&lt;br /&gt;         super(MyTagLib)&lt;br /&gt;     }&lt;br /&gt;&lt;br /&gt;     void testRepeat() {&lt;br /&gt;         tagLib.repeat(times: '2') {&lt;br /&gt;            'output&amp;lt;br/&amp;gt;'&lt;br /&gt;         }&lt;br /&gt;&lt;br /&gt;     assertEquals 'output&amp;lt;br/&amp;gt;output&amp;lt;br/&amp;gt;', tagLib.out.toString()&lt;br /&gt;     }&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;span id="internal-source-marker_0.2050209198836913" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;img height="158px;" src="https://lh5.googleusercontent.com/i5og30c8-RsWovV-dmRznS1UMuzz_X5N6HqMIEt0drcBTnjgVNyK8RnLeUW5m5m47H3q1zSZyQCrboQt0V2eHKHRCus4UYfoQdYOgu2ter1rrsPgMQ" width="345px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;img height="229px;" src="https://lh4.googleusercontent.com/CEmR9gy4jy1yPhWnoTGtxWeEKGtWrOxmIUPXRbX8ypNMVLQvnzTh25D3-AMzOvD7-9jpsOV_DM5ds_NrXGwUJfO43V-7cJ0mfmnr-aR-9HIh9Wjl-A" width="460px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;One oddity is the empty map ([:]) as an argument, which is required because the tag&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;expects an attribute map as the first argument. If we were passing in at least one attri-&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;bute value, we could use the implicit syntax instead:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;tagLib.isLoggedIn(attr1: "value") { ... }&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;In order to check whether the appropriate text has been generated by the tag, we&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;then perform a &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;toString()&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; on the &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;out&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; property and compare it to the expected value&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;h3 id="internal-source-marker_0.5810118844734445"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;mockConfig&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;In your controller you have to use &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;org.codehaus.groovy.grails.commons.ConfigurationHolder&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;. Then is very simple used &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;mockConfig&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example:&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;private void takeOverDemoTestsets(school) {&lt;br /&gt;       def String[] ids = ConfigurationHolder.config.cz.svse.testy.demo.testsets.ids.split(",")&lt;br /&gt;       ids.each(){ id -&amp;gt;&lt;br /&gt;           def testset = Testset.get(id)&lt;br /&gt;           if(testset){&lt;br /&gt;               school.addToTestsets( testset.clone(  school ) )&lt;br /&gt;               log.info(" add testset: ${testset.title}" )              &lt;br /&gt;           }&lt;br /&gt;   }&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;class SchoolControllerTests extends grails.test.ControllerUnitTestCase {&lt;br /&gt;  &lt;br /&gt;    protected void setUp() {&lt;br /&gt;       super.setUp()&lt;br /&gt;           &lt;br /&gt;       mockDomain(Testset, [&lt;br /&gt;                   new Testset(id:1, title:"one"),&lt;br /&gt;                   new Testset(id:2, title:"two")&lt;br /&gt;       ])&lt;br /&gt;&lt;br /&gt;       mockDomain(School,[])&lt;br /&gt;&lt;br /&gt;       mockConfig ('''&lt;br /&gt;               cz.svse.testy.demo.testsets.ids="1,2"&lt;br /&gt;       ''')     &lt;br /&gt;    }&lt;br /&gt;&lt;br /&gt;    protected void tearDown() {&lt;br /&gt;           super.tearDown()&lt;br /&gt;    }&lt;br /&gt;  &lt;br /&gt;    void testTakeOverDemoTestsets() {&lt;br /&gt;           &lt;br /&gt;       def school = new School()&lt;br /&gt;       assertEquals 0, school.testsets.size()&lt;br /&gt;&lt;br /&gt;       this.controller.takeOverDemoTestsets(school)&lt;br /&gt;       assertEquals 2, school.testsets.size()                &lt;br /&gt;    }&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/199347374923183082-2909183595314352354?l=tomasjurman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tomasjurman.blogspot.com/feeds/2909183595314352354/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tomasjurman.blogspot.com/2010/08/grails-unit-testing.html#comment-form' title='8 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/2909183595314352354'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/2909183595314352354'/><link rel='alternate' type='text/html' href='http://tomasjurman.blogspot.com/2010/08/grails-unit-testing.html' title='Grails: Unit testing'/><author><name>Tom Jurman</name><uri>http://www.blogger.com/profile/00104562212599535461</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://3.bp.blogspot.com/_lsyyvFurh9s/SuQdL_1dwJI/AAAAAAAAAAc/anR56lMKBDc/S220/p1010102.jpg'/></author><thr:total>8</thr:total></entry><entry><id>tag:blogger.com,1999:blog-199347374923183082.post-4199414926479547971</id><published>2010-08-04T11:39:00.000-07:00</published><updated>2010-08-04T11:45:02.347-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='UML'/><title type='text'>UML - class diagram</title><content type='html'>&lt;span id="internal-source-marker_0.6954307618386353" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;All text are from: &lt;/span&gt;&lt;a href="http://www.ibm.com/developerworks/rational/library/content/RationalEdge/sep04/bell/"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;http://www.ibm.com/developerworks/rational/library/content/RationalEdge/sep04/bell/&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Class&lt;/span&gt;&lt;/h3&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;name&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;attributes&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;operations&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="128px;" src="https://lh6.googleusercontent.com/6H09YyKYMy71KKbUIX80-ZYjDTQJm3-xHTux6NEFD96rrqRiJx-lAdZ1zxpFEZx7IkC69SHm22wKUI7h0ZtVlkSRvlsVk2-vovYOqddPIYhMnD0kEw" width="288px;" /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Inheritance&lt;/span&gt;&lt;/h3&gt;&lt;ol&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: lower-alpha; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;class&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: lower-alpha; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;interface&lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;a) class&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="335px;" src="https://lh3.googleusercontent.com/y7k7rqLHMEU7EX1VOAwBgo-j2BF_v3uUa5ibkf8OEOIvkOwvCLlAY1pjDX3Hg4RDHYSYny1sDiXQy1NHAKivArXedToUnrUUGNpqBYP2ewIx76nevQ" width="563px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The class BankAccount &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;is abstract class &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;and the method: &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;withdrawal&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; is abstract. Notice the &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;italicized text&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;. You can use stereotype &lt;i&gt;abstract&lt;/i&gt;&lt;/span&gt;&lt;i&gt;&lt;span id="internal-source-marker_0.6954307618386353" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;abstract&gt;&lt;/abstract&gt;&lt;/span&gt;&lt;/i&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; too.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;b) interface&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="262px;" src="https://lh6.googleusercontent.com/zI3oj9jxX_R5wpjgXMX_BdytHdXxcndc6MLnp1Jfs9rOjePi7UeXFewysV2MnbUteqsqzJYDZZUTe2edW5AxU5uO3xyaREhkfLb8D0TW6YAq1TuVZg" width="325px;" /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Asociation&lt;/span&gt;&lt;/h3&gt;&lt;ol&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: lower-alpha; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Bi-directional&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: lower-alpha; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Uni-directional&lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;a) Bi-directional&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="147px;" src="https://lh4.googleusercontent.com/Zroks8s9pn71HQQWfEyaNlywyWfIUHlqVL5VbcSH3gowhsNnTun3Jb8Lur__DGHnwyuI_1NAWgihxbZfshAjhvYX3p6m9eYM5Ogovxc6D_K3X80dBw" width="580px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;b) Uni-directional&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;img height="109px;" src="https://lh3.googleusercontent.com/yqP_ROFoP3d7brVkZNYEjp0tQH9QkX7aLwr-SlRaCjKP1smt2JPyLfQB4_P4BjS971Tcv8J133PZAMPkEUJp6ULTSFF1BYmJQk4435tXI-hXSbaOnw" width="580px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Association class&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;In  modeling an association, there are times when you need to include  another class because it includes valuable information about the  relationship. For this you would use an &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;association class&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; that you tie to the primary association. An association class is represented like a normal class.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="186px;" src="https://lh3.googleusercontent.com/VZ2aEQ9BON6H-0jg2BozMKz9n4XAVowboQp3RTnsGYrJHYL-PD8ax5qRUaXw52z4IggxSI1btapbCD6-htpAuX-7f96wsPuxc60ai5rUsSudEdnegQ" width="580px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Aggregation&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;An  association with an aggregation relationship indicates that one class  is a part of another class. In an aggregation relationship, the child  class instance can outlive its parent class.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="49px;" src="https://lh4.googleusercontent.com/iEYEGFpUcIUzef2s18S3xN4Dl8EhVIA7X83FenkAzHcxmFioz79f1fOHMjD8v2HRH_QtFrln0anFv318Wm5cpfRWKjbkiJLWd2dz76sldeVA6bFsWA" width="291px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Composition&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Because  the relationship is a composition relationship, when the Company  instance is removed/destroyed, the Department instance is automatically  removed/destroyed as well. Another important feature of composition  aggregation is that the part class can only be related to one instance  of the parent class.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="47px;" src="https://lh3.googleusercontent.com/stnrd6cJ8Q1H-EP2SMDw06jhVMIVVLrncvSZA8a9TPACCaAgcsBJrbQyULBUOK_hcwI3zHHKIAvKuGTfySTHKsh9Dr51vvalWVDXU2M1wvW0UufpGA" width="341px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Reflexive association &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;A class can also be associated with itself, using a reflexive association.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="114px;" src="https://lh5.googleusercontent.com/zlW9VwyH-m77VfT6x4R0zoKxHZg7pRq7n3qu8qKOjXf65DiD97n9kIsPFb5cd7fqFNEaJOmSRZACZpEgXIuEi5Ji-h1b2sch7HRg9Ohhwml84Xa_ow" width="193px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Visibility&lt;/span&gt;&lt;/h3&gt;&lt;table style="border-collapse: collapse; border: medium none;"&gt;&lt;tbody&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Mark&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Visibility type&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;+&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Public&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;#&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Protected&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;-&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Private&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;~&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Package&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Multiplicity&lt;/span&gt;&lt;/h3&gt;&lt;table style="border-collapse: collapse; border: medium none;"&gt;&lt;tbody&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Indicator&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Meaning&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;0..1&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Zero or one&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;1&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;One only&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;0..*&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Zero or more&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;*&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Zero or more&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;1..*&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;One or more&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;3&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Three only&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;0..5&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Zero to Five&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;5..15&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Five to Fifteen&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/199347374923183082-4199414926479547971?l=tomasjurman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tomasjurman.blogspot.com/feeds/4199414926479547971/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tomasjurman.blogspot.com/2010/08/uml-class-diagram.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/4199414926479547971'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/4199414926479547971'/><link rel='alternate' type='text/html' href='http://tomasjurman.blogspot.com/2010/08/uml-class-diagram.html' title='UML - class diagram'/><author><name>Tom Jurman</name><uri>http://www.blogger.com/profile/00104562212599535461</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://3.bp.blogspot.com/_lsyyvFurh9s/SuQdL_1dwJI/AAAAAAAAAAc/anR56lMKBDc/S220/p1010102.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-199347374923183082.post-4180231597985889867</id><published>2010-08-03T01:41:00.000-07:00</published><updated>2010-08-03T01:44:51.402-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='XML'/><title type='text'>XML schema</title><content type='html'>&lt;span id="internal-source-marker_0.34264563619830257" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;All text are from &lt;/span&gt;&lt;a href="http://www.w3schools.com/schema"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;http://www.w3schools.com/schema&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML Schema is an XML-based alternative to &lt;/span&gt;&lt;a href="http://tomasjurman.blogspot.com/2010/07/dtd.html"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;DTD&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;An XML Schema:&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML Schemas are extensible to future additions&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML Schemas are richer and more powerful than DTDs&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML Schemas&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt; are written in XML&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML Schemas &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;support data types&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML Schemas support namespaces&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Example:&amp;nbsp;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="99px;" src="https://lh6.googleusercontent.com/OI2nSC2yD4NeR0QNp7CfQLkulcp_4L_Dvuotdjt5Plk2T-AIDp7wax1Ev9W7u5hgC13BymsKUwbyc3AjValZIHggQIku9-wLUKrY9jwNScjQcQ9Y" width="340px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;DTD:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="70px;" src="https://lh3.googleusercontent.com/KXT5nwpJ5G6fx1iMh1j4g1jBkzw7QIo6wop6RgNqF-Fi3NTUVccMl8gdYj5ziIxh0R1HJ3NEdPNqpUusaxSALJZcBvcYfBSRR31CYcUweix9TaCR" width="321px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XMLSchema:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;img height="261px;" src="https://lh4.googleusercontent.com/39_bwfbqzJkZqm5rE20n2eSq3IHYBMDrtMO43x1I2OWO0kcrue0Ub6OqdwbpiT_3N_r_4uQ3nv4Oh7s1LAXATQJ-aI6sQIQ23TkZRX4GKu1kz83Q" width="416px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The note element is a &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;complex type&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; because it contains other elements. The other elements (to, from, heading, body) are &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;simple types&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; because they do not contain other elements.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Reference to a DTD&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="161px;" src="https://lh3.googleusercontent.com/oUamrRM1wLomtvraaubGHvhjwscmvO036N0BQfHO1saBlqRDeUPSdeNze9h4txjjBEm5PyWUR22OfPekUMuPPlpBzE9Xb9Ittei0k7n78tew7vHM" width="345px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Reference to an XML Schema&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="160px;" src="https://lh5.googleusercontent.com/aJUQDBc143iHZkEwdCN_HxbILTUWFXth4oLnWpKJAc-dbp7EkAUOFgdd87jrYEcAabK88hFChFUfz5QHJLA1tdiGf_MTMEwaCr6V1yJIfM_ZWR-4WA" width="420px;" /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;XSD - &amp;lt;schema&amp;gt; element&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;The &amp;lt;schema&amp;gt; element is the root element of every XML Schema.&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Simple elements&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;A simple element is an XML element that &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;can contain only text&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;. It cannot contain any other elements or attributes.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The  text can be of many different types. It can be one of the types  included in the XML Schema definition (boolean, string, date, etc.), or  it can be a custom type that you can define yourself.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;You  can also add restrictions (facets) to a data type in order to limit its  content, or you can require the data to match a specific pattern.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Example:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="43px;" src="https://lh5.googleusercontent.com/JT5CXkPMocHlptM3sQ8XGHIU6hIZsYhpguzJ8oYp0frXaXG9DJoQ_6Z1UFRfc7QRLNVo2qFYcP_BFJwRXjUId4DNT-yDBZSjbI8s88Emac8EyHjbbg" width="243px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XSD&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="45px;" src="https://lh3.googleusercontent.com/EUdenZ7--XMLGuOcLGcd5VLStpIjNrsBtvLNm8dxMe8KXtW4Tw599IY-9rPKG0EFVEoZaem7YbTQ6-ClO5bFkuT2XqJNuoG6ViBML0Exns6oaDXdMw" width="355px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML Schema has a lot of built-in data types. The most common types are:&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;xs:string&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;xs:decimal&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;xs:integer&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;xs:boolean&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;xs:date&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;xs:time&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;default&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xs:element name="color" type="xs:string" &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;default="red"&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;/&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;fixed&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;You cannot specify another value.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xs:element name="color" type="xs:string" &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;fixed="red"&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;/&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;XSD Attributes&lt;/span&gt;&lt;/h3&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;All attributes are declared as simple types.&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Simple elements cannot have attributes.&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Example:&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xs:attribute name="lang" type="xs:string"/&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;default&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xs:attribute name="lang" type="xs:string" &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;default="EN"&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;/&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;fixed&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xs:attribute name="lang" type="xs:string" &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;fixed="EN"&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;/&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;optional&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xs:attribute name="lang" type="xs:string" &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;use="required"&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;/&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;XSD Restrictions / Facets&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Restrictions are used to define acceptable values for XML elements or attributes. &lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Restrictions &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table style="border-collapse: collapse; border: medium none;"&gt;&lt;tbody&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Constraint&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Description&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;enumeration&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Defines a list of acceptable values&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;fractionDigits&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Specifies the maximum number of decimal places allowed. Must be equal to or greater than zero&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;length&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Specifies the exact number of characters or list items allowed. Must be equal to or greater than zero&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;maxExclusive&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Specifies the upper bounds for numeric values (the value must be less than this value)&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;maxInclusive&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Specifies the upper bounds for numeric values (the value must be less than or equal to this value)&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;maxLength&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Specifies the maximum number of characters or list items allowed. Must be equal to or greater than zero&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;minExclusive&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Specifies the lower bounds for numeric values (the value must be greater than this value)&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;minInclusive&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Specifies the lower bounds for numeric values (the value must be greater than or equal to this value)&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;minLength&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Specifies the minimum number of characters or list items allowed. Must be equal to or greater than zero&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;pattern&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Defines the exact sequence of characters that are acceptable&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;totalDigits&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Specifies the exact number of digits allowed. Must be greater than zero&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;whiteSpace&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Specifies how white space (line feeds, tabs, spaces, and carriage returns) is handled&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Examples:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Restrictions on Values&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="118px;" src="https://lh4.googleusercontent.com/r_HFaT6p0xYisz4qFkQdsBIRyKQ3DcT-8BmxEDxWK5DMG9R9rt_7qlQeUBgzxXuyGnyf1zdQ5WJEXvcEhhoI2a7P7LsE49RKKeJpIfCbuHFkKgHg" width="290px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Restrictions on a Set of Values&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="127px;" src="https://lh5.googleusercontent.com/xr8Al791_lm8NBZ-sR_AswRtBqqYh6fg08tssLWgxuw-ohCYHnquJGolKQrTJL0gy688tcwO-gR80zU-wNE5pCCHBwcBaCYNCkfTJIbcqrXF-6Kq" width="302px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt; &lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Restriction as pattern&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="100px;" src="https://lh3.googleusercontent.com/1hGcw_mqYrxDIzEk63Hwf3noLINEDxnuQ9qoxGo3LSa2wLsIM5NUdYrTOxKSwM6g_VSTeBR_efxYo3VB67Mo9awGLqILKzF1Ahn-_NyulBFaNTo4" width="295px;" /&gt;&lt;br /&gt;&lt;img height="102px;" src="https://lh6.googleusercontent.com/8s_d7VQoeCXWJR_MzS3zVbourujVhmjcs57Yvh7o9bvpKhgbIan0Yj6dAhvYffaDay07tggQqIxCyf2iMKI4RADftFnsvVLZSSm8vbG_-QcVyVQ6" width="305px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;Restrictions on whitespace characters&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The  whiteSpace constraint is set to "replace", which means that the XML  processor WILL REPLACE all white space characters (line feeds, tabs,  spaces, and carriage returns) with spaces:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="102px;" src="https://lh3.googleusercontent.com/WIyMQ7gqad9iDnIB14RT3XScMHqHiMR4aewyiGOGiQr1b7mF3g0fkWgeemrc1aK6pDgOt8tzqf89E7DHdwlqKLmBQWOJYa3Ph1Sc1Ki2MNmB8D0t-A" width="294px;" /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Complex element&lt;/span&gt;&lt;/h3&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;empty elements&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;elements that contain only other elements&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;elements that contain only text&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;elements that contain both other elements and text&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;A complex XML element, "product", which is empty:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;product pid="1345"/&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;A complex XML element, "employee", which contains only other elements:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;employee&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; &amp;nbsp;&amp;lt;firstname&amp;gt;John&amp;lt;/firstname&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; &amp;nbsp;&amp;lt;lastname&amp;gt;Smith&amp;lt;/lastname&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;/employee&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;A complex XML element, "food", which contains only text:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;food type="dessert"&amp;gt;Ice cream&amp;lt;/food&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;A complex XML element, "description", which contains both elements and text:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;description&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;It happened on &amp;lt;date lang="norwegian"&amp;gt;03.03.99&amp;lt;/date&amp;gt; ....&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;/description&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Define a Complex element&lt;/span&gt;&lt;/h3&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The "employee" element can have a type attribute that refers to the name of the complex type to use:&lt;/span&gt;&lt;br /&gt;&lt;img height="115px;" src="https://lh4.googleusercontent.com/1hA5DbqpQTsTWIYcuuowvQYgN0e_Hzfj0zW0gbNHYyW9LchTgpLXuzJJ9gwZT2OKBmabbZNQCvdS34cD6h_jE9tfzil1jwH0Y1kngfDRtiEESa_2" width="402px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;If you use the method described above, several elements can refer to the same complex type, like this:&lt;/span&gt;&lt;img height="149px;" src="https://lh5.googleusercontent.com/_Bff8czitBOm5zBVuGl70-UStELeu88nT8XNB3PgCOjXzQkJ0vPI3qapywLCptgFoi8VyMrk_fDLNIQj5EmlNl_QdEOOrEXcjXjSBfdxwcSWwMku" width="397px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;You can also base a complex element on an existing complex element and add some elements, like this:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="292px;" src="https://lh5.googleusercontent.com/mP0KE89-NOuUgRFRh3-bm3ITqTf-GanuznaDh0X-QadzpFCQNqwyPijvkhTapOKswigCmsnVQMUDF0AQCaR0wjVG4qhhVlIa7VLNqMKk05RAfd1l" width="415px;" /&gt;&lt;br /&gt;&lt;h3&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/h3&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Complex Empty Elements&lt;/span&gt;&lt;/h3&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;An empty XML element:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;product prodid="1345" /&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;To  define a type with no content, we must define a type that allows  elements in its content, but we do not actually declare any elements,  like this:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="132px;" src="https://lh4.googleusercontent.com/jgXR9_AiWYJjkthXSes705pPYXch5re78UgpstgDXmCgEpf61R0vhi3vG6Y67HmqZ9Qv4IDE-pDrQ0R7ikze8YIZDLngh57TyuSbMooNdTbZ_exg" width="483px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;However, it is possible to declare the "product" element more compactly.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="75px;" src="https://lh5.googleusercontent.com/hGqZzQFQUMd3bHHlfSMfmYJV5Ta8TDukPHVzYWR6SFXCRu495sKEdaHgrlBGgWPGo5Y8NRVZ_JKfG-FL7kahp3oUQX3bNsMIh_5ARRUEJg9cnrk7" width="450px;" /&gt;&lt;br /&gt;&lt;h3&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/h3&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Complex Elements Only&lt;/span&gt;&lt;/h3&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;An XML element, "person", that contains only other elements:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;person&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; &amp;nbsp;&amp;lt;firstname&amp;gt;John&amp;lt;/firstname&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; &amp;nbsp;&amp;lt;lastname&amp;gt;Smith&amp;lt;/lastname&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;/person&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;You  can give the complexType element a name, and let the "person" element  have a type attribute that refers to the name of the complexType (if you  use this method, several elements can refer to the same complex type):&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="119px;" src="https://lh3.googleusercontent.com/gFMlV-Foay5cc2F3W9VRJx-oGwIY1lILlX65rALGTF91NiiP3Ne4IyEIuuSBVs3xh-eoZvQ2lW8njpZLxmRCY_w0_79_P1z7AbUSyIe8gTKxOCzj" width="399px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Notice  the &amp;lt;xs:sequence&amp;gt; tag. It means that the elements defined  ("firstname" and "lastname") must appear in that order inside a  "person" element.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Text-Only Elements&lt;/span&gt;&lt;/h3&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Here is an example of an XML element, "shoesize", that contains text-only:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;shoesize country="france"&amp;gt;35&amp;lt;/shoesize&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;This  type contains only simple content (text and attributes), therefore we  add a simpleContent element around the content. When using simple  content, you must define an extension OR a restriction within the  simpleContent element, like this:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="336px;" src="https://lh6.googleusercontent.com/B4m876VvA1B150KigA3nOBStLINpXgTFLbb0q9VhJ_RuJSurB9Mnj8FmdGzyk_dsJJXmyObh4bdQDbOkBYIBHrnY5DFvhJVEzVvTYWR9JcMbRA91" width="302px;" /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Mixed Content&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;A mixed complex type element can contain attributes, elements, and text.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;xml:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="77px;" src="https://lh6.googleusercontent.com/mEw3d4LnA7z9hFEqtFxG8p4whH8ldyGkqdTZ4EXISeASQnMuYBOV7zKW6tcnEwyelzvf3IcA7FfMvC_77jOhiAN9dSmS_FbWuiY30ZNSNSqbCXuv" width="386px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;declaration:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="134px;" src="https://lh4.googleusercontent.com/cANTgKCenh9NbdHhsEVbjFdPAdki9ef7R_EAqQlu9u-wWNMLj5gs7RrrghVEmAKjnCkFVpMtew1m-FhbtUvV5Bzm5gpSPl3koYjiqAdThrrr-M5T" width="444px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Note:&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;  To enable character data to appear between the child-elements of  "letter", the mixed attribute must be set to "true". The  &amp;lt;xs:sequence&amp;gt; tag means that the elements defined (name,  orderid and shipdate) must appear in that order inside a "letter"  element.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Indicators&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Order indicators:&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;All&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Choice&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Sequence&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Occurrence indicators:&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;maxOccurs&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;minOccurs&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Group indicators:&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Group name&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;attributeGroup name&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;All indicator&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The &amp;lt;all&amp;gt; indicator specifies that the child elements can appear in &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;any order,&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; and that each child element must occur &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;only once&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; &lt;/span&gt;&lt;img height="117px;" src="https://lh5.googleusercontent.com/8rjaSR8U4MR7FltGQ5SFAnIzdSkZbxeOPyd165Nnp8UaaDn75gsxNVyu0ezykf-FDRp7KytgTZadHjR69Eo2olz_ly-0rdgBc0Xm13oHJ_HiA3qt" width="388px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Choice indicator&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The &amp;lt;choice&amp;gt; indicator specifies that either &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;one &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;child element &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;or another&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; can occur:&lt;/span&gt;&lt;img height="117px;" src="https://lh3.googleusercontent.com/VumewERj6KybDrMdEWfBGffXo5-xD-FTFolRojOTQLh2sTrmE9sNzzN7BT0MBeozcw7HyfwAQVkc4xE_yED9ox9vVCHDdxMu01XAB0f9fXmrX1jN" width="373px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Sequence indicator&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The &amp;lt;sequence&amp;gt; indicator specifies that the child elements must appear &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;in a specific order&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;:&lt;/span&gt;&lt;img height="117px;" src="https://lh5.googleusercontent.com/tysZ1cjDyqm4Uxb7YAdLbdDIImRiffQMAqddR0PDyDRHHXhKOSDuJGyvBN-7Tth1cwzH-2_V_oT_SXpJ1VvvLIMmoKUCMBxcH3YR-SCfhaWNxVne7w" width="382px;" /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Occurrence indicators&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="131px;" src="https://lh3.googleusercontent.com/NIim3LrpmJNMkH-OvihXMCR5ga7Fzd9szOunEFtnYcfnJzfAxH9DBbtjZmUU5aQMUIURyUKWnyPF37R77Eb6JSqU8k0bFMONMl35iwkC2a-hQV3y" width="388px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Group indicators&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Group indicators are used to define related sets of elements.&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Element groups&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Attribute groups&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Declare Element groups&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="231px;" src="https://lh3.googleusercontent.com/HOJha4c5AegKmbDunBjmK-ouSluru6JE6YqniwDaB4rzarUnWZgTLwczh1jKHU5efiz9AwUHyGn6RzaNsZxyFvWng-Fka8gW7ejjoBa1VZVgjwyr" width="380px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Declare Attribute groups:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="159px;" src="https://lh3.googleusercontent.com/tKZw5YJPbDV2nlaV356E3hqfaVMR9mAu3xT1LN2teF52hK9G2klVR4cIahmVSulq8cpLPV6YLucd32InvdIwuu1xvNtD79xKkMNbZGP_Ebobsz-h" width="372px;" /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;The &amp;lt;any&amp;gt; element&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The &amp;lt;any&amp;gt; element &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;enables us to extend the XML &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;document with elements not specified by the schema.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The  following example is a fragment from an XML schema called "family.xsd".  It shows a declaration for the "person" element. By using the  &amp;lt;any&amp;gt; element we can extend (after  &amp;lt;lastname&amp;gt;) the content of "person" with any element:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="132px;" src="https://lh3.googleusercontent.com/flfAtS0WhOvOMo1W9J6afzz-OWwIizcA0yfzBIM_iUKzoqMVKZ-0DJ5xDQrD187WAZfNF4nHHnpc14ROW3fmgi7cxwFQKcbiUlEeEqhiIQg6Wk3l" width="404px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Schema file called “children.xsd”&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="234px;" src="https://lh5.googleusercontent.com/4-6wGmZDQk7LpJtXIb7CKpjRb8TWYaXyBSrzmiIyckHUp_X9-EkLGS0IuFJgtes-r16hp593q4ojfYSjOiihxQp9jAZwVIy3avTX5cwBQ3XyP4JF" width="415px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The XML file below (called "Myfamily.xml"), uses components from two different schemas; "family.xsd" and "children.xsd":&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="307px;" src="https://lh3.googleusercontent.com/oTIGRfLZjRqDwQISXqTorD8DnDUBGAp_z1W7yswZzonlymMYXhp43HLIGLBB8VMXl3jMFnUfuGsybicZAwT2qjiIDU8ieWcLcdU35OfzVuYjqIPQ" width="420px;" /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;The &amp;lt;anyAttribute&amp;gt; element&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The &amp;lt;anyAttribute&amp;gt; element enables us to extend the XML document with attributes not specified by the schema.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The  following example is a fragment from an XML schema called "family.xsd".  It shows a declaration for the "person" element. By using the  &amp;lt;anyAttribute&amp;gt; element we can add any number of attributes  to the "person" element:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="127px;" src="https://lh5.googleusercontent.com/gQ5VMnCQiJ3Q3tOHDIjtkCFPq9ZfNUdEFI0y5-HPVg7v_XPDW7yaqNSedq-IirZ1DswpowDdgxHUVJQ0ZdMOYilT8ADJrrbC2SpR0D5YXm9C8sv_Sg" width="401px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Schema file, called "attribute.xsd"&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="217px;" src="https://lh4.googleusercontent.com/baTrVXCAtU3AtmSecBh9hILRzfWVFTkgGK6yb6o-PplG3GdhFauuxfnGBHB354sieasJFNd6i_elMJcOE34X_ShIALtz3vhcYGRZObg0Iz3cJtNTEQ" width="422px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The XML file below (called "Myfamily.xml"), uses components from two different schemas; "family.xsd" and "attribute.xsd"&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="264px;" src="https://lh5.googleusercontent.com/2Qbrx_QE9wW1A6udpGxN27mzTMiGIhtbjbIqQcOLNqrU3TOly1TkMyfLsMqh0R4Hzb4BgqaGzoehD8fys77-El7T-4_C9bmsG0qinAmr1rzWwZKk" width="418px;" /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;b&gt;Element substitution &lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;There are way define alias for element called &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;substitutionGroup&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="160px;" src="https://lh4.googleusercontent.com/6hbDUMeNEpgMPrFWd495Jlsobi8z1re-FoufdrkyaSndig9St-Bga3Rhcl7AKH9CCXyKiNeuyw5v1KuBuKe4UXTVcKVl5Uy1MMbYr_ZptNiMF7CI" width="425px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;now you can use:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;kunde&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;navn&amp;gt;tom&amp;lt;/navn&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;/kunde&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Basic data types&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;String&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Date&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Numeric&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Misc&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;String types&lt;/span&gt;&lt;/h3&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;String data type&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The XML processor will &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;not modify the value&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; if you use the string data type.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xs:element name="customer" type="xs:string"/&amp;gt;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;NormalizedString data type&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The XML processor will &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;remove line feeds, carriage returns, and tab characters&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xs:element name="customer" type="xs:normalizedString"/&amp;gt;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Token data type&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The XML processor will remove line feeds, carriage returns, tabs, &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;leading and trailing spaces, and multiple spaces&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xs:element name="customer" type="xs:token"/&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Note&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;: There are more String types. The other derived from String types.&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Date and time types&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Date type&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The date is specified in the following form "&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;YYYY-MM-DD&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;".&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xs:element name="start" type="xs:date"/&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example:&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;start&amp;gt;2002-09-24&amp;lt;/start&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Time type&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The time is specified in the following form "&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;hh:mm:ss&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;".&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xs:element name="start" type="xs:time"/&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example:&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;start&amp;gt;09:00:00&amp;lt;/start&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;DateTime type&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The dateTime is specified in the following form "&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;YYYY-MM-DDThh:mm:ss&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;". All components are required!&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xs:element name="startdate" type="xs:dateTime"/&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example:&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;startdate&amp;gt;2002-05-30T09:00:00&amp;lt;/startdate&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Duration type&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The time interval is specified in the following form "&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;PnYnMnDTnHnMnS&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;".&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;P indicates the period (required)&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;nY indicates the number of years&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;nM indicates the number of months&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;nD indicates the number of days&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;T indicates the start of a time section (required if you are going to specify hours, minutes, or seconds)&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;nH indicates the number of hours&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;nM indicates the number of minutes&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;nS indicates the number of seconds&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xs:element name="period" type="xs:duration"/&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example:&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;period&amp;gt;P5Y&amp;lt;/period&amp;gt; &amp;lt;!--five years -&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Note&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;: There are more Date and time types. The other derived from Date and time types.&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Numeric data types&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Decimal data type&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The decimal data type is used to specify a numeric value.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xs:element name="prize" type="xs:decimal"/&amp;gt;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example:&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;prize&amp;gt;999.50&amp;lt;/prize&amp;gt;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Integer data type&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The integer data type is used to specify a numeric value without a fractional component.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xs:element name="prize" type="xs:integer"/&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Note&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;: There are more &amp;nbsp;numeric types. The other derived from Decimal data type. (long, short, unsigned,...)&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Miscellaneous data type&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Boolean data type&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Legal values for boolean are true, false, 1 (which indicates true), and 0 (which indicates false).&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xs:attribute name="disabled" type="xs:boolean"/&amp;gt;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example:&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;prize disabled="true"&amp;gt;999&amp;lt;/prize&amp;gt;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Binary data type&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;We have two binary data types:&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;base64Binary (Base64-encoded binary data)&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;hexBinary (hexadecimal-encoded binary data)&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xs:element name="blobsrc" type="xs:hexBinary"/&amp;gt;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;AnyURI data type&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The anyURI data type is used to specify a URI.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;xs:attribute name="src" type="xs:anyURI"/&amp;gt;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;example:&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;pic src="http://www.w3schools.com/images/smiley.gif" /&amp;gt;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/199347374923183082-4180231597985889867?l=tomasjurman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tomasjurman.blogspot.com/feeds/4180231597985889867/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tomasjurman.blogspot.com/2010/08/xml-schema.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/4180231597985889867'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/4180231597985889867'/><link rel='alternate' type='text/html' href='http://tomasjurman.blogspot.com/2010/08/xml-schema.html' title='XML schema'/><author><name>Tom Jurman</name><uri>http://www.blogger.com/profile/00104562212599535461</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://3.bp.blogspot.com/_lsyyvFurh9s/SuQdL_1dwJI/AAAAAAAAAAc/anR56lMKBDc/S220/p1010102.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-199347374923183082.post-4003199425387234994</id><published>2010-07-30T02:15:00.000-07:00</published><updated>2010-07-30T04:09:40.362-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Groovy'/><title type='text'>Groovy magic</title><content type='html'>&lt;span id="internal-source-marker_0.06852708404643482" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;All text and example are from:&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;a href="http://groovy.codehaus.org/Dynamic+Groovy"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;http://groovy.codehaus.org/Dynamic+Groovy&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;a href="http://groovy.dzone.com/articles/metaprogramming-groovy-i"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;http://groovy.dzone.com/articles/metaprogramming-groovy-i&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;a href="http://groovy.dzone.com/articles/metaprogramming-groovy-ii-expa"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;http://groovy.dzone.com/articles/metaprogramming-groovy-ii-expa&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Implementing the GroovyObject &lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Groovy's  MOP system includes some extension/hooks points that you can use to  change how a class or an object behaves, mainly being&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;getProperty/setProperty: control property access&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;invokeMethod:  controls method invocation, you can use it to tweak parameters of  existing methods or intercept not-yet existing ones&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;methodMissing: the preferred way to intercept non-existing methods&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;propertyMissing: also the preferred way to intercept non-existing properties&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;invokeMethod() &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;In  any Groovy class you can override invokeMethod which will essentially  intercept all method calls. Simple usage of invokeMethod is to provide  simple AOP style around advice to existing methods:&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;class MyClass implements GroovyInterceptable {&lt;br /&gt;  def invokeMethod(String name, args) {&lt;br /&gt;   &lt;br /&gt;      System.out.println ("Beginning $name")&lt;br /&gt;       def metaMethod = metaClass.getMetaMethod(name, args)&lt;br /&gt;      def result = metaMethod.invoke(this, args)&lt;br /&gt;        System.out.println ("Completed $name")&lt;br /&gt;      return result&lt;br /&gt;  }&lt;br /&gt;}&amp;nbsp;&lt;/pre&gt;&lt;br /&gt;&lt;span id="internal-source-marker_0.06852708404643482" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;getProperty()&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;You can also override property access using the getProperty and setProperty property access hooks.&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;class Expandable {&lt;br /&gt;  def storage = [:]&lt;br /&gt;  def getProperty(String name) { storage[name] }&lt;br /&gt;  void setProperty(String name, value) { storage[name] = value }&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;def e = new Expandable()&lt;br /&gt;e.foo = "bar"&lt;br /&gt;println e.foo&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;span id="internal-source-marker_0.06852708404643482" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;methodMissing&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;class Person {&lt;br /&gt; String name&lt;br /&gt; String sayHello( toWhom ){ "Hello $toWhom" }&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;Person.metaClass.methodMissing = { String name, args -&amp;gt;&lt;br /&gt; "$name() called with $args"&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;def duke = new Person(name:'Duke')&lt;br /&gt;assert duke.sayHello('world') == 'Hello world'&lt;br /&gt;assert duke.greet() == 'greet() called with {}'&lt;br /&gt;assert duke.greet('world') == 'greet() called with {"world"}'&lt;br /&gt;&lt;/pre&gt;&lt;span id="internal-source-marker_0.06852708404643482" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;ExpandoMetaClass&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;/h3&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Every object in groovy has a &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;MetaClass&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;,  responsible for holding information about the object's class. You can  obtain list of methods, add your methods and other meta-programming  scenarios.&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt; &lt;/span&gt;&lt;/h3&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Finding method &lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;println obj.metaClass.methods&lt;br /&gt;println obj.metaClass.methods.find { it.name.startsWith("to") }&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;class Foo {&lt;br /&gt; String prop&lt;br /&gt; def bar() { "bar" }&lt;br /&gt; def bar(String name) { "bar $name" }&lt;br /&gt; def add(Integer one, Integer two) { one + two}&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;def f = new Foo()&lt;br /&gt;&lt;br /&gt;if(f.metaClass.respondsTo(f, "bar")) {&lt;br /&gt; // do stuff&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;if(f.metaClass.respondsTo(f, "bar", String)) {&lt;br /&gt; // do stuff&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;if(!f.metaClass.respondsTo(f, "bar", Integer)) {&lt;br /&gt; // do stuff&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;if(f.metaClass.respondsTo(f, "add", Integer, Integer)) {&lt;br /&gt; // do stuff&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;span id="internal-source-marker_0.06852708404643482" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Note method &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;respondsTo&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Finding properties&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;println obj.metaClass.properties&lt;br /&gt;println obj.metaClass.properties.find { it.name.startsWith("to") }&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;class Foo {&lt;br /&gt; String prop&lt;br /&gt; def bar() { "bar" }&lt;br /&gt; def bar(String name) { "bar $name" }&lt;br /&gt; def add(Integer one, Integer two) { one + two}&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;def f = new Foo()&lt;br /&gt;if(f.metaClass.hasProperty(f, "prop")) {&lt;br /&gt;// do stuff&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;span id="internal-source-marker_0.06852708404643482" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Note method &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;hasProperty&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Add behavour&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;import org.apache.commons.lang.StringUtils&lt;br /&gt;&lt;br /&gt;String.metaClass.capitalize = {&lt;br /&gt; StringUtils.capitalize(delegate)&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;String.metaClass.normalize = {&lt;br /&gt; delegate.split("_").collect { word -&amp;gt;&lt;br /&gt;    word.toLowerCase().capitalize()&lt;br /&gt; }.join("")&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;assert "Groovy" == "groovy".capitalize()&lt;br /&gt;assert "CamelCase" == "CAMEL_CASE".normalize()&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;span id="internal-source-marker_0.06852708404643482" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Example2&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;class Person {&lt;br /&gt; String name&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;Person.metaClass.greet = {&lt;br /&gt; "Hello, I'm $name"&lt;br /&gt;}&lt;br /&gt;def duke = new Person(name:'Duke')&lt;br /&gt;assert duke.greet() == "Hello, I'm Duke"&lt;br /&gt;&lt;/pre&gt;&lt;span id="internal-source-marker_0.06852708404643482" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Overload method&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;:&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;Person.metaClass.whatIsThis = { String arg -&amp;gt;&lt;br /&gt; "it is a String with value '$arg'"&lt;br /&gt;}&lt;br /&gt;Person.metaClass.whatIsThis &amp;lt;&amp;lt; { int arg -&amp;gt;&lt;br /&gt; "it is an int with value $arg"&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;assert duke.whatIsThis( 'Groovy' ) == "it is a String with value 'Groovy'"&lt;br /&gt;assert duke.whatIsThis( 12345 ) == "it is an int with value 12345"&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;span id="internal-source-marker_0.06852708404643482" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Inheritance is not enabled by default&lt;/span&gt;&lt;br /&gt;&lt;pre class="java" name="code"&gt;class Person {&lt;br /&gt; String name&lt;br /&gt;}&lt;br /&gt;class Employee extends Person {&lt;br /&gt; int employeeId&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;Person.metaClass.greet = { -&amp;gt; "Hello!" }&lt;br /&gt;&lt;br /&gt;def duke = new Person(name:'Duke')&lt;br /&gt;assert duke.greet() == "Hello!"&lt;br /&gt;def worker = new Employee(name:'Drone1')&lt;br /&gt;// the following line causes an exception!!&lt;br /&gt;assert worker.greet() == "Hello!"&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;span id="internal-source-marker_0.06852708404643482" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Normally when you add a MetaMethod, it is added for &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;all instances&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt; of that class&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;. However, for GroovyObjects, you can dynamically &lt;/span&gt;&lt;a href="http://groovy.codehaus.org/Per-Instance+MetaClass"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;add methods to individual instances&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; by giving that instance its own MetaClass.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Categories&lt;/span&gt;&lt;/h3&gt;&lt;span id="internal-source-marker_0.06852708404643482" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;With categories you have control over add methods.&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;any &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;public static method&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; is a candidate to be a category method&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;the type of the first parameter is the target type that may have the new methods&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;there is no need to extend a particular class or implement an interface&lt;/span&gt;&lt;img height="171px;" src="https://lh4.googleusercontent.com/yBdvYX-2fjlzElgpBP--ot4RAnRoLML1pnlDAW-I1Fn1mGtk9wsyY8cDgoFVPLxEEv8nbA8Q1uv5qSN6rsYVxLHIAUjdpjeXrKj6iRtoTaXjJ-FY" width="438px;" /&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;if you try to call any of those methods outside &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;use()&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; an exception will be thrown.&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/199347374923183082-4003199425387234994?l=tomasjurman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tomasjurman.blogspot.com/feeds/4003199425387234994/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tomasjurman.blogspot.com/2010/07/groovy-magic.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/4003199425387234994'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/4003199425387234994'/><link rel='alternate' type='text/html' href='http://tomasjurman.blogspot.com/2010/07/groovy-magic.html' title='Groovy magic'/><author><name>Tom Jurman</name><uri>http://www.blogger.com/profile/00104562212599535461</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://3.bp.blogspot.com/_lsyyvFurh9s/SuQdL_1dwJI/AAAAAAAAAAc/anR56lMKBDc/S220/p1010102.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-199347374923183082.post-265936458549827145</id><published>2010-07-24T02:54:00.000-07:00</published><updated>2010-07-24T03:04:00.780-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='XML'/><title type='text'>DTD</title><content type='html'>&lt;span id="internal-source-marker_0.3475784777982637" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;All text are from &lt;/span&gt;&lt;a href="http://www.w3schools.com/dtd"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;http://www.w3schools.com/dtd&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;A  Document Type Definition (DTD) defines the legal building blocks of an  XML document. It defines the document structure with a list of legal  elements and attributes.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;A DTD can be declared:&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;inside XML&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;external reference&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;DTD is not XML document.&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;DTD inside:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="202px;" src="https://lh3.googleusercontent.com/7HYv0YgerQf7Q52IlLIyRjgz2NPlpEJrBTCoIEY1sHgACYJZpY1xYtj2Q3NBaX0PSqqc9ShGwKE-xryMMzh-OL5oaXkus60Xb0lb9iFV1vBweEtW" width="315px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;DTD external&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="117px;" src="https://lh6.googleusercontent.com/5oz7tW714RGYGKCqZQMp5ukuZHncvYLOhtWKiryHAG5glY8VQAYMemjG2_w7atxY818lKQakxdiW_l8X_sng5XkE0Nq1CQ5duxL7th2UHxxx2CI0" width="339px;" /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Why is DTD useful&lt;/span&gt;&lt;/h3&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;With a DTD, each of your XML files can carry a description of its own format.&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;With a DTD, independent groups of people can agree to use a standard DTD for interchanging data.&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Your application can use a standard DTD to verify that the data you receive from the outside world is valid.&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;You can also use a DTD to verify your own data.&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;hr /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Bulding blocks in XML&lt;/span&gt;&lt;/h3&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Elements&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Attributes&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Entities&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;PCDATA&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;CDATA&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Entities&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The following entities are predefined in XML:&lt;/span&gt;&lt;br /&gt;&lt;table style="border-collapse: collapse; border: medium none;"&gt;&lt;tbody&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Entity References&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Character&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;amp;lt&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;amp;lt&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;amp;amp&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;amp;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;"&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;"&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;'&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;'&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;PCDATA&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;PCDATA means &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;parsed character data.&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;PCDATA is text that &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;will be parsed by a parser&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;. The text will be examined by the parser for entities and markup.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;CDATA&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;CDATA means &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;character data&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;CDATA is text that &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;will not be parsed by a parser.&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; Tags inside the text will NOT be treated as markup and entities will not be expanded.&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Elements&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Declaring&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ELEMENT element-name category&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;or&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ELEMENT element-name (element-content)&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Empty elements&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ELEMENT br EMPTY&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Elements with PCDATA&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ELEMENT from (#PCDATA)&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Element with children&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ELEMENT note (to,from,heading,body)&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;When  children are declared in a sequence separated by commas, the children  must appear in the same sequence in the document. In a full declaration,  the children must also be declared, and the children can also have  children. The full declaration of the "note" element is: &lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ELEMENT note (to,from,heading,body)&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ELEMENT to (#PCDATA)&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ELEMENT from (#PCDATA)&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ELEMENT heading (#PCDATA)&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ELEMENT body (#PCDATA)&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;One occurence&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ELEMENT note (message)&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;One and more&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ELEMENT note (message+)&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Zero and more &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ELEMENT note (message*)&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Zero or one&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; &lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ELEMENT note (message?)&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Either/ or content&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ELEMENT note (to,from,header,(message|body))&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Mixed content&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ELEMENT note (#PCDATA|to|from|header|message)*&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Attributes&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Declaring attributes&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;! ATTLIST element-name attribute-name attribute-type default-value&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Example:&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ATTLIST payment type CDATA "check"&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;attribute-type&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; can be one of the following:&lt;/span&gt;&lt;br /&gt;&lt;table style="border-collapse: collapse; border: medium none;"&gt;&lt;tbody&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Type&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Description&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;CDATA&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The value is character data&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;(&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;en1&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;|&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;en2&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;|..)&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The value must be one from an enumerated list&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;ID&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The value is a unique id&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;IDREF&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The value is the id of another element&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;IDREFS&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The value is a list of other ids&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;NMTOKEN&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The value is a valid XML name&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;NMTOKENS&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The value is a list of valid XML names&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;ENTITY&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The value is an entity&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;ENTITIES&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The value is a list of entities&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;NOTATION&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The value is a name of a notation&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;xml:&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The value is a predefined xml value&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;default-value&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; can be one of the following:&lt;/span&gt;&lt;br /&gt;&lt;table style="border-collapse: collapse; border: medium none;"&gt;&lt;tbody&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Value&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Explanation&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;value&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The default value of the attribute&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;#REQUIRED&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The attribute is required&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;#IMPLIED&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The attribute is not required&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;#FIXED &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: italic; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;value&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The attribute value is fixed&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; &lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Default attribute value&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ELEMENT square EMPTY&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ATTLIST square width CDATA "0"&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;In  the example above, the "square" element is defined to be an empty  element with a "width" attribute of &amp;nbsp;type CDATA. If no width is  specified, it has a default value of 0.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Enumerated values&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ATTLIST payment type (check|cash) "cash"&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Example:&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;payment type="check" /&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;or&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;payment type="cash" /&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Why is elements better then attributes&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Data can be stored in child elements or in attributes.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Attribute:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="86px;" src="https://lh5.googleusercontent.com/AWnF8dWfcmFnnLYMtjgmQn6M372ypsFrCjuHC0oNxVRbin0n4uUIKv0rYxgFC_rEIcSG1pkqH_5v2CUrTHmSgQCGyl8xRr6BEiYN29-LzcImXrs9" width="344px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Element:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;img height="160px;" src="https://lh3.googleusercontent.com/mB0dLAPV3H--7WOjFfLG07_k-pPAXJdhFJFyHyTaR5XfZnDrf8ROR5LVWuo-ISvgleV-URxTtaSSd4EeVpOTP53XPzPQ-SS5rFNJAf-mCLsi8z0LHA" width="344px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Some of the problems with attributes are:&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;attributes cannot contain multiple values (child elements can)&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;attributes are not easily expandable (for future changes)&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;attributes cannot describe structures (child elements can)&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;attributes are more difficult to manipulate by program code&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;attribute values are not easy to test against a DTD&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Use attributes only to provide information that is not relevant to the data.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;b&gt;Example: &lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="217px;" src="https://lh6.googleusercontent.com/waLWmwYqDAE_pXuOiOSHKRaLV-Ku-FfnpDjcwMuKyWNgxWAmY-7rzS9LyItrcTsGddgWy_K9WqgNeQaA_8nrOVLjQ7rYHccUT9UuSt2QwlOGPulk" width="340px;" /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Entities&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Entities are variables used to define shortcuts to standard text or special characters.&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Entities can be declared internal or external&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Internal&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ENTITY entity-name "entity-value"&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Example&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ENTITY copyright "Copyright W3Schools."&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;External&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ENTITY entity-name SYSTEM "URI/URL"&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Example&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;!ENTITY writer SYSTEM "http://www.w3schools.com/entities.dtd"&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/199347374923183082-265936458549827145?l=tomasjurman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tomasjurman.blogspot.com/feeds/265936458549827145/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tomasjurman.blogspot.com/2010/07/dtd.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/265936458549827145'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/265936458549827145'/><link rel='alternate' type='text/html' href='http://tomasjurman.blogspot.com/2010/07/dtd.html' title='DTD'/><author><name>Tom Jurman</name><uri>http://www.blogger.com/profile/00104562212599535461</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://3.bp.blogspot.com/_lsyyvFurh9s/SuQdL_1dwJI/AAAAAAAAAAc/anR56lMKBDc/S220/p1010102.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-199347374923183082.post-4050995023414648998</id><published>2010-07-21T01:00:00.000-07:00</published><updated>2010-07-24T02:57:51.977-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='XML'/><title type='text'>XML in nutshell</title><content type='html'>&lt;span id="internal-source-marker_0.1772919163408807" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;All text are from &lt;/span&gt;&lt;a href="http://www.w3schools.com/xml/"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;http://www.w3schools.com/xml/&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Basic&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML was designed to &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;transport and store  data&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML is use to:&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XHTML &lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;WSDL for describing  available web services&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;WAP and WML as markup  languages for handheld devices&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;RSS languages for news  feeds&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;RDF and OWL for describing resources and ontology&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;SMIL for describing  multimedia for the web &lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Syntax rules:&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;All XML elements must  have a closing tag&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML are case sensitive&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML elements must be  properly nested&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML document must have a roo element&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML attribute values  must be quoted&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;There are 5 predefined &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;entity&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; references in XML:&lt;/span&gt;&lt;br /&gt;&lt;table style="border-collapse: collapse; border: medium none;"&gt;&lt;tbody&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;lt;&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;less  than&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;gt;&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;gt;&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;greater  than&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;amp;&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;amp;&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;ampersand  &lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;'&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;'&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;apostrophe&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;"&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;"&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;quotation  mark&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; &lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML elements &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;naming rules&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;:&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Names can contain  letters, numbers, and other characters&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Names cannot start  with a number or punctuation character&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Names cannot start  with the letters xml (or XML, or Xml, etc)&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: disc; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Names cannot contain  spaces&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Validation&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML with correct syntax is "&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Well Formed&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;" XML.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML validated against a  DTD is "&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Valid&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;" XML.&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;DTD &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;(Document Type  Definition )&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The purpose of a DTD is to define the structure of an XML  document. It defines the structure with a list of legal elements:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="121px;" src="https://lh4.googleusercontent.com/1jyyszyUcLq5ZBRWpIO8nwGNNx1jYZSaVjznzzdOSBDYU37WWkS0DDHRSoEFkArPnltWvyqXj0dIhovbTGlzvQviPX14O8wvUDU3j0kusE4Sq1Mg" width="302px;" /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;XML Schema&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;W3C supports an &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;XML-based alternative  to DTD&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;,  called XML Schema:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="178px;" src="https://lh4.googleusercontent.com/G_bix2dA6IilxE-1053yrooLXiFWNJnGHlqvvurssvsPNWfts6drGqK5cXWvmWEz-MkR7T_EqYSWK1ze5d3EvZRH5GYkywFWH5gT6ePrubUJwiHl" width="386px;" /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;XML validator&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;a href="http://validator.w3.org/"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;http://validator.w3.org/&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;XML Namespace&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XML Namespaces provide  a method to avoid element name conflicts.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Namespaces can be  declared in the elements where they are used or in the XML root element:&lt;/span&gt;&lt;img height="242px;" src="https://lh5.googleusercontent.com/UrRBa5uMHkUITcD00zJVelJ9IPbd3p7ikUiXri1QOG34BzhPm47O2Mx7pCv0-GDahXl7lafj7Lj7JETBZcM6NKPcIgiT_7faqOqCgJzT2-Pv3A0q" width="417px;" /&gt;&lt;br /&gt;&lt;img height="265px;" src="https://lh5.googleusercontent.com/hyb9haU_ehZ4iE3neV_hEr8hnW1-jcXoprtbtLz3JxdQEGUtPFK7Hg5Pl1HWyyPva6My4wvLKWW3u6ZSog7KmU4Gi3ewVaUtEQWLV_PopM9nG-tV" width="350px;" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Note:&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; The namespace URI is not used by the parser  to look up information.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;The purpose is to give the namespace a unique  name&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;.  However, often companies use the namespace as a pointer to a web page  containing namespace information.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;In the XSLT document below, you can see  that most of the tags are HTML tags.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The tags that are not HTML tags have  the prefix xsl, identified by the namespace  xmlns:xsl="http://www.w3.org/1999/XSL/Transform":&lt;/span&gt;&lt;img height="385px;" src="https://lh5.googleusercontent.com/IasWw_eJQaTjrLFRoUeJi7mQOtmhdDW61JuNKvBT-GBjo4TWyn1GxMPCpqT82MqUooM8aW8j2bRM3aK1OPaNj6zrYi6IIAM8DC2b45jD_FOIvs6x" width="395px;" /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;CDATA - (Unparsed) Character Data&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The term CDATA is used  about text data that &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;should not be parsed by the XML parser&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;.&amp;nbsp;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;img height="225px;" src="https://lh5.googleusercontent.com/-TO1HojPzClFi9NxSgeJ9csZTnr1UEgmCQkl8Ynv2qRuspbkfnxp8pL4BamZZAhmJ2oZzxYTNejefXJZ1rtqWLvGera9AUDi63izHDZZnO5KapUx" width="205px;" /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/199347374923183082-4050995023414648998?l=tomasjurman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tomasjurman.blogspot.com/feeds/4050995023414648998/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tomasjurman.blogspot.com/2010/07/xml-in-nutshell.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/4050995023414648998'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/4050995023414648998'/><link rel='alternate' type='text/html' href='http://tomasjurman.blogspot.com/2010/07/xml-in-nutshell.html' title='XML in nutshell'/><author><name>Tom Jurman</name><uri>http://www.blogger.com/profile/00104562212599535461</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://3.bp.blogspot.com/_lsyyvFurh9s/SuQdL_1dwJI/AAAAAAAAAAc/anR56lMKBDc/S220/p1010102.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-199347374923183082.post-7026650851295730694</id><published>2010-07-18T11:01:00.000-07:00</published><updated>2010-07-18T11:16:19.270-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Linux'/><title type='text'>Git a nutshell</title><content type='html'>&lt;span id="internal-source-marker_0.23265551349382185" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;I read&lt;/span&gt;&lt;br /&gt;&lt;a href="http://progit.org/"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;http://progit.org/&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;I use&lt;/span&gt;&lt;br /&gt;&lt;a href="http://nbgit.org/"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;http://nbgit.org/&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Install&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Package name&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ yum install git-core&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ apt-get install  git-core&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Global setting&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git config --global  user.name "John Doe"&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git config --global user.email johndoe@example.com&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Local&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Creating Repository&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;ol&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: lower-alpha; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;init&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: lower-alpha; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;clone&lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;a)&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; &lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;//go to project  folder:&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git init&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;b)&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git clone  git://github.com/schacon/grit.git myDestinationFolderName&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Ignore files&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;//cat .gitignore&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;doc/*.txt&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;*.log&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Add files&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;git add [file name,  folder name, or wildcard]&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;git add submodule1/PrimaryClass.java&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;git add .&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;git add *.java&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Committing&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;git commit –m ”your  commit message”&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Status&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git status&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;What's changed&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git diff&lt;/span&gt;&lt;span style="background-color: #e6ecf9; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Remove&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git rm log/\*.log&lt;/span&gt;&lt;span style="background-color: #e6ecf9; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Show history&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git log&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Show tags&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git tag&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Tags&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;ol&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: lower-alpha; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;annotated&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: lower-alpha; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;lightweight&lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;a)&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Add tag&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git tag -a v1.4 -m  'my version 1.4'&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Show tag&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git show v1.4&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;b)&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Add tag&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git tag v1.4-lw&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Remote&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Show remote  repositories&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git remote -v&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Add new remote  repository&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git remote add pb  git://github.com/paulboone/ticgit.git&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Fetch&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;To retrieve remote changes without  merging&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git fetch [name of  remote repository]&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Pull&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Pulling is the combination of a fetch  and a merge.&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git pull&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git pull [remote name]&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git pull [remote  name] [branch name]&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Send your work to  remote repository&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git push origin master&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Search remote repository&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git remote show  origin&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Rename remote  repository&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git remote rename pb  paul&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Remove remote  reposirory&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git remote rm paul&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Send tag to remote  repository&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git push origin v1.5&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;or&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git push origin  --tags&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: #e6ecf9; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Branching&lt;/span&gt;&lt;span style="background-color: #e6ecf9; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: #e6ecf9; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Show branches&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git branch -a&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Create new branch&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git branch [new  branch name] [from branch]&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git branch [new branch name]&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Choosing a Branch&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git checkout [branch  name]&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Merging&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git checkout master&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git merge hotfix&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Delete branch&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git branch -d hotfix&lt;/span&gt;&lt;span style="background-color: #e6ecf9; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Send local branch  "serverfix" to remote branch "awesomebranch"&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Courier New; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;$ git push origin  serverfix:awesomebranch&lt;/span&gt;&lt;span style="background-color: #e6ecf9; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: #e6ecf9; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/199347374923183082-7026650851295730694?l=tomasjurman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tomasjurman.blogspot.com/feeds/7026650851295730694/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tomasjurman.blogspot.com/2010/07/git-nutshell.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/7026650851295730694'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/7026650851295730694'/><link rel='alternate' type='text/html' href='http://tomasjurman.blogspot.com/2010/07/git-nutshell.html' title='Git a nutshell'/><author><name>Tom Jurman</name><uri>http://www.blogger.com/profile/00104562212599535461</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://3.bp.blogspot.com/_lsyyvFurh9s/SuQdL_1dwJI/AAAAAAAAAAc/anR56lMKBDc/S220/p1010102.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-199347374923183082.post-8346890458302413290</id><published>2010-07-10T22:59:00.000-07:00</published><updated>2010-07-10T23:02:02.891-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='XML'/><title type='text'>XLink and XPointer</title><content type='html'>&lt;span id="internal-source-marker_0.3634290293556972" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;All text is from &lt;/span&gt;&lt;a href="http://www.w3schools.com/xlink/"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;http://www.w3schools.com/xlink/&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XLink defines a  standard way of creating hyperlinks in XML documents.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XPointer allows the  hyperlinks to point to more specific parts in the XML document.&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;XLink&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;In HTML, we know (and  all the browsers know!) that the "a" element defines a hyperlink.  However, this is not how it works with XML. In XML documents, you can  use whatever element names you want - therefore it is impossible for  browsers to predict what hyperlink elements will be called in XML  documents.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;To get access to the  XLink attributes and features &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;we must declare the XLink namespace&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; at the top of the  document.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;b&gt;example:&amp;nbsp; &lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/_lsyyvFurh9s/TDlc8fb569I/AAAAAAAAAEU/pQ_ks9y6XMs/s1600/xLinkExample.png" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="400" src="http://2.bp.blogspot.com/_lsyyvFurh9s/TDlc8fb569I/AAAAAAAAAEU/pQ_ks9y6XMs/s400/xLinkExample.png" width="390" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;hr id="internal-source-marker_0.3634290293556972" /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;XPointer&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;If the hyperlink  points to an XML document, we can add an XPointer part after the URL in  the xlink:href attribute, to navigate (with an XPath expression) to a  specific place in the document.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;example:&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/_lsyyvFurh9s/TDldOaVJwUI/AAAAAAAAAEc/1oy-3vQAyE4/s1600/xPointerExample.png" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="338" src="http://2.bp.blogspot.com/_lsyyvFurh9s/TDldOaVJwUI/AAAAAAAAAEc/1oy-3vQAyE4/s400/xPointerExample.png" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; &lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/199347374923183082-8346890458302413290?l=tomasjurman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tomasjurman.blogspot.com/feeds/8346890458302413290/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tomasjurman.blogspot.com/2010/07/xlink-and-xpointer.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/8346890458302413290'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/8346890458302413290'/><link rel='alternate' type='text/html' href='http://tomasjurman.blogspot.com/2010/07/xlink-and-xpointer.html' title='XLink and XPointer'/><author><name>Tom Jurman</name><uri>http://www.blogger.com/profile/00104562212599535461</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://3.bp.blogspot.com/_lsyyvFurh9s/SuQdL_1dwJI/AAAAAAAAAAc/anR56lMKBDc/S220/p1010102.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_lsyyvFurh9s/TDlc8fb569I/AAAAAAAAAEU/pQ_ks9y6XMs/s72-c/xLinkExample.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-199347374923183082.post-8980989069883337192</id><published>2010-07-10T01:14:00.000-07:00</published><updated>2010-07-10T01:15:29.156-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='XML'/><title type='text'>XQuery</title><content type='html'>&lt;span id="internal-source-marker_0.5864081927574213" style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;All text is from &lt;/span&gt;&lt;a href="http://www.w3schools.com/xquery/"&gt;&lt;span style="background-color: transparent; color: #000099; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;www.w3schools.com/xquery/&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;b&gt;XQuery is to XML what  SQL is to database tables&lt;/b&gt;.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XQuery is case-sensitive and XQuery elements,  attributes, and variables must be valid XML names.&lt;/span&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;FLWOR&lt;/span&gt;&lt;/h3&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;FLWOR is an acronym  for "For, Let, Where, Order by, Return".&lt;/span&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;for&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; clause selects all  book elements under the bookstore element &amp;nbsp;into a variable called $x.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;where&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; clause selects only  book elements with a price element with a value greater than 30.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;order by&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; clause defines the  sort-order. Will be sort by the title element.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;The &lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;return&lt;/span&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; clause specifies what  should be returned. Here it returns the title elements.&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;hr /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/_lsyyvFurh9s/TDgrlRdWr0I/AAAAAAAAAEM/Wf_4ioYU5qk/s1600/xquery.png" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="640" src="http://2.bp.blogspot.com/_lsyyvFurh9s/TDgrlRdWr0I/AAAAAAAAAEM/Wf_4ioYU5qk/s640/xquery.png" width="328" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="background-color: transparent; color: black; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/199347374923183082-8980989069883337192?l=tomasjurman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tomasjurman.blogspot.com/feeds/8980989069883337192/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tomasjurman.blogspot.com/2010/07/xquery.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/8980989069883337192'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/8980989069883337192'/><link rel='alternate' type='text/html' href='http://tomasjurman.blogspot.com/2010/07/xquery.html' title='XQuery'/><author><name>Tom Jurman</name><uri>http://www.blogger.com/profile/00104562212599535461</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://3.bp.blogspot.com/_lsyyvFurh9s/SuQdL_1dwJI/AAAAAAAAAAc/anR56lMKBDc/S220/p1010102.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_lsyyvFurh9s/TDgrlRdWr0I/AAAAAAAAAEM/Wf_4ioYU5qk/s72-c/xquery.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-199347374923183082.post-5261704809752638987</id><published>2010-07-09T23:57:00.000-07:00</published><updated>2010-07-10T00:44:32.816-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='XML'/><title type='text'>XPath</title><content type='html'>&lt;h1 id="internal-source-marker_0.11655180240638363" style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;All text is from &lt;/span&gt;&lt;a href="http://www.w3schools.com/XPath/"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: underline; vertical-align: baseline;"&gt;www.w3schools.com/XPath/&lt;/span&gt;&lt;/a&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/h1&gt;&lt;hr style="color: black;" /&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;XPath is a language  for finding information in an XML document.&lt;/span&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;XPath includes over &lt;/span&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;100 built-in  functions.&lt;/span&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;  There are functions for string values, numeric values, date and time  comparison, node and QName manipulation, sequence manipulation, Boolean  values, and more.&lt;/span&gt;&lt;/div&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;In  XPath, there are seven kinds of nodes: &lt;/span&gt;&lt;/div&gt;&lt;ol style="color: black;"&gt;&lt;li style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: decimal; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;element&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: decimal; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;attribute&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: decimal; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;text&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: decimal; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;namespace&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: decimal; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;processing-instruction&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: decimal; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;comment&lt;/span&gt;&lt;/li&gt;&lt;li style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; list-style-type: decimal; text-decoration: none; vertical-align: baseline;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;document nodes&lt;/span&gt;&lt;br /&gt;&lt;/li&gt;&lt;/ol&gt;&lt;h3 style="color: black;"&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/h3&gt;&lt;h3 id="internal-source-marker_0.11655180240638363" style="color: black;"&gt;&lt;span id="internal-source-marker_0.10810187889553968" style="background-color: transparent; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;The XML Example Document&lt;/span&gt;&lt;/h3&gt;&lt;div class="separator" style="clear: both; color: black; text-align: center;"&gt;&lt;a href="http://1.bp.blogspot.com/_lsyyvFurh9s/TDgh4MbWo5I/AAAAAAAAAEE/n0M16Yj8Z4s/s1600/xml.png" imageanchor="1"&gt;&lt;img align="left" border="0" src="http://1.bp.blogspot.com/_lsyyvFurh9s/TDgh4MbWo5I/AAAAAAAAAEE/n0M16Yj8Z4s/s320/xml.png" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div style="color: black;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;h3 id="internal-source-marker_0.11655180240638363" style="clear: both; color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&amp;nbsp;&lt;/span&gt;&lt;/h3&gt;&lt;h3 id="internal-source-marker_0.11655180240638363" style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Selecting Nodes&lt;/span&gt;&lt;/h3&gt;&lt;table style="border-collapse: collapse; border: medium none; color: black;"&gt;&lt;tbody&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Path Expression&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Result&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;bookstore&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects all the child  nodes of the bookstore element&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;/bookstore&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  the root element bookstore&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Note:&lt;/span&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; If the path starts with a slash ( / ) it &amp;nbsp;&amp;nbsp;&amp;nbsp;  always represents an absolute path to an element!&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;bookstore/book&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects all book  elements that are children of bookstore&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;//book&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects all book  elements no matter where they are in the &amp;nbsp;&amp;nbsp;&amp;nbsp; document&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;bookstore//book&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects all book  elements that are descendant of the &amp;nbsp;&amp;nbsp;&amp;nbsp; bookstore element, no matter  where they are under the bookstore element&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;//@lang&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects all attributes  that are named lang&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;div style="color: black;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;h3 style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Predicates&lt;/span&gt;&lt;/h3&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Predicates are always  embedded in square brackets.&lt;/span&gt;&lt;/div&gt;&lt;table style="border-collapse: collapse; border: medium none; color: black;"&gt;&lt;tbody&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Path  Expression&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Result&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;/bookstore/book[1]&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  the first book element that is the child of the &amp;nbsp;&amp;nbsp;&amp;nbsp; bookstore element.&lt;/span&gt;&lt;br /&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Note:&lt;/span&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt; IE5 and later has  implemented that [0] should be the first node, but according to the W3C  standard it should have been [1]!!&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;/bookstore/book[last()]&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  the last book element that is the child of the &amp;nbsp;&amp;nbsp;&amp;nbsp; bookstore element&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;/bookstore/book[last()-1]&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  the last but one book element that is the child of the &amp;nbsp;&amp;nbsp;&amp;nbsp; bookstore  element&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;/bookstore/book[position()&amp;lt;3]&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  the first two book elements that are children of the &amp;nbsp;&amp;nbsp;&amp;nbsp; bookstore  element&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;//title[@lang]&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all the title elements that have an attribute named &amp;nbsp;&amp;nbsp;&amp;nbsp; lang&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;//title[@lang='eng']&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all the title elements that have an attribute named lang &amp;nbsp;&amp;nbsp;&amp;nbsp; with a  value of 'eng'&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;/bookstore/book[price&amp;gt;35.00]&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all the book elements of the bookstore element that &amp;nbsp;&amp;nbsp;&amp;nbsp; have a price  element with a value greater than 35.00&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;/bookstore/book[price&amp;gt;35.00]/title&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all the title elements of the book elements of the &amp;nbsp;&amp;nbsp;&amp;nbsp; bookstore  element that have a price element with a value greater than 35.00&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;h3 style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Wildcard&lt;/span&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/h3&gt;&lt;table style="border-collapse: collapse; border: medium none; color: black;"&gt;&lt;tbody&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Wildcard&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Description&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;*&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Matches any element  node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;@*&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Matches  any attribute node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;node()&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Matches  any node of any kind&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;div style="color: black;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;In the table below we  have listed some path expressions and the result of the expressions:&lt;/span&gt;&lt;/div&gt;&lt;table style="border-collapse: collapse; border: medium none; color: black;"&gt;&lt;tbody&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Path Expression&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Result&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;/bookstore/*&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects all the child  nodes of the bookstore element&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;//*&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all elements in the document&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;//title[@*]&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all title elements which have any attribute&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;h3 style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Selecting Several  Paths&lt;/span&gt;&lt;/h3&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;By  using the | operator in an XPath expression you can select several  paths.&lt;/span&gt;&lt;/div&gt;&lt;table style="border-collapse: collapse; border: medium none; color: black;"&gt;&lt;tbody&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Path Expression&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Result&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;//book/title | //book/price&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all the title AND price elements of all book &amp;nbsp;&amp;nbsp;&amp;nbsp; elements&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;//title | //price&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all the title AND price elements in the document&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;/bookstore/book/title | //price&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all the title elements of the book element of the &amp;nbsp;&amp;nbsp;&amp;nbsp; bookstore element  AND all the price elements in the document&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h3 style="color: black;"&gt;&lt;br /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt; XPath Axes&lt;/span&gt;&lt;/h3&gt;&lt;table style="border-collapse: collapse; border: medium none; color: black;"&gt;&lt;tbody&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;AxisName&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Result&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;ancestor&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects all ancestors  (parent, grandparent, etc.) of the current node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;ancestor-or-self&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all ancestors (parent, grandparent, etc.) of the current node &amp;nbsp;&amp;nbsp;&amp;nbsp; and  the current node itself&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;attribute&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all attributes of the current node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;child&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all children of the current node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;descendant&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all descendants (children, grandchildren, etc.) of the current node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;descendant-or-self&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all descendants (children, grandchildren, etc.) of the current node &amp;nbsp;&amp;nbsp;&amp;nbsp;  and the current node itself&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;following&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  everything in the document after the closing tag of the current node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;following-sibling&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all siblings after the current node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;namespace&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all namespace nodes of the current node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;parent&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects the parent of  the current node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;preceding&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  everything in the document that is before the start tag of the current  node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;preceding-sibling&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all siblings before the current node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;self&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  the current node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;h3 style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;The syntax for a  location step is:&lt;/span&gt;&lt;/h3&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: yellow; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;axisname::nodetest[predicate]&lt;/span&gt;&lt;span style="background-color: yellow; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;h3 style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Examples&lt;/span&gt;&lt;/h3&gt;&lt;table style="border-collapse: collapse; border: medium none; color: black;"&gt;&lt;tbody&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Example&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Result&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;child::book&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects all book nodes  that are children of the current node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;attribute::lang&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects the lang  attribute of the current node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;child::*&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all children of the current node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;attribute::*&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all attributes of the current node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;child::text()&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all text child nodes of the current node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;child::node()&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects all child  nodes of the current node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;descendant::book&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all book descendants of the current node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;ancestor::book&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects all book  ancestors of the current node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;ancestor-or-self::book&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all book ancestors of the current node - and the current as well if it  is a book node&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr style="height: 0px;"&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;child::*/child::price&lt;/span&gt;&lt;/td&gt;&lt;td style="border: 1px dotted rgb(170, 170, 170); padding: 7px; vertical-align: top;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;Selects  all price grandchildren of the curren&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h3 style="color: black;"&gt;&lt;br /&gt;&lt;br /&gt;&lt;hr /&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 14pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Examples&lt;/span&gt;&lt;/h3&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Select all the titles&lt;/span&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;/bookstore/book/title &lt;/span&gt;&lt;/div&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Select the title of  the first book&lt;/span&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;/bookstore/book[1]/title  &lt;/span&gt;&lt;/div&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Select price nodes  with price&amp;gt;35&lt;/span&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;/bookstore/book[price&amp;gt;35]/price  &lt;/span&gt;&lt;/div&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: bold; text-decoration: none; vertical-align: baseline;"&gt;Select title nodes  with price&amp;gt;35&lt;/span&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="color: black;"&gt;&lt;span style="background-color: transparent; font-family: Arial; font-size: 11pt; font-style: normal; font-weight: normal; text-decoration: none; vertical-align: baseline;"&gt;/bookstore/book[price&amp;gt;35]/title&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/199347374923183082-5261704809752638987?l=tomasjurman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tomasjurman.blogspot.com/feeds/5261704809752638987/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tomasjurman.blogspot.com/2010/07/xpath.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/5261704809752638987'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/5261704809752638987'/><link rel='alternate' type='text/html' href='http://tomasjurman.blogspot.com/2010/07/xpath.html' title='XPath'/><author><name>Tom Jurman</name><uri>http://www.blogger.com/profile/00104562212599535461</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://3.bp.blogspot.com/_lsyyvFurh9s/SuQdL_1dwJI/AAAAAAAAAAc/anR56lMKBDc/S220/p1010102.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_lsyyvFurh9s/TDgh4MbWo5I/AAAAAAAAAEE/n0M16Yj8Z4s/s72-c/xml.png' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-199347374923183082.post-6159245875859955185</id><published>2010-05-26T13:05:00.000-07:00</published><updated>2010-05-27T00:05:57.444-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Linux'/><title type='text'>File permissions notation in Linux</title><content type='html'>&lt;p&gt;Every file or folder in Linux has access permissions. There are three types of permissions (what allowed to do with a file):&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;strong&gt;read&lt;/strong&gt; access&lt;/li&gt;&lt;li&gt;&lt;strong&gt;write&lt;/strong&gt; access&lt;/li&gt;&lt;li&gt;&lt;strong&gt;execute&lt;/strong&gt; access&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;Permissions are defined for three types of users:&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;strong&gt;owner&lt;/strong&gt; of the file&lt;/li&gt;&lt;li&gt;&lt;strong&gt;group&lt;/strong&gt; that the owner belongs to&lt;/li&gt;&lt;li&gt;&lt;strong&gt;other&lt;/strong&gt; users&lt;/li&gt;&lt;/ul&gt;&lt;h4&gt;Numeric (octal) representation&lt;/h4&gt;&lt;table&gt;&lt;tr&gt;&lt;th&gt;Octal digit&lt;/th&gt;&lt;th&gt;Text equivalent&lt;/th&gt;&lt;th&gt;Binary value&lt;/th&gt;&lt;th&gt;Meaning&lt;/th&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;0&lt;/td&gt;&lt;td&gt;---&lt;/td&gt;&lt;td&gt;000&lt;/td&gt;&lt;td&gt;All types of access are denied&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;1&lt;/td&gt;&lt;td&gt;--x&lt;/td&gt;&lt;td&gt;001&lt;/td&gt;&lt;td&gt;Execute access is allowed only&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;2&lt;/td&gt;&lt;td&gt;-w-&lt;/td&gt;&lt;td&gt;010&lt;/td&gt;&lt;td&gt;Write access is allowed only&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;3&lt;/td&gt;&lt;td&gt;-wx&lt;/td&gt;&lt;td&gt;011&lt;/td&gt;&lt;td&gt;Write and execute access are allowed&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;4&lt;/td&gt;&lt;td&gt;r--&lt;/td&gt;&lt;td&gt;100&lt;/td&gt;&lt;td&gt;  Read access is allowed only&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;5&lt;/td&gt;&lt;td&gt;r-x&lt;/td&gt;&lt;td&gt;101&lt;/td&gt;&lt;td&gt;Read and execute access are allowed&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;6&lt;/td&gt;&lt;td&gt;rw-&lt;/td&gt;&lt;td&gt;110&lt;/td&gt;&lt;td&gt;Read and write access are allowed&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;7&lt;/td&gt;&lt;td&gt;rwx&lt;/td&gt;&lt;td&gt;111&lt;/td&gt;&lt;td&gt;Everything is allowed&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;h4&gt;Difference in access permissions for files and folders&lt;/h4&gt;&lt;table&gt;&lt;tr&gt;&lt;th&gt;Access type&lt;/th&gt;&lt;th&gt;File&lt;/th&gt;&lt;th&gt;Folder&lt;/th&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Read&lt;/td&gt;&lt;td&gt;can read&lt;/td&gt;&lt;td&gt;can listing&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Write&lt;/td&gt;&lt;td&gt;can write to file&lt;/td&gt;&lt;td id="write"&gt;can create, rename, delete files in direcory&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Execute&lt;/td&gt;&lt;td&gt;can be executed&lt;/td&gt;&lt;td&gt;can pass through or into&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;h4&gt;Special bit&lt;/h4&gt;&lt;dl&gt; &lt;dt&gt;setuid&lt;/dt&gt; &lt;dd&gt;Execute file with owner permission (example: program &lt;code&gt;su&lt;/code&gt;)&lt;/dd&gt; &lt;dd&gt;&lt;code&gt;-rw&lt;strong&gt;s&lt;/strong&gt;------&lt;/code&gt;&lt;/dd&gt;&lt;dd&gt;bit:4000&lt;/dd&gt; &lt;dt&gt;setgid&lt;/dt&gt; &lt;dd&gt;If file execute this with group permission.&lt;/dd&gt; &lt;dd&gt;If folder save every file into folder with folder group permission. All file in folder have been the same group.&lt;/dd&gt; &lt;dd&gt;&lt;code&gt;-rwxrw&lt;strong&gt;s&lt;/strong&gt;---&lt;/code&gt;&lt;/dd&gt;&lt;dd&gt;bit:2000&lt;/dd&gt; &lt;dt&gt;sticky&lt;/dt&gt; &lt;dd&gt;If file already is not supported&lt;/dd&gt; &lt;dd&gt;If folder has sticky bit can &lt;a href="#write"&gt;delete&lt;/a&gt; files into folder only owner of file or superuser. &lt;/dd&gt; &lt;dd&gt;&lt;code&gt;-rwxrwxrw&lt;strong&gt;t&lt;/strong&gt;&lt;/code&gt;&lt;/dd&gt;&lt;dd&gt;bit:1000&lt;/dd&gt;&lt;/dl&gt;&lt;h4&gt;File types&lt;/h4&gt;&lt;dl&gt; &lt;dt&gt;Regular file&lt;/dt&gt; &lt;dd&gt;-&lt;/dd&gt; &lt;dt&gt;Directory&lt;/dt&gt; &lt;dd&gt;d&lt;/dd&gt; &lt;dt&gt;Link&lt;/dt&gt; &lt;dd&gt;l&lt;/dd&gt; &lt;dt&gt;Special files&lt;/dt&gt; &lt;dd&gt;c&lt;/dd&gt; &lt;dt&gt;Socket&lt;/dt&gt; &lt;dd&gt;s&lt;/dd&gt; &lt;dt&gt;Named pipe&lt;/dt&gt; &lt;dd&gt;p&lt;/dd&gt; &lt;dt&gt;Block device&lt;/dt&gt; &lt;dd&gt;b&lt;/dd&gt;&lt;/dl&gt;&lt;h4&gt;Examples&lt;/h4&gt;&lt;ul&gt; &lt;li&gt;&lt;code&gt;chmod 644 myFile.txt&lt;/code&gt;&lt;/li&gt;&lt;li&gt;&lt;code&gt;chmod 4700 /bin/ls&lt;/code&gt; (setuid)&lt;/li&gt;&lt;li&gt;&lt;code&gt;chmod 2770 /bin/ls&lt;/code&gt; (setgid)&lt;/li&gt;&lt;li&gt;&lt;code&gt;chmod 1777 myFolder&lt;/code&gt; (sticky)&lt;/li&gt; &lt;li&gt;&lt;code&gt;chown tomas myFile.txt&lt;/code&gt;&lt;/li&gt; &lt;li&gt;&lt;code&gt;chgrp user myFile.txt&lt;/code&gt;&lt;/li&gt; &lt;li&gt;&lt;code&gt;chown tomas.user myFile.txt&lt;/code&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/199347374923183082-6159245875859955185?l=tomasjurman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tomasjurman.blogspot.com/feeds/6159245875859955185/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tomasjurman.blogspot.com/2010/05/file-permissions-notation-in-linux.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/6159245875859955185'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/6159245875859955185'/><link rel='alternate' type='text/html' href='http://tomasjurman.blogspot.com/2010/05/file-permissions-notation-in-linux.html' title='File permissions notation in Linux'/><author><name>Tom Jurman</name><uri>http://www.blogger.com/profile/00104562212599535461</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://3.bp.blogspot.com/_lsyyvFurh9s/SuQdL_1dwJI/AAAAAAAAAAc/anR56lMKBDc/S220/p1010102.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-199347374923183082.post-8621394203975959694</id><published>2010-04-14T06:26:00.000-07:00</published><updated>2010-04-15T12:18:16.543-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Linux'/><title type='text'>VPN client server configuration</title><content type='html'>&lt;p&gt;In our company we need to allow certain members access to our computer network from the outside. Therefore, we decided to get a &lt;a href="http://en.wikipedia.org/wiki/Virtual_private_network"&gt;VPN&lt;/a&gt;.&lt;/p&gt;&lt;p&gt;We choose &lt;a href="http://openvpn.net/"&gt;OpenVPN&lt;/a&gt;, because it is &lt;strong&gt;Open Source&lt;/strong&gt; and it is available for Linux, Windows and another OS.&lt;/p&gt;&lt;p&gt;You can let running &lt;strong&gt;VPN server on Linux&lt;/strong&gt; and let blunt Windows client to connect to server.&lt;/p&gt;&lt;p&gt;For &lt;strong&gt;server-client configuration&lt;/strong&gt; you need to generate keys and certificates, but configuration is very simple.&lt;/p&gt;&lt;hr /&gt;&lt;h3&gt;Server configuration&lt;/h3&gt;&lt;p&gt;&lt;code&gt;/etc/openvpn/server.conf&lt;/code&gt;&lt;p&gt;&lt;pre name="code" class="cpp"&gt;&lt;br /&gt;port 1194&lt;br /&gt;proto tcp&lt;br /&gt;dev tun&lt;br /&gt;keepalive 10 60&lt;br /&gt;comp-lzo&lt;br /&gt;&lt;br /&gt;server  10.10.1.0 255.255.255.0&lt;br /&gt;ifconfig-pool-persist /etc/openvpn/ipp.txt&lt;br /&gt;max-clients 3&lt;br /&gt;&lt;br /&gt;push "route 172.16.128.0 255.255.255.0"&lt;br /&gt;push "dhcp-option DNS 172.16.128.1"&lt;br /&gt;&lt;br /&gt;ca /etc/openvpn/keys/ca.crt&lt;br /&gt;cert /etc/openvpn/keys/akela.crt&lt;br /&gt;key /etc/openvpn/keys/akela.key&lt;br /&gt;dh /etc/openvpn/keys/dh1024.pem&lt;br /&gt;tls-auth /etc/openvpn/keys/static.key&lt;br /&gt;&lt;br /&gt;log-append /var/log/openvpn.log&lt;br /&gt;status /var/log/openvpn-status.log&lt;br /&gt;mute 10&lt;br /&gt;verb 5&lt;br /&gt;&lt;/pre&gt;&lt;p&gt;All important you find out in &lt;strong&gt;man pages&lt;/strong&gt; or on project &lt;a href="http://openvpn.net/index.php/open-source/documentation.html"&gt;documentation&lt;/a&gt;.&lt;/p&gt;&lt;p&gt;&lt;code&gt;push "dhcp-option DNS 172.16.128.1"&lt;/code&gt; get only Windows client. For Linux client you need script. See &lt;a href="http://openvpn.net/index.php/open-source/documentation/howto.html#dhcp"&gt;HOWTO&lt;/a&gt;&lt;/p&gt;&lt;h3&gt;Generate certificates&lt;/h3&gt;&lt;p&gt;You can use &lt;strong&gt;OpenSSL&lt;/strong&gt;, but developers of &lt;strong&gt;OpenVPN&lt;/strong&gt; prepare scripts for simply generate keys and certificates for server and clients.&lt;/p&gt;&lt;p&gt;You find out it: &lt;code&gt;/user/share/doc/openvpn/examples/easy-rsa/2.0/&lt;/code&gt;&lt;/p&gt;&lt;p&gt;Scripts config file is &lt;code&gt;vars&lt;/code&gt;. There you can set same variables.&lt;/p&gt;&lt;p&gt;1. We load the config file to system, and create &lt;strong&gt;self-signed Certificate Authority&lt;/strong&gt;&lt;/p&gt;&lt;pre name="code" class="cpp"&gt;&lt;br /&gt;. ./vars&lt;br /&gt;./clean-all&lt;br /&gt;./build-ca&lt;br /&gt;&lt;/pre&gt;&lt;p&gt;In folder &lt;code&gt;keys&lt;/code&gt; (depend on your &lt;strong&gt;vars&lt;/strong&gt; files) you find out file:&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;code&gt;ca.pem&lt;/code&gt; - public certificate&lt;/li&gt;&lt;li&gt;&lt;code&gt;ca.key&lt;/code&gt; - private key of Certificate Authority&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;2. we create key and certificate for server.&lt;/p&gt;&lt;pre name="code" class="cpp"&gt;&lt;br /&gt;./build-key-server akela&lt;br /&gt;&lt;/pre&gt;&lt;p&gt;It creates file:&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;code&gt;akela.pem&lt;/code&gt; - certificate of your server signed of your CA&lt;/li&gt;&lt;li&gt;&lt;code&gt;akela.ctr&lt;/code&gt; - request of sign (you don´t need that file)&lt;/li&gt;&lt;li&gt;&lt;code&gt;akela.key&lt;/code&gt; - private key of your server&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;3. we create Deffie-Hellmann parameters for &lt;strong&gt;dynamic key encryption&lt;/strong&gt;&lt;/p&gt;&lt;pre name="code" class="cpp"&gt;&lt;br /&gt;./build-df&lt;br /&gt;&lt;/pre&gt;&lt;p&gt;It creates file:&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;code&gt;dh1024.pem&lt;/code&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;4. we create &lt;strong&gt;static TLS-AUTH key&lt;/strong&gt;&lt;/p&gt;&lt;pre name="code" class="cpp"&gt;&lt;br /&gt;openvpn --genkey --secret static.key&lt;br /&gt;&lt;/pre&gt;&lt;p&gt;It creates file:&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;code&gt;static.key&lt;/code&gt;&lt;/li&gt;&lt;/ul&gt;&lt;hr /&gt;&lt;h3&gt;Client configuration&lt;/h3&gt;&lt;p&gt;We need to create certificate for your client.&lt;/p&gt;&lt;p&gt;&lt;strong&gt;In your server&lt;/strong&gt; use:&lt;/p&gt;&lt;pre name="code" class="cpp"&gt;&lt;br /&gt;./build-key kibo&lt;br /&gt;&lt;/pre&gt;&lt;ul&gt;&lt;li&gt;&lt;code&gt;kibo.pem&lt;/code&gt; - certificate of your client(notebook) signed of your CA&lt;/li&gt;&lt;li&gt;&lt;code&gt;kibo.ctr&lt;/code&gt; - request of sign (you don´t need that file)&lt;/li&gt;&lt;li&gt;&lt;code&gt;kibo.key&lt;/code&gt; - private key of your client(notebook)&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;In your client(notebook) save this file:&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;code&gt;kibo.pem&lt;/code&gt;&lt;/li&gt;&lt;li&gt;&lt;code&gt;kibo.key&lt;/code&gt;&lt;/li&gt;&lt;li&gt;&lt;code&gt;ca.pem&lt;/code&gt;&lt;/li&gt;&lt;li&gt;&lt;code&gt;static.key&lt;/code&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;Clinet configuration on &lt;code&gt;/etc/openvpn/client.conf&lt;/code&gt; in Linux client.&lt;p&gt;&lt;p&gt;Clinet configuration on &lt;code&gt;..\ProgramFiles\OpenVPN\Config\client.ovpn&lt;/code&gt; in Windows client.&lt;p&gt;&lt;pre name="code" class="cpp"&gt;&lt;br /&gt;client&lt;br /&gt;pull&lt;br /&gt;dev tun&lt;br /&gt;proto tcp&lt;br /&gt;remote ourServer.tld&lt;br /&gt;&lt;br /&gt;ca /etc/openvpn/keys/ca.crt&lt;br /&gt;cert /etc/openvpn/keys/kibo.crt&lt;br /&gt;key /etc/openvpn/keys/kibo.key&lt;br /&gt;tls-auth /etc/openvpn/keys/static.key&lt;br /&gt;&lt;br /&gt;comp-lzo&lt;br /&gt;verb 4&lt;br /&gt;mute 10&lt;br /&gt;ns-cert-type server&lt;br /&gt;&lt;/pre&gt;&lt;hr /&gt;&lt;p&gt;Start server and then try to connect from client.&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;code&gt;openvpn /etc/openvpn/server.conf&lt;/code&gt; - on Linux server (or as service)&lt;/li&gt;&lt;li&gt;&lt;code&gt;openvpn /etc/openvpn/client.conf&lt;/code&gt; - on Linux client(notebook)&lt;/li&gt;&lt;/ul&gt;&lt;hr /&gt;&lt;h3&gt;OpenVPN and IPTables&lt;/h3&gt;&lt;pre name="code" class="cpp"&gt;&lt;br /&gt;$IPTABLES -A INPUT -p tcp --dport 1194 -j ACCEPT       # VPN new&lt;br /&gt;$IPTABLES -A INPUT -i tun+             -j ACCEPT       # VPN tun&lt;br /&gt;$IPTABLES -A FORWARD -i tun+ -o $LAN_IFACE -j ACCEPT   # VPN forward &gt;&lt;br /&gt;$IPTABLES -A FORWARD -i $LAN_IFACE -o tun+ -j ACCEPT   # VPN forward &lt;&lt;br /&gt;&lt;/pre&gt;&lt;hr /&gt;&lt;p&gt;Good Luck.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/199347374923183082-8621394203975959694?l=tomasjurman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tomasjurman.blogspot.com/feeds/8621394203975959694/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tomasjurman.blogspot.com/2010/04/vpn-client-server-configuration.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/8621394203975959694'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/8621394203975959694'/><link rel='alternate' type='text/html' href='http://tomasjurman.blogspot.com/2010/04/vpn-client-server-configuration.html' title='VPN client server configuration'/><author><name>Tom Jurman</name><uri>http://www.blogger.com/profile/00104562212599535461</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://3.bp.blogspot.com/_lsyyvFurh9s/SuQdL_1dwJI/AAAAAAAAAAc/anR56lMKBDc/S220/p1010102.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-199347374923183082.post-1699679890528479735</id><published>2010-04-05T23:38:00.000-07:00</published><updated>2010-08-06T08:09:16.769-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Grails'/><title type='text'>www.harvart.cz with Grails</title><content type='html'>For us last web project &lt;a href="http://www.harvart.cz/"&gt;www.harvart.cz&lt;/a&gt; we used &lt;a href="http://grails.org/doc/latest/"&gt;Grails framework&lt;/a&gt;.&lt;br /&gt;Earlier we used &lt;a href="http://static.springsource.org/spring/docs/current/spring-framework-reference/html/"&gt;Spring MVC&lt;/a&gt; with &lt;a href="http://www.springsource.org/roo"&gt;Spring Roo&lt;/a&gt; for all us projects.&lt;br /&gt;We are really excited to work with Grails framework.&lt;br /&gt;Let mi introduce same of features in Grails:&lt;br /&gt;&lt;h3&gt;Rapid development&lt;/h3&gt;We don´t often restart Tomcat. After changes in controller classes, gsp pages or config classes is project automatically reloaded. When you add or change same bean in Spring context, it automatically reload too. It is very comfortable behaviour.&lt;br /&gt;&lt;h3&gt;URL mapping&lt;/h3&gt;For URL mapping Grails use simple mapping file:&lt;br /&gt;&lt;pre class="java" name="code"&gt;"/clanky"(controller:'article', action:'all')&lt;br /&gt;"/clanky/$url"(controller:'article', action:'show')&lt;br /&gt;"/klub"(controller:'klub', action:'about')&lt;br /&gt;"/fotogalerie"(controller:'gallery', action:'all')&lt;br /&gt;"/fotogalerie/$url"(controller:'gallery', action:'show')  &lt;br /&gt;&lt;/pre&gt;You only determine which controller and action is conjunction with url. When you use &lt;a href="http://grails.org/doc/latest/ref/Tags/link.html"&gt;Grails link tag&lt;/a&gt; then the url is automatically compile in all your HTML links. It is grait!&lt;br /&gt;&lt;h3&gt;GORM&lt;/h3&gt;Every domain class has automatically all GRUD methods. You don´t need to write boring DAO classes.&lt;br /&gt;&lt;h3&gt;Plugins&lt;/h3&gt;There are a lot of useful plugins. You only install same plugin and you can use it immediately. In &lt;a href="http://www.harvart.cz/"&gt;www.harvart.cz&lt;/a&gt; we used search plugin. We only marked domain class, which can be search. It is unbelievably simply!&lt;br /&gt;&lt;h3&gt;Conclusion&lt;/h3&gt;Grails is great! As developer you can concentrate to write your own code only. Groovy give you all you need as web developer. You can use all for Spring, Hibernate and SiteMesh.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/199347374923183082-1699679890528479735?l=tomasjurman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://tomasjurman.blogspot.com/feeds/1699679890528479735/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://tomasjurman.blogspot.com/2010/04/wwwharvartcz-with-grails.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/1699679890528479735'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/199347374923183082/posts/default/1699679890528479735'/><link rel='alternate' type='text/html' href='http://tomasjurman.blogspot.com/2010/04/wwwharvartcz-with-grails.html' title='www.harvart.cz with Grails'/><author><name>Tom Jurman</name><uri>http://www.blogger.com/profile/00104562212599535461</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://3.bp.blogspot.com/_lsyyvFurh9s/SuQdL_1dwJI/AAAAAAAAAAc/anR56lMKBDc/S220/p1010102.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-199347374923183082.post-3538004365393538971</id><published>2010-04-03T02:20:00.000-07:00</published><updated>2010-04-03T06:39:15.169-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Database'/><title type='text'>MYSQL - JOIN conjunction</title><content type='html'>&lt;p&gt;Where you have two and more tables, you can made conjunction between table.&lt;/p&gt;&lt;p&gt;You can use this kind of conjunction:&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;strong&gt;INNER JOIN&lt;/strong&gt;&lt;/li&gt;&lt;li&gt;&lt;strong&gt;LEFT OUTER JOIN&lt;/strong&gt;&lt;/li&gt;&lt;li&gt;&lt;strong&gt;RIGHT OUTER JOIN&lt;/strong&gt;&lt;/li&gt;&lt;li&gt;&lt;strong&gt;FULL JOIN&lt;/strong&gt;&lt;/li&gt;&lt;li&gt;&lt;strong&gt;CROSS JOIN&lt;/strong&gt;&lt;/li&gt;&lt;/ul&gt;&lt;hr /&gt;&lt;h3&gt;Source table&lt;/h3&gt;&lt;pre name="code" class="sql"&gt;&lt;br /&gt;mysql&gt; select* from EMPLOYEE;&lt;br /&gt;+----+--------+---------------+&lt;br /&gt;| ID | NAME   | ID_DEPARTMENT |&lt;br /&gt;+----+--------+---------------+&lt;br /&gt;|  1 | Tom    |             1 | &lt;br /&gt;|  2 | Petr   |             1 | &lt;br /&gt;|  3 | Jan    |             2 | &lt;br /&gt;|  4 | Michal |             2 | &lt;br /&gt;|  5 | Pepa   |             3 | &lt;br /&gt;|  6 | Zdenek |             0 | &lt;br /&gt;+----+--------+---------------+&lt;br /&gt;&lt;/pre&gt;&lt;pre name="code" class="sql"&gt;&lt;br /&gt;mysql&gt; select* from DEPARTMENT;&lt;br /&gt;+----+----------+&lt;br /&gt;| ID | TITLE    |&lt;br /&gt;+----+----------+&lt;br /&gt;|  1 | economy  | &lt;br /&gt;|  2 | it       | &lt;br /&gt;|  3 | research | &lt;br /&gt;|  4 | sales    | &lt;br /&gt;+----+----------+&lt;br /&gt;&lt;/pre&gt;&lt;hr /&gt;&lt;h3&gt;INNER JOIN&lt;/h3&gt;&lt;p&gt;Return only corresponding records. You use &lt;strong&gt;inner join&lt;/strong&gt; or &lt;strong&gt;join&lt;/strong&gt; or empty clause.&lt;/p&gt;&lt;p&gt;This selects are the same:&lt;/p&gt;&lt;pre name="code" class="sql"&gt;&lt;br /&gt;select * from EMPLOYEE inner join DEPARTMENT on EMPLOYEE.ID_DEPARTMENT = DEPARTMENT.ID&lt;br /&gt;&lt;/pre&gt;&lt;pre name="code" class="sql"&gt;&lt;br /&gt;select * from EMPLOYEE join DEPARTMENT on EMPLOYEE.ID_DEPARTMENT = DEPARTMENT.ID&lt;br /&gt;&lt;/pre&gt;&lt;pre name="code" class="sql"&gt;&lt;br /&gt;select * from EMPLOYEE, DEPARTMENT where EMPLOYEE.ID_DEPARTMENT = DEPARTMENT.ID&lt;br /&gt;&lt;/pre&gt;&lt;pre name="code" class="sql"&gt;&lt;br /&gt;+----+--------+---------------+----+----------+&lt;br /&gt;| ID | NAME   | ID_DEPARTMENT | ID | TITLE    |&lt;br /&gt;+----+--------+---------------+----+----------+&lt;br /&gt;|  1 | Tom    |             1 |  1 | economy  | &lt;br /&gt;|  2 | Petr   |             1 |  1 | economy  | &lt;br /&gt;|  3 | Jan    |             2 |  2 | it       | &lt;br /&gt;|  4 | Michal |             2 |  2 | it       | &lt;br /&gt;|  5 | Pepa   |             3 |  3 | research | &lt;br /&gt;+----+--------+---------------+----+----------+&lt;br /&gt;&lt;/pre&gt;&lt;hr /&gt;&lt;h3&gt;LEFT OUTER JOIN&lt;/h3&gt;&lt;p&gt;Return all records from left table. You can use &lt;strong&gt;left outer join&lt;/strong&gt; or  &lt;br /&gt;&lt;strong&gt;left join&lt;/strong&gt; clause only.&lt;/p&gt;&lt;pre name="code" class="sql"&gt;&lt;br /&gt;mysql&gt; SELECT *                         &lt;br /&gt;    -&gt; FROM EMPLOYEE&lt;br /&gt;    -&gt; LEFT OUTER JOIN DEPARTMENT ON EMPLOYEE.ID_DEPARTMENT = DEPARTMENT.ID;&lt;br /&gt;+----+--------+---------------+------+----------+&lt;br /&gt;| ID | NAME   | ID_DEPARTMENT | ID   | TITLE    |&lt;br /&gt;+----+--------+---------------+------+----------+&lt;br /&gt;|  1 | Tom    |             1 |    1 | economy  | &lt;br /&gt;|  2 | Petr   |             1 |    1 | economy  | &lt;br /&gt;|  3 | Jan    |             2 |    2 | it       | &lt;br /&gt;|  4 | Michal |     
