wood burning stoves*
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes [URLyBird 1.3.1] Just download, some questions! Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Bookmark "[URLyBird 1.3.1] Just download, some questions!" Watch "[URLyBird 1.3.1] Just download, some questions!" New topic
Author

[URLyBird 1.3.1] Just download, some questions!

Leo Ho
Ranch Hand

Joined: Mar 31, 2005
Posts: 36
Hello ranchers, I downloaded URLyBird 1.3.1 yesterday and after ruminating over it, I have the following questions:

1. Although the DBMain.java interface (sent by Sun) have a lot of methods such as 'delete', 'create' etc. but the UI requirements do not mention that I need to have any kind of adding or deleting functionality. So the question is: should I provide the implementation for those methods, leave the implementation empty, OR should I implement the functionalities in the UI?

2. The interface sent by Sun does not comply with some coding conventions (Javadoc, interface's methods declared public etc.) Should I leave it alone or make necessary change to it (i.e. which will not deduce my mark)?

Please help me with these questions!

Leo
Ed Tse
Ranch Hand

Joined: Sep 18, 2003
Posts: 183
1. You have to implement all the methods but you may not be using a few of them in your implementation. ie. create, delete,

2. You should not change the interface.


SCJP, Pre-SCJD (URLyBird 1.3.1), Teradata Cert'd Prof
Leo Ho
Ranch Hand

Joined: Mar 31, 2005
Posts: 36
Thanks so much for the info, Ed.

Folks, the GUI requirements from SUN for the URLyBird is very brief and I'm not sure if I fully understand them. Can s/o tell me if it is OK to interpret some of them as follows:

1. Whenever the user clicks button Book, then the record will be associated with a customer if it is not associated with anyone yet. If the record has already been associated with s/o else, then the client app will receive an exception like "RoomAlreadyBookedException" (note that the DBMain interface sent from Sun does not declare any such exception, thus I think I will need to implement this logic in the business layer). Is this the way most people do to handle the situation?

2. I will need to have some fields in the GUI, e.g. Cust ID, that indicate whether the room is already booked or not.

3. After the Book button is clicked and the room is associated with a customer, should I automatically refresh the screen with the new customer ID by just updating the model keep in the client-tier instead of loading all the records from the DB again?

4. Should I be worried about the fact that the booking status displayed in the screen will get stale/out-of-date sometimes (since another client, say Mr. Broker B, can update the status a specific room)? Even if I don't need to care about that, what behavior the GUI must have to maintain usability in that case, i.e. the user clicks to book a room which is not shown to be already booked (but in fact it *was* book by another user) and realize that he/she cannot do that? Should I have a message box saying s/t like "The room is already booked, you may need to refresh the screen - by clicking display all or search - in order to notice that"?

I appreciate your ideas/suggestions.

Leo
Leo Ho
Ranch Hand

Joined: Mar 31, 2005
Posts: 36
Come on, guys! You can help by telling me how you interpret the GUI requirements for the UGLyBird... Thanks!
Roy Mallard
Ranch Hand

Joined: Jul 14, 2005
Posts: 53
1. Whenever the user clicks button Book, then the record will be associated with a customer if it is not associated with anyone yet. If the record has already been associated with s/o else, then the client app will receive an exception like "RoomAlreadyBookedException" (note that the DBMain interface sent from Sun does not declare any such exception, thus I think I will need to implement this logic in the business layer). Is this the way most people do to handle the situation?


Yes, that sounds similar to the way I plan on handling it. I think you need to use runtime exceptions because adding a checked exception would change the method signature of the methods you have to implement, which is not allowed.


2. I will need to have some fields in the GUI, e.g. Cust ID, that indicate whether the room is already booked or not.


Depends if you are displaying all records, or only the available records.
BTW Have you thought about letting a user undo their own bookings?


3. After the Book button is clicked and the room is associated with a customer, should I automatically refresh the screen with the new customer ID by just updating the model keep in the client-tier instead of loading all the records from the DB again?


That sounds like a good idea to me.

4. Should I be worried about the fact that the booking status displayed in the screen will get stale/out-of-date sometimes (since another client, say Mr. Broker B, can update the status a specific room)? Even if I don't need to care about that, what behavior the GUI must have to maintain usability in that case, i.e. the user clicks to book a room which is not shown to be already booked (but in fact it *was* book by another user) and realize that he/she cannot do that? Should I have a message box saying s/t like "The room is already booked, you may need to refresh the screen - by clicking display all or search - in order to notice that"?


Yes. I don't think it's necessary to have the server broadcast changes to all the clients as they happen.


SCJP 1.4<br />SCJD
Leo Ho
Ranch Hand

Joined: Mar 31, 2005
Posts: 36
Thanks, Roy. I'm glad that you think the same for most of the issues.

>>BTW Have you thought about letting a user undo their own bookings?
No, I won't do anything that falls outside the scope of the assignment AND does not make me learn s/t new (unbooking is just like booking)

Leo
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: [URLyBird 1.3.1] Just download, some questions!
 
Similar Threads
URLyBird requirements confusion
URLybird
URLybird 1.1.2
About URLyBird 1.2.3 Assignment Question
NX: URLyBird - Data Access