Question

In: Computer Science

Consider the XML DTD definition below. Write a well-formed and valid XML Document that conforms to...

Consider the XML DTD definition below. Write a well-formed and valid XML Document that conforms to this definition.

<!ELEMENT wine-catalog (wine+)>

<!ELEMENT wine (properties,origin,price,year,tasting-note?)>

<!ATTLIST wine

   code   ID #REQUIRED

name   #PCDATA #REQUIRED

   classification #PCDATA #REQUIRED

format (375ml|750ml) “750ml”>

<!ELEMENT properties (color,alcohol-content)>

<!ELEMENT color (#PCDATA)>

<!ELEMENT alcohol-content (#PCDATA)>

<!ELEMENT origin (country, region, producer)>

<!ELEMENT country (#PCDATA)>

<!ELEMENT region (#PCDATA)>

<!ELEMENT producer (#PCDATA)>

<!ELEMENT price (#PCDATA)>

<!ELEMENT year (#PCDATA)>

<!ELEMENT tasting-note (#PCDATA)>

Solutions

Expert Solution

THE VALID XML DOCUMENT THAT CONFORMS TO THE GIVEN DEFINATION .

NOTE THAT I HAVE PUT ALL THE VALUES SUCH AS name of the wine etc AS AN EXAMPLE. YOU CAN CHANGE THE VALUES , BUT THE SCHEMA REMAINS SAME .

<!DOCTYPE wine_catalog SYSTEM "wine.dtd">
  <wine-catalog>
    <wine code="124579" , name = "Red wine" , classification ="smooth-wine" , format ="750ml">
      <properties>
         <color>red</color>
         <alchol-content> 35% </alchol-content>
      </properties>
      <origin>
         <country>swiss</country>
         <region>alps mountains</region>
         <producer> swiss wines</producer>
       </origin>
      <price> 1000$ </price>
      <year> 1879 </year>
      <tasting-note>Incredibly smooth </tasting-note>
    <wine>
   <wine-catalog>
      

Related Solutions

What is the well formatted XML document
What is the well formatted XML document
Write a DTD for this XML document such that the corrected version of the example is...
Write a DTD for this XML document such that the corrected version of the example is a valid XML document <?xml version="1.0"?> <computers> <item type = "Laptop" code = "Dell437">    <make>    <brand>Dell Inspiration</Brand>    <supplier id = "Dell"/>    </make>    <spec>    <cpu speed = "900"/>    <harddisk size = "12" units = "GB"/>    </Spec>    <price n = "950" units = "USD"/> </item> <item type = "Desktop" code = "Apple1679">    <make>    <brand>Apple iMac</brand>...
Create a XSD Schema to validate and provide structure for the XML document below: <?xml version="1.0"...
Create a XSD Schema to validate and provide structure for the XML document below: <?xml version="1.0" encoding="UTF-8" ?> <forecast qTime="28/10/20 10:00 PM" qLocation="Singapore"> <weather yyyymmdd="20200430"> <year>2020</year>   <month>04</month> <date>30</date> <comment>Plenty of sunshine</comment> <code>sunny</code> <highest>32.6</highest> <lowest>28.4</lowest> </weather> <weather yyyymmdd="20200218"> <year>2020</year>   <month>02</month> <date>18</date> <comment>Plenty of sunshine</comment> <code>sunny</code> <highest>34.6</highest> <lowest>30.5</lowest> </weather> <weather yyyymmdd="20200710"> <year>2020</year>   <month>07</month> <date>10</date> <comment>Partly sunny</comment> <code>partlySunny</code> <highest>33.1</highest> <lowest>29.2</lowest> </weather> <weather yyyymmdd="20200616"> <year>2020</year>   <month>06</month> <date>16</date> <comment>Considerable clouds</comment> <code>cloudy</code> <highest>30.5</highest> <lowest>25.4</lowest> </weather> <weather yyyymmdd="20200612"> <year>2020</year>   <month>06</month> <date>12</date> <comment>Cloudy with a thunderstorm</comment> <code>thunderstorm</code> <highest>29.1</highest>...
In one well formed post to a discussion write a maximum of 350 words and express...
In one well formed post to a discussion write a maximum of 350 words and express the following. As an undergraduate student do you feel that the study of Macroeconomics theory is important and if so why?Explain one topic in macroeconomics (any topic)
Write your plan for the investigation as described below and save it as a Word document.
  Fire Suppression Investigation Plan Write your plan for the investigation as described below and save it as a Word document. Detailed one page summary of your plans, including sketches if necessary. (Note: If you cannot submit your sketches, describe them in words.) Itemized list of materials, with total costs. Stoichiometric calculations of the amount of reactants required to produce enough gas to extinguish the fires. Remember that some gas may be lost prior to its use as a fire...
Research the topic below. Write one full page document (12 pt font) on your findings ....
Research the topic below. Write one full page document (12 pt font) on your findings . Your findings should be one page and completed in Microsoft Word. List positive and negative impacts that businesses making goods and services available for purchase on the Web have on consumers, as well as the businesses themselves. Do businesses that have a physical store and an online presence offer the same goods and services? Are they offered for the same price? Do they have...
Consider two electrons, both in the ground state of an in?nite potential well. Write the wave...
Consider two electrons, both in the ground state of an in?nite potential well. Write the wave function ?(x1,x2) for this system. Assume the electrons are non-interacting
-After observing all energy demonstrations listed below, write a preliminary working definition of energy. The energy...
-After observing all energy demonstrations listed below, write a preliminary working definition of energy. The energy demonstrations are: 1. beaker of water brought to boil over a hot plate or stove. 2. viscous heat pack (you have all seen them work, you do not have to buy one unless you do not know how they work. 3. popcorn to be popped and eaten (great with your loved one and a movie). 4. battery operated or windup toy car set into...
Please write a well written paragraph in your own words on the question below based off...
Please write a well written paragraph in your own words on the question below based off Southwest Airlines. Thank you QUESTION: Referencing Southwest Airlines summarize how you would make decisions about booking a flight from both a Functional & Psychological perspective per each of the steps reviewed in the decision making process?
We went over the format and syntax of CSS. Below, write the correct CSS syntax to make the body of an HTML document the color blue.
We went over the format and syntax of CSS. Below, write the correct CSS syntax to make the body of an HTML document the color blue. Also write what each keyword represents (example: the selector? property? etc.)
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT