code: @Override
      protected void doHandle(CommandContext ctx) throws CommandLineException {
  
          final ParsedCommandLine args = ctx.getParsedCommandLine();
          final String action = this.action.getValue(args);
          if(action == null) {
              throw new CommandFormatException("Command is missing.");
          }
  
          if(action.equals("list")) {
              ctx.printColumns(getExistingCommands());
              return;
          }
  
          if(action.equals("add")) {
              final String nodePath = this.nodePath.getValue(args, true);
              final String propName = this.idProperty.getValue(args, false);
              final String cmdName = this.commandName.getValue(args, true);
              validateInput(ctx, nodePath, propName);
  
              if(cmdRegistry.getCommandHandler(cmdName) != null) {
                  throw new CommandFormatException("Command '" + cmdName + "' already registered.");
              }
              cmdRegistry.registerHandler(new GenericTypeOperationHandler(cmdName, ctx, nodePath, propName), cmdName);
              return;
          }
  
          if(action.equals("remove")) {
              final String cmdName = this.commandName.getValue(args, true);
              CommandHandler handler = cmdRegistry.getCommandHandler(cmdName);
              if(!(handler instanceof GenericTypeOperationHandler)) {
                  throw new CommandFormatException("Command '" + cmdName + "' is not a generic type command.");
              }
              cmdRegistry.remove(cmdName);
              return;
          }
  
          throw new CommandFormatException("Unexpected action: " + action);
      }
docs: /* (non-Javadoc)
  @see org.jboss.as.cli.handlers.CommandHandlerWithHelp#doHandle(org.jboss.as.cli.CommandContext)