• Post Reply Bookmark Topic Watch Topic
  • New Topic

JAR file question  RSS feed

 
Alok Pota
Ranch Hand
Posts: 185
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If I have a JAR file (text.jar) and in that text.jar file I have one file (foo.txt). How do I create a File object from foo.txt without unjaring the jar file.
 
John M. Gabriele
Ranch Hand
Posts: 232
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You *can* have a File object for a non-existent file...
To read in foo.txt, sounds like you just need to create a FileInputStream and layer on all the buffering and unzipping stuff.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!