Module 1: Getting the demos to work


Back to Module 1


 
Note: we will assume you know how to run Java programs at the commandline, as explained here. If not, please work with a neighbor instead of trying to learn commandline execution in class.

Start by downloading and unpacking demos.zip.

There are two ways to proceed:

  1. If you've already put lintool.jar in your CLASSPATH and gotten that to work, you do not need to execute lintool.jar as a jar file.
  2. If you are new to CLASSPATHs, the demos are designed to run independently but by running lintool.jar as an executable jar. We'll see below what this means.
For now, we'll assume the latter approach.

After unpacking demos.zip:

This is how to execute a Java program that needs a jar library without messing with the CLASSPATH. If, on the other hand, you already have lintool.jar in your CLASSPATH, you can run the test-demo by typing java DemoTest.

You can execute any other demo by replacing DemoTest with the desired demo. For example, to run the Bezier demo:

As mentioned, if you already have lintool.jar in your CLASSPATH, you can just type java BezierDemo.


© 2015, Rahul Simha