Examples of CommandHandler


Examples of org.jboss.as.cli.CommandHandler

            } finally {
                this.parsedCmd = originalParsedArguments;
            }
        }

        CommandHandler handler = cmdRegistry.getCommandHandler(parsedCmd.getOperationName());
        if (handler == null) {
            throw new OperationFormatException("No command handler for '" + parsedCmd.getOperationName() + "'.");
        }
        if (!(handler instanceof OperationCommand)) {
            throw new OperationFormatException("The command is not allowed in a batch.");
View Full Code Here

Examples of org.jboss.as.cli.CommandHandler

            return;
        }

        if(action.equals("remove")) {
            final String cmdName = this.commandName.getValue(args, true);
            CommandHandler handler = cmdRegistry.getCommandHandler(cmdName);
            if(!(handler instanceof GenericTypeOperationHandler)) {
                ctx.printLine("Command '" + cmdName + "' is not a generic type command.");
                return;
            }
            cmdRegistry.remove(cmdName);
View Full Code Here

Examples of org.jboss.as.cli.CommandHandler

            return;
        }

        if(action.equals("remove")) {
            final String cmdName = this.commandName.getValue(args, true);
            CommandHandler handler = cmdRegistry.getCommandHandler(cmdName);
            if(!(handler instanceof GenericTypeOperationHandler)) {
                ctx.printLine("Command '" + cmdName + "' is not a generic type command.");
                return;
            }
            cmdRegistry.remove(cmdName);
View Full Code Here

Examples of org.jboss.as.cli.CommandHandler

    @Override
    public List<String> getOperationNames(CommandContext ctx, OperationRequestAddress prefix) {
        final List<String> commands = new ArrayList<String>();
        for(String command : registry.getTabCompletionCommands()) {
            CommandHandler handler = registry.getCommandHandler(command);
            if(handler.isAvailable(ctx)) {
                commands.add(command);
            }
        }
        return commands;
    }
View Full Code Here

Examples of org.jboss.as.cli.CommandHandler

        return commands;
    }

    @Override
    public Collection<CommandArgument> getProperties(CommandContext ctx, String operationName, OperationRequestAddress address) {
        CommandHandler handler = registry.getCommandHandler(operationName);
        if(handler == null) {
            return Collections.emptyList();
        }
        return handler.getArguments(ctx);
    }
View Full Code Here

Examples of org.jboss.as.cli.CommandHandler

            return;
        }

        if(action.equals("remove")) {
            final String cmdName = this.commandName.getValue(args, true);
            CommandHandler handler = cmdRegistry.getCommandHandler(cmdName);
            if(!(handler instanceof GenericTypeOperationHandler)) {
                ctx.printLine("Command '" + cmdName + "' is not a generic type command.");
                return;
            }
            cmdRegistry.remove(cmdName);
View Full Code Here

Examples of org.jboss.as.cli.CommandHandler

    @Override
    public List<String> getOperationNames(CommandContext ctx, OperationRequestAddress prefix) {
        final List<String> commands = new ArrayList<String>();
        for(String command : registry.getTabCompletionCommands()) {
            CommandHandler handler = registry.getCommandHandler(command);
            if(handler.isAvailable(ctx)) {
                commands.add(command);
            }
        }
        return commands;
    }
View Full Code Here

Examples of org.jboss.as.cli.CommandHandler

        return commands;
    }

    @Override
    public List<CommandArgument> getProperties(CommandContext ctx, String operationName, OperationRequestAddress address) {
        CommandHandler handler = registry.getCommandHandler(operationName);
        if(handler == null) {
            return Collections.emptyList();
        }
        return handler.getArguments(ctx);
    }
View Full Code Here

Examples of org.jboss.narayana.blacktie.btadmin.CommandHandler

      .getLogger(ListRunningServersTest.class);

  private CommandHandler commandHandler;

  public void setUp() throws Exception {
    this.commandHandler = new CommandHandler();
  }
View Full Code Here

Examples of org.jboss.narayana.blacktie.btadmin.CommandHandler

  private CommandHandler commandHandler;

  boolean shutdownRequired = false;

  public void setUp() throws Exception {
    this.commandHandler = new CommandHandler();
    shutdownRequired = false;
  }
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.