$values */ private ?array $values; /** * @internal */ public function __construct( private readonly QueryBuilder $sql, private readonly string $table, ) { } /** * @param array $values */ public function values(array $values): self { $this->values = $values; return $this; } /** * @return positive-int */ public function execute(): int { return $this->sql->_executeInsert($this); } /** * @internal */ public function _getTable(): string { return $this->table; } /** * @internal * @return array */ public function _getValues(): array { if (!isset($this->values)) { throw new InvalidSqlException('INSERT: $values must be set before calling execute()'); } return $this->values; } }