private static <T> Bytes toBytesOrNull(T t, Function<T, byte[]> f) {
      if (t == null) {
        return null;
      } else {
        return new Bytes(f.apply(t));
      }
    }
Constructor. Makes a deep copy of the supplied descriptor. TODO: make this private after the
HCD is removed.
@param desc The descriptor.
hbase-client/src/main/java/org/apache/hadoop/hbase/client/ColumnFamilyDescriptorBuilder.java