src/Invoice/Validator/Constraints/InvoicePaymentNotificationUnique.php line 40
<?phpdeclare(strict_types=1);/*** Copyright (c) 2022 TECLA Consulting Group oü.* All rights reserved.** This unpublished material is proprietary to TECLA Consulting Group oü.* All rights reserved. The methods and* techniques described herein are considered trade secrets* and/or confidential. Reproduction or distribution, in whole* or in part, is forbidden except by express written permission* of TECLA Consulting Group oü.** @author Matúš Sýkorjak <matus@tecla.no>* @copyright 2022 TECLA Consulting Group oü*/namespace App\Invoice\Validator\Constraints;use Symfony\Component\Validator\Constraint;use Symfony\Component\Validator\Exception\MissingOptionsException;final class InvoicePaymentNotificationUnique extends Constraint{public const NOT_UNIQUE_ERROR = '1acfa1b7-ca8d-4ad6-8715-a6c530023593';public string $message = 'Invoice payment notification is not unique.';public ?string $subscriberPropertyPath = null;public ?string $supplierPropertyPath = null;public ?string $customerPropertyPath = null;protected static $errorNames = [self::NOT_UNIQUE_ERROR => 'NOT_UNIQUE_ERROR',];public function __construct(array $options = null,?array $groups = null,mixed $payload = null,?string $message = null,?string $subscriberPropertyPath = null,?string $supplierPropertyPath = null,?string $customerPropertyPath = null) {parent::__construct($options ?? [], $groups, $payload);$this->message = $message ?? $this->message;$this->subscriberPropertyPath = $subscriberPropertyPath ?? $this->subscriberPropertyPath;$this->supplierPropertyPath = $supplierPropertyPath ?? $this->supplierPropertyPath;$this->customerPropertyPath = $customerPropertyPath ?? $this->customerPropertyPath;if (null === $this->subscriberPropertyPath) {throw new MissingOptionsException(sprintf('Option "subscriberPropertyPath" must be given for constraint "%s".', __CLASS__), ['subscriberPropertyPath']);}if (null === $this->supplierPropertyPath) {throw new MissingOptionsException(sprintf('Option "supplierPropertyPath" must be given for constraint "%s".', __CLASS__), ['supplierPropertyPath']);}if (null === $this->customerPropertyPath) {throw new MissingOptionsException(sprintf('Option "customerPropertyPath" must be given for constraint "%s".', __CLASS__), ['customerPropertyPath']);}}public function getTargets(): array|string{return self::CLASS_CONSTRAINT;}}