1 13 14 package org.ejbca.core.protocol.xkms.client; 15 16 import org.ejbca.ui.cli.IAdminCommand; 17 18 24 public class XKMSCLICommandFactory { 25 28 private XKMSCLICommandFactory() { 29 } 30 31 38 public static IAdminCommand getCommand(String [] args) { 39 if (args.length < 1) { 40 return null; 41 } 42 43 if (args[0].equals("locate")) { 44 return new LocateCommand(args); 45 } 46 47 if (args[0].equals("register")) { 48 return new RegisterCommand(args); 49 } 50 51 if (args[0].equals("reissue")) { 52 return new ReissueCommand(args); 53 } 54 55 if (args[0].equals("recover")) { 56 return new RecoverCommand(args); 57 } 58 59 if (args[0].equals("revoke")) { 60 return new RevokeCommand(args); 61 } 62 63 else { 64 return null; 65 } 66 } 67 68 } 70 71 72 | Popular Tags |