<?php

declare(strict_types=1);

namespace Plugin\tnt_mcp\src\Mcp\Settings;

/**
 * A `list` source in settings.yaml — a single-table, explicit-column read via
 * {@see \JTL\DB\DbInterface::selectAll()}. Never `SELECT *`: `fields` is the whitelist.
 */
final class SettingList
{
    /**
     * @param list<string>        $fields column whitelist, in SELECT order
     * @param array<string,mixed> $where  optional equality filter (column => scalar)
     */
    public function __construct(
        public readonly string $table,
        public readonly array $fields,
        public readonly array $where = [],
        public readonly string $order = '',
    ) {
    }
}
