File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Java in General and the fly likes Compiling  and jaring up a .java file from code Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "Compiling  and jaring up a .java file from code" Watch "Compiling  and jaring up a .java file from code" New topic
Author

Compiling and jaring up a .java file from code

Vassili Vladimir
Ranch Hand

Joined: Mar 08, 2007
Posts: 1585
Hi,

I want to write a java class that will compile a .java file to a .class file and then jar it up.

Can you tell me how to do that ?

Regards,


Vassili ...
SCJP 5.0, SCWCD 1.4, SCJA 1.0
Joanne Neal
Rancher

Joined: Aug 05, 2005
Posts: 3154
    
  10
You can use the JavaCompiler interface for compiling and the JarFile class for creating jar files.


Joanne
 
 
subject: Compiling and jaring up a .java file from code
 
Similar Threads
question on java files
conversion
about java decompiler
from class file to java file
File Upload thru jsp page