Overview
  • Package
  • Class
  • Tree
  • Todo

Packages

  • AddonValue
    • Interfaces
  • ApiV2Controllers
  • Category
    • Collections
    • Entities
    • Factories
    • Interfaces
    • Providers
    • Repositories
    • Storages
  • Customer
    • Address
    • Country
    • CountryZone
    • Interfaces
    • Validation
    • ValueObjects
  • Email
    • Collections
    • Entities
    • Exceptions
    • Interfaces
    • Repository
    • ValueObjects
  • Http
    • Collections
    • Exceptions
    • Factories
    • Interfaces
    • ValueObjects
  • Loaders
    • CrossCuttingLoader
    • GXCoreLoader
    • Interfaces
  • None
  • Order
    • Collections
    • Entities
    • Factories
    • Interfaces
    • Repositories
    • Storages
    • ValueObjects
  • Product
    • Collections
    • Entities
    • Factories
    • Interfaces
    • Providers
    • Repositories
    • Storages
  • ProductModule
    • Collections
    • Deleter
    • Entities
    • Factories
    • Interface
    • Interfaces
    • Reader
    • Repositories
    • Writer
  • Shared
    • Exceptions
    • FileSystem
    • Interfaces
    • Storage
    • Types
  • Statistics
    • Interfaces
  • UserConfiguration
    • Interfaces
    • Repository

Classes

  • AbstractAddonValueServiceFactory
  • AbstractAddonValueStorage
  • AbstractApiV2Controller
  • AbstractCategoryServiceFactory
  • AbstractCollection
  • AbstractCustomerFactory
  • AbstractCustomerServiceFactory
  • AbstractFileStorage
  • AbstractHttpContextFactory
  • AbstractHttpViewControllerRegistryFactory
  • AbstractImagesApiV2Controller
  • AbstractOrderServiceFactory
  • AbstractProductAttributeServiceFactory
  • AbstractProductServiceFactory
  • AddonValueService
  • AddonValueServiceFactory
  • AddonValueStorageFactory
  • AddressBlock
  • AddressBookService
  • AddressClass
  • AddressesApiV2Controller
  • AddressFormatProvider
  • AdminHttpViewController
  • AdminPageHttpControllerResponse
  • Asset
  • AssetCollection
  • AttachmentCollection
  • AttachmentName
  • AttachmentPath
  • AttachmentsApiV2Controller
  • AttachmentsHandler
  • BoolType
  • CategoriesApiV2Controller
  • Category
  • CategoryAddonValueStorage
  • CategoryFactory
  • CategoryIconsApiV2Controller
  • CategoryImagesApiV2Controller
  • CategoryListItem
  • CategoryListItemCollection
  • CategoryListProvider
  • CategoryListProviderFactory
  • CategoryObjectService
  • CategoryReadService
  • CategoryRepository
  • CategoryRepositoryDeleter
  • CategoryRepositoryReader
  • CategoryRepositoryWriter
  • CategoryServiceFactory
  • CategorySettings
  • CategorySettingsRepository
  • CategorySettingsRepositoryReader
  • CategorySettingsRepositoryWriter
  • CategoryWriteService
  • ContactCollection
  • ContactName
  • ContactType
  • CountriesApiV2Controller
  • CountryService
  • CrossCuttingLoader
  • CurrencyCode
  • Customer
  • CustomerAccountInputValidator
  • CustomerAddress
  • CustomerAddressDeleter
  • CustomerAddressInputValidator
  • CustomerAddressReader
  • CustomerAddressRepository
  • CustomerAddressWriter
  • CustomerB2BStatus
  • CustomerCallNumber
  • CustomerCity
  • CustomerCompany
  • CustomerCountry
  • CustomerCountryIso2
  • CustomerCountryIso3
  • CustomerCountryName
  • CustomerCountryReader
  • CustomerCountryRepository
  • CustomerCountryZone
  • CustomerCountryZoneIsoCode
  • CustomerCountryZoneName
  • CustomerCountryZoneReader
  • CustomerCountryZoneRepository
  • CustomerDateOfBirth
  • CustomerDeleter
  • CustomerEmail
  • CustomerFactory
  • CustomerFirstname
  • CustomerGender
  • CustomerInputValidator
  • CustomerInputValidatorSettings
  • CustomerLastname
  • CustomerNumber
  • CustomerPassword
  • CustomerPostcode
  • CustomerReader
  • CustomerReadService
  • CustomerRegistrationInputValidatorService
  • CustomerRepository
  • CustomersApiV2Controller
  • CustomerService
  • CustomerServiceFactory
  • CustomerServiceSettings
  • CustomerStatusInformation
  • CustomerStatusProvider
  • CustomerStreet
  • CustomerSuburb
  • CustomerVatNumber
  • CustomerWriter
  • CustomerWriteService
  • DecimalType
  • DefaultApiV2Controller
  • EditableCollection
  • EditableKeyValueCollection
  • Email
  • EmailAddress
  • EmailAttachment
  • EmailCollection
  • EmailContact
  • EmailContent
  • EmailDeleter
  • EmailFactory
  • EmailReader
  • EmailRepository
  • EmailsApiV2Controller
  • EmailService
  • EmailStringType
  • EmailSubject
  • EmailWriter
  • EmptyCurrencyCode
  • EmptyDateTime
  • EmptyLanguageCode
  • EmptyOrderItemDownloadInformation
  • EmptyProductImage
  • EnvCategoryServiceSettings
  • EnvironmentHttpContextFactory
  • EnvironmentHttpViewControllerRegistryFactory
  • EnvProductImageFileStorageSettings
  • ExistingDirectory
  • ExistingFile
  • FilenameStringType
  • GXCoreLoader
  • GXCoreLoaderSettings
  • GXEngineOrder
  • GXEngineProduct
  • HttpApiV2Controller
  • HttpContext
  • HttpContextReader
  • HttpControllerResponse
  • HttpDispatcher
  • HttpResponseProcessor
  • HttpService
  • HttpServiceFactory
  • HttpViewController
  • HttpViewControllerFactory
  • HttpViewControllerRegistry
  • IdCollection
  • IdType
  • ImageFileStorage
  • IntType
  • JsonHttpControllerResponse
  • KeyValueCollection
  • LanguageCode
  • LegacyProductImageProcessing
  • MailerAdapter
  • NonEmptyStringType
  • OrderAddonValueStorage
  • OrderFactory
  • OrderItem
  • OrderItemAddonValueStorage
  • OrderItemAttribute
  • OrderItemAttributeCollection
  • OrderItemAttributeFactory
  • OrderItemAttributeRepository
  • OrderItemAttributeRepositoryDeleter
  • OrderItemAttributeRepositoryFactory
  • OrderItemAttributeRepositoryReader
  • OrderItemAttributeRepositoryWriter
  • OrderItemCollection
  • OrderItemDownloadInformation
  • OrderItemFactory
  • OrderItemProperty
  • OrderItemPropertyFactory
  • OrderItemPropertyRepository
  • OrderItemPropertyRepositoryDeleter
  • OrderItemPropertyRepositoryReader
  • OrderItemPropertyRepositoryWriter
  • OrderItemRepository
  • OrderItemRepositoryDeleter
  • OrderItemRepositoryReader
  • OrderItemRepositoryWriter
  • OrderListGenerator
  • OrderListItem
  • OrderListItemCollection
  • OrderObjectService
  • OrderPaymentType
  • OrderReadService
  • OrderRepository
  • OrderRepositoryDeleter
  • OrderRepositoryReader
  • OrderRepositoryWriter
  • OrdersApiV2Controller
  • OrderServiceFactory
  • OrderServiceSettings
  • OrderShippingType
  • OrdersHistoryApiV2Controller
  • OrdersItemsApiV2Controller
  • OrdersItemsAttributesApiV2Controller
  • OrderStatusHistoryListItem
  • OrderStatusHistoryListItemCollection
  • OrderStatusHistoryStorage
  • OrdersTotalsApiV2Controller
  • OrderTotal
  • OrderTotalCollection
  • OrderTotalFactory
  • OrderTotalRepository
  • OrderTotalRepositoryDeleter
  • OrderTotalRepositoryReader
  • OrderTotalRepositoryWriter
  • OrderWriteService
  • ProductAddonValueStorage
  • ProductAttribute
  • ProductAttributeCollection
  • ProductAttributeFactory
  • ProductAttributeObjectService
  • ProductAttributeRepository
  • ProductAttributeRepositoryDeleter
  • ProductAttributeRepositoryReader
  • ProductAttributeRepositoryWriter
  • ProductAttributeService
  • ProductAttributeServiceFactory
  • ProductCategoryLinker
  • ProductFactory
  • ProductImage
  • ProductImageCollection
  • ProductImageContainer
  • ProductImageContainerRepository
  • ProductImageFileStorage
  • ProductImagesApiV2Controller
  • ProductListItem
  • ProductListItemCollection
  • ProductListProvider
  • ProductListProviderFactory
  • ProductObjectService
  • ProductPermissionSetter
  • ProductReadService
  • ProductRepository
  • ProductRepositoryDeleter
  • ProductRepositoryReader
  • ProductRepositoryWriter
  • ProductsApiV2Controller
  • ProductServiceFactory
  • ProductSettings
  • ProductSettingsRepository
  • ProductSettingsRepositoryReader
  • ProductSettingsRepositoryWriter
  • ProductsLinksApiV2Controller
  • ProductWriteService
  • RedirectHttpControllerResponse
  • StaticCrossCuttingLoader
  • StaticGXCoreLoader
  • StatisticsService
  • StoredCategory
  • StoredOrderItem
  • StoredOrderItemAttribute
  • StoredOrderItemAttributeCollection
  • StoredOrderItemCollection
  • StoredOrderItemProperty
  • StoredOrderTotal
  • StoredOrderTotalCollection
  • StoredProduct
  • StoredProductAttribute
  • StoredProductAttributeCollection
  • StringCollection
  • StringType
  • UserConfigurationReader
  • UserConfigurationService
  • UserConfigurationWriter
  • VatNumberValidator
  • WritableDirectory
  • WritableFile
  • YetAnotherLanguageProvider
  • ZonesApiV2Controller

Interfaces

  • AddonValueContainerInterface
  • AddonValueServiceInterface
  • AddonValueStorageFactoryInterface
  • AddressBlockInterface
  • AddressBookServiceInterface
  • AddressClassInterface
  • AddressFormatProviderInterface
  • AssetCollectionInterface
  • AssetInterface
  • AttachmentCollectionInterface
  • AttachmentNameInterface
  • AttachmentPathInterface
  • AttachmentsHandlerInterface
  • CategoryFactoryInterface
  • CategoryInterface
  • CategoryListProviderFactoryInterface
  • CategoryListProviderInterface
  • CategoryObjectServiceInterface
  • CategoryReadServiceInterface
  • CategoryRepositoryDeleterInterface
  • CategoryRepositoryInterface
  • CategoryRepositoryReaderInterface
  • CategoryRepositoryWriterInterface
  • CategoryServiceSettingsInterface
  • CategorySettingsInterface
  • CategorySettingsRepositoryInterface
  • CategorySettingsRepositoryReaderInterface
  • CategorySettingsRepositoryWriterInterface
  • CategoryWriteServiceInterface
  • ContactCollectionInterface
  • ContactNameInterface
  • ContactTypeInterface
  • ContentViewInterface
  • CountryServiceInterface
  • CrossCuttingLoaderInterface
  • CrossCuttingObjectInterface
  • CustomerAccountInputValidatorInterface
  • CustomerAddressDeleterInterface
  • CustomerAddressInputValidatorInterface
  • CustomerAddressInterface
  • CustomerAddressReaderInterface
  • CustomerAddressRepositoryInterface
  • CustomerAddressWriterInterface
  • CustomerB2BStatusInterface
  • CustomerCallNumberInterface
  • CustomerCityInterface
  • CustomerCompanyInterface
  • CustomerCountryInterface
  • CustomerCountryIso2Interface
  • CustomerCountryIso3Interface
  • CustomerCountryNameInterface
  • CustomerCountryReaderInterface
  • CustomerCountryRepositoryInterface
  • CustomerCountryZoneInterface
  • CustomerCountryZoneIsoCodeInterface
  • CustomerCountryZoneNameInterface
  • CustomerCountryZoneReaderInterface
  • CustomerCountryZoneRepositoryInterface
  • CustomerDeleterInterface
  • CustomerEmailInterface
  • CustomerFirstnameInterface
  • CustomerGenderInterface
  • CustomerInputValidatorInterface
  • CustomerInputValidatorSettingsInterface
  • CustomerInterface
  • CustomerLastnameInterface
  • CustomerNumberInterface
  • CustomerPasswordInterface
  • CustomerPostcodeInterface
  • CustomerReaderInterface
  • CustomerReadServiceInterface
  • CustomerRegistrationInputValidatorServiceInterface
  • CustomerRepositoryInterface
  • CustomerServiceInterface
  • CustomerServiceSettingsInterface
  • CustomerStatusProviderInterface
  • CustomerStreetInterface
  • CustomerSuburbInterface
  • CustomerVatNumberInterface
  • CustomerWriterInterface
  • CustomerWriteServiceInterface
  • EmailAddressInterface
  • EmailAttachmentInterface
  • EmailCollectionInterface
  • EmailContactInterface
  • EmailContentInterface
  • EmailDeleterInterface
  • EmailFactoryInterface
  • EmailInterface
  • EmailReaderInterface
  • EmailRepositoryInterface
  • EmailServiceInterface
  • EmailSubjectInterface
  • EmailWriterInterface
  • GXCoreLoaderInterface
  • GXCoreLoaderSettingsInterface
  • HttpContextInterface
  • HttpContextReaderInterface
  • HttpControllerResponseInterface
  • HttpDispatcherInterface
  • HttpResponseProcessorInterface
  • HttpServiceFactoryInterface
  • HttpServiceInterface
  • HttpViewControllerFactoryInterface
  • HttpViewControllerInterface
  • HttpViewControllerRegistryInterface
  • IdInterface
  • LanguageProviderInterface
  • MailerAdapterInterface
  • OrderFactoryInterface
  • OrderInterface
  • OrderItemAttributeFactoryInterface
  • OrderItemAttributeInterface
  • OrderItemAttributeRepositoryDeleterInterface
  • OrderItemAttributeRepositoryFactoryInterface
  • OrderItemAttributeRepositoryInterface
  • OrderItemAttributeRepositoryReaderInterface
  • OrderItemAttributeRepositoryWriterInterface
  • OrderItemFactoryInterface
  • OrderItemInterface
  • OrderItemPropertyFactoryInterface
  • OrderItemPropertyRepositoryDeleterInterface
  • OrderItemPropertyRepositoryReaderInterface
  • OrderItemPropertyRepositoryWriterInterface
  • OrderItemRepositoryDeleterInterface
  • OrderItemRepositoryInterface
  • OrderItemRepositoryReaderInterface
  • OrderItemRepositoryWriterInterface
  • OrderListGeneratorInterface
  • OrderObjectServiceInterface
  • OrderPaymentTypeInterface
  • OrderReadServiceInterface
  • OrderRepositoryDeleterInterface
  • OrderRepositoryInterface
  • OrderRepositoryReaderInterface
  • OrderRepositoryWriterInterface
  • OrderServiceSettingsInterface
  • OrderShippingTypeInterface
  • OrderStatusHistoryReaderInterface
  • OrderStatusHistoryWriterInterface
  • OrderTotalFactoryInterface
  • OrderTotalInterface
  • OrderTotalRepositoryDeleterInterface
  • OrderTotalRepositoryInterface
  • OrderTotalRepositoryReaderInterface
  • OrderTotalRepositoryWriterInterface
  • OrderWriteServiceInterface
  • ProductAttributeFactoryInterface
  • ProductAttributeInterface
  • ProductAttributeObjectServiceInterface
  • ProductAttributeRepositoryDeleterInterface
  • ProductAttributeRepositoryInterface
  • ProductAttributeRepositoryReaderInterface
  • ProductAttributeRepositoryWriterInterface
  • ProductAttributeServiceInterface
  • ProductCategoryLinkerInterface
  • ProductFactoryInterface
  • ProductImageContainerInterface
  • ProductImageContainerRepositoryInterface
  • ProductImageInterface
  • ProductImagePathsSettingsInterface
  • ProductImageProcessingInterface
  • ProductInterface
  • ProductListProviderFactoryInterface
  • ProductListProviderInterface
  • ProductObjectServiceInterface
  • ProductPermissionSetterInterface
  • ProductReadServiceInterface
  • ProductRepositoryDeleterInterface
  • ProductRepositoryInterface
  • ProductRepositoryReaderInterface
  • ProductRepositoryWriterInterface
  • ProductSettingsInterface
  • ProductSettingsRepositoryInterface
  • ProductSettingsRepositoryReaderInterface
  • ProductSettingsRepositoryWriterInterface
  • ProductWriteServiceInterface
  • StatisticsServiceInterface
  • StoredCategoryInterface
  • StoredOrderItemAttributeInterface
  • StoredOrderItemInterface
  • StoredOrderTotalInterface
  • StoredProductAttributeInterface
  • StoredProductInterface
  • UserConfigurationReaderInterface
  • UserConfigurationServiceInterface
  • UserConfigurationWriterInterface
  • VatNumberValidatorInterface

Exceptions

  • AjaxException
  • AttachmentNotFoundException
  • FileNotFoundException
  • HttpApiV2Exception
  • MissingControllerNameException
  • UnknownEnvironmentException
  1 <?php
  2 /* --------------------------------------------------------------
  3    CustomerServiceFactory.inc.php 2015-01-29 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 MainFactory::load_class('AbstractCustomerServiceFactory');
 13 
 14 /**
 15  * Class CustomerServiceFactory
 16  *
 17  * Factory class for all needed customer data.
 18  *
 19  * @category System
 20  * @package  Customer
 21  * @extends  AbstractCustomerServiceFactory
 22  */
 23 class CustomerServiceFactory extends AbstractCustomerServiceFactory
 24 {
 25     /**
 26      * Query builder.
 27      * @var CI_DB_query_builder
 28      */
 29     protected $ciDatabaseQueryBuilder;
 30 
 31 
 32     /**
 33      * CustomerServiceFactory constructor.
 34      *
 35      * @param CI_DB_query_builder $ciDatabaseQueryBuilder Query builder.
 36      */
 37     public function __construct(CI_DB_query_builder $ciDatabaseQueryBuilder)
 38     {
 39         $this->ciDatabaseQueryBuilder = $ciDatabaseQueryBuilder;
 40     }
 41 
 42 
 43     /**
 44      * Returns the country service.
 45      *
 46      * @return CountryService Country service.
 47      */
 48     public function getCountryService()
 49     {
 50         $customerCountryRepo     = $this->_getCustomerCountryRepository();
 51         $customerCountryZoneRepo = $this->_getCustomerCountryZoneRepository();
 52 
 53         $countryService = MainFactory::create('CountryService', $customerCountryRepo, $customerCountryZoneRepo);
 54 
 55         return $countryService;
 56     }
 57 
 58 
 59     /**
 60      * Returns the customer service.
 61      *
 62      * @return CustomerService Customer service.
 63      */
 64     public function getCustomerService()
 65     {
 66         $customerReadService  = $this->createCustomerReadService();
 67         $customerWriteService = $this->createCustomerWriteService();
 68 
 69         $customerService = MainFactory::create('CustomerService', $customerReadService, $customerWriteService);
 70 
 71         return $customerService;
 72     }
 73 
 74 
 75     /**
 76      * Creates a customer read service object.
 77      *
 78      * @return CustomerReadService Customer read service.
 79      */
 80     public function createCustomerReadService()
 81     {
 82         $customerRepository = $this->_getCustomerRepository();
 83 
 84         $customerReadService = MainFactory::create('CustomerReadService', $customerRepository);
 85 
 86         return $customerReadService;
 87     }
 88 
 89 
 90     /**
 91      * Creates a customer service object.
 92      *
 93      * @return CustomerService Customer service.
 94      */
 95     public function createCustomerWriteService()
 96     {
 97         $addressBookService      = $this->getAddressBookService();
 98         $customerRepository      = $this->_getCustomerRepository();
 99         $customerServiceSettings = $this->_getCustomerServiceSettings();
100         $vatValidator            = MainFactory::create('VatNumberValidator');
101 
102         $customerWriteService = MainFactory::create('CustomerWriteService', $addressBookService, $customerRepository,
103                                                     $customerServiceSettings, $vatValidator);
104 
105         return $customerWriteService;
106     }
107     
108     
109     /**
110      * Returns the address book service.
111      *
112      * @return AddressBookService Address book service.
113      */
114     public function getAddressBookService()
115     {
116         $addressRepository  = $this->_getCustomerAddressRepository();
117         $addressBookService = MainFactory::create('AddressBookService', $addressRepository);
118 
119         return $addressBookService;
120     }
121 
122 
123     /**
124      * Returns the customer registration input validator service.
125      *
126      * @return CustomerRegistrationInputValidatorService Customer registration input validator service.
127      */
128     public function getCustomerRegistrationInputValidatorService()
129     {
130         return $this->_getCustomerInputValidatorServiceByValidatorName('CustomerRegistrationInputValidatorService');
131     }
132     
133 
134     /**
135      * Returns the customer account input validator.
136      *
137      * @return CustomerAccountInputValidator Customer account input validator.
138      */
139     public function getCustomerAccountInputValidator()
140     {
141         return $this->_getCustomerInputValidatorServiceByValidatorName('CustomerAccountInputValidator');
142     }
143 
144 
145     /**
146      * Returns the database query builder.
147      *
148      * @return CI_DB_query_builder Query builder.
149      */
150     public function getDatabaseQueryBuilder()
151     {
152         return $this->ciDatabaseQueryBuilder;
153     }
154 
155 
156     /**
157      * Returns the customer factory.
158      *
159      * @return CustomerFactory Customer factory.
160      *
161      * TODO Inject CustomerFactory
162      */
163     protected function _getCustomerFactory()
164     {
165         $customerFactory = MainFactory::create('CustomerFactory');
166 
167         return $customerFactory;
168     }
169     
170 
171     /**
172      * Creates a customer repository object.
173      *
174      * @return CustomerRepository Customer repository.
175      */
176     protected function _getCustomerRepository()
177     {
178         $customerWriter    = $this->_getCustomerWriter();
179         $customerReader    = $this->_getCustomerReader();
180         $customerDeleter   = $this->_getCustomerDeleter();
181         $addressRepository = $this->_getCustomerAddressRepository();
182         $customerFactory   = $this->_getCustomerFactory();
183 
184         $repository = MainFactory::create('CustomerRepository', $customerWriter, $customerReader, $customerDeleter,
185                                           $addressRepository, $customerFactory);
186 
187         return $repository;
188     }
189 
190 
191     /**
192      * Returns the customer input validator.
193      *
194      * @return CustomerAddressInputValidator Customer input validator.
195      */
196     public function getCustomerAddressInputValidatorService()
197     {
198         return $this->_getCustomerInputValidatorServiceByValidatorName('CustomerAddressInputValidator');
199     }
200     
201 
202     /**
203      * Creates a customer country repository object.
204      *
205      * @return CustomerCountryRepository Customer country repository.
206      */
207     protected function _getCustomerCountryRepository()
208     {
209         $reader = $this->_getCustomerCountryReader();
210         $repo   = MainFactory::create('CustomerCountryRepository', $reader);
211 
212         return $repo;
213     }
214 
215 
216     /**
217      * Creates a customer country zone repository object.
218      *
219      * @return CustomerCountryZoneRepository Customer country zone repository.
220      */
221     protected function _getCustomerCountryZoneRepository()
222     {
223         $reader          = $this->_getCustomerCountryZoneReader();
224         $customerFactory = $this->_getCustomerFactory();
225         $repo            = MainFactory::create('CustomerCountryZoneRepository', $reader, $customerFactory);
226 
227         return $repo;
228     }
229 
230 
231     /**
232      * Creates a customer address repository object.
233      *
234      * @return CustomerAddressRepository Customer address repository.
235      */
236     protected function _getCustomerAddressRepository()
237     {
238         $writer     = $this->_getCustomerAddressWriter();
239         $reader     = $this->_getCustomerAddressReader();
240         $deleter    = $this->_getCustomerAddressDeleter();
241         $factory    = $this->_getCustomerFactory();
242         $repository = MainFactory::create('CustomerAddressRepository', $writer, $deleter, $reader, $factory);
243 
244         return $repository;
245     }
246 
247 
248     /**
249      * Returns customer input validator service by validator name.
250      *
251      * @param string $inputValidatorName Name of input validator service.
252      *
253      * @return object Found customer input validator service.
254      */
255     protected function _getCustomerInputValidatorServiceByValidatorName($inputValidatorName)
256     {
257         $customerService    = $this->getCustomerService();
258         $countryService     = $this->getCountryService();
259         $settings           = MainFactory::create('CustomerInputValidatorSettings');
260         $countryRepo        = $this->_getCustomerCountryRepository();
261         $countryZoneRepo    = $this->_getCustomerCountryZoneRepository();
262         $vatNumberValidator = MainFactory::create('VatNumberValidator');
263 
264         $validator = MainFactory::create($inputValidatorName, $customerService, $countryService, $settings,
265                                          $countryRepo, $countryZoneRepo, $vatNumberValidator);
266 
267         return $validator;
268     }
269 
270 
271     /**
272      * Creates a customer address deleter object.
273      *
274      * @return CustomerAddressDeleter Customer address deleter.
275      */
276     protected function _getCustomerAddressDeleter()
277     {
278         $deleter = MainFactory::create('CustomerAddressDeleter', $this->getDatabaseQueryBuilder());
279 
280         return $deleter;
281     }
282     
283 
284     /**
285      * Creates a customer address reader object.
286      *
287      * @return CustomerAddressReader Customer address reader.
288      */
289     protected function _getCustomerAddressReader()
290     {
291         $customerFactory = $this->_getCustomerFactory();
292         $countryService  = $this->getCountryService();
293 
294         $reader = MainFactory::create('CustomerAddressReader', $customerFactory, $countryService,
295                                       $this->getDatabaseQueryBuilder());
296 
297         return $reader;
298     }
299 
300 
301     /**
302      * Creates a customer country zone reader object.
303      *
304      * @return CustomerCountryZoneReader Customer country zone reader.
305      */
306     protected function _getCustomerCountryZoneReader()
307     {
308         $customerFactory = $this->_getCustomerFactory();
309         $reader          = MainFactory::create('CustomerCountryZoneReader', $customerFactory,
310                                                $this->getDatabaseQueryBuilder());
311 
312         return $reader;
313     }
314 
315 
316     /**
317      * Creates a customer country reader object
318      *
319      * @return CustomerCountryReader Customer country reader.
320      */
321     protected function _getCustomerCountryReader()
322     {
323         $customerFactory = $this->_getCustomerFactory();
324         $reader          = MainFactory::create('CustomerCountryReader', $customerFactory,
325                                                $this->getDatabaseQueryBuilder());
326 
327         return $reader;
328     }
329 
330 
331     /**
332      * Creates a customer writer object.
333      *
334      * @return CustomerWriter Customer writer.
335      */
336     protected function _getCustomerWriter()
337     {
338         $customerWriter = MainFactory::create('CustomerWriter', $this->getDatabaseQueryBuilder());
339 
340         return $customerWriter;
341     }
342 
343 
344     /**
345      * Creates a customer reader object.
346      *
347      * @return CustomerReader Customer reader.
348      */
349     protected function _getCustomerReader()
350     {
351         $customerFactory           = $this->_getCustomerFactory();
352         $customerAddressRepository = $this->_getCustomerAddressRepository();
353         $dbQueryBuilder            = $this->getDatabaseQueryBuilder();
354 
355         $customerReader = MainFactory::create('CustomerReader', $customerFactory, $customerAddressRepository,
356                                               $dbQueryBuilder);
357 
358         return $customerReader;
359     }
360     
361 
362     /**
363      * Creates a customer deleter object.
364      *
365      * @return CustomerDeleter Customer deleter.
366      */
367     protected function _getCustomerDeleter()
368     {
369         $customerDeleter = MainFactory::create('CustomerDeleter', $this->getDatabaseQueryBuilder());
370 
371         return $customerDeleter;
372     }
373     
374 
375     /**
376      * Creates a customer service settings object.
377      *
378      * @return CustomerServiceSettings Customer service settings.
379      */
380     protected function _getCustomerServiceSettings()
381     {
382         $settings = MainFactory::create('CustomerServiceSettings');
383 
384         return $settings;
385     }
386 
387 
388     /**
389      * Creates a customer address writer object.
390      *
391      * @return CustomerAddressWriter Customer address writer.
392      */
393     protected function _getCustomerAddressWriter()
394     {
395         $writer = MainFactory::create('CustomerAddressWriter', $this->getDatabaseQueryBuilder());
396 
397         return $writer;
398     }
399 } 
API documentation generated by ApiGen