Originally posted by Eric Kim:
My assignment is URLyBird v1.1.1, the requirement is not very clear on couple of issues:
The requirements are intentinally made ambigous so that they test on our decision making things on issues.
1) It does not mention reservation functionality except in the overview section. Can I make the following assumptions:
I think in the USER INTERFACE section also, they should have mentioned on how to do search and book. Maybe you can check that section once.
. Be able to list all hotels and rooms regardless of available or not
Yeah, its ok to show the booked rooms also. Then again, it depends on your design, if you don't want to allow the client to know about already booked rooms, you can only show those rooms which are vacant. If you want to allow re-booking of a room, then you must show all records.
. Be able to search hotels (using any combination of all 7 columns, perhaps something like: name=palace, location=small, smoke=y etc parameter format)
It is not required. If you check your USER INTERFACE section in the instructions .html file, there it should have mentioned on how you should allow CSR to search. In general only name/location search should be enough for project scope.
. Be able to reserve a room when required size is less than or equal to avaialble room in one of the found hotel.
Its an overkill. Here is how it works in general. You show all the records in the db in a table. CSR selects a row in a table and enter the owner to book. That is the basis or room booking. In real, your thinking is exact on to allow the CSR to search on all the 7 fields. But for the scope of project, I think that is not required.
2) It mentioned user configuration should be done via GUI. I assume this is through client GUI with a preference or setting or configuation menu and store these config info to a suncertify.properties file. This will work for a alone mode when client and server are on the same machine. What if the network server and database are on different machine than client (For instance, network server and database are on a solaris box and client is on Windows XP)? How to save those config information to server side? I think both server and client need config information to work properly.
Here is a link that should help you to understand this concept clearly.
3) The download just give me an interface definition about database implementation, when I implement this database, can I add more public methods, or should I be constrainted within these small set of interfaces?
You can add any number of methods to the class which implements this interface. But it is not advisable to add methods to the interface itself.
4) What to do with magic cookie in the db file? It is a hex value like 00 00 01 01, even if I verify this value with a db file, it does not necessary meaning a db file is a valid file, does it deserve any attention at all?
It seemed that you are opening it using hex editor as you said in other post. But we have to read the db file using one of the java.io.* package classes or java.nio.* package classes. For example, you can use RandomAccessFile of java.io.* package to read and write data to the file. We are supposed to read and write using the API classes and not using any editor.
5) About Delete flag, should GUI provide any function to delete a record at all? I did not find any requirement on this, but the db file contains this bit. What should I do with it?
You must implement a way to delete the record i.e. by making the flag 1. This is only required in the class that implements given interface. There is no requirement as to provide this functionality in the GUI. You can simply ignore this issue when working with GUI.
6) Startup mode, the assignment requires something like this:
java -jar path_and_filename [<mode>]
mode can be server, alone or left blank.
Here is what the instruction says when left blank:
The mode flag must be either "server", indicating the server program must run, "alone", indicating standalone mode, or left out entirely, in which case the network client and gui must run.
I don't know what this means: "in which case the network client and gui must run", does that mean we should treat this as alone mode? I don't think there is any other way to operate this whole thing.
Thanks in advance
In the link I provided above, George has mentioned another link "Mode Flag confusion". That is a very good post where I think most of your doubts regarding this point should be clarified.
Originally posted by Eric Kim:
Thanks, but I still don't know how do you save server configuration information from client in a true distributed mode such as this:
Server is running on Solaris.
Client is running on Windows XP.
Perhaps the assignment does not expect this
What's brown and sticky? ... a stick. Or a tiny ad.
RavenDB is an Open Source NoSQL Database that’s fully transactional (ACID) across your databasehttps://coderanch.com/t/704633/RavenDB-Open-Source-NoSQL-Database