java beginner- in which folder should I place a "database.properties" file

Posted by Arvind on Stack Overflow See other posts from Stack Overflow or by Arvind
Published on 2012-06-22T21:10:04Z Indexed on 2012/06/22 21:16 UTC
Read the original article Hit count: 169

Filed under:
|

I read some tutorials on how to read data from a database.properties file- which basically stored key-value pairs.

What i want to know is, in which folder should I place this file? Is it in the root (ie "src") or within a package... And how do I access this file, if it is placed in "src"- my code will be within a package (and the package's directory will be under src)- so how do I access the properties file, which is in "src", from a class within a package?

© Stack Overflow or respective owner

Related posts about java

Related posts about properties