View Javadoc

1   /*
2   Copyright (C) 2000 Chr. Clemens Lee <clemens@kclee.com>.
3   
4   This file is part of JavaNCSS
5   (http://www.kclee.com/clemens/java/javancss/).
6   
7   JavaNCSS is free software; you can redistribute it and/or modify it
8   under the terms of the GNU General Public License as published by the
9   Free Software Foundation; either version 2, or (at your option) any
10  later version.
11  
12  JavaNCSS is distributed in the hope that it will be useful, but WITHOUT
13  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
14  FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
15  for more details.
16  
17  You should have received a copy of the GNU General Public License
18  along with JavaNCSS; see the file COPYING.  If not, write to
19  the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
20  Boston, MA 02111-1307, USA.  */
21  
22  package javancss;
23  
24  import java.io.IOException;
25  import java.util.Locale;
26  
27  /**
28   * Main class of the JavaNCSS application. It does nothing
29   * than starting the batch process and immediately delegates
30   * control to the Javancss class.
31   *
32   * @author    Chr. Clemens Lee <clemens@kclee.com>
33   * @version   $Id: Main.java 151 2009-05-22 21:41:33Z hboutemy $
34   */
35  public class Main {
36      private static final String IMPL_VERSION = Main.class.getPackage().getImplementationVersion();
37      public static final String S_RCS_HEADER = "$Header: /javancss/Main.java,v "
38          + ((IMPL_VERSION == null) ? "0.0 2001/01/01 00:00:00" : IMPL_VERSION) + " clemens Exp clemens $";
39  
40      public static void main(String[] asArgs) throws IOException {
41          Locale.setDefault( Locale.US );
42  
43          Javancss pJavancss = new Javancss(asArgs);
44  
45          if (pJavancss.getLastErrorMessage() != null) {
46              System.exit(1);
47          }
48  
49          System.exit(0);
50      }
51  }