Hi all, Having been give an automatic failure originally due to a JDK version mix up ( I submitted it for the Java 6 platform about four days after it was released in December, see my Automatic Failure thread)
I received the good news today that I passed the SCJD exam with a score of 354 / 400. I am a little disappointed with the score but having waited so long I am just glad to have passed . I lost nine marks for the GUI and also I got the mysterious 44/80 score for locking seem to be a very common. The score breakdown is as follows.
The maximum possible score is 400; the minimum to pass is 320. General Considerations (maximum = 100): 99 Documentation (maximum = 70): 70 O-O Design (maximum = 30): 30 GUI (maximum = 40): 31 Locking (maximum = 80): 44 Data store (maximum = 40): 40 Network server (maximum = 40): 40
Thanks to all ranchers I got alot of great ideas and advice from everybody here. the main book I used was Max's Java Developer exam with J2SE 1.4 even though it is Java 5 / 6 that must be used now the main ideas in the book are still excellent and relevant .
The main points of my design were as follows:
Three tiered approach with a data layer, business layer and a client GUI.
Data Implementation: -LockManager class for handling locking -Client lock identification based on thread ID (no cookies in assignment API) -RecordSchema class to load and store record schema info from file header. -DataHelper class to perform actual low level IO operations such as read and write to a file. -ReadWrite Lock to ensure no dirty reads. -Local RandomAccessFile objects instead of one single RAF -Custom unchecked DataIOException for wrapping IOExceptions in Data methods. -Throw IllegalArgumentException for invalid records, record numbers etc. -Only data validation was that record field are correct length as per schema and contained ASCII data. (No date validation etc - keeps Data class generic) -No discernable primary key therefore no DuplicateKey exceptions thrown by create method.
Business Layer -Fa�ade class for booking and searching methods. -Perform application specific data validation here (48hr rule, valid ownerID etc). -Client friendly custom Exceptions (BookingExceptions, SearchException) -Value object to provide Object oriented wrapper for database records.
Network Layer -RMI used for network protocol. -UnicastRemoteObject instance as Remote server basically an RMI wrapper class for a local Fa�ade object. Same methods, interface etc. -Connection Manager factory class for creating local or remote DB connections
Server -Very simple server GUI with a shutdown button and a text area.
GUI -MVC pattern -All booked and available rooms on or after today�s date displayed on startup. -Simple GUI with text fields for book and search. -Keyboard Mnemonics for all buttons and menus. -Custom TableModel implementation -Custom properties JDialog that shows the properties relevant to the mode the applications. -The default search option is a case insensitive, starts with search. In the search menu items using the search properties dialog this can be configured to be a case sensitive and / or an exact match search. -Panel for searching on top of GUI. -Large Centered JTable to display the rooms. -Book Button in bottom right corner. Button is disabled when no room is selected. -JDialog used to input the customer ID for booking a room. -If the booking action is successful the table is automatically updated -Menubar with options to quit, connect, disconnect, edit search options and edit connection settings. -The properties for the current mode may be edited by selecting the appropriate item from the file menu.