Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Here's the schema I came up with:</p> <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt; &lt;schema id="inheritance" targetNamespace="http://test.com" elementFormDefault="qualified" xmlns="http://www.w3.org/2001/XMLSchema" xmlns:test="http://test.com" &gt; &lt;element name="Time"&gt; &lt;complexType&gt; &lt;sequence&gt; &lt;element name="First" type="test:A" /&gt; &lt;element name="Second" type="test:B" /&gt; &lt;/sequence&gt; &lt;/complexType&gt; &lt;/element&gt; &lt;complexType name="shortOptions"&gt; &lt;sequence&gt; &lt;element name="Day" /&gt; &lt;/sequence&gt; &lt;/complexType&gt; &lt;complexType name="longOptions"&gt; &lt;complexContent&gt; &lt;extension base="test:shortOptions"&gt; &lt;sequence&gt; &lt;element name="Week" /&gt; &lt;/sequence&gt; &lt;/extension&gt; &lt;/complexContent&gt; &lt;/complexType&gt; &lt;complexType name="A"&gt; &lt;sequence&gt; &lt;element name="options" type="test:shortOptions" /&gt; &lt;/sequence&gt; &lt;/complexType&gt; &lt;complexType name="B"&gt; &lt;sequence&gt; &lt;element name="options" type="test:longOptions" /&gt; &lt;/sequence&gt; &lt;/complexType&gt; &lt;/schema&gt; </code></pre> <p>Which seems to fit this xml:</p> <pre><code>&lt;?xml version="1.0" encoding="utf-8" ?&gt; &lt;Time xmlns="http://test.com"&gt; &lt;First&gt; &lt;options&gt; &lt;Day&gt;Today&lt;/Day&gt; &lt;/options&gt; &lt;/First&gt; &lt;Second&gt; &lt;options&gt; &lt;Day&gt;Tomorrow&lt;/Day&gt; &lt;Week&gt;This Week&lt;/Week&gt; &lt;/options&gt; &lt;/Second&gt; &lt;/Time&gt; </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload