1 | <?php |
||
24 | class ContentValidator |
||
25 | { |
||
26 | /** |
||
27 | * @var \Magento\Downloadable\Model\File\ContentValidator |
||
28 | */ |
||
29 | private $fileContentValidator; |
||
30 | |||
31 | |||
32 | /** |
||
33 | * @var UrlValidator |
||
34 | */ |
||
35 | private $urlValidator; |
||
36 | |||
37 | |||
38 | /** |
||
39 | * @param \Magento\Downloadable\Model\File\ContentValidator $fileContentValidator |
||
40 | * @param \Magento\Framework\Url\Validator $urlValidator |
||
41 | */ |
||
42 | public function __construct( |
||
49 | |||
50 | |||
51 | /** |
||
52 | * @param \LizardMedia\ProductAttachment\Api\Data\AttachmentInterface $attachment |
||
53 | * @param bool $validateAttachmentContent |
||
54 | * |
||
55 | * @throws \Magento\Framework\Exception\InputException |
||
56 | * |
||
57 | * @return bool |
||
58 | */ |
||
59 | public function isValid(AttachmentInterface $attachment, bool $validateAttachmentContent = true) : bool |
||
72 | |||
73 | |||
74 | /** |
||
75 | * @param \LizardMedia\ProductAttachment\Api\Data\AttachmentInterface $attachment |
||
76 | * |
||
77 | * @throws \Magento\Framework\Exception\InputException |
||
78 | * |
||
79 | * @return void |
||
80 | */ |
||
81 | protected function validateAttachmentResource(AttachmentInterface $attachment) : void |
||
96 | } |
||
97 |