|
@ -1,6 +1,6 @@ |
|
|
<?php |
|
|
<?php |
|
|
|
|
|
|
|
|
class SqlResultProvider |
|
|
|
|
|
|
|
|
class SqlResultProvider implements iSqlResultItems |
|
|
{ |
|
|
{ |
|
|
/** |
|
|
/** |
|
|
* @var DbStatement |
|
|
* @var DbStatement |
|
@ -77,15 +77,6 @@ class SqlResultProvider |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* @return DbStatement[]|SqlResultCollection[] |
|
|
|
|
|
*/ |
|
|
|
|
|
public function fetchAll() |
|
|
|
|
|
{ |
|
|
|
|
|
$this->defineResultItems(); |
|
|
|
|
|
return $this->result_items; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
|
* @param $key |
|
|
* @param $key |
|
|
* @return mixed |
|
|
* @return mixed |
|
|
* метод актуален после вызова assoc |
|
|
* метод актуален после вызова assoc |
|
@ -96,6 +87,15 @@ class SqlResultProvider |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
|
|
|
* @return DbStatement[]|SqlResultCollection[] |
|
|
|
|
|
*/ |
|
|
|
|
|
public function fetchAll() |
|
|
|
|
|
{ |
|
|
|
|
|
$this->defineResultItems(); |
|
|
|
|
|
return $this->result_items; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
* @param $field |
|
|
* @param $field |
|
|
* @return mixed |
|
|
* @return mixed |
|
|
*/ |
|
|
*/ |
|
@ -104,11 +104,17 @@ class SqlResultProvider |
|
|
return $this->result->fetchField($field); |
|
|
return $this->result->fetchField($field); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
public function fetch($style = Db::FETCH_OBJ) |
|
|
|
|
|
|
|
|
/** |
|
|
|
|
|
* @return mixed |
|
|
|
|
|
*/ |
|
|
|
|
|
public function fetch() |
|
|
{ |
|
|
{ |
|
|
return $this->result->fetch($style); |
|
|
|
|
|
|
|
|
return $this->result->fetch(Db::FETCH_OBJ); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
|
* @return int |
|
|
|
|
|
*/ |
|
|
public function affectedRows() |
|
|
public function affectedRows() |
|
|
{ |
|
|
{ |
|
|
return $this->result->affectedRows(); |
|
|
return $this->result->affectedRows(); |
|
|