JavaProjectPart 2.docx - GetACoder

weaverchurchΛογισμικό & κατασκευή λογ/κού

15 Αυγ 2012 (πριν από 8 χρόνια και 11 μήνες)

361 εμφανίσεις

Part 2

You now should have the following items completed:


A Use case diagram(s) for the above requirements


UML Class Diagram for a model to capture the above information. This diagram
should have the attributes and method of the main elements of the


An implementation in java of the class diagram.


An ERD diagram of the access database that you intend to use


A html prototype of the web site


DAO objects to insert, remove and update to your database.


Tests for each of the DAO’s.

You no
w have to implement a fully functional web application. But before this
happens, you realise that you need to improve the robustness and scalability of the
existing project.

To do this you will need to:

Create your own class for handling database connect
ions, the
DBConnectionFactory class. This class will pool database connections, get its
connection settings from a properties file and will have a method

to return a database connection object. This class must operate
as a singleton, so a

method must be included. Synchronisation
issues must be taken care of.

The application needs to log all database accesses and allow support people to
manage the application. Use a java logging framework to send all relevant
output to a log file.

There has been a couple of changes in requirements from phase 1, so here is what the
requirements are for phase 2:

When users log in, there name must appear at the top of each page they visit.

If they try to access a page when they are not logged in,
they will be forced
back to the login page.

Add a search box where users can search across the entire site

Add a global error page

Add an AJAX (asynchronous java and xml) element to make your application
more eye catching

Add javascript validation to make
the application more robust.

Error messages/general messages should be centralised in a single message

What to do:

Make the technical changes required above

Rename your .html files to .jsp files.

Create a web project in NetBeans and copy in your

.jsp and your .java files

As you require it, make changes to your DAO’s to support the functionality

Try to reduce the amount of java code that is in the JSP’s. If more than one
database access is required inside a transaction, create a Manager

class which
carries out the DAO accesses.

Use javascript where necessary.


You should hand up a cd which contains the following:


All java code, JSP pages, cascading style sheets etc.


Instructions on how to run application in readme.txt,
with the names/student
numbers of group with responsibilities.


Word document, called testplan.doc which describes the expected/actual test
results (should match the use cases)


ERD diagram


db.doc file, which lists the tables, columns, datatypes and explains

function of each column

What do you get marks for:

Good design

Neat, efficient readable code/jsp’s

Well presented and accurate documentation

Robust web site (bug free)

The following mark breakdown applies:


Marks (/100)

Completed JSP
ation(with login)


Database connection changes




Name on each page


Search Functionality


AJAX Function


Java script validation


Centralised Message file


Error page