<?php declare(strict_types=1);

namespace apexl\Vault\exceptions;

use Exception;

/**
 * Thrown by the `sqlite` driver when a consumer calls a method that has no
 * SQLite implementation. Mirrors MongoUnsupportedException's role for the
 * mongodb driver.
 *
 * Currently: upsert(). The mysql driver's upsert emits MySQL-only
 * `INSERT ... ON DUPLICATE KEY UPDATE`; SQLite's equivalent is
 * `INSERT ... ON CONFLICT (...) DO UPDATE`, which the underlying
 * Aura\SqlQuery\Sqlite\Insert builder does not support (it only offers
 * OR IGNORE / OR REPLACE flags, whose semantics differ: REPLACE deletes
 * and re-inserts the row, changing its rowid and firing delete triggers).
 * Rather than silently emitting a plain INSERT (or subtly different
 * semantics), the sqlite driver refuses loudly.
 */
class SqliteUnsupportedException extends Exception
{
}
