private void writeStorageInfo(DataOutputStream out, Partition partition, Table table)
      throws HiveException, IOException {
    StorageInfo storageInfo = getStorageInfo(table, partition);

    out.write(("location:" + storageInfo.location).getBytes(StandardCharsets.UTF_8));
    out.write(Utilities.newLineCode);
    out.write(("inputformat:" + storageInfo.inputFormatClass).getBytes(StandardCharsets.UTF_8));
    out.write(Utilities.newLineCode);
    out.write(("outputformat:" + storageInfo.outputFormatClass).getBytes(StandardCharsets.UTF_8));
  }
Formats SHOW TABLE STATUS commands to text format.
ql/src/java/org/apache/hadoop/hive/ql/ddl/table/info/show/status/formatter/TextShowTableStatusFormatter.java