org.apache.accumulo.core.util.shell.commands
public class ScanCommand extends Shell.Command
Shell.Command.CompletionSet
Modifier and Type | Field and Description |
---|---|
protected org.apache.commons.cli.Option |
timestampOpt |
Constructor and Description |
---|
ScanCommand() |
Modifier and Type | Method and Description |
---|---|
protected void |
addScanIterators(Shell shellState,
org.apache.commons.cli.CommandLine cl,
Scanner scanner,
String tableName) |
String |
description() |
int |
execute(String fullCommand,
org.apache.commons.cli.CommandLine cl,
Shell shellState) |
protected void |
fetchColumns(org.apache.commons.cli.CommandLine cl,
ScannerBase scanner,
ScanInterpreter formatter) |
protected Authorizations |
getAuths(org.apache.commons.cli.CommandLine cl,
Shell shellState) |
protected Class<? extends Formatter> |
getFormatter(org.apache.commons.cli.CommandLine cl,
String tableName,
Shell shellState) |
protected ScanInterpreter |
getInterpreter(org.apache.commons.cli.CommandLine cl,
String tableName,
Shell shellState) |
org.apache.commons.cli.Options |
getOptions() |
protected Shell.PrintFile |
getOutputFile(org.apache.commons.cli.CommandLine cl) |
protected Range |
getRange(org.apache.commons.cli.CommandLine cl,
ScanInterpreter formatter) |
protected long |
getTimeout(org.apache.commons.cli.CommandLine cl) |
int |
numArgs()
If the number of arguments is not always zero (not including those arguments handled through Options), make sure to override the
Shell.Command.usage() method. |
protected void |
printBinaryRecords(org.apache.commons.cli.CommandLine cl,
Shell shellState,
Iterable<Map.Entry<Key,Value>> scanner) |
protected void |
printBinaryRecords(org.apache.commons.cli.CommandLine cl,
Shell shellState,
Iterable<Map.Entry<Key,Value>> scanner,
Shell.PrintFile outFile) |
protected void |
printRecords(org.apache.commons.cli.CommandLine cl,
Shell shellState,
Iterable<Map.Entry<Key,Value>> scanner,
Class<? extends Formatter> formatter) |
protected void |
printRecords(org.apache.commons.cli.CommandLine cl,
Shell shellState,
Iterable<Map.Entry<Key,Value>> scanner,
Class<? extends Formatter> formatter,
Shell.PrintFile outFile) |
getName, getOptionsWithHelp, printHelp, printHelp, registerCompletion, registerCompletionForCommands, registerCompletionForNamespaces, registerCompletionForTables, registerCompletionForUsers, registerCompletionGeneral, usage
public int execute(String fullCommand, org.apache.commons.cli.CommandLine cl, Shell shellState) throws Exception
execute
in class Shell.Command
Exception
protected long getTimeout(org.apache.commons.cli.CommandLine cl)
protected void addScanIterators(Shell shellState, org.apache.commons.cli.CommandLine cl, Scanner scanner, String tableName) throws Exception
Exception
protected void printRecords(org.apache.commons.cli.CommandLine cl, Shell shellState, Iterable<Map.Entry<Key,Value>> scanner, Class<? extends Formatter> formatter) throws IOException
IOException
protected void printRecords(org.apache.commons.cli.CommandLine cl, Shell shellState, Iterable<Map.Entry<Key,Value>> scanner, Class<? extends Formatter> formatter, Shell.PrintFile outFile) throws IOException
IOException
protected void printBinaryRecords(org.apache.commons.cli.CommandLine cl, Shell shellState, Iterable<Map.Entry<Key,Value>> scanner) throws IOException
IOException
protected void printBinaryRecords(org.apache.commons.cli.CommandLine cl, Shell shellState, Iterable<Map.Entry<Key,Value>> scanner, Shell.PrintFile outFile) throws IOException
IOException
protected ScanInterpreter getInterpreter(org.apache.commons.cli.CommandLine cl, String tableName, Shell shellState) throws Exception
Exception
protected Class<? extends Formatter> getFormatter(org.apache.commons.cli.CommandLine cl, String tableName, Shell shellState) throws IOException
IOException
protected void fetchColumns(org.apache.commons.cli.CommandLine cl, ScannerBase scanner, ScanInterpreter formatter) throws UnsupportedEncodingException
UnsupportedEncodingException
protected Range getRange(org.apache.commons.cli.CommandLine cl, ScanInterpreter formatter) throws UnsupportedEncodingException
UnsupportedEncodingException
protected Authorizations getAuths(org.apache.commons.cli.CommandLine cl, Shell shellState) throws AccumuloSecurityException, AccumuloException
public String description()
description
in class Shell.Command
public org.apache.commons.cli.Options getOptions()
getOptions
in class Shell.Command
public int numArgs()
Shell.Command
Shell.Command.usage()
method.
Otherwise, Shell.Command.usage()
does need to be overridden.numArgs
in class Shell.Command
protected Shell.PrintFile getOutputFile(org.apache.commons.cli.CommandLine cl) throws FileNotFoundException
FileNotFoundException
Copyright © 2011–2016 The Apache Software Foundation. All rights reserved.