Example #1
0
  private static String readBlock(PeekableLineReader r) throws IOException {
    String first = r.readLine().trim();
    String result = first.substring(first.lastIndexOf(' ') + 1);

    for (; ; ) {
      String peek = r.peekLine().trim();
      if (peek.length() < 1 || peek.indexOf('=') >= 0) {
        break;
      }
      result += r.readLine().trim();
    }

    return result;
  }
Example #2
0
  private void runAllVectors(StreamCipher hc, String fileName, PeekableLineReader r)
      throws IOException {
    for (; ; ) {
      String line = r.readLine();
      if (line == null) {
        break;
      }

      line = line.trim();

      if (line.startsWith("Set ")) {
        runVector(hc, fileName, r, dellChar(line, ':'));
      }
    }
  }