コード例 #1
0
 /**
  * Set Dependencies for Instantiation
  *
  * @return  array
  * @since   1.0.0
  * @throws  \CommonApi\Exception\RuntimeException
  */
 public function onBeforeInstantiation(array $dependency_values = null)
 {
     parent::onBeforeInstantiation($dependency_values);
     $this->dependencies['applications'] = $this->getApplicationInstances();
     $this->dependencies['request_path'] = $this->dependencies['Request']->path;
     return $this->dependencies;
 }
コード例 #2
0
ファイル: RouteFactoryMethod.php プロジェクト: molajo/route
 /**
  * Set Dependency values
  *
  * @param   array $dependency_values (ignored in Service Item Adapter, based in from handler)
  *
  * @return  $this
  * @since   1.0.0
  */
 public function onBeforeInstantiation(array $dependency_values = null)
 {
     parent::onBeforeInstantiation($dependency_values);
     $this->dependencies['Filters'] = $this->getApplicationFilters();
     $this->dependencies['Actions'] = $this->getApplicationActions();
     $this->dependencies['Runtimedata']->reserved = new stdClass();
     $this->dependencies['Runtimedata']->reserved->filters = $this->dependencies['Filters'];
     $this->dependencies['Runtimedata']->reserved->actions = $this->dependencies['Actions'];
     return $this;
 }
コード例 #3
0
 /**
  * Set Dependencies for Instantiation
  *
  * @return  array
  * @since   1.0.0
  * @throws  \CommonApi\Exception\RuntimeException
  */
 public function onBeforeInstantiation(array $dependency_values = null)
 {
     parent::onBeforeInstantiation($dependency_values);
     $cache_callbacks = array();
     $cache_callbacks['get_cache_callback'] = $this->dependencies['Getcachecallback'];
     $cache_callbacks['set_cache_callback'] = $this->dependencies['Setcachecallback'];
     $cache_callbacks['delete_cache_callback'] = $this->dependencies['Deletecachecallback'];
     $this->dependencies['cache_callbacks'] = $cache_callbacks;
     return $this->dependencies;
 }
コード例 #4
0
ファイル: EmailFactoryMethod.php プロジェクト: molajo/email
 /**
  * Set Dependency values
  *
  * @param   array $dependency_values (ignored in Service Item Adapter, based in from adapter)
  *
  * @return  $this
  * @since   1.0.0
  */
 public function onBeforeInstantiation(array $dependency_values = null)
 {
     parent::onBeforeInstantiation($dependency_values);
     $this->dependencies['mailer_transport'] = null;
     $this->dependencies['site_name'] = null;
     $this->dependencies['smtpauth'] = null;
     $this->dependencies['smtphost'] = null;
     $this->dependencies['smtpuser'] = null;
     $this->dependencies['smtppass'] = null;
     $this->dependencies['smtpsecure'] = null;
     $this->dependencies['smtpport'] = null;
     $this->dependencies['sendmail_path'] = null;
     $this->dependencies['mailer_disable_sending'] = null;
     $this->dependencies['mailer_transport'] = $this->dependencies['Runtimedata']->application->parameters->mailer_transport;
     $this->dependencies['site_name'] = $this->dependencies['Runtimedata']->application->parameters->application_name;
     switch ($this->dependencies['Runtimedata']->application->parameters->mailer_transport) {
         case 'smtp':
             $this->dependencies['smtpauth'] = $this->dependencies['Runtimedata']->application->parameters->mailer_smtpauth;
             $this->dependencies['smtphost'] = $this->dependencies['Runtimedata']->application->parameters->mailer_smtphost;
             $this->dependencies['smtpuser'] = $this->dependencies['Runtimedata']->application->parameters->mailer_smtpuser;
             $this->dependencies['smtppass'] = $this->dependencies['Runtimedata']->application->parameters->mailer_smtppass;
             $this->dependencies['smtpsecure'] = $this->dependencies['Runtimedata']->application->parameters->mailer_smtpsecure;
             $this->dependencies['smtpport'] = $this->dependencies['Runtimedata']->application->parameters->mailer_smtpport;
             break;
         case 'sendmail':
             $this->dependencies['sendmail_path'] = $this->dependencies['Runtimedata']->application->parameters->mailer_send_mail;
             break;
         default:
             break;
     }
     $this->dependencies['to'] = $this->dependencies['Runtimedata']->application->parameters->mailer_only_deliver_to;
     $this->dependencies['from'] = $this->dependencies['Runtimedata']->application->parameters->mailer_mail_from;
     $this->dependencies['reply_to'] = $this->dependencies['Runtimedata']->application->parameters->mailer_mail_reply_to;
     $this->dependencies['email_adapter'] = 'phpMailer';
     //= $this->dependencies['Runtimedata']->application->parameters->email_adapter;
     $this->dependencies['mailer_disable_sending'] = $this->dependencies['Runtimedata']->application->parameters->mailer_disable_sending;
     $this->dependencies['mailer_only_deliver_to'] = '*****@*****.**';
     return $dependency_values;
 }
コード例 #5
0
ファイル: MessagesFactoryMethod.php プロジェクト: molajo/user
 /**
  * Set Dependencies for Instantiation
  *
  * @return  array
  * @since   1.0.0
  * @throws  \CommonApi\Exception\RuntimeException
  */
 public function onBeforeInstantiation(array $dependency_values = null)
 {
     parent::onBeforeInstantiation($dependency_values);
     $this->dependencies['messages'] = $this->setMessages();
     return $this->dependencies;
 }
コード例 #6
0
 /**
  * Set Dependencies for Instantiation
  *
  * @return  array
  * @since   1.0.0
  * @throws  \CommonApi\Exception\RuntimeException
  */
 public function onBeforeInstantiation(array $dependency_values = null)
 {
     parent::onBeforeInstantiation($dependency_values);
     $this->dependencies['field_path'] = $this->base_path . '/vendor/molajo/application/Source/Model/Fields/';
     return $this->dependencies;
 }
コード例 #7
0
 /**
  * Set Dependencies for Instantiation
  *
  * @return  array
  * @since   1.0.0
  * @throws  \CommonApi\Exception\RuntimeException
  */
 public function onBeforeInstantiation(array $dependency_values = null)
 {
     parent::onBeforeInstantiation($dependency_values);
     $this->dependencies['extensions_filename'] = $this->base_path . '/Bootstrap/Files/Output/Extensions.json';
     return $this->dependencies;
 }
コード例 #8
0
ファイル: TemplateFactoryMethod.php プロジェクト: molajo/user
 /**
  * Set Dependencies for Instantiation
  *
  * @return  array
  * @since   1.0.0
  * @throws  \CommonApi\Exception\RuntimeException
  */
 public function onBeforeInstantiation(array $dependency_values = null)
 {
     parent::onBeforeInstantiation($dependency_values);
     $this->dependencies['Templates'] = $this->getTemplates();
     return $this;
 }
コード例 #9
0
 /**
  * Logic contained within this method is invoked after Dependencies Instances are available
  *  and before the instantiateClass Method is invoked
  *
  * @param   array $dependency_values
  *
  * @return  array
  * @since   1.0.0
  */
 public function onBeforeInstantiation(array $dependency_values = null)
 {
     parent::onBeforeInstantiation($dependency_values);
     $this->setConfigurationData();
     return $dependency_values;
 }
コード例 #10
0
 /**
  * Set Dependencies for Instantiation
  *
  * @return  array
  * @since   1.0.0
  * @throws  \CommonApi\Exception\RuntimeException
  */
 public function onBeforeInstantiation(array $dependency_values = null)
 {
     parent::onBeforeInstantiation($dependency_values);
     $this->dependencies['Configuration'] = $this->getConfiguration();
     return $this->dependencies;
 }