1 | <?php |
||
23 | class Croper |
||
24 | { |
||
25 | /** |
||
26 | * @var \Jb\Bundle\FileUploaderBundle\Service\CropFileManager |
||
27 | */ |
||
28 | protected $cropManager; |
||
29 | |||
30 | /** |
||
31 | * |
||
32 | * @var \Jb\Bundle\FileUploaderBundle\Service\ResolverChain |
||
33 | */ |
||
34 | protected $resolvers; |
||
35 | |||
36 | /** |
||
37 | * @var \Jb\Bundle\FileUploaderBundle\Service\EndpointConfiguration |
||
38 | */ |
||
39 | protected $configuration; |
||
40 | |||
41 | /** |
||
42 | * @var \Jb\Bundle\FileUploaderBundle\Service\ValidatorManager |
||
43 | */ |
||
44 | protected $validator; |
||
45 | |||
46 | /** |
||
47 | * Constructor |
||
48 | * |
||
49 | * @param \Jb\Bundle\FileUploaderBundle\Service\CropFileManager $cropManager |
||
50 | * @param \Jb\Bundle\FileUploaderBundle\Service\ResolverChain $resolvers |
||
51 | * @param \Jb\Bundle\FileUploaderBundle\Service\EndpointConfiguration $configuration |
||
52 | * @param \Jb\Bundle\FileUploaderBundle\Service\ValidatorManager $validator |
||
53 | */ |
||
54 | public function __construct( |
||
65 | |||
66 | /** |
||
67 | * Crop an image |
||
68 | * |
||
69 | * @param string $endpoint |
||
70 | * @param array $data |
||
71 | * |
||
72 | * @return string |
||
73 | */ |
||
74 | public function crop($endpoint, array $data) |
||
91 | |||
92 | /** |
||
93 | * Get crop resolver configuration |
||
94 | * |
||
95 | * @param string $endpoint |
||
96 | * @return string |
||
97 | * |
||
98 | * @throws JbFileUploaderException |
||
99 | */ |
||
100 | protected function getCropResolver($endpoint) |
||
109 | } |
||
110 |