UMBC CMSC 491/691s Spring 2009
Special Topics: The Semantic Web

Assignment Two

Due Wednesday 11 February

You are asked to develop an XML representation for the UMBC course offerings. See the UMBC Spring 2009 schedule for Computer Science for the data that is associated with courses. Specifically
  • design an appropriate XML representation and express it using an XML Schema (not a DTD)
  • use your XML representation to encode the data for CMSC 331, 601 and 691s from the current course schedule shown on the UMBC site.
  • Develop a simple XSLT transformation to render this is HTML.

(1) Designing your representation

Your first job is to produce the XML Schema for your representation, giving it the name schedule.xls.

Even this simple problem can result in a complex representation. You don't need to do this. You can make the following simplifying assumptions:

  • Courses meet in the same room and at the same time on each day that it meets.
  • Courses have only one instructor

You can find the standard XML data types in the W3C's XML Schema Part 2: Datatypes document. Feel free to use the xs:string data type freely. Of course, if you want, you can use other data types (e.g., xs:gYear, xs:time, xs:nonNegativeInteger) but my advice is to keep it simple. be sure to add appropriate comments to help a person reading your schema understand it and how it is to be used.

Here's a sketch of the elements you might use. You can choose your own set of elements and your own names.


A schedule has
   a year (e.g., 2007) 
   a semester (e.g., Spring)
   one or more courses.


a course has 

 a program identifier (e.g., CMSC) 
 a number (e.g., 202, 691s)
 a title (e.g., Computer Science II for Majors)
 a credits (e.g., 4) (comment: )
 a grading method (e.g., REG/P-F/AUD)
 an optional registration constraint (e.g., PermReq)
 one or more sections.


A section has
 an instructor (e.g., R. Chang)
 a scheduleNumber (e.g., 1532)
 a sectionNumber (e.g., 0101)
 a room (e.g., LH8)
 a days (e.g., TuThr)
 a startTime (e.g., 10:00am)
 an endTime (e.g., 11:15am)
 

(2) An example data file

The second step is to use your schema file to create an example XML data file for a part of the Spring 2007 Schedule. In particular, encode data for CMSC 331, 601 and 691m from the current course schedule shown on the UMBC site. Name this file spring2009.xml.

(3) An XSLT transformation file

The third step is to use XSLT to create a transform that will convert your xml file into HTML.

(4) What to hand in

When you are done, zip or tar the three files and email them to finin@cs.umbc.edu using the subject Assignment two.

Tools you can use

You can develop your files using simple tools like emacs or eclipse. You can also try downloading a free evaluation copy of XMLSpy, a popular XML editing environment for Windows. If you do, check out the XMLSpy Tutorial to help you get going. You might also look at this list of XML editors from O'Reilly.