怎样导出生成.jar文件,高手帮帮忙谢  
   请说说具体的过程哈...

解决方案 »

  1.   

    你可以用ANT给打包成jar
    具体怎么用你可以去csdn上下载一个ANT的教程
      

  2.   

    eclipse不是有自带的吗?Export-->JAR File
      

  3.   

    直接在eclipse中就可以导出,右键点击要导出的包或类——Export——jar;
      

  4.   

    在控制台中输入 jar 命令,敲回车后就有参数和示例了,自己看看吧。
      

  5.   

    如果是应用程序打包的话,推荐使用fatjar插件有引用外部jar包的话,fatjar可以自动添加外部jar,并打包classpath
      

  6.   

    eclipse-->Export-->JAR File
      

  7.   

    如果用eclipse的话,可以用自带的功能eclipse-->Export-->JAR File,另外还可以下个叫做fatjar的插件,这个个人认为好用些。可以在这里找到http://fjep.sourceforge.net/。
      

  8.   

    最简单的就是再cmd 命令行  
    输入jar -vcf 向成生jar包的名 需要打包的文件的地址
      

  9.   

    Java Archive (JAR) files allow developers to package many classes into a single file. JAR files also use compression, so this can make applets and applications smaller.
    If you are not using any IDE or ANT, you may like to read the following:Creating a .JAR file is easy. Simple go to the directory your classes are stored in and type :-jar -cf yourJarFileName.jar *.classIf your application or applet uses packages, then you'll need to do things a little differently. Suppose your classes were in the package yourcode.games.CoolGame - you'd change to the directory above yourcode and type the following :- (Remember to use / on UNIX systems)jar -cf yourJarFileName.jar .\yourcode\games\CoolGame\*.classNow, if you have an existing JAR file, and want to extract it, you'd type the followingjar -xf yourJarFileName.jarWorking with JAR files isn't that difficult, especially if you've used the unix 'tar' command before.  If you're planning on packaging an applet for Internet Explorer, or an application for Microsoft's jview, you might also want to consider .CAB files.
      

  10.   

    eclipse   -->export    
      

  11.   

    jar cvf **.jar *.*就可以了