CS4025 Assignment 5

 

Due: Apr. 9, 2008

 

Write source codes for the following XML document designs.

 

Design an XML document to store information about patients in a hospital. Information about patients must include name (in three parts: first name, middle initial, last name, ), home address (in three parts: street, city, province), Social Insurance Number (SIN), age, room number, Medicare card information – including province name, member identification number, and expiration date (month and year), private medical insurance number – including insurance company name, address (in three parts), and phone number as well as member identification number and policy number. The patient’s first and last names, SIN, and room number is required, others are optional. The Medicare card information and all its elements are required. The private insurance information is optional, but if it does exist all its elements are required.

 

  1. Write a DTD for the above XML document with file name  “patients.dtd”
  2. Write an XML schema for the above XML document with file name “patients.xsd”
  3. Make up data for at least 5 patients, and create an XML document with file name “patients.xml”, according to the DTD or XML schema created above.
  4. Create an XSLT style sheet with file name “patients.xsl” to format all the patient elements in the above XML document and display the whole document.

 

Make sure that you validate the 4 documents using some tools before submitting your documents.

 

Zip all the 4 files in a single zip file with name “cs4025a5.zip” and submit the zip file online though CS4025 website.