I'm just about ready to submit my project. Only concern really burning in my mind now is the location of the .properties file for the program. Ideally, if it were up to me, I'd just package it in the scjda-XXXXXXXX jar file and have it install when that jar is unpacked. However, that's a violation of the packaging spec. So what I've done was include it in the runme.jar, and in the installation section of the users guide, state that a "resources" folder has to be extracted from runme.jar first, before the application can run. Is this acceptable? It doesn't sound like a good practice, but given the specs it doesn't seem like too many other options are available.
I guess, your application needs a properties file before it can start up. Is it right? If your answer is yes, then it is wrong - I have read in this forum that someone got failed for this.
Your project should create a properties file at the current working directory, when there is no properties file could be found.
Hope this helps.
SCJP 1.6, SCJD, SCWCD, SCBCD.
Be nice to people on the way up cos, you'll need 'em on your way down - From somewhere I can't remember!
Joined: Nov 01, 2005
That actually does help a lot. Makes sense too. I didn't see anything mentioned in the spec about where the .properties file was supposed to be put.
Now that I think about it, the same thing is crossing my mind for the .db file. In my development environment, I have the .db file in a folder called resources, and on installation, I have the user extract that folder from the runme.jar. Is this also incorrect? Sounds like I should probably rethink the file system architecture of my project before submiting
Joined: May 16, 2005
1. Actually you should NOT extract (or expect anyone to extract ) the runme.jar at all for anything. I have the image files and the help (html) files in the runme.jar, but I access them through the program. 2. My instructions demand that the .db file should be placed in the root directory, which I have named as 'project' and this directory should be jarred as scjda-XXXXXXXXX.jar. 3. The assesor should only extract scjda-XXXXXXXXX.jar. 4. The directory structure should be like
/project/runme.jar /project/version.txt /project/readme.txt -->not necessary, but I have it! /project/xx.db /project/code/--> all the source codes /project/docs/choices.txt /project/docs/javadoc/ --> the javadoc created /project/instrctions.html given by sun.