function Query($query, $index = "*", $comment = "")
{
assert(empty($this->_reqs));
$this->AddQuery($query, $index, $comment);
$results = $this->RunQueries();
$this->_reqs = array();
// just in case it failed too early
if (!is_array($results)) {
return false;
}
// probably network error; error message should be already filled
$this->_error = $results[0]["error"];
$this->_warning = $results[0]["warning"];
if ($results[0]["status"] == SEARCHD_ERROR) {
return false;
} else {
return $results[0];
}
}