<?php declare(strict_types=1);

namespace Shop\Presentation\Transformers;

use League\Fractal\TransformerAbstract;
use Shop\Domain\Catalog\Contracts\CatalogEntityInterface;

class CatalogTransformer  extends TransformerAbstract
{
    public function transform(CatalogEntityInterface $catalog):array
    {
        return [
            'id' => $catalog->getId(),
            'name' => $catalog->getName()
        ];
    }
}