Class CustomerService

Class CustomerService

This class provides methods for creating and deleting customer data

CustomerService implements CustomerServiceInterface
Package: Customer
Category: System
Implements: CustomerServiceInterface
Located at Services/Core/Customer/CustomerService.inc.php

Methods summary

public __construct( CustomerReadServiceInterface $customerReadService, CustomerWriteServiceInterface $customerWriteService )

Constructor of the class CustomerService.

public createNewCustomer( CustomerEmailInterface $email, CustomerPasswordInterface $password, DateTime $dateOfBirth, CustomerVatNumberInterface $vatNumber, CustomerCallNumberInterface $telephoneNumber, CustomerCallNumberInterface $faxNumber, AddressBlockInterface $addressBlock, KeyValueCollection $addonValues ) : Customer

Creates a new customer with the given parameters.

public createNewGuest( CustomerEmailInterface $email, DateTime $dateOfBirth, CustomerVatNumberInterface $vatNumber, CustomerCallNumberInterface $telephoneNumber, CustomerCallNumberInterface $faxNumber, AddressBlockInterface $addressBlock, KeyValueCollection $addonValues ) : Customer

Creates a new guest account with the given parameters.

public getCustomerById( IdType $customerId ) : Customer

Finds a customer by its ID.

public deleteCustomerById( IdType $customerId )

Deletes the customer by its ID.

public registreeEmailExists( CustomerEmailInterface $email ) : boolean

Checks if the email address of the registree already exists.

public updateCustomer( CustomerInterface $customer ) : CustomerInterface

Updates customer data.

public addressIsDefaultCustomerAddress( CustomerAddressInterface $customerAddress ) : boolean

Checks if address is the default address of the customer.

public filterCustomers( array $conditions = array(), integer $limit = null, integer $offset = null ) : array

Filters customer records and returns an array with results.

Properties summary

protected $customerReadService : CustomerReadServiceInterface

Customer read service.


		
protected $customerWriteService : CustomerWriteServiceInterface

Customer write service.