private byte[] toByteArray() {
      return ProtobufUtil.prependPBMagic(ProtobufUtil.toTableSchema(this).toByteArray());
    }
Returns the bytes in pb format
hbase-client/src/main/java/org/apache/hadoop/hbase/client/TableDescriptorBuilder.java