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

tech.ydb.query.QueryStream Maven / Gradle / Ivy

There is a newer version: 2.3.0
Show newest version
package tech.ydb.query;

import java.util.concurrent.CompletableFuture;

import io.grpc.ExperimentalApi;

import tech.ydb.core.Issue;
import tech.ydb.core.Result;
import tech.ydb.query.result.QueryInfo;
import tech.ydb.query.result.QueryResultPart;

/**
 *
 * @author Aleksandr Gorshenin
 */
@ExperimentalApi("QueryService is experimental and API may change without notice")
public interface QueryStream {
    interface PartsHandler {
        default void onIssues(Issue[] issues) { }
        void onNextPart(QueryResultPart part);
    }

    CompletableFuture> execute(PartsHandler handler);

    void cancel();

    default CompletableFuture> execute() {
        return execute(null);
    };
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy