Ejemplo n.º 1
0
 @Override
 public void writeTo(StreamOutput out) throws IOException {
   super.writeTo(out);
   out.writeVInt(tasks.size());
   for (UnblockTestTaskResponse task : tasks) {
     task.writeTo(out);
   }
 }
Ejemplo n.º 2
0
 @Override
 public void readFrom(StreamInput in) throws IOException {
   super.readFrom(in);
   int taskCount = in.readVInt();
   List<UnblockTestTaskResponse> builder = new ArrayList<>();
   for (int i = 0; i < taskCount; i++) {
     builder.add(new UnblockTestTaskResponse(in));
   }
   tasks = Collections.unmodifiableList(builder);
 }
 @Override
 public void writeTo(StreamOutput out) throws IOException {
   super.writeTo(out);
   out.writeList(tasks);
 }
 @Override
 public void readFrom(StreamInput in) throws IOException {
   super.readFrom(in);
   tasks = Collections.unmodifiableList(in.readList(TaskInfo::new));
 }