Return the results.
189770
public function get_results() {
        $query = $this->build_query();
        $query = $this->_solrclient->createSelect($query);

        if (isset($this->_query_modifiers['limit'])) {
            $query->setRows($this->_query_modifiers['limit']);
        }

        if (isset($this->_query_modifiers['offset'])) {
            $query->setStart($this->_query_modifiers['offset']);
        }

        if (isset($this->_query_modifiers['fields'])) {
            $query->setFields($this->_query_modifiers['fields']);
        }

        if (isset($this->_query_modifiers['sort'])) {
            foreach ($this->_query_modifiers['sort'] as $k => $dir) {
                $dir = $dir == 'ASC' ? $query::SORT_ASC : $query::SORT_DESC;
                $query->addSort($k, $dir);
            }
        }

        $results = array();

        $resultsset = $this->_solrclient->select($query);
        foreach ($resultset as $document) {
            $class = $document->collection = 'cartoons' ? 'CartoonsResult' : 'CollectionsResult';
            $results[] = new $class($document);
        }

        return $results;
    }
163456
def result(self):
        """"""
        msg = "Use get_result() which forces correct exception handling"
        warnings.warn(DeprecationWarning(msg), stacklevel=2)
        return self._result
343710
def __process_results(results):
    
    if 'no match' in results and 'returning 0 elements' in results:
        return []

    result_list = []

    # Splts the result and cuts first and last dataset which are comments
    split = results.split(sep='\n\n')[1:-1]

    for entry in split:
        entry_dict = {}
        for value in entry.split('\n'):
            if len(value) < 1:
                continue
            (desc, val) = value.split(': ')
            entry_dict[desc.replace('-', '')] = val.strip(' ')
        result_list.append(entry_dict)
    return result_list
499674
def results(self):
        
        self.__init()
        for k,v in self._results.items():
            param = self._get_json(v['paramUrl'])
            if param['dataType'] == "GPFeatureRecordSetLayer":
                self._results[k] = GPFeatureRecordSetLayer.fromJSON(json.dumps(param))
            elif param['dataType'].lower().find('gpmultivalue') > -1:
                self._results[k] = GPMultiValue.fromJSON(json.dumps(param))
            elif param['dataType'] == "GPString":
                self._results[k] = GPString.fromJSON(json.dumps(param))
            elif param['dataType'] == "GPLong":
                self._results[k] = GPLong.fromJSON(json.dumps(param))
            elif param['dataType'] == "GPDouble":
                self._results[k] = GPDouble.fromJSON(json.dumps(param))
            elif param['dataType'] == "GPDate":
                self._results[k] = GPDate.fromJSON(json.dumps(param))
            elif param['dataType'] == "GPBoolean":
                self._results[k] = GPBoolean.fromJSON(json.dumps(param))
            elif param['dataType'] == "GPDataFile":
                self._results[k] = GPDataFile.fromJSON(json.dumps(param))
            elif param['dataType'] == "GPLinearUnit":
                self._results[k] = GPLinearUnit.fromJSON(json.dumps(param))
            elif param['dataType'] == "GPMultiValue":
                self._results[k] = GPMultiValue.fromJSON(json.dumps(param))
            elif param['dataType'] == "GPRasterData":
                self._results[k] = GPRasterData.fromJSON(json.dumps(param))
            elif param['dataType'] == "GPRasterDataLayer":
                self._results[k] = GPRasterDataLayer.fromJSON(json.dumps(param))
            elif param['dataType'] == "GPRecordSet":
                self._results[k] = GPRecordSet.fromJSON(json.dumps(param))
        return self._results
938471
private void returnResults() {
    final StringBuilder sb = new StringBuilder();
    for (final String result : this.results) {
      sb.append(result);
    }
    this.results.clear();
    LOG.log(Level.INFO, "Return results to the client:\n{0}", sb);
    httpCallbackHandler.onNext(CODEC.encode(sb.toString()));
  }
363181
def result_type(self):
        """"""
        if not hasattr(self, '_result_type'):
            self._result_type = conf.lib.clang_getResultType(self.type)

        return self._result_type
186080
def result(self):
        """"""
        # Module(body=[Expr(value=...)])
        return self.eval_(ast.parse(self.expr).body[0].value)
1281139
def result(self):
    
    self.wait()
    if self.failed:
      raise Exception('Query failed: %s' % str(self.errors))
    return self._table
1294761
def _print_results(results, stat=False, verbose=False):
    
    results.generate_pretty_output(stat=stat,
                                   verbose=verbose,
                                   output_function=click.secho)
694619
def fetch_result(self):
        """"""
        results = self.soup.find_all('div', {'class': 'container container-small'})
        href = None
        is_match = False

        i = 0
        while i < len(results) and not is_match:
            result = results[i]
            anchor = result.find('a', {'rel': 'bookmark'})
            is_match = self._filter_results(result, anchor)
            href = anchor['href']

            i += 1

        try:
            page = get_soup(href)
        except (Exception):
            page = None

        # Return page if search is successful
        if href and page:
            return page
        else:
            raise PageNotFoundError(PAGE_ERROR)
1141221
def check_results(tmp_):
        """"""
        # TODO: Fix this to work with more meaningful names
        if tmp_['t'] > 0:
            if tmp_['l'] > 0:
                if tmp_['rr'] > 0 or tmp_['ra'] > 1:
                    print 1, 3, tmp_
                    return 3
                elif tmp_['cr'] > 0 or tmp_['ca'] > 1:
                    print 2, 3, tmp_
                    return 3
                elif tmp_['mr'] > 0 or tmp_['ma'] > 1:
                    print 3, 2, tmp_
                    return 2
            if tmp_['cr'] > 1 or tmp_['ca'] > 2:
                print 4, 2, tmp_
                return 2
            if tmp_['mr'] > 0 or tmp_['ma'] > 1:
                if tmp_['cr'] > 0 or tmp_['ca'] > 1:
                    print 6, 0, tmp_
                    return 0
            if tmp_['rr'] > 1 or tmp_['ra'] > 2:
                print 7, 0, tmp_
                return 0
            if tmp_['sr'] > 1 or tmp_['sa'] > 2:
                print 8, 0, tmp_
                return 0
        if tmp_['l'] > 0:
            if tmp_['rr'] > 0 or tmp_['ra'] > 1:
                print 9, 2, tmp_
                return 2
            if tmp_['cr'] > 0 or tmp_['ca'] > 1:
                print 10, 0, tmp_
                return 0
        return -1
1177415
def _processResults(self):
        

        resultsByClass = self._genEmptyResults()

        for astroObject in self.objectList:
            sortKey = self._getSortKey(astroObject)
            resultsByClass[sortKey] += 1

        return resultsByClass
1338418
def load_results(result_files, options, run_set_id=None, columns=None,
                 columns_relevant_for_diff=set()):
    """"""
    return parallel.map(
        load_result,
        result_files,
        itertools.repeat(options),
        itertools.repeat(run_set_id),
        itertools.repeat(columns),
        itertools.repeat(columns_relevant_for_diff))
766583
def get_result(self):
        """"""
        result = get_json_from_remote_server(self.call)
        if result:
            date, value = max(result.iteritems(), key=itemgetter(1))
            return {'date': date, 'users': value}
        else:
            return {'date': "No Data", 'users': 0}
527369
def _viewset_results(self):
        """"""
        results = []
        try:
            response = self._viewset_method(
                self._viewset.request, *self._request.args, **self._request.kwargs
            )

            if response.status_code == 200:
                results = response.data

                if not isinstance(results, list):
                    if isinstance(results, dict):
                        # XXX: This can incidently match if a single
                        # object has results key
                        if 'results' in results and isinstance(
                            results['results'], list
                        ):
                            # Support paginated results.
                            results = results['results']
                        else:
                            results.setdefault(self._meta.primary_key, 1)
                            results = [collections.OrderedDict(results)]
                    else:
                        raise ValueError(
                            "Observable views must return a dictionary or a list of dictionaries!"
                        )
        except Http404:
            pass
        except django_exceptions.ObjectDoesNotExist:
            # The evaluation may fail when certain dependent objects (like users) are removed
            # from the database. In this case, the observer is stopped.
            pass

        return results
1023252
def process_result(self, raw_result):
        
        if self.results_class and raw_result:
            if isinstance(raw_result, dict_type):
                return self.results_class(raw_result)
            elif isinstance(raw_result, collections.Iterable):
                return [self.results_class(result) for result in raw_result]

        return raw_result
738376
def results(self):
        ""
        cur = self._conn.cursor()
        rows = cur.execute("SELECT * FROM results")
        for row in rows:
            yield (row['job_id'], _row_to_work_result(row))