1 <?php
2
3 /* --------------------------------------------------------------
4 ProductImageContainerInterface.php 2015-12-29
5 Gambio GmbH
6 http://www.gambio.de
7 Copyright (c) 2015 Gambio GmbH
8 Released under the GNU General Public License (Version 2)
9 [http://www.gnu.org/licenses/gpl-2.0.html]
10 --------------------------------------------------------------
11 */
12
13 /**
14 * Interface ProductImageContainerInterface
15 *
16 * @category System
17 * @package Product
18 * @subpackage Interfaces
19 */
20 interface ProductImageContainerInterface
21 {
22 /**
23 * Sets the primary image of the image container.
24 *
25 * @param ProductImageInterface $image Primary product image to set.
26 *
27 * @return ProductImageContainerInterface Same instance for chained method calls.
28 */
29 public function setPrimary(ProductImageInterface $image);
30
31
32 /**
33 * Returns the primary product image from the image container.
34 *
35 * @return ProductImageInterface The requested primary product image from container.
36 */
37 public function getPrimary();
38
39
40 /**
41 * Adds an additional image to the container.
42 *
43 * @param ProductImageInterface $image Additional product image to add to the container.
44 *
45 * @return ProductImageContainerInterface Same instance for chained method calls.
46 */
47 public function addAdditional(ProductImageInterface $image);
48
49
50 /**
51 * Returns the collection of additional images from the image container.
52 *
53 * @return ProductImageCollection The requested additional images from the image container.
54 */
55 public function getAdditionals();
56
57
58 /**
59 * Replaces an additional product image in the container.
60 *
61 * @param FilenameStringType $imageFile Image filename.
62 * @param ProductImageInterface $image Image to place.
63 *
64 * @return ProductImageContainerInterface Same instance for chained method calls.
65 */
66 public function replaceAdditional(FilenameStringType $imageFile, ProductImageInterface $image);
67
68
69 /**
70 * Deletes an image from the image container.
71 *
72 * @param FilenameStringType $imageFile Image filename.
73 *
74 * @return ProductImageContainerInterface Same instance for chained method calls.
75 */
76 public function delete(FilenameStringType $imageFile);
77 }