Examples of HelpCommand


Examples of co.cask.cdap.shell.command.HelpCommand

      @Override
      public void onHostnameChanged(String newHostname) {
        reader.setPrompt("cdap (" + cliConfig.getURI() + ")> ");
      }
    });
    this.helpCommand = new HelpCommand(new Supplier<CommandSet>() {
      @Override
      public CommandSet get() {
        return getCommands();
      }
    }, cliConfig);
View Full Code Here

Examples of com.baulsupp.curses.application.HelpCommand

  public CommandList getCommands() {
    return commands;
  }

  public void createDefaultCommands() {
    addCommand(new HelpCommand());
    addCommand(new QuitCommand());
    addCommand(new ListMovementCommand());
  }
View Full Code Here

Examples of com.baulsupp.kolja.ansi.commands.HelpCommand

  public void setFixedWidth(boolean b) {
    renderer.setFixedWidth(b);
  }

  protected void createDefaultCommands() {
    commands.add("h", new HelpCommand());
    commands.add(" ", new PauseCommand());
    commands.add("q", new QuitCommand());
  }
View Full Code Here

Examples of com.cloudloop.client.cli.commands.HelpCommand

    }
   
    private static void registerCommands( )
    {
  CommandFactory.getInstance( ).registerCommand( new ExitCommand( ) );
  CommandFactory.getInstance( ).registerCommand( new HelpCommand( ) );
  CommandFactory.getInstance( ).registerCommand( new CatCommand( ) );
  CommandFactory.getInstance( ).registerCommand( new ConfigCommand( ) );
  CommandFactory.getInstance( ).registerCommand( new RmCommand( ) );
  CommandFactory.getInstance( ).registerCommand( new RmDirCommand( ) );
  CommandFactory.getInstance( ).registerCommand( new ChangeDirCommand( ) );
View Full Code Here

Examples of com.codahale.shore.HelpCommand

    private ByteArrayOutputStream output;
   
    @Before
    public void setup() throws Exception {
      this.output = new ByteArrayOutputStream();
      this.cmd = new HelpCommand("Usage: woo", output);
    }
View Full Code Here

Examples of com.codahale.shore.HelpCommand

    @Test
    public void itReturnsAHelpCommandWithASubcommandList() throws Exception {
      final Runnable runnable = parse();
      assertThat(runnable, is(HelpCommand.class));
     
      final HelpCommand cmd = (HelpCommand) runnable;
      assertThat(cmd.getOutputStream(), is(sameInstance((OutputStream) System.out)));
      assertThat(cmd.getText(), is(
        "usage: shoretest <subcommand> [options]\n" +
        "\n" +
        "Available subcommands:\n" +
        "   server    Run shoretest as an HTTP server.\n" +
        "   schema    Generate a database schema for shoretest.\n" +
View Full Code Here

Examples of com.codahale.shore.HelpCommand

    @Test
    public void itReturnsAHelpCommandWithASubcommandList() throws Exception {
      final Runnable runnable = parse("-h");
      assertThat(runnable, is(HelpCommand.class));

      final HelpCommand cmd = (HelpCommand) runnable;
      assertThat(cmd.getOutputStream(), is(sameInstance((OutputStream) System.out)));
      assertThat(cmd.getText(), is(
        "usage: shoretest <subcommand> [options]\n" +
        "\n" +
        "Available subcommands:\n" +
        "   server    Run shoretest as an HTTP server.\n" +
        "   schema    Generate a database schema for shoretest.\n" +
View Full Code Here

Examples of com.codahale.shore.HelpCommand

    @Test
    public void itReturnsAHelpCommandWithASubcommandList() throws Exception {
      final Runnable runnable = parse("--help");
      assertThat(runnable, is(HelpCommand.class));

      final HelpCommand cmd = (HelpCommand) runnable;
      assertThat(cmd.getOutputStream(), is(sameInstance((OutputStream) System.out)));
      assertThat(cmd.getText(), is(
        "usage: shoretest <subcommand> [options]\n" +
        "\n" +
        "Available subcommands:\n" +
        "   server    Run shoretest as an HTTP server.\n" +
        "   schema    Generate a database schema for shoretest.\n" +
View Full Code Here

Examples of com.codahale.shore.HelpCommand

    @Test
    public void itReturnsAHelpCommandWithServerOptions() throws Exception {
      final Runnable runnable = parse("server");
      assertThat(runnable, is(HelpCommand.class));

      final HelpCommand cmd = (HelpCommand) runnable;
      assertThat(cmd.getOutputStream(), is(sameInstance((OutputStream) System.out)));
      assertThat(cmd.getText(), is(
        "usage: shoretest server -c <file> -p <port>\n" +
        "   -c, --config=FILE    Which Hibernate config file to use\n" +
        "   -h, --host=HOST      Which hostname to listen on\n" +
        "   -p, --port=PORT      Which port to bind to"
      ));
View Full Code Here

Examples of com.codahale.shore.HelpCommand

    @Test
    public void itReturnsAHelpCommandWithServerOptions() throws Exception {
      final Runnable runnable = parse("server", "-h");
      assertThat(runnable, is(HelpCommand.class));

      final HelpCommand cmd = (HelpCommand) runnable;
      assertThat(cmd.getOutputStream(), is(sameInstance((OutputStream) System.out)));
      assertThat(cmd.getText(), is(
        "usage: shoretest server -c <file> -p <port>\n" +
        "   -c, --config=FILE    Which Hibernate config file to use\n" +
        "   -h, --host=HOST      Which hostname to listen on\n" +
        "   -p, --port=PORT      Which port to bind to"
      ));
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.