Ejemplo n.º 1
0
 /**
  *
  * @param ZendT_Type $value
  * @param type $func 
  */
 public function setTotal($value, $func = 'sum')
 {
     if ($value instanceof ZendT_Type) {
         $this->_total['value'] += $value->toPhp();
     } else {
         $this->_total['value'] += $value;
     }
     $this->_total['count']++;
     $this->_total['func'] = $func;
 }
Ejemplo n.º 2
0
 /**
  * Adiciona uma variável bind pronta
  *
  * @param string $name
  * @param string|int|ZendT_Type $value
  * @return \ZendT_Db_Where 
  */
 public function addBind($name, $value, $groupName = null)
 {
     $this->_othersBind[$name] = $value;
     /**
      * @todo melhorar implementação de bind 
      */
     if ($value instanceof ZendT_Type) {
         $this->_bindsGroup[$groupName][] = $value->get();
     } else {
         $this->_bindsGroup[$groupName][] = $value;
     }
     return $this;
 }