Ejemplo n.º 1
0
 /**
  * Constructor
  * 
  * @param RestoContext $context
  * @param RestoContext $user
  */
 public function __construct($context, $user)
 {
     parent::__construct($context, $user);
     $this->providers = isset($this->context->modules[get_class($this)]['providers']) ? $this->context->modules[get_class($this)]['providers'] : array();
 }
Ejemplo n.º 2
0
 /**
  * Constructor
  * 
  * @param RestoContext $context
  * @param RestoUser $user
  */
 public function __construct($context, $user)
 {
     parent::__construct($context, $user);
 }
Ejemplo n.º 3
0
 /**
  * Constructor
  * 
  * @param RestoContext $context
  * @param RestoUser $user
  */
 public function __construct($context, $user)
 {
     parent::__construct($context, $user);
     $this->dbh = $this->getDatabaseHandler(isset($this->options['database']) ? $this->options['database'] : null);
 }
Ejemplo n.º 4
0
 /**
  * Constructor
  * 
  * @param RestoContext $context
  * @param RestoUser $user
  * @param RestoModel $model
  */
 public function __construct($context, $user, $model = null)
 {
     parent::__construct($context, $user);
     /*
      * Patterns processor (i.e. When, What and Where)
      * Note : Where processor needs gazetteer
      */
     $this->queryManager = new QueryManager($this->context->dictionary, $model);
     $this->whenProcessor = new WhenProcessor($this->queryManager);
     $this->whatProcessor = new WhatProcessor($this->queryManager, $this->options);
     if (isset($context->modules['Gazetteer'])) {
         $this->whereProcessor = new WhereProcessor($this->queryManager, RestoUtil::instantiate($context->modules['Gazetteer']['className'], array($this->context, $this->user)));
     }
 }