<?php

declare(strict_types=1);

namespace ApiModel\Domain\Repository;

interface CurrencyRepositoryInterface
{
    public function findById(string $id): ?array;

    public function findByCode(string $code): ?array;

    /** @return list<array<string, mixed>> */
    public function listAll(?bool $activeOnly = null): array;

    public function insert(string $id, string $code, string $name, ?string $symbol, int $decimalPlaces): void;

    public function update(string $id, string $code, string $name, ?string $symbol, int $decimalPlaces, bool $isActive): void;

    public function delete(string $id): void;

    public function codeExists(string $code, ?string $excludeId = null): bool;

    public function isActiveCode(string $code): bool;
}
