private static boolean readerReadLine(CliContext ctx, IoTDBConnection connection) {
    String s;
    try {
      s = ctx.getLineReader().readLine(cliPrefix + "> ", null);
      boolean continues = processCommand(ctx, s, connection);
      if (!continues) {
        return true;
      }
    } catch (UserInterruptException e) {
      // Exit on signal INT requires confirmation.
      readLine(ctx);
    } catch (EndOfFileException e) {
      // Exit on EOF (usually by pressing CTRL+D).
      ctx.exit(CODE_OK);
    } catch (IllegalArgumentException e) {
      if (e.getMessage().contains("history")) {
        return false;
      }
      throw e;
    }
    return false;
  }
IoTDB Client main function.

@param args launch arguments
@throws ClassNotFoundException ClassNotFoundException
iotdb-client/cli/src/main/java/org/apache/iotdb/cli/Cli.java