1) Ok, the class i'm using for local database file access has no record locking. Is this ok? The record locking I have for RMI access has record locking which works, but I didn't see any sense in implementing it for direct access to the file.
2) My server doesn't have a clean way to shutdown, you have to hit ctrl-c, is this ok? Or should I try and implement a proper way to shut it down. If so, any ideas?
3) My GUI, although it works, is a little horrible looking. All columns in my JTable are the same width and all data etc. is aligned left in all the columns. I had the idea of trying to resize my column widths based on the widest element in each column, but this has so far proved fairly difficult to do in a nice way. So should I spend time on this, or would I still be likely to pass as it does allow you to see all data, select a flight, and books a flight. Any ideas on this whole area is greatly appreciated.
4) Exception handling for most of my client pops up some form of JOptionPane, displaying the name of the exception and the message from the exception. With a couple of buttons to continue or to exit. Is this the correct way to do things, or should I attempt to give slightly more useful messages to the user instead of the message from the exception thrown?
5) The criteriaFind method, although it works, IMHO it is a bit of a mess (I have quite alot of mess don't I ). At the moment it involves a number of StringTokenizer's, about three String arrays, an int array and an ArrayList. So, does anyone have any tips on how I might go about tidying this up, making the code better etc.?
SCJP 1.4, SCJD 1.4, SCBCD (Preparing!)
1) Ok, the class i'm using for local database file access has no record locking. Is this ok? The record locking I have for RMI access has record locking which works, but I didn't see any sense in implementing it for direct access to the file.
2) My server doesn't have a clean way to shutdown, you have to hit ctrl-c, is this ok? Or should I try and implement a proper way to shut it down. If so, any ideas?
3) My GUI, although it works, is a little horrible looking. All columns in my JTable are the same width and all data etc. is aligned left in all the columns. I had the idea of trying to resize my column widths based on the widest element in each column, but this has so far proved fairly difficult to do in a nice way. So should I spend time on this, or would I still be likely to pass as it does allow you to see all data, select a flight, and books a flight. Any ideas on this whole area is greatly appreciated.
4) Exception handling for most of my client pops up some form of JOptionPane, displaying the name of the exception and the message from the exception. With a couple of buttons to continue or to exit. Is this the correct way to do things, or should I attempt to give slightly more useful messages to the user instead of the message from the exception thrown?
5) The criteriaFind method, although it works, IMHO it is a bit of a mess (I have quite alot of mess don't I ). At the moment it involves a number of StringTokenizer's, about three String arrays, an int array and an ArrayList. So, does anyone have any tips on how I might go about tidying this up, making the code better etc.?
The Sun Certified Java Developer Exam with J2SE 5: paper version from Amazon, PDF from Apress, Online reference: Books 24x7 Personal blog
My criteriaFind method is quite long and uses sections of code that would mainly be useless in other methods as they'd never be reused by anything else in this class so it would seem pretty pointless to move sections of code out into other methods. I might do as Andrew suggested and start another post relating to this if i'm finding it quite hard to rewrte myself and make it sensible
I am thinking of shutting down the server properly, but haven't got a good idea yet.2. Ctrl-C is OK for closing the server. Some of us created Server GUIs, but that is not a requirement for closing the server. However, you still need to have code to lock all the records if "-1" is passed to the lock method.
Peter
The Sun Certified Java Developer Exam with J2SE 5: paper version from Amazon, PDF from Apress, Online reference: Books 24x7 Personal blog
This parrot is no more. It has ceased to be. Now it's a tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
|