<?php

namespace Myvetshop\Module\Clinique\Cart\Preventer;

interface AddToCartPreventerInterface
{
    /**
     * @param \Product $product target product of the operation
     * @param int $qty Number to add / remove
     * @param string $operation up|down
     *
     * @return string|null An error message, or null if the operation is allowed
     */
    public function getErrorMessage(
        \Product $product,
        int $idProductAttribute,
        int $qty,
        string $operation,
        \Customer $customer,
        \Cart $cart
    ): ?string;
}
