docs: public static <T> void writeNullableCollection(Collection<T> items, ObjectDataOutput out) throws IOException {
          // write true when the collection is NOT null
          out.writeBoolean(items != null);
          if (items == null) {
              return;
          }
          writeCollection(items, out);
      }