phpDocumentor

CustomerServiceInterface

Interface CustomerServiceInterface

Tags
category

System

subpackage

Interfaces

Table of Contents

addressIsDefaultCustomerAddress()  : bool
Checks if address is the default address of the customer.
createNewCustomer()  : Customer
Creates a new customer with the given parameters.
createNewGuest()  : Customer
Creates a new guest account with the given parameters.
filterCustomers()  : array<string|int, mixed>
Filters customer records and returns an array with results.
registreeEmailExists()  : bool
Checks if the email address of the registree already exists.
updateCustomer()  : CustomerInterface
Updates customer data.

Methods

createNewCustomer()

Creates a new customer with the given parameters.

public createNewCustomer(CustomerEmailInterface $email, CustomerPasswordInterface $password, DateTime $dateOfBirth, CustomerVatNumberInterface $vatNumber, CustomerCallNumberInterface $telephoneNumber, CustomerCallNumberInterface $faxNumber, AddressBlockInterface $addressBlock, KeyValueCollection $addonValues[, CustomerNumberInterface|null $customerNumber = null ]) : Customer
Parameters
$email : CustomerEmailInterface

Customer's E-Mail address.

$password : CustomerPasswordInterface

Customer's password.

$dateOfBirth : DateTime

Customer's date of birth.

$vatNumber : CustomerVatNumberInterface

Customer's VAT number.

$telephoneNumber : CustomerCallNumberInterface

Customer's telephone number.

$faxNumber : CustomerCallNumberInterface

Customer's fax number.

$addressBlock : AddressBlockInterface

Customer's address.

$addonValues : KeyValueCollection

Customer's additional values.

$customerNumber : CustomerNumberInterface|null = null

Customer's number.

Tags
throws
UnexpectedValueException

On invalid arguments.

Return values
Customer

Created customer.

createNewGuest()

Creates a new guest account with the given parameters.

public createNewGuest(CustomerEmailInterface $email, DateTime $dateOfBirth, CustomerVatNumberInterface $vatNumber, CustomerCallNumberInterface $telephoneNumber, CustomerCallNumberInterface $faxNumber, AddressBlockInterface $addressBlock, KeyValueCollection $addonValues[, CustomerNumberInterface|null $customerNumber = null ]) : Customer
Parameters
$email : CustomerEmailInterface

Customer's E-Mail address.

$dateOfBirth : DateTime

Customer's date of birth.

$vatNumber : CustomerVatNumberInterface

Customer's VAT number.

$telephoneNumber : CustomerCallNumberInterface

Customer's telephone number.

$faxNumber : CustomerCallNumberInterface

Customer's fax number.

$addressBlock : AddressBlockInterface

Customer's address.

$addonValues : KeyValueCollection

Customer's additional values.

$customerNumber : CustomerNumberInterface|null = null

Customer's number.

Tags
throws
UnexpectedValueException

On invalid arguments.

Return values
Customer

Created guest customer.

filterCustomers()

Filters customer records and returns an array with results.

public filterCustomers([array<string|int, mixed> $conditions = [] ][, Pager|null $pager = null ][, array<string|int, mixed> $sorters = [] ]) : array<string|int, mixed>

Example: $service->filterCustomers(['customers_id' => 1]);

Parameters
$conditions : array<string|int, mixed> = []

Associative array containing the desired field and value.

$pager : Pager|null = null

(Optional) Pager object with pagination information

$sorters : array<string|int, mixed> = []

(Optional) array of Sorter objects with data sorting information

Return values
array<string|int, mixed>

Returns an array that contains customer objects.

Search results