Java examples for Java Virtual Machine:Utility
Terminating the Application
public class Main { public void m() { // No errors/*from w w w. j a v a 2 s . co m*/ int errorCode = 0; // An error occurred errorCode = -1; // Terminate System.exit(errorCode); } }