File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Identifying when a jar file is added at the runtime

 
Bhagirathi Mallick
Greenhorn
Posts: 26
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is there any listener class to identifying when a jar file is added at the run time into our application...

if not ,then how can i acheive that...

thanks in advance
 
Steve Luke
Bartender
Pie
Posts: 4181
21
IntelliJ IDE Java Python
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes, there is a WatchService available in the java.nio package (for Java 1.7+) which will do what you need (other classes that will be good to read: java.nio.Paths, java.nio.Watchable, java.nio.FileSystem, and java.nio.Path).
 
Bhagirathi Mallick
Greenhorn
Posts: 26
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Actually i am using java 6 .
Is there any listener method in java 6 to notify when a jar file as added or removed from your project at the run time.
so please replay..
thanks..
 
Steve Luke
Bartender
Pie
Posts: 4181
21
IntelliJ IDE Java Python
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No, you will have to update or roll your own.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic