1 <?php
2 /* --------------------------------------------------------------
3 CustomerAddressReaderInterface.inc.php 2015-02-18 gm
4 Gambio GmbH
5 http://www.gambio.de
6 Copyright (c) 2015 Gambio GmbH
7 Released under the GNU General Public License (Version 2)
8 [http://www.gnu.org/licenses/gpl-2.0.html]
9 --------------------------------------------------------------
10 */
11
12 /**
13 * Interface CustomerAddressReaderInterface
14 *
15 * @category System
16 * @package Customer
17 * @subpackage Interfaces
18 */
19 interface CustomerAddressReaderInterface
20 {
21
22 /**
23 * Method to find a customer address with a given ID if it exits else it will return null
24 *
25 * @param IdType $id
26 *
27 * @return CustomerAddress|null
28 * @throws InvalidArgumentException
29 */
30 public function findById(IdType $id);
31
32
33 /**
34 * Method to find customer addresses with a given customer
35 * Returns an array of all customer's addresses
36 *
37 * @param CustomerInterface $customer
38 *
39 * @return array containing CustomerAddress objects
40 */
41 public function findAddressesByCustomer(CustomerInterface $customer);
42 }