Drivers\Abstraction\Sql::getAll PHP Method

getAll() public method

Previously called get_results.
public getAll ( $table = false, $where = [], $fields = [], $returnType = false ) : object
return object
    public function getAll($table = false, $where = array(), $fields = array(), $returnType = false)
    {
        if (!$table) {
            $result = $this->results($this->command());
            $this->returnType = 'object';
            return $result;
        }
        if ($returnType) {
            $this->returnType = $returnType;
        }
        $column = '*';
        if (!empty($fields)) {
            $column = $fields;
        }
        $this->select($column)->from($table);
        if (!empty($where)) {
            foreach ($where as $key => $val) {
                $this->where($key, '=', $val, 'AND');
            }
        }
        return $this->getAll();
    }