1 21 22 package org.continuent.sequoia.console.text.commands.dbadmin; 23 24 import java.util.StringTokenizer ; 25 26 import org.continuent.sequoia.common.i18n.ConsoleTranslate; 27 import org.continuent.sequoia.console.text.module.VirtualDatabaseAdmin; 28 29 38 public class CopyLogFromCheckpoint extends AbstractAdminCommand 39 { 40 45 public CopyLogFromCheckpoint(VirtualDatabaseAdmin module) 46 { 47 super(module); 48 } 49 50 53 public void parse(String commandText) throws Exception 54 { 55 StringTokenizer st = new StringTokenizer (commandText); 56 String checkpointName = null, controllerName = null; 57 try 58 { 59 checkpointName = st.nextToken(); 60 controllerName = st.nextToken(); 61 } 62 catch (Exception e) 63 { 64 console.printError(getUsage()); 65 return; 66 } 67 68 jmxClient.getVirtualDatabaseProxy(dbName, user, password) 69 .copyLogFromCheckpoint(checkpointName, controllerName); 70 } 71 72 75 public String getCommandParameters() 76 { 77 return ConsoleTranslate.get("admin.command.restore.log.params"); } 79 80 83 public String getCommandName() 84 { 85 return "restore log"; } 87 88 91 public String getCommandDescription() 92 { 93 return ConsoleTranslate.get("admin.command.restore.log.description"); } 95 96 } 97 | Popular Tags |