Sun Certified Web Component Developer 1.4<br />Sun Certified Java Developer 1.4<br />IBM Certified Associate Developer - WebSphere Studio, V5.0 (285)<br />IBM Certified Specialist - IBM WebSphere Application Server, Adv Single Server Edition for Multiplatforms, V4.0 (158)<br />IBM Certified Solutions Expert - IBM Websphere Studio V4.0 (487)<br />IBM Certified Specialist - IBM Visual Age for Java V4.0 (283)<br />Sun Certified Java Programmer 1.2
Originally posted by Sanjay Joshi:
My assignment is the B&S Contractors.
1. "The new application, using the existing data file format, MUST allow the CSRs to generate a list of constractors that match a customer's criteria. This is the project that you have been commissioned to implement."
I have implemented Case Sensitive and Insensitive searches for Name, Location, Specialty and Owner fields. I did not implement them for Rate and Size because they would be text field searches and be meaningless since these fields have a numeric value. Am I okay?
Sanjay, you were OK after you had implemented the case sensitive search for name and location.![]()
Those are the only required searches. Searching the other fields and the case insensitive search are all extras. They probably won't boost your score any, but on the other hand, if they work well they aren't going to detract from your score either.
2. The program must be able to work in a non-networked mode. In this mode, the database and GUI must run in the same VM and must perform no networking, must not use loopback networking, and must not involve the serialization of any objects when communicating between the GUI and database elements.
I understand that loopback networking is when you use "localhost" as host name to connect to the same machine. I have access to just one computer, how can I test for this condition? When I put the IP address/machine name of my machine and try, it also works. If I give a non-existent host name, it does not connect. Am I okay here?
Your quotation from the assignment instructions is talking about the non-networked mode (also known as standalone mode). So if you run in standalone mode, that is, "java -jar runme.jar alone" all by itself, "the database and GUI must run in the same VM and must perform no networking, must not use loopback networking, and must not involve the serialization of any objects when communicating between the GUI and database elements." So if you meet all those requirements when your application is running in standalone mode, then you're OK.
You can test your client-server applications (that is, "java -jar runme.jar server" and "java -jar runme.jar") on the same machine. In this case you are testing both server mode and network client mode and since you are doing this on a single machine you are using loopback networking. But that's OK, it's only in the standalone case that you are prohibited from using loopback networking. It's really nice to be able to test your application on two different machines. If you can possibly borrow someone's portable computer it would be worth your while. That said, I did 95% of my testing on a single computer. The remaining 5% was done on two computers. I don't remember discovering any specific problems I discovered by using a second computer, but it made me feel a little more confident.
My advice is to package your project as you would before you submit it, create a new directory and install your application from your submission jar file according to your user's guide instructions and test the application in all three operating modes (so you'll have to install at least two instances). Also unjar your submission jar and make sure everything is there where it's supposed to be according to the very detailed packaging instructions included in the assignment instructions. I know of one person who had to pay a $150 resubmission fee just because he made a simple mistake in the packaging.
3. It must allow the user to search the data for all records, or for records where the name and/or location fields exactly match values specified by the user.
This sounds like some trick requirement. I have implemented searches for Name, Location, Specialty and Owner. Does this fulfil the requirement above? What do they mean by "search the data for all records"?
Again, you only needed to allow searches for name and location. What I believe they mean by "search the data for all records" is that using your search capability it should be possible for the user to retrieve all the records there are in the database file (except for the ones that are marked as deleted). How you do this is variable. For example, leaving all the search criteria fields blank and pressing the Search button might return to the JTable all the records in the database. Alternatively, you might make the user put a star (*) or "ANY" in all the search fields, press the Search button, and then the user will see all the records in the database appear in the JTable. (I think the first alternative is more elegant.) So assuming you allow the user to return all the records in the database and you allow the user to search for: a given name (only), a given location (only), and a given name AND location, then I think you're OK.
3. Are we allowed to change (not the code) DBAccess.java interface in any way? What I mean is, can I make changes to add javadoc comments, or should that file be left untouched even though the other files have comments?
Yes, you should change the format of the Sun interface comments to use the standard javadoc format. I would not change the content of the method comments, and as you say, I would certainly not change any of the code.
4. Network Approaches
Your choice of RMI or serialized objects will not affect your grade, but no other approach is acceptable. In either case, the program must allow the user to specify the location of the database, and it must also accept an indication that a local database is to be used, in which case, the networking must be bypassed entirely.
I am confused about this one here, when I bring up my Server, it first shows a Configuration window where you enter the Port number and Database location. Then you bring up the Network Client in a different DOS window and it asks you for the host name and port number. Once you enter that, it brings the main client window up in the Networked mode. What do they mean by "it must also accept an indication that a local database is to be used"? Are they talking about the local client mode? Why does the Heading say "Network Approaches"?
The description of your application operating in server and network client modes sounds exactly right. I think by "it must also accept an indication that a local database is to be used," means that you must allow the user to enter the command: "java -jar runme.jar alone" and if that happens then you must start your application in standalone mode which means that a local database will be used. When you start up your application in standalone mode it should allow you to specify the database location. (Aside: it's not required but it is a really nice thing to allow the user to use a JFileChooser when specifying the database location. Usually I'm an advocate of just meeting the requirements as simply as possible, but the JFileChooser is so neat and so little work, that I recommend people use it even though it's probably not required.)
So the answer to your question "are they talking about local client mode?" is yes. Why they choose to impart this pearl of wisdom in the midst of talking about "network approaches" is unclear. The answer might just be "because."Some parts of the assignment instructions seem to been well thought-out; other parts read like stream-of-consciousness dictation.
Regards, George
SCJP, SCJD, SCWCD, SCBCD
Originally posted by Sanjay Joshi:
Hello,
I am reaching the end of my project coding assignment (I think!) and would like to clarify some things.
My assignment is the B&S Contractors.
1. "The new application, using the existing data file format, MUST allow the CSRs to generate a list of constractors that match a customer's criteria. This is the project that you have been commissioned to implement."
I have implemented Case Sensitive and Insensitive searches for Name, Location, Specialty and Owner fields. I did not implement them for Rate and Size because they would be text field searches and be meaningless since these fields have a numeric value. Am I okay?
[qb]
I think it is Okay. Actually I think we should co-relate this with the User Interface requirements and supply search functionality.
2. The program must be able to work in a non-networked mode. In this mode, the database and GUI must run in the same VM and must perform no networking, must not use loopback networking, and must not involve the serialization of any objects when communicating between the GUI and database elements.
I understand that loopback networking is when you use "localhost" as host name to connect to the same machine. I have access to just one computer, how can I test for this condition? When I put the IP address/machine name of my machine and try, it also works. If I give a non-existent host name, it does not connect. Am I okay here?
Sorry, I don't know. Maybe some networking experts will answer this.
3. It must allow the user to search the data for all records, or for records where the name and/or location fields exactly match values specified by the user.
This sounds like some trick requirement. I have implemented searches for Name, Location, Specialty and Owner. Does this fulfil the requirement above? What do they mean by "search the data for all records"?
There are many discussions on this particular requiremnt. I will try to tell what I understood from them. Most people provide search functionality in the following way. Allow CSR to do exact search, case-sensitive search for name and location fields. This they do by providing editable combo's or providing a check-box for exact matching. You did supply extra functionality than required like providing search by owner and speciality. What I did for for "search the data for all records" is that I provided a search all button at first. Later on George's suggestion, I thought it is redundant to provide if we allow CSR to search all(show) records by pressing the search button without entering any name/location in the text fields.
3. Are we allowed to change (not the code) DBAccess.java interface in any way? What I mean is, can I make changes to add javadoc comments, or should that file be left untouched even though the other files have comments?
The same issue was discussed a couple of days ago, I think. One of the instructions given to me is to provide javadoc comments for each element in a public interface. So I think we should add javadoc comments for this one also.
4. Network Approaches
Your choice of RMI or serialized objects will not affect your grade, but no other approach is acceptable. In either case, the program must allow the user to specify the location of the database, and it must also accept an indication that a local database is to be used, in which case, the networking must be bypassed entirely.
I am confused about this one here, when I bring up my Server, it first shows a Configuration window where you enter the Port number and Database location. Then you bring up the Network Client in a different DOS window and it asks you for the host name and port number. Once you enter that, it brings the main client window up in the Networked mode. What do they mean by "it must also accept an indication that a local database is to be used"? Are they talking about the local client mode? Why does the Heading say "Network Approaches"?
I think here they are talking about the local mode, becasue if we read the rest of line it cleary states that the network code must be bypassed entirely. So I think what they mean is when running in the local mode we must provide the indication of the local db.
![]()
Thanks!
Sanjay
[ March 17, 2004: Message edited by: Sanjay Joshi ][/QB]
(Aside: it's not required but it is a really nice thing to allow the user to use a JFileChooser when specifying the database location. Usually I'm an advocate of just meeting the requirements as simply as possible, but the JFileChooser is so neat and so little work, that I recommend people use it even though it's probably not required.)
Sun Certified Web Component Developer 1.4<br />Sun Certified Java Developer 1.4<br />IBM Certified Associate Developer - WebSphere Studio, V5.0 (285)<br />IBM Certified Specialist - IBM WebSphere Application Server, Adv Single Server Edition for Multiplatforms, V4.0 (158)<br />IBM Certified Solutions Expert - IBM Websphere Studio V4.0 (487)<br />IBM Certified Specialist - IBM Visual Age for Java V4.0 (283)<br />Sun Certified Java Programmer 1.2
My app already uses JFileChooser. However, I sometimes find that this is a bit slow, when you click on the button which is supposed to bring it up, it does not always pop up immediately. Is this something any of you encountered?
Regards, George
SCJP, SCJD, SCWCD, SCBCD
Sun Certified Web Component Developer 1.4<br />Sun Certified Java Developer 1.4<br />IBM Certified Associate Developer - WebSphere Studio, V5.0 (285)<br />IBM Certified Specialist - IBM WebSphere Application Server, Adv Single Server Edition for Multiplatforms, V4.0 (158)<br />IBM Certified Solutions Expert - IBM Websphere Studio V4.0 (487)<br />IBM Certified Specialist - IBM Visual Age for Java V4.0 (283)<br />Sun Certified Java Programmer 1.2
Originally posted by Sanjay Joshi:
A submission question.
When I make the JAR file, and upload it, what should the filename be? Can it be anything? I didnt find any guidelines on that.
The executable JAR containing the programs. This must be called runme.jar
Regards, George
SCJP, SCJD, SCWCD, SCBCD
Sun Certified Web Component Developer 1.4<br />Sun Certified Java Developer 1.4<br />IBM Certified Associate Developer - WebSphere Studio, V5.0 (285)<br />IBM Certified Specialist - IBM WebSphere Application Server, Adv Single Server Edition for Multiplatforms, V4.0 (158)<br />IBM Certified Solutions Expert - IBM Websphere Studio V4.0 (487)<br />IBM Certified Specialist - IBM Visual Age for Java V4.0 (283)<br />Sun Certified Java Programmer 1.2
Sun Certified Web Component Developer 1.4<br />Sun Certified Java Developer 1.4<br />IBM Certified Associate Developer - WebSphere Studio, V5.0 (285)<br />IBM Certified Specialist - IBM WebSphere Application Server, Adv Single Server Edition for Multiplatforms, V4.0 (158)<br />IBM Certified Solutions Expert - IBM Websphere Studio V4.0 (487)<br />IBM Certified Specialist - IBM Visual Age for Java V4.0 (283)<br />Sun Certified Java Programmer 1.2
Originally posted by Sanjay Joshi:
My searches on Name and Location use the 'startsWith' method so that matches are from the beginning of the field.
What about Specialties? I just realized that I had used the same idea, but its kind of meaningless since multiple specialties for a contractor are separated by a comma.
Regards, George
SCJP, SCJD, SCWCD, SCBCD
Something must be done about this. Let's start by reading this tiny ad:
Smokeless wood heat with a rocket mass heater
https://woodheat.net
|