private void readInput() {
      // if we have an output file defined, print to it
      // otherwise print to defined output, usually standard output.
      StringBuilder jsonData = new StringBuilder();

      if (jsonSourceFile != null) {
        try {
          BufferedReader reader = Files.newBufferedReader(jsonSourceFile.toPath(), UTF_8);

          String line;
          while ((line = reader.readLine()) != null) jsonData.append(line);
        } catch (IOException e) {
          throw new ExecutionException(spec.commandLine(), "Unable to read JSON file.");
        }
      } else {
        // get JSON data from standard input
        try (Scanner scanner = new Scanner(parentCommand.in, UTF_8.name())) {
          while (scanner.hasNextLine()) {
            jsonData.append(String.join("", scanner.nextLine().split("\\s")));
          }
        }
      }

      // next step is to encode the value
      encode(jsonData.toString());
    }
Reads the stdin or from a file if one is specified by {@link #jsonSourceFile} then goes to
{@link #encode(String)} this data
app/src/main/java/org/hyperledger/besu/cli/subcommands/rlp/RLPSubCommand.java