KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > ejb > ca


1 /*************************************************************************
2  * *
3  * EJBCA: The OpenSource Certificate Authority *
4  * *
5  * This software is free software; you can redistribute it and/or *
6  * modify it under the terms of the GNU Lesser General Public *
7  * License as published by the Free Software Foundation; either *
8  * version 2.1 of the License, or any later version. *
9  * *
10  * See terms of license at gnu.org. *
11  * *
12  *************************************************************************/

13  
14 package org.ejbca.ui.cli;
15
16 /**
17  * Implements the CA command line interface
18  *
19  * @version $Id: ca.java,v 1.2.10.1 2007/04/02 08:22:52 jeklund Exp $
20  */

21 public class ca extends BaseCommand {
22     /**
23      * Main
24      *
25      * @param args command line arguments
26      */

27     public static void main(String JavaDoc[] args) {
28         try {
29             IAdminCommand cmd = CaAdminCommandFactory.getCommand(args);
30
31             if (cmd != null) {
32                 cmd.execute();
33             } else {
34                 System.out.println(
35                     "Usage: CA info | init | listcas | getrootcert | createcrl | getcrl | listexpired | exportprofiles | importprofiles | exportca | importca | importcert | republish | activateca | deactivateca");
36             }
37         } catch (Exception JavaDoc e) {
38             System.out.println(e.getMessage());
39             //e.printStackTrace();
40
System.exit(-1);
41         }
42     } // main
43
} // ca
44
Popular Tags