/HTML>
Programming assignment:
The purpose of this assignment is to introduce you to beginning
Java programming concepts and to get you to
learn how to edit, compile, and print Java source
code files,
how to run Java applications, how to run Java applets,
and to learn how to print the output
of your Java applications and applets.
Write a Java application, using the class style, similar to the
HelloWorldApp.java in the tutorial
that will print your name and three lines
telling what you did over the summer. For the hierarchy for your
application you can put
Object - YourApplicationClassName
Write a Java applet, using the class style, similar to the
HelloWorld.java applet in the tutorial
that will print your name and three lines
telling what you did over the summer
on one of
your web pages.
For the hierarchy for your applet you can put
Object - Component - Container - Panel - Applet - YerAppletClassName
Hand in:
Programming assignment:
The purpose of this program is to give you an opportunity to practice loops and branching statements.
Write both an application and an applet that prints out a random number of cool places to visit in your home town chosen randomly from a list of 8 or more. Items must be displayed in a random order. Be sure no item is displayed more than once.
Hand in:
Hardcopy of both the applet and the application.
Hardcopy of 3 runs of your application.
The evolution of the Point class.
Programming assignment:
The purpose of this program is to give you a chance to look at other people's
Java code, and see how they organize their classes and use the API,
and also to give you some ideas
about possible projects you might want to do for the class.
Hand in:
the annotated
hardcopy of your applet code with the URL of the original applet
and the URL of your modified applet.
Programming assignment:
The purpose of this program is to give you an opportunity to practice
using inheritance, polymorphism, abstraction, and encapsulation.
(1)Write a subclass of the
class designed in lecture and a subclass of your class.
Conceptually, you are designing a Boat and a deluxe version of your
Boat. Each subclass must have at least one new instance variable.
All Boats must fit in a bounding box 200 pixels high and 300 pixels
wide. (They don't have to fill the bounding box, they just can't
be bigger than that.) Your boat should sit on the bottom of the box -
that is where I will put the water. Waves will be no more than 10
pixels high. Your boats must be drawn going from left to right (->).
Both your boat classes must have a default constructor - a constructor
that takes no parameters.
(
Example of a subclass and a
deluxe subclass of that class - there are many right ways to do this)
Include at least 2 constructors for each of your new classes
(one should be a default constructor)
and access methods
for any new data, if appropriate.
(2) Write a Java application
that creates at least one instance of each class you wrote
and uses access methods to print out the values of the variables.
(NOTE - the sample application does not fulfill the program requirements,
it is just an application that prints out the values of some of the variables
for one Boat.)
(3) Write a Java applet that draws
at least one object from each of your classes.
(NOTE - the sample applet does not fulfill the program requirements,
it just shows how one is drawn and plays with the move methods.)
Think about what you want to do for your project for the rest of the course. (You can have 1 partner for the project, but not for this assignment.)
Hand in:
hardcopy of your new subclasses, your application, your applet
and output from your application.
Assignment:
The purpose of the first part of this assignment is to help you get a feel
for how applets run in
a browser and to help you understand the purpose for each of the
applet methods. Do the first part by yourself - no partner.
The purpose of the second part is to have you develop the
first draft of your project design. If you are going to have a partner,
you must do it together. (Hand in one copy with both names on it.)
The form handed out in class contains a list of different things you can do to an applet while it is running, e.g., move to a different page, scroll the page, etc. On the form mark which methods are called for each thing you do. You must make up the last 5 yourself. The ones you make up must be different from the ones I put on the form. Use the ExtendedSimple applet to find out which methods are called. (You can find the version of the browser in the Help menu.)
Decide on a project to work on for the rest of the class. It can be an applet or an application or both and it can do anything you want, but it must
Prepare a program header for your project and a rough drawing of the graphical user interface (GUI).
Hand in:
The form describing the
things you tried while running the ExtendedSimple applet and
which methods were called for each.
The program header describing your project and the GUI drawing.
Programming assignment: Students! Start your projects! All projects, applets and applications, will use Java 1.2 or higher and will use Swing components (no AWT Components). Remember to convert your html file if your project is an applet.
For this assignment, add at least one of the components you will need. The components must show up, but they don't have to do anything. They also don't have to be in the proper place.
Hand in:
Hardcopy of your project. (Applets must run on the web and applications
must be in your Public directory, so I can run them.)
Programming assignment: Continue working on your GUI. Use the proper layout managers and containers so your GUI is formatted the way you want it.
Hand in:
Hardcopy of your project. (Applets must run on the web and applications
must be in your Public directory, so I can run them.)
Programming assignment:
Add event handling to your project. Make "help" for your project one of
the events that works properly.
Hand in:
Hardcopy of your project. (Applets must run on the web and applications
must be in your Public directory, so I can run them.)
Programming assignment:
Add sound, images, colors, and fonts to your project.
Hand in:
Hardcopy of your project. (Applets must run on the web and applications
must be in your Public directory, so I can run them.)
Programming assignment:
Add animation to your project.
Hand in on Friday:
Programming assignment:
work on your project
Hand in on Friday:
Hand in before you leave:
Final hard copy of your code and critiques of at least 3 other project. (Applets must run on the web and applications
must be in your Public directory, so I can run them.)