This week's book giveaway is in the Kotlin forum.
We're giving away four copies of Kotlin in Action and have Dmitry Jemerov & Svetlana Isakova on-line!
See this thread for details.
Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

java resource loading question, help please!!!  RSS feed

 
Larry Xu
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi I have the following structure in a eclipse project

project1
- src
- file1.java
- Libraries
- resource.jar(displaying contents below)
- com.xyz.setting.properties
- build



my question is how can I get to the file "setting.properties" in resource.jar from file1.java, how can i load it using classLoader's getResource function, what is the path to it if it's included in the classpath as a jar.

Thanks a bunch!
 
Larry Xu
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
oops, ok i redrew it.

project1
-- src
---- file1.java
-- Libraries
---- resource.jar(displaying contents below)
------ com.xyz.setting.properties
-- build
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!