示例#1
0
  protected void writeBinary(BinaryData o) {

    ensureRoom((int) (o.length(null) * 2 + 2));
    write('\'');
    StringConverter.writeHexBytes(getBuffer(), count, o.getBytes());

    count += (o.length(null) * 2);

    write('\'');
  }
示例#2
0
  protected void writeBit(BinaryData o) {

    ensureRoom((int) (o.length(null) * 8 + 2));
    write('\'');

    String s = StringConverter.byteArrayToBitString(o.getBytes(), (int) o.bitLength(null));

    writeBytes(s);
    write('\'');
  }