code: public Observable<ServiceResponse<ConnectionMonitorQueryResultInner>> queryWithServiceResponseAsync(String resourceGroupName, String networkWatcherName, String connectionMonitorName) {
          if (resourceGroupName == null) {
              throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null.");
          }
          if (networkWatcherName == null) {
              throw new IllegalArgumentException("Parameter networkWatcherName is required and cannot be null.");
          }
          if (connectionMonitorName == null) {
              throw new IllegalArgumentException("Parameter connectionMonitorName is required and cannot be null.");
          }
          if (this.client.subscriptionId() == null) {
              throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null.");
          }
          final String apiVersion = "2018-08-01";
          Observable<Response<ResponseBody>> observable = service.query(resourceGroupName, networkWatcherName, connectionMonitorName, this.client.subscriptionId(), apiVersion, this.client.acceptLanguage(), this.client.userAgent());
          return client.getAzureClient().getPostOrDeleteResultAsync(observable, new TypeToken<ConnectionMonitorQueryResultInner>() { }.getType());
      }
docs: Query a snapshot of the most recent connection states.
  
  @param resourceGroupName The name of the resource group containing Network Watcher.
  @param networkWatcherName The name of the Network Watcher resource.
  @param connectionMonitorName The name given to the connection monitor.
  @throws IllegalArgumentException thrown if parameters fail the validation
  @return the observable for the request