Original command line java

Today encounter special circumstances, it is necessary for a party computer windows operating system code to find out where the bug problem. Layout of the entire project too much trouble, the project is too big, put the error written a utility class labeled jar package, call the investigation;

Under the first review, create a simple java class

public class Hellow
{
    public static void main(String[] args){
    System.out.println("55550");
    }
}

Then, cmd to open the black window, go to the directory where the java class

javac Hellow.java   compile;

java Hellow     run code

I use exlipse, first create a simple java project

MANIFEST.MF file is created in the name of the project the following can be.

I am here to thank a test on gbase connection.

Then click on the project name, right where

Can be exported jar package, without reference to the first package,

The second is labeled jar package will contain a reference to the package.

To refer to the package java project, then the project can reference the package right here the desired item.

 

 

After you run java documents and the same, enter the directory where the jar

java -jar ssssssss.jar

Guess you like

Origin blog.csdn.net/Peter_S/article/details/93753270