Assignment 3 - due on 02/10 [xhtml]

The jaxp source is available as a netbeans project but you won't need it for this assignment. I've already started a web application in netbeans that you should complete. Download that netbeans project for this assingment.

In the 'web' or 'Web Pages' directory there are a set of XML files that contain three plays by Shakespeare. There are two versions of each play. The version in the 'Web Pages' directory is the full play. The version in the 'compact' directory is the play broken down by act. You'll notice many more files in the 'compact' subdirectory.

There is a file called 'index.xml' which has 'play' elements that point to each starting file for each play in the 'compact' directory. There is also a file called 'playlist.xml' which has 'play' elements that point to each full play in the main directory. The main difference is that the plays in the 'compact' directory have the acts in separate files.

In general, your task is to create an XSLT stylesheet that can style all this content into XHTML. You should expect to have one XHTML docment for each XML document. You should be able to read the acts. There is plenty of structure and you should decide how much you want to present to the user.

For this assignment, you must specifically do the following:

  1. Build an XSLT stylesheet for this content to format to XHTML.

  2. Add a set of Ant tasks to the ant file 'offline-build.xml' to build you content offline. The output suffix should be '.xhtml'.

  3. Setup the content to work with the web application via the servlet filter as discussed in the class lecture.

The project already contains the XSLT Filter code compiled and in the appropriate place in the web application's directory structure.

What to turn in:

Please turn in a deployable war file so I can test your application. Netbeans will build this for you:

  1. Right click on the project 'assignment-3' and select 'Build Project' from the context menu.

  2. In the directory dist/deploy there should be a file called 'assignment-3.war'. Please turn that file in for this assignment.

If you are not using netbeans, you can build a war file by just using the jar command to build a jar file with the extension 'war'. You'll have to be in the root directory of the web content and so that the 'WEB-INF' is a subdirectory. Then just type:

jar cvf ../assignment-3.war *