3333import com .azure .search .documents .models .AutocompleteMode ;
3434import com .azure .search .documents .models .AutocompleteResult ;
3535import com .azure .search .documents .models .IndexDocumentsResult ;
36+ import com .azure .search .documents .models .QueryDebugMode ;
3637import com .azure .search .documents .models .QueryLanguage ;
3738import com .azure .search .documents .models .QuerySpellerType ;
3839import com .azure .search .documents .models .QueryType ;
3940import com .azure .search .documents .models .ScoringStatistics ;
4041import com .azure .search .documents .models .SearchMode ;
42+ import com .azure .search .documents .models .SemanticErrorHandling ;
4143import java .util .List ;
44+ import java .util .Map ;
4245import java .util .Objects ;
4346import java .util .UUID ;
4447import java .util .stream .Collectors ;
@@ -113,6 +116,9 @@ Mono<Response<SearchDocumentsResult>> searchGet(
113116 @ QueryParam (value = "scoringParameter" , multipleQueryParams = true ) List <String > scoringParameters ,
114117 @ QueryParam ("scoringProfile" ) String scoringProfile ,
115118 @ QueryParam ("semanticConfiguration" ) String semanticConfiguration ,
119+ @ QueryParam ("semanticErrorHandling" ) SemanticErrorHandling semanticErrorHandling ,
120+ @ QueryParam ("semanticMaxWaitInMilliseconds" ) Integer semanticMaxWaitInMilliseconds ,
121+ @ QueryParam ("debug" ) QueryDebugMode debug ,
116122 @ QueryParam ("searchFields" ) String searchFields ,
117123 @ QueryParam ("queryLanguage" ) QueryLanguage queryLanguage ,
118124 @ QueryParam ("speller" ) QuerySpellerType speller ,
@@ -149,6 +155,9 @@ Response<SearchDocumentsResult> searchGetSync(
149155 @ QueryParam (value = "scoringParameter" , multipleQueryParams = true ) List <String > scoringParameters ,
150156 @ QueryParam ("scoringProfile" ) String scoringProfile ,
151157 @ QueryParam ("semanticConfiguration" ) String semanticConfiguration ,
158+ @ QueryParam ("semanticErrorHandling" ) SemanticErrorHandling semanticErrorHandling ,
159+ @ QueryParam ("semanticMaxWaitInMilliseconds" ) Integer semanticMaxWaitInMilliseconds ,
160+ @ QueryParam ("debug" ) QueryDebugMode debug ,
152161 @ QueryParam ("searchFields" ) String searchFields ,
153162 @ QueryParam ("queryLanguage" ) QueryLanguage queryLanguage ,
154163 @ QueryParam ("speller" ) QuerySpellerType speller ,
@@ -193,7 +202,7 @@ Response<SearchDocumentsResult> searchPostSync(
193202 @ Get ("/docs('{key}')" )
194203 @ ExpectedResponses ({200 })
195204 @ UnexpectedResponseExceptionType (SearchErrorException .class )
196- Mono <Response <Object >> get (
205+ Mono <Response <Map < String , Object > >> get (
197206 @ HostParam ("endpoint" ) String endpoint ,
198207 @ HostParam ("indexName" ) String indexName ,
199208 @ PathParam ("key" ) String key ,
@@ -206,7 +215,7 @@ Mono<Response<Object>> get(
206215 @ Get ("/docs('{key}')" )
207216 @ ExpectedResponses ({200 })
208217 @ UnexpectedResponseExceptionType (SearchErrorException .class )
209- Response <Object > getSync (
218+ Response <Map < String , Object > > getSync (
210219 @ HostParam ("endpoint" ) String endpoint ,
211220 @ HostParam ("indexName" ) String indexName ,
212221 @ PathParam ("key" ) String key ,
@@ -652,10 +661,11 @@ public SearchDocumentsResult searchPost(SearchRequest searchRequest, RequestOpti
652661 * @throws IllegalArgumentException thrown if parameters fail the validation.
653662 * @throws SearchErrorException thrown if the request is rejected by server.
654663 * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
655- * @return any object along with {@link Response} on successful completion of {@link Mono}.
664+ * @return a document retrieved via a document lookup operation along with {@link Response} on successful completion
665+ * of {@link Mono}.
656666 */
657667 @ ServiceMethod (returns = ReturnType .SINGLE )
658- public Mono <Response <Object >> getWithResponseAsync (
668+ public Mono <Response <Map < String , Object > >> getWithResponseAsync (
659669 String key , List <String > selectedFields , RequestOptions requestOptions ) {
660670 final String accept = "application/json; odata.metadata=none" ;
661671 UUID xMsClientRequestIdInternal = null ;
@@ -693,10 +703,11 @@ public Mono<Response<Object>> getWithResponseAsync(
693703 * @throws IllegalArgumentException thrown if parameters fail the validation.
694704 * @throws SearchErrorException thrown if the request is rejected by server.
695705 * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
696- * @return any object along with {@link Response} on successful completion of {@link Mono}.
706+ * @return a document retrieved via a document lookup operation along with {@link Response} on successful completion
707+ * of {@link Mono}.
697708 */
698709 @ ServiceMethod (returns = ReturnType .SINGLE )
699- public Mono <Response <Object >> getWithResponseAsync (
710+ public Mono <Response <Map < String , Object > >> getWithResponseAsync (
700711 String key , List <String > selectedFields , RequestOptions requestOptions , Context context ) {
701712 final String accept = "application/json; odata.metadata=none" ;
702713 UUID xMsClientRequestIdInternal = null ;
@@ -731,10 +742,10 @@ public Mono<Response<Object>> getWithResponseAsync(
731742 * @throws IllegalArgumentException thrown if parameters fail the validation.
732743 * @throws SearchErrorException thrown if the request is rejected by server.
733744 * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
734- * @return any object on successful completion of {@link Mono}.
745+ * @return a document retrieved via a document lookup operation on successful completion of {@link Mono}.
735746 */
736747 @ ServiceMethod (returns = ReturnType .SINGLE )
737- public Mono <Object > getAsync (String key , List <String > selectedFields , RequestOptions requestOptions ) {
748+ public Mono <Map < String , Object > > getAsync (String key , List <String > selectedFields , RequestOptions requestOptions ) {
738749 return getWithResponseAsync (key , selectedFields , requestOptions )
739750 .flatMap (res -> Mono .justOrEmpty (res .getValue ()));
740751 }
@@ -750,10 +761,10 @@ public Mono<Object> getAsync(String key, List<String> selectedFields, RequestOpt
750761 * @throws IllegalArgumentException thrown if parameters fail the validation.
751762 * @throws SearchErrorException thrown if the request is rejected by server.
752763 * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
753- * @return any object on successful completion of {@link Mono}.
764+ * @return a document retrieved via a document lookup operation on successful completion of {@link Mono}.
754765 */
755766 @ ServiceMethod (returns = ReturnType .SINGLE )
756- public Mono <Object > getAsync (
767+ public Mono <Map < String , Object > > getAsync (
757768 String key , List <String > selectedFields , RequestOptions requestOptions , Context context ) {
758769 return getWithResponseAsync (key , selectedFields , requestOptions , context )
759770 .flatMap (res -> Mono .justOrEmpty (res .getValue ()));
@@ -770,10 +781,10 @@ public Mono<Object> getAsync(
770781 * @throws IllegalArgumentException thrown if parameters fail the validation.
771782 * @throws SearchErrorException thrown if the request is rejected by server.
772783 * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
773- * @return any object along with {@link Response}.
784+ * @return a document retrieved via a document lookup operation along with {@link Response}.
774785 */
775786 @ ServiceMethod (returns = ReturnType .SINGLE )
776- public Response <Object > getWithResponse (
787+ public Response <Map < String , Object > > getWithResponse (
777788 String key , List <String > selectedFields , RequestOptions requestOptions , Context context ) {
778789 final String accept = "application/json; odata.metadata=none" ;
779790 UUID xMsClientRequestIdInternal = null ;
@@ -808,10 +819,10 @@ public Response<Object> getWithResponse(
808819 * @throws IllegalArgumentException thrown if parameters fail the validation.
809820 * @throws SearchErrorException thrown if the request is rejected by server.
810821 * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
811- * @return any object .
822+ * @return a document retrieved via a document lookup operation .
812823 */
813824 @ ServiceMethod (returns = ReturnType .SINGLE )
814- public Object get (String key , List <String > selectedFields , RequestOptions requestOptions ) {
825+ public Map < String , Object > get (String key , List <String > selectedFields , RequestOptions requestOptions ) {
815826 return getWithResponse (key , selectedFields , requestOptions , Context .NONE ).getValue ();
816827 }
817828
0 commit comments