Java Reference Book
- I find this an excellent introductory reference for Java, plus
it's free! If you like it, you can purchase a paper copy (I did).
It's also very convenient to carry around with you on your laptop.
Download from
http://www.bruceeckel.com/javabook.html
The MySQL Server
- This is a freeware SQL server that works very well. I will set up
a server on a faculty machine running MySQL for your use, but I would
also encourage you to try installing and running the server for
yourself. There are pointers from this site to supported JDBC drivers
for MySQL.
More information at
http://www.mysql.com
Javadoc
- Javadoc is distributed with JDK1.1 and above. A good reference
for commenting your code so that javadoc can automatically produce
high-quality HTML documentation can be found at
http://www.javasoft.com/products/jdk/javadoc/index.html
API Javadoc Example
- Here is the
actual javadoc output
from one of the objects in the version of this database that I
implemented (with Alex Kononov) last year. Note the
copious use of comments throughout! This example is
just one of a number of classes that were implemented for the project,
but should give you some idea of what I am looking for.
MySQL Manual
- Here is the user's guide for
MySQL. I have now set up a MySQL server on bell.rutgers.edu. To
use it you will need to get a mysql client binary (see below), and a
logon and password (which will be handed out in class). In the
meanwhile, take a look at the manual!
Here are binaries for the mysql client. The client allows full
interactive use of the MySQL db. Sorry, no Windows version!
To run the client, download it to your machine, rename it to
"mysql", and chmod u+x mysql to make it executable.
Then enter the command:
- mysql -hbell.rutgers.edu -uclassN -pYourPass classN
where classN is your user ID and YourPass is your
password. Note the lack of spaces between the argument keyword and
value!
JDBC Example
-
I have written a small example Java program that uses the MySQL
database. The program has been tested with JDK 1.1, and should
probably also work with 1.2. You can download testjdbc.java and compile it using javac.
In order to run it (or any program that uses JDBC) you will need a
JDBC driver for MySQL. Here is
mysql.jar. You must make sure that this file
is in your CLASSPATH! This has been compiled with JDK 1.1.6, and has
been tested on paul. I don't know if it will work correctly with JDK
1.2, but it probably will.
To run the program, look at the comments at the top of the source
file. I have tested this program on paul, and it works. I will be
happy to assist you if you have trouble, but please make sure you have
set up your environment correctly first!
Java Blend
-
Sun is offering a product that, in effect, automates the mapping
between Java objects and SQL. No, you can't use it for your projects,
but you might be interested in what Sun has to say about it.
http://www.sun.com/software/javablend/whitepaper/index.html
SQL3
-
You didn't ask for it - but here it is anyway! The entire
more-or-less current proposed standard for SQL3 in four
huge documents!
Be amazed! Be overwhelmed! Be very, very afraid!
- SQL3 Database Language
- SQL3 Host Language Bindings
- SQL3 Call-Level Interface
- SQL3 Persistent Stored Modules
RMI Example
-
I wrote this last year to help out some friends who were new to RMI.
You may find it instructive. You will need the following files:
Here is some documentation
about how this all fits together.