Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on Apr 24th, 2012  |  syntax: None  |  size: 0.32 KB  |  hits: 8  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. Is it possible to put resources file into JAR files?
  2. resources.jar
  3.        
  4. configuration.xml
  5.        
  6. new File("/conf/configuration.xml")
  7.        
  8. Thread.currentThread().getContextClassLoader().getResource("/conf/configuration.xml");
  9.        
  10. Thread.currentThread().getContextClassLoader().getResourceAsStream("/conf/configuration.xml");