Exemplo n.º 1
0
 @Override
 public void writeTo(StreamOutput out) throws IOException {
   super.writeTo(out);
   out.writeUTF(type);
   out.writeUTF(id);
   if (routing == null) {
     out.writeBoolean(false);
   } else {
     out.writeBoolean(true);
     out.writeUTF(routing);
   }
   out.writeBoolean(refresh);
 }
Exemplo n.º 2
0
 @Override
 public void writeTo(StreamOutput out) throws IOException {
   super.writeTo(out);
   out.writeSharedString(type);
   out.writeOptionalString(id);
   out.writeOptionalString(routing);
   out.writeOptionalString(parent);
   out.writeOptionalString(timestamp);
   out.writeLong(ttl);
   out.writeBytesReference(source);
   out.writeByte(opType.id());
   out.writeBoolean(refresh);
   out.writeLong(version);
   out.writeByte(versionType.getValue());
 }