presto-hive/src/main/java/io/prestosql/plugin/hive/metastore/SortingColumn.java/Order/fromMetastoreApiOrder
class Order:        public static Order fromMetastoreApiOrder(int value, String tablePartitionName)
        {
            for (Order order : values()) {
                if (value == order.getHiveOrder()) {
                    return order;
                }
            }
            throw new PrestoException(HIVE_INVALID_METADATA, "Table/partition metadata has invalid sorting order: " + tablePartitionName);
        }