code: public String readBinary(char end) throws IOException {
          int startOffset = bufferOffset;
          int startLinePos = linePos;
          CharArrayWriter baos = new CharArrayWriter();
          while (readNextChar()) {
              if (lastChar == end) {
                  lastChar = 0;
                  return baos.toString();
              } else if (lastChar == ' ' || lastChar == '\t' || lastChar == '\r' || lastChar == '\n') {
                  throw failure(getLineNo(), startLinePos, startOffset, "Illegal char '%s' in binary", Strings.escape((char) lastChar));
              }
              baos.write(lastChar);
          }
          throw eof("Unexpected end of file in binary");
      }
docs: Read the 'content' of encoded binary. This does not parse the
  binary, just read out from the buffer the string representing the
  binary data, as delimited by the requested 'end' char.
  
  @param end The char that ends the binary content.
  @return The string encoded string representation.
  @throws TokenizerException On illegal content.