org.lsst.ccs.shell
Class CommandTable

java.lang.Object
  extended by org.lsst.ccs.shell.CommandTable

public class CommandTable
extends Object

Command table is responsible for managing a lot of ShellCommands and is like a dictionary, because its main function is to return a command by name.

Author:
ASG

Constructor Summary
CommandTable(CommandNamer namer)
           
 
Method Summary
 void addMethod(Method method, Object handler, String prefix)
           
 void addShellCommand(ShellCommand command)
           
 List<ShellCommand> commandsByName(String discriminator)
           
 List<ShellCommand> getCommandTable()
           
 CommandNamer getNamer()
           
 ShellCommand lookupCommand(String discriminator, List<Token> tokens)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CommandTable

public CommandTable(CommandNamer namer)
Method Detail

getNamer

public CommandNamer getNamer()

getCommandTable

public List<ShellCommand> getCommandTable()

addShellCommand

public void addShellCommand(ShellCommand command)

addMethod

public void addMethod(Method method,
                      Object handler,
                      String prefix)

commandsByName

public List<ShellCommand> commandsByName(String discriminator)

lookupCommand

public ShellCommand lookupCommand(String discriminator,
                                  List<Token> tokens)
                           throws CLIException
Throws:
CLIException


Copyright © 2013 LSST. All Rights Reserved.