<?php

namespace App\Tests\Domain\Scraping\Adapter;

use App\Domain\Shared\Domain\Contract\ImageStorageInterface;

class InMemoryImageStorage implements ImageStorageInterface
{
    /** @var array<string, string> targetId => pagesDirectory */
    public array $stored = [];

    public function storeChapterImages(string $targetId, array $localImagePaths): string
    {
        $dir = '/fake/pages/' . $targetId;
        $this->stored[$targetId] = $dir;

        return $dir;
    }

    public function extractFromCbz(string $targetId, string $cbzBinary): string
    {
        $dir = '/fake/pages/' . $targetId;
        $this->stored[$targetId] = $dir;

        return $dir;
    }

    public function countCbzImages(string $cbzBinary): int
    {
        return 0;
    }
}
