All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.reactiverse.elasticsearch.client.reactivex.IndicesClient Maven / Gradle / Ivy

There is a newer version: 0.9.0-ec7.10.1
Show newest version
/*
 * Copyright 2014 Red Hat, Inc.
 *
 * Red Hat licenses this file to you under the Apache License, version 2.0
 * (the "License"); you may not use this file except in compliance with the
 * License.  You may obtain a copy of the License at:
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
 * License for the specific language governing permissions and limitations
 * under the License.
 */

package io.reactiverse.elasticsearch.client.reactivex;

import java.util.Map;
import io.reactivex.Observable;
import io.reactivex.Flowable;
import io.reactivex.Single;
import io.reactivex.Completable;
import io.reactivex.Maybe;
import org.elasticsearch.client.indices.GetMappingsRequest;
import org.elasticsearch.client.indices.GetMappingsResponse;
import org.elasticsearch.client.indices.ReloadAnalyzersResponse;
import org.elasticsearch.client.indices.rollover.RolloverResponse;
import org.elasticsearch.action.admin.indices.cache.clear.ClearIndicesCacheResponse;
import org.elasticsearch.client.indices.AnalyzeResponse;
import org.elasticsearch.action.admin.indices.forcemerge.ForceMergeResponse;
import org.elasticsearch.action.admin.indices.validate.query.ValidateQueryRequest;
import org.elasticsearch.client.indices.GetIndexResponse;
import org.elasticsearch.client.indices.UnfreezeIndexRequest;
import org.elasticsearch.action.admin.indices.shrink.ResizeRequest;
import org.elasticsearch.client.indices.ReloadAnalyzersRequest;
import org.elasticsearch.client.RequestOptions;
import org.elasticsearch.action.admin.indices.shrink.ResizeResponse;
import org.elasticsearch.client.indices.IndexTemplatesExistRequest;
import org.elasticsearch.action.admin.indices.settings.get.GetSettingsResponse;
import org.elasticsearch.action.admin.indices.alias.get.GetAliasesRequest;
import org.elasticsearch.client.indices.GetFieldMappingsResponse;
import org.elasticsearch.action.admin.indices.alias.IndicesAliasesRequest;
import org.elasticsearch.action.admin.indices.template.delete.DeleteIndexTemplateRequest;
import org.elasticsearch.client.indices.CreateIndexResponse;
import org.elasticsearch.client.indices.rollover.RolloverRequest;
import org.elasticsearch.action.admin.indices.cache.clear.ClearIndicesCacheRequest;
import org.elasticsearch.action.admin.indices.validate.query.ValidateQueryResponse;
import org.elasticsearch.action.admin.indices.settings.get.GetSettingsRequest;
import org.elasticsearch.client.core.ShardsAcknowledgedResponse;
import org.elasticsearch.client.indices.GetIndexRequest;
import org.elasticsearch.client.indices.PutMappingRequest;
import org.elasticsearch.client.indices.PutIndexTemplateRequest;
import org.elasticsearch.client.indices.GetIndexTemplatesResponse;
import org.elasticsearch.action.admin.indices.open.OpenIndexRequest;
import org.elasticsearch.action.admin.indices.settings.put.UpdateSettingsRequest;
import org.elasticsearch.action.admin.indices.forcemerge.ForceMergeRequest;
import org.elasticsearch.client.indices.CloseIndexRequest;
import org.elasticsearch.action.admin.indices.open.OpenIndexResponse;
import org.elasticsearch.client.GetAliasesResponse;
import org.elasticsearch.action.admin.indices.refresh.RefreshRequest;
import io.vertx.core.AsyncResult;
import org.elasticsearch.action.admin.indices.flush.FlushResponse;
import org.elasticsearch.client.SyncedFlushResponse;
import org.elasticsearch.action.admin.indices.flush.SyncedFlushRequest;
import org.elasticsearch.client.indices.FreezeIndexRequest;
import org.elasticsearch.action.admin.indices.delete.DeleteIndexRequest;
import org.elasticsearch.client.indices.CreateIndexRequest;
import org.elasticsearch.client.indices.GetIndexTemplatesRequest;
import org.elasticsearch.client.indices.GetFieldMappingsRequest;
import org.elasticsearch.action.support.master.AcknowledgedResponse;
import org.elasticsearch.client.indices.AnalyzeRequest;
import org.elasticsearch.action.admin.indices.flush.FlushRequest;
import org.elasticsearch.action.admin.indices.refresh.RefreshResponse;
import io.vertx.core.Handler;
import org.elasticsearch.client.indices.CloseIndexResponse;


@io.vertx.lang.rx.RxGen(io.reactiverse.elasticsearch.client.IndicesClient.class)
public class IndicesClient {

  @Override
  public String toString() {
    return delegate.toString();
  }

  @Override
  public boolean equals(Object o) {
    if (this == o) return true;
    if (o == null || getClass() != o.getClass()) return false;
    IndicesClient that = (IndicesClient) o;
    return delegate.equals(that.delegate);
  }
  
  @Override
  public int hashCode() {
    return delegate.hashCode();
  }

  public static final io.vertx.lang.rx.TypeArg __TYPE_ARG = new io.vertx.lang.rx.TypeArg<>(    obj -> new IndicesClient((io.reactiverse.elasticsearch.client.IndicesClient) obj),
    IndicesClient::getDelegate
  );

  private final io.reactiverse.elasticsearch.client.IndicesClient delegate;
  
  public IndicesClient(io.reactiverse.elasticsearch.client.IndicesClient delegate) {
    this.delegate = delegate;
  }

  public io.reactiverse.elasticsearch.client.IndicesClient getDelegate() {
    return delegate;
  }

  public void deleteAsync(DeleteIndexRequest deleteIndexRequest, RequestOptions options, Handler> handler) { 
    delegate.deleteAsync(deleteIndexRequest, options, handler);
  }

  public Single rxDeleteAsync(DeleteIndexRequest deleteIndexRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      deleteAsync(deleteIndexRequest, options, handler);
    });
  }

  public void createAsync(CreateIndexRequest createIndexRequest, RequestOptions options, Handler> handler) { 
    delegate.createAsync(createIndexRequest, options, handler);
  }

  public Single rxCreateAsync(CreateIndexRequest createIndexRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      createAsync(createIndexRequest, options, handler);
    });
  }

  public void putMappingAsync(PutMappingRequest putMappingRequest, RequestOptions options, Handler> handler) { 
    delegate.putMappingAsync(putMappingRequest, options, handler);
  }

  public Single rxPutMappingAsync(PutMappingRequest putMappingRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      putMappingAsync(putMappingRequest, options, handler);
    });
  }

  public void getMappingAsync(GetMappingsRequest getMappingsRequest, RequestOptions options, Handler> handler) { 
    delegate.getMappingAsync(getMappingsRequest, options, handler);
  }

  public Single rxGetMappingAsync(GetMappingsRequest getMappingsRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      getMappingAsync(getMappingsRequest, options, handler);
    });
  }

  public void getFieldMappingAsync(GetFieldMappingsRequest getFieldMappingsRequest, RequestOptions options, Handler> handler) { 
    delegate.getFieldMappingAsync(getFieldMappingsRequest, options, handler);
  }

  public Single rxGetFieldMappingAsync(GetFieldMappingsRequest getFieldMappingsRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      getFieldMappingAsync(getFieldMappingsRequest, options, handler);
    });
  }

  public void updateAliasesAsync(IndicesAliasesRequest indicesAliasesRequest, RequestOptions options, Handler> handler) { 
    delegate.updateAliasesAsync(indicesAliasesRequest, options, handler);
  }

  public Single rxUpdateAliasesAsync(IndicesAliasesRequest indicesAliasesRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      updateAliasesAsync(indicesAliasesRequest, options, handler);
    });
  }

  public void openAsync(OpenIndexRequest openIndexRequest, RequestOptions options, Handler> handler) { 
    delegate.openAsync(openIndexRequest, options, handler);
  }

  public Single rxOpenAsync(OpenIndexRequest openIndexRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      openAsync(openIndexRequest, options, handler);
    });
  }

  public CloseIndexResponse close(CloseIndexRequest closeIndexRequest, RequestOptions options) { 
    CloseIndexResponse ret = delegate.close(closeIndexRequest, options);
    return ret;
  }

  public void closeAsync(CloseIndexRequest closeIndexRequest, RequestOptions options, Handler> handler) { 
    delegate.closeAsync(closeIndexRequest, options, handler);
  }

  public Single rxCloseAsync(CloseIndexRequest closeIndexRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      closeAsync(closeIndexRequest, options, handler);
    });
  }

  public void existsAliasAsync(GetAliasesRequest getAliasesRequest, RequestOptions options, Handler> handler) { 
    delegate.existsAliasAsync(getAliasesRequest, options, handler);
  }

  public Single rxExistsAliasAsync(GetAliasesRequest getAliasesRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      existsAliasAsync(getAliasesRequest, options, handler);
    });
  }

  public void refreshAsync(RefreshRequest refreshRequest, RequestOptions options, Handler> handler) { 
    delegate.refreshAsync(refreshRequest, options, handler);
  }

  public Single rxRefreshAsync(RefreshRequest refreshRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      refreshAsync(refreshRequest, options, handler);
    });
  }

  public void flushAsync(FlushRequest flushRequest, RequestOptions options, Handler> handler) { 
    delegate.flushAsync(flushRequest, options, handler);
  }

  public Single rxFlushAsync(FlushRequest flushRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      flushAsync(flushRequest, options, handler);
    });
  }

  public void flushSyncedAsync(SyncedFlushRequest syncedFlushRequest, RequestOptions options, Handler> handler) { 
    delegate.flushSyncedAsync(syncedFlushRequest, options, handler);
  }

  public Single rxFlushSyncedAsync(SyncedFlushRequest syncedFlushRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      flushSyncedAsync(syncedFlushRequest, options, handler);
    });
  }

  public void getSettingsAsync(GetSettingsRequest getSettingsRequest, RequestOptions options, Handler> handler) { 
    delegate.getSettingsAsync(getSettingsRequest, options, handler);
  }

  public Single rxGetSettingsAsync(GetSettingsRequest getSettingsRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      getSettingsAsync(getSettingsRequest, options, handler);
    });
  }

  public void getAsync(GetIndexRequest getIndexRequest, RequestOptions options, Handler> handler) { 
    delegate.getAsync(getIndexRequest, options, handler);
  }

  public Single rxGetAsync(GetIndexRequest getIndexRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      getAsync(getIndexRequest, options, handler);
    });
  }

  public void forcemergeAsync(ForceMergeRequest forceMergeRequest, RequestOptions options, Handler> handler) { 
    delegate.forcemergeAsync(forceMergeRequest, options, handler);
  }

  public Single rxForcemergeAsync(ForceMergeRequest forceMergeRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      forcemergeAsync(forceMergeRequest, options, handler);
    });
  }

  public void clearCacheAsync(ClearIndicesCacheRequest clearIndicesCacheRequest, RequestOptions options, Handler> handler) { 
    delegate.clearCacheAsync(clearIndicesCacheRequest, options, handler);
  }

  public Single rxClearCacheAsync(ClearIndicesCacheRequest clearIndicesCacheRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      clearCacheAsync(clearIndicesCacheRequest, options, handler);
    });
  }

  public void existsAsync(GetIndexRequest request, RequestOptions options, Handler> handler) { 
    delegate.existsAsync(request, options, handler);
  }

  public Single rxExistsAsync(GetIndexRequest request, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      existsAsync(request, options, handler);
    });
  }

  public void shrinkAsync(ResizeRequest resizeRequest, RequestOptions options, Handler> handler) { 
    delegate.shrinkAsync(resizeRequest, options, handler);
  }

  public Single rxShrinkAsync(ResizeRequest resizeRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      shrinkAsync(resizeRequest, options, handler);
    });
  }

  public void splitAsync(ResizeRequest resizeRequest, RequestOptions options, Handler> handler) { 
    delegate.splitAsync(resizeRequest, options, handler);
  }

  public Single rxSplitAsync(ResizeRequest resizeRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      splitAsync(resizeRequest, options, handler);
    });
  }

  public void cloneAsync(ResizeRequest resizeRequest, RequestOptions options, Handler> handler) { 
    delegate.cloneAsync(resizeRequest, options, handler);
  }

  public Single rxCloneAsync(ResizeRequest resizeRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      cloneAsync(resizeRequest, options, handler);
    });
  }

  public void rolloverAsync(RolloverRequest rolloverRequest, RequestOptions options, Handler> handler) { 
    delegate.rolloverAsync(rolloverRequest, options, handler);
  }

  public Single rxRolloverAsync(RolloverRequest rolloverRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      rolloverAsync(rolloverRequest, options, handler);
    });
  }

  public void getAliasAsync(GetAliasesRequest getAliasesRequest, RequestOptions options, Handler> handler) { 
    delegate.getAliasAsync(getAliasesRequest, options, handler);
  }

  public Single rxGetAliasAsync(GetAliasesRequest getAliasesRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      getAliasAsync(getAliasesRequest, options, handler);
    });
  }

  public void putSettingsAsync(UpdateSettingsRequest updateSettingsRequest, RequestOptions options, Handler> handler) { 
    delegate.putSettingsAsync(updateSettingsRequest, options, handler);
  }

  public Single rxPutSettingsAsync(UpdateSettingsRequest updateSettingsRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      putSettingsAsync(updateSettingsRequest, options, handler);
    });
  }

  public void putTemplateAsync(PutIndexTemplateRequest putIndexTemplateRequest, RequestOptions options, Handler> handler) { 
    delegate.putTemplateAsync(putIndexTemplateRequest, options, handler);
  }

  public Single rxPutTemplateAsync(PutIndexTemplateRequest putIndexTemplateRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      putTemplateAsync(putIndexTemplateRequest, options, handler);
    });
  }

  public void validateQueryAsync(ValidateQueryRequest validateQueryRequest, RequestOptions options, Handler> handler) { 
    delegate.validateQueryAsync(validateQueryRequest, options, handler);
  }

  public Single rxValidateQueryAsync(ValidateQueryRequest validateQueryRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      validateQueryAsync(validateQueryRequest, options, handler);
    });
  }

  public void getIndexTemplateAsync(GetIndexTemplatesRequest getIndexTemplatesRequest, RequestOptions options, Handler> handler) { 
    delegate.getIndexTemplateAsync(getIndexTemplatesRequest, options, handler);
  }

  public Single rxGetIndexTemplateAsync(GetIndexTemplatesRequest getIndexTemplatesRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      getIndexTemplateAsync(getIndexTemplatesRequest, options, handler);
    });
  }

  public void existsTemplateAsync(IndexTemplatesExistRequest indexTemplatesExistRequest, RequestOptions options, Handler> handler) { 
    delegate.existsTemplateAsync(indexTemplatesExistRequest, options, handler);
  }

  public Single rxExistsTemplateAsync(IndexTemplatesExistRequest indexTemplatesExistRequest, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      existsTemplateAsync(indexTemplatesExistRequest, options, handler);
    });
  }

  public void analyzeAsync(AnalyzeRequest request, RequestOptions options, Handler> handler) { 
    delegate.analyzeAsync(request, options, handler);
  }

  public Single rxAnalyzeAsync(AnalyzeRequest request, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      analyzeAsync(request, options, handler);
    });
  }

  public void freezeAsync(FreezeIndexRequest request, RequestOptions options, Handler> handler) { 
    delegate.freezeAsync(request, options, handler);
  }

  public Single rxFreezeAsync(FreezeIndexRequest request, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      freezeAsync(request, options, handler);
    });
  }

  public void unfreezeAsync(UnfreezeIndexRequest request, RequestOptions options, Handler> handler) { 
    delegate.unfreezeAsync(request, options, handler);
  }

  public Single rxUnfreezeAsync(UnfreezeIndexRequest request, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      unfreezeAsync(request, options, handler);
    });
  }

  public void deleteTemplateAsync(DeleteIndexTemplateRequest request, RequestOptions options, Handler> handler) { 
    delegate.deleteTemplateAsync(request, options, handler);
  }

  public Single rxDeleteTemplateAsync(DeleteIndexTemplateRequest request, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      deleteTemplateAsync(request, options, handler);
    });
  }

  public void reloadAnalyzersAsync(ReloadAnalyzersRequest request, RequestOptions options, Handler> handler) { 
    delegate.reloadAnalyzersAsync(request, options, handler);
  }

  public Single rxReloadAnalyzersAsync(ReloadAnalyzersRequest request, RequestOptions options) { 
    return io.vertx.reactivex.impl.AsyncResultSingle.toSingle(handler -> {
      reloadAnalyzersAsync(request, options, handler);
    });
  }


  public static  IndicesClient newInstance(io.reactiverse.elasticsearch.client.IndicesClient arg) {
    return arg != null ? new IndicesClient(arg) : null;
  }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy