Example #1
0
 public function __construct($format = 'Y-m-d')
 {
     parent::__construct();
     $dateStrategy = new DateTimeStrategy($format);
     $this->addStrategy('birth_date', $dateStrategy);
     $this->addStrategy('hire_date', $dateStrategy);
 }
Example #2
0
 public function __construct($format = 'Y-m-d')
 {
     parent::__construct();
     $dateStrategy = new DateTimeStrategy($format);
     $this->addStrategy('created_date', $dateStrategy);
     $this->addStrategy('modified_date', $dateStrategy);
 }
 /**
  * @param string $needle          What substring identifies the related object
  * @param string $setter          What function to call to populate the object
  * @param mixed  $objectPrototype Prototype Object to be used for the Hydration
  * @param bool   $underscoreSeparatedKeys
  */
 public function __construct($needle, $setter, $objectPrototype, $underscoreSeparatedKeys = true)
 {
     parent::__construct($underscoreSeparatedKeys);
     $this->needle = $needle;
     $this->setter = $setter;
     $this->prototype = $objectPrototype;
 }
 /**
  * {@inheritdoc}
  */
 public function __construct($underscoreSeparatedKeys = true)
 {
     parent::__construct($underscoreSeparatedKeys);
     // Exclude this methods from the extraction
     $this->filterComposite->addFilter('model', new MethodMatchFilter('getModel', true), FilterComposite::CONDITION_AND);
     $this->filterComposite->addFilter('hydrator', new MethodMatchFilter('getHydrator', true), FilterComposite::CONDITION_AND);
     $this->filterComposite->addFilter('inputFilter', new MethodMatchFilter('getInputFilter', true), FilterComposite::CONDITION_AND);
 }
Example #5
0
 public function __construct($underscoreSeparatedKeys = true)
 {
     parent::__construct();
     $this->setUnderscoreSeparatedKeys($underscoreSeparatedKeys);
     $this->callableMethodFilter = new OptionalParametersFilter();
     $this->filterComposite->addFilter('is', new IsFilter());
     $this->filterComposite->addFilter('has', new HasFilter());
     $this->filterComposite->addFilter('get', new GetFilter());
     $this->filterComposite->addFilter('parameter', new OptionalParametersFilter(), FilterComposite::CONDITION_AND);
 }
 public function __construct()
 {
     parent::__construct();
     $addressStrategy = new AddressStrategy();
     $datetimeStrategy = new DateTimeFormatterStrategy(\DateTime::ISO8601);
     $this->addStrategy('billing_address', $addressStrategy);
     $this->addStrategy('shipping_address', $addressStrategy);
     $this->addStrategy('created_time', $datetimeStrategy);
     $this->addStrategy('updated_time', $datetimeStrategy);
 }
 public function __construct()
 {
     parent::__construct();
     $datetimeStrategy = new DateTimeFormatterStrategy(\DateTime::ISO8601);
     $planStrategy = new PlanStrategy();
     $cardStrategy = new CardStrategy();
     $customerStrategy = new CustomerStrategy();
     $this->addStrategy('created_time', $datetimeStrategy);
     $this->addStrategy('updated_time', $datetimeStrategy);
     $this->addStrategy('plan', $planStrategy);
     $this->addStrategy('card', $cardStrategy);
     $this->addStrategy('customer', $customerStrategy);
     $this->addStrategy('current_term_starts_at', $datetimeStrategy);
     $this->addStrategy('current_term_ends_at', $datetimeStrategy);
 }
Example #8
0
 public function __construct()
 {
     parent::__construct(false);
 }
Example #9
0
 public function __construct(UserLogic $userLogic, PasswordHasher $passwordHasher)
 {
     $this->userLogic = $userLogic;
     $this->passwordHasher = $passwordHasher;
     parent::__construct(false);
 }
Example #10
0
 /**
  * @param ZendCryptPassword $cryptoService
  * @param bool|array        $underscoreSeparatedKeys
  */
 public function __construct(ZendCryptPassword $cryptoService, $underscoreSeparatedKeys = true)
 {
     parent::__construct($underscoreSeparatedKeys);
     $this->cryptoService = $cryptoService;
 }
 public function __construct($underscoreSeparatedKeys = false)
 {
     parent::__construct($underscoreSeparatedKeys);
 }
 /**
  * @param HydratorPluginManager $pluginManager
  */
 public function __construct(HydratorPluginManager $pluginManager)
 {
     parent::__construct();
     $this->pluginManager = $pluginManager;
 }
Example #13
0
 public function __construct(AddressService $addressService)
 {
     parent::__construct(false);
     $this->addressService = $addressService;
 }