1<?php 2/* 3 * Copyright 2014 Google Inc. 4 * 5 * Licensed under the Apache License, Version 2.0 (the "License"); you may not 6 * use this file except in compliance with the License. You may obtain a copy of 7 * the License at 8 * 9 * http://www.apache.org/licenses/LICENSE-2.0 10 * 11 * Unless required by applicable law or agreed to in writing, software 12 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 13 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 14 * License for the specific language governing permissions and limitations under 15 * the License. 16 */ 17 18namespace Google\Service\CloudSearch; 19 20class SearchResponse extends \Google\Collection 21{ 22 protected $collection_key = 'structuredResults'; 23 protected $debugInfoType = ResponseDebugInfo::class; 24 protected $debugInfoDataType = ''; 25 protected $errorInfoType = ErrorInfo::class; 26 protected $errorInfoDataType = ''; 27 protected $facetResultsType = FacetResult::class; 28 protected $facetResultsDataType = 'array'; 29 /** 30 * @var bool 31 */ 32 public $hasMoreResults; 33 protected $queryInterpretationType = QueryInterpretation::class; 34 protected $queryInterpretationDataType = ''; 35 /** 36 * @var string 37 */ 38 public $resultCountEstimate; 39 /** 40 * @var string 41 */ 42 public $resultCountExact; 43 protected $resultCountsType = ResultCounts::class; 44 protected $resultCountsDataType = ''; 45 protected $resultsType = SearchResult::class; 46 protected $resultsDataType = 'array'; 47 protected $spellResultsType = SpellResult::class; 48 protected $spellResultsDataType = 'array'; 49 protected $structuredResultsType = StructuredResult::class; 50 protected $structuredResultsDataType = 'array'; 51 52 /** 53 * @param ResponseDebugInfo 54 */ 55 public function setDebugInfo(ResponseDebugInfo $debugInfo) 56 { 57 $this->debugInfo = $debugInfo; 58 } 59 /** 60 * @return ResponseDebugInfo 61 */ 62 public function getDebugInfo() 63 { 64 return $this->debugInfo; 65 } 66 /** 67 * @param ErrorInfo 68 */ 69 public function setErrorInfo(ErrorInfo $errorInfo) 70 { 71 $this->errorInfo = $errorInfo; 72 } 73 /** 74 * @return ErrorInfo 75 */ 76 public function getErrorInfo() 77 { 78 return $this->errorInfo; 79 } 80 /** 81 * @param FacetResult[] 82 */ 83 public function setFacetResults($facetResults) 84 { 85 $this->facetResults = $facetResults; 86 } 87 /** 88 * @return FacetResult[] 89 */ 90 public function getFacetResults() 91 { 92 return $this->facetResults; 93 } 94 /** 95 * @param bool 96 */ 97 public function setHasMoreResults($hasMoreResults) 98 { 99 $this->hasMoreResults = $hasMoreResults; 100 } 101 /** 102 * @return bool 103 */ 104 public function getHasMoreResults() 105 { 106 return $this->hasMoreResults; 107 } 108 /** 109 * @param QueryInterpretation 110 */ 111 public function setQueryInterpretation(QueryInterpretation $queryInterpretation) 112 { 113 $this->queryInterpretation = $queryInterpretation; 114 } 115 /** 116 * @return QueryInterpretation 117 */ 118 public function getQueryInterpretation() 119 { 120 return $this->queryInterpretation; 121 } 122 /** 123 * @param string 124 */ 125 public function setResultCountEstimate($resultCountEstimate) 126 { 127 $this->resultCountEstimate = $resultCountEstimate; 128 } 129 /** 130 * @return string 131 */ 132 public function getResultCountEstimate() 133 { 134 return $this->resultCountEstimate; 135 } 136 /** 137 * @param string 138 */ 139 public function setResultCountExact($resultCountExact) 140 { 141 $this->resultCountExact = $resultCountExact; 142 } 143 /** 144 * @return string 145 */ 146 public function getResultCountExact() 147 { 148 return $this->resultCountExact; 149 } 150 /** 151 * @param ResultCounts 152 */ 153 public function setResultCounts(ResultCounts $resultCounts) 154 { 155 $this->resultCounts = $resultCounts; 156 } 157 /** 158 * @return ResultCounts 159 */ 160 public function getResultCounts() 161 { 162 return $this->resultCounts; 163 } 164 /** 165 * @param SearchResult[] 166 */ 167 public function setResults($results) 168 { 169 $this->results = $results; 170 } 171 /** 172 * @return SearchResult[] 173 */ 174 public function getResults() 175 { 176 return $this->results; 177 } 178 /** 179 * @param SpellResult[] 180 */ 181 public function setSpellResults($spellResults) 182 { 183 $this->spellResults = $spellResults; 184 } 185 /** 186 * @return SpellResult[] 187 */ 188 public function getSpellResults() 189 { 190 return $this->spellResults; 191 } 192 /** 193 * @param StructuredResult[] 194 */ 195 public function setStructuredResults($structuredResults) 196 { 197 $this->structuredResults = $structuredResults; 198 } 199 /** 200 * @return StructuredResult[] 201 */ 202 public function getStructuredResults() 203 { 204 return $this->structuredResults; 205 } 206} 207 208// Adding a class alias for backwards compatibility with the previous class name. 209class_alias(SearchResponse::class, 'Google_Service_CloudSearch_SearchResponse'); 210