示例#1
0
 @Override
 public void accept(BsonReader reader) {
   reader.readObjectId();
 }
 private void writeObjectId(
     BsonReader reader, final MapOrListWriterImpl writer, String fieldName, boolean isList) {
   final VarBinaryHolder vObj = new VarBinaryHolder();
   final byte[] objBytes = reader.readObjectId().toByteArray();
   writeBinary(writer, fieldName, isList, vObj, objBytes);
 }
 @Override
 protected Object readObjectId(BsonReader reader, DecoderContext ctx) {
   return reader.readObjectId().toHexString();
 }