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

ru.tinkoff.piapi.contract.v1.MarketDataServiceGrpc Maven / Gradle / Ivy

There is a newer version: 1.25
Show newest version
package ru.tinkoff.piapi.contract.v1;

import static io.grpc.MethodDescriptor.generateFullMethodName;

/**
 * 
 *Сервис получения биржевой информации:</br> **1**. свечи;</br> **2**. стаканы;</br> **3**. торговые статусы;</br> **4**. лента сделок.
 * 
*/ @javax.annotation.Generated( value = "by gRPC proto compiler (version 1.56.1)", comments = "Source: marketdata.proto") @io.grpc.stub.annotations.GrpcGenerated public final class MarketDataServiceGrpc { private MarketDataServiceGrpc() {} public static final String SERVICE_NAME = "tinkoff.public.invest.api.contract.v1.MarketDataService"; // Static method descriptors that strictly reflect the proto. private static volatile io.grpc.MethodDescriptor getGetCandlesMethod; @io.grpc.stub.annotations.RpcMethod( fullMethodName = SERVICE_NAME + '/' + "GetCandles", requestType = ru.tinkoff.piapi.contract.v1.GetCandlesRequest.class, responseType = ru.tinkoff.piapi.contract.v1.GetCandlesResponse.class, methodType = io.grpc.MethodDescriptor.MethodType.UNARY) public static io.grpc.MethodDescriptor getGetCandlesMethod() { io.grpc.MethodDescriptor getGetCandlesMethod; if ((getGetCandlesMethod = MarketDataServiceGrpc.getGetCandlesMethod) == null) { synchronized (MarketDataServiceGrpc.class) { if ((getGetCandlesMethod = MarketDataServiceGrpc.getGetCandlesMethod) == null) { MarketDataServiceGrpc.getGetCandlesMethod = getGetCandlesMethod = io.grpc.MethodDescriptor.newBuilder() .setType(io.grpc.MethodDescriptor.MethodType.UNARY) .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetCandles")) .setSampledToLocalTracing(true) .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( ru.tinkoff.piapi.contract.v1.GetCandlesRequest.getDefaultInstance())) .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( ru.tinkoff.piapi.contract.v1.GetCandlesResponse.getDefaultInstance())) .setSchemaDescriptor(new MarketDataServiceMethodDescriptorSupplier("GetCandles")) .build(); } } } return getGetCandlesMethod; } private static volatile io.grpc.MethodDescriptor getGetLastPricesMethod; @io.grpc.stub.annotations.RpcMethod( fullMethodName = SERVICE_NAME + '/' + "GetLastPrices", requestType = ru.tinkoff.piapi.contract.v1.GetLastPricesRequest.class, responseType = ru.tinkoff.piapi.contract.v1.GetLastPricesResponse.class, methodType = io.grpc.MethodDescriptor.MethodType.UNARY) public static io.grpc.MethodDescriptor getGetLastPricesMethod() { io.grpc.MethodDescriptor getGetLastPricesMethod; if ((getGetLastPricesMethod = MarketDataServiceGrpc.getGetLastPricesMethod) == null) { synchronized (MarketDataServiceGrpc.class) { if ((getGetLastPricesMethod = MarketDataServiceGrpc.getGetLastPricesMethod) == null) { MarketDataServiceGrpc.getGetLastPricesMethod = getGetLastPricesMethod = io.grpc.MethodDescriptor.newBuilder() .setType(io.grpc.MethodDescriptor.MethodType.UNARY) .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetLastPrices")) .setSampledToLocalTracing(true) .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( ru.tinkoff.piapi.contract.v1.GetLastPricesRequest.getDefaultInstance())) .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( ru.tinkoff.piapi.contract.v1.GetLastPricesResponse.getDefaultInstance())) .setSchemaDescriptor(new MarketDataServiceMethodDescriptorSupplier("GetLastPrices")) .build(); } } } return getGetLastPricesMethod; } private static volatile io.grpc.MethodDescriptor getGetOrderBookMethod; @io.grpc.stub.annotations.RpcMethod( fullMethodName = SERVICE_NAME + '/' + "GetOrderBook", requestType = ru.tinkoff.piapi.contract.v1.GetOrderBookRequest.class, responseType = ru.tinkoff.piapi.contract.v1.GetOrderBookResponse.class, methodType = io.grpc.MethodDescriptor.MethodType.UNARY) public static io.grpc.MethodDescriptor getGetOrderBookMethod() { io.grpc.MethodDescriptor getGetOrderBookMethod; if ((getGetOrderBookMethod = MarketDataServiceGrpc.getGetOrderBookMethod) == null) { synchronized (MarketDataServiceGrpc.class) { if ((getGetOrderBookMethod = MarketDataServiceGrpc.getGetOrderBookMethod) == null) { MarketDataServiceGrpc.getGetOrderBookMethod = getGetOrderBookMethod = io.grpc.MethodDescriptor.newBuilder() .setType(io.grpc.MethodDescriptor.MethodType.UNARY) .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetOrderBook")) .setSampledToLocalTracing(true) .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( ru.tinkoff.piapi.contract.v1.GetOrderBookRequest.getDefaultInstance())) .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( ru.tinkoff.piapi.contract.v1.GetOrderBookResponse.getDefaultInstance())) .setSchemaDescriptor(new MarketDataServiceMethodDescriptorSupplier("GetOrderBook")) .build(); } } } return getGetOrderBookMethod; } private static volatile io.grpc.MethodDescriptor getGetTradingStatusMethod; @io.grpc.stub.annotations.RpcMethod( fullMethodName = SERVICE_NAME + '/' + "GetTradingStatus", requestType = ru.tinkoff.piapi.contract.v1.GetTradingStatusRequest.class, responseType = ru.tinkoff.piapi.contract.v1.GetTradingStatusResponse.class, methodType = io.grpc.MethodDescriptor.MethodType.UNARY) public static io.grpc.MethodDescriptor getGetTradingStatusMethod() { io.grpc.MethodDescriptor getGetTradingStatusMethod; if ((getGetTradingStatusMethod = MarketDataServiceGrpc.getGetTradingStatusMethod) == null) { synchronized (MarketDataServiceGrpc.class) { if ((getGetTradingStatusMethod = MarketDataServiceGrpc.getGetTradingStatusMethod) == null) { MarketDataServiceGrpc.getGetTradingStatusMethod = getGetTradingStatusMethod = io.grpc.MethodDescriptor.newBuilder() .setType(io.grpc.MethodDescriptor.MethodType.UNARY) .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetTradingStatus")) .setSampledToLocalTracing(true) .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( ru.tinkoff.piapi.contract.v1.GetTradingStatusRequest.getDefaultInstance())) .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( ru.tinkoff.piapi.contract.v1.GetTradingStatusResponse.getDefaultInstance())) .setSchemaDescriptor(new MarketDataServiceMethodDescriptorSupplier("GetTradingStatus")) .build(); } } } return getGetTradingStatusMethod; } private static volatile io.grpc.MethodDescriptor getGetTradingStatusesMethod; @io.grpc.stub.annotations.RpcMethod( fullMethodName = SERVICE_NAME + '/' + "GetTradingStatuses", requestType = ru.tinkoff.piapi.contract.v1.GetTradingStatusesRequest.class, responseType = ru.tinkoff.piapi.contract.v1.GetTradingStatusesResponse.class, methodType = io.grpc.MethodDescriptor.MethodType.UNARY) public static io.grpc.MethodDescriptor getGetTradingStatusesMethod() { io.grpc.MethodDescriptor getGetTradingStatusesMethod; if ((getGetTradingStatusesMethod = MarketDataServiceGrpc.getGetTradingStatusesMethod) == null) { synchronized (MarketDataServiceGrpc.class) { if ((getGetTradingStatusesMethod = MarketDataServiceGrpc.getGetTradingStatusesMethod) == null) { MarketDataServiceGrpc.getGetTradingStatusesMethod = getGetTradingStatusesMethod = io.grpc.MethodDescriptor.newBuilder() .setType(io.grpc.MethodDescriptor.MethodType.UNARY) .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetTradingStatuses")) .setSampledToLocalTracing(true) .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( ru.tinkoff.piapi.contract.v1.GetTradingStatusesRequest.getDefaultInstance())) .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( ru.tinkoff.piapi.contract.v1.GetTradingStatusesResponse.getDefaultInstance())) .setSchemaDescriptor(new MarketDataServiceMethodDescriptorSupplier("GetTradingStatuses")) .build(); } } } return getGetTradingStatusesMethod; } private static volatile io.grpc.MethodDescriptor getGetLastTradesMethod; @io.grpc.stub.annotations.RpcMethod( fullMethodName = SERVICE_NAME + '/' + "GetLastTrades", requestType = ru.tinkoff.piapi.contract.v1.GetLastTradesRequest.class, responseType = ru.tinkoff.piapi.contract.v1.GetLastTradesResponse.class, methodType = io.grpc.MethodDescriptor.MethodType.UNARY) public static io.grpc.MethodDescriptor getGetLastTradesMethod() { io.grpc.MethodDescriptor getGetLastTradesMethod; if ((getGetLastTradesMethod = MarketDataServiceGrpc.getGetLastTradesMethod) == null) { synchronized (MarketDataServiceGrpc.class) { if ((getGetLastTradesMethod = MarketDataServiceGrpc.getGetLastTradesMethod) == null) { MarketDataServiceGrpc.getGetLastTradesMethod = getGetLastTradesMethod = io.grpc.MethodDescriptor.newBuilder() .setType(io.grpc.MethodDescriptor.MethodType.UNARY) .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetLastTrades")) .setSampledToLocalTracing(true) .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( ru.tinkoff.piapi.contract.v1.GetLastTradesRequest.getDefaultInstance())) .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( ru.tinkoff.piapi.contract.v1.GetLastTradesResponse.getDefaultInstance())) .setSchemaDescriptor(new MarketDataServiceMethodDescriptorSupplier("GetLastTrades")) .build(); } } } return getGetLastTradesMethod; } private static volatile io.grpc.MethodDescriptor getGetClosePricesMethod; @io.grpc.stub.annotations.RpcMethod( fullMethodName = SERVICE_NAME + '/' + "GetClosePrices", requestType = ru.tinkoff.piapi.contract.v1.GetClosePricesRequest.class, responseType = ru.tinkoff.piapi.contract.v1.GetClosePricesResponse.class, methodType = io.grpc.MethodDescriptor.MethodType.UNARY) public static io.grpc.MethodDescriptor getGetClosePricesMethod() { io.grpc.MethodDescriptor getGetClosePricesMethod; if ((getGetClosePricesMethod = MarketDataServiceGrpc.getGetClosePricesMethod) == null) { synchronized (MarketDataServiceGrpc.class) { if ((getGetClosePricesMethod = MarketDataServiceGrpc.getGetClosePricesMethod) == null) { MarketDataServiceGrpc.getGetClosePricesMethod = getGetClosePricesMethod = io.grpc.MethodDescriptor.newBuilder() .setType(io.grpc.MethodDescriptor.MethodType.UNARY) .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetClosePrices")) .setSampledToLocalTracing(true) .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( ru.tinkoff.piapi.contract.v1.GetClosePricesRequest.getDefaultInstance())) .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( ru.tinkoff.piapi.contract.v1.GetClosePricesResponse.getDefaultInstance())) .setSchemaDescriptor(new MarketDataServiceMethodDescriptorSupplier("GetClosePrices")) .build(); } } } return getGetClosePricesMethod; } /** * Creates a new async stub that supports all call types for the service */ public static MarketDataServiceStub newStub(io.grpc.Channel channel) { io.grpc.stub.AbstractStub.StubFactory factory = new io.grpc.stub.AbstractStub.StubFactory() { @java.lang.Override public MarketDataServiceStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new MarketDataServiceStub(channel, callOptions); } }; return MarketDataServiceStub.newStub(factory, channel); } /** * Creates a new blocking-style stub that supports unary and streaming output calls on the service */ public static MarketDataServiceBlockingStub newBlockingStub( io.grpc.Channel channel) { io.grpc.stub.AbstractStub.StubFactory factory = new io.grpc.stub.AbstractStub.StubFactory() { @java.lang.Override public MarketDataServiceBlockingStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new MarketDataServiceBlockingStub(channel, callOptions); } }; return MarketDataServiceBlockingStub.newStub(factory, channel); } /** * Creates a new ListenableFuture-style stub that supports unary calls on the service */ public static MarketDataServiceFutureStub newFutureStub( io.grpc.Channel channel) { io.grpc.stub.AbstractStub.StubFactory factory = new io.grpc.stub.AbstractStub.StubFactory() { @java.lang.Override public MarketDataServiceFutureStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new MarketDataServiceFutureStub(channel, callOptions); } }; return MarketDataServiceFutureStub.newStub(factory, channel); } /** *
   *Сервис получения биржевой информации:</br> **1**. свечи;</br> **2**. стаканы;</br> **3**. торговые статусы;</br> **4**. лента сделок.
   * 
*/ public interface AsyncService { /** *
     *Метод запроса исторических свечей по инструменту.
     * 
*/ default void getCandles(ru.tinkoff.piapi.contract.v1.GetCandlesRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetCandlesMethod(), responseObserver); } /** *
     *Метод запроса цен последних сделок по инструментам.
     * 
*/ default void getLastPrices(ru.tinkoff.piapi.contract.v1.GetLastPricesRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetLastPricesMethod(), responseObserver); } /** *
     *Метод получения стакана по инструменту.
     * 
*/ default void getOrderBook(ru.tinkoff.piapi.contract.v1.GetOrderBookRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetOrderBookMethod(), responseObserver); } /** *
     *Метод запроса статуса торгов по инструментам.
     * 
*/ default void getTradingStatus(ru.tinkoff.piapi.contract.v1.GetTradingStatusRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetTradingStatusMethod(), responseObserver); } /** *
     *Метод запроса статуса торгов по инструментам.
     * 
*/ default void getTradingStatuses(ru.tinkoff.piapi.contract.v1.GetTradingStatusesRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetTradingStatusesMethod(), responseObserver); } /** *
     *Метод запроса обезличенных сделок за последний час.
     * 
*/ default void getLastTrades(ru.tinkoff.piapi.contract.v1.GetLastTradesRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetLastTradesMethod(), responseObserver); } /** *
     *Метод запроса цен закрытия торговой сессии по инструментам.
     * 
*/ default void getClosePrices(ru.tinkoff.piapi.contract.v1.GetClosePricesRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetClosePricesMethod(), responseObserver); } } /** * Base class for the server implementation of the service MarketDataService. *
   *Сервис получения биржевой информации:</br> **1**. свечи;</br> **2**. стаканы;</br> **3**. торговые статусы;</br> **4**. лента сделок.
   * 
*/ public static abstract class MarketDataServiceImplBase implements io.grpc.BindableService, AsyncService { @java.lang.Override public final io.grpc.ServerServiceDefinition bindService() { return MarketDataServiceGrpc.bindService(this); } } /** * A stub to allow clients to do asynchronous rpc calls to service MarketDataService. *
   *Сервис получения биржевой информации:</br> **1**. свечи;</br> **2**. стаканы;</br> **3**. торговые статусы;</br> **4**. лента сделок.
   * 
*/ public static final class MarketDataServiceStub extends io.grpc.stub.AbstractAsyncStub { private MarketDataServiceStub( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } @java.lang.Override protected MarketDataServiceStub build( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new MarketDataServiceStub(channel, callOptions); } /** *
     *Метод запроса исторических свечей по инструменту.
     * 
*/ public void getCandles(ru.tinkoff.piapi.contract.v1.GetCandlesRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ClientCalls.asyncUnaryCall( getChannel().newCall(getGetCandlesMethod(), getCallOptions()), request, responseObserver); } /** *
     *Метод запроса цен последних сделок по инструментам.
     * 
*/ public void getLastPrices(ru.tinkoff.piapi.contract.v1.GetLastPricesRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ClientCalls.asyncUnaryCall( getChannel().newCall(getGetLastPricesMethod(), getCallOptions()), request, responseObserver); } /** *
     *Метод получения стакана по инструменту.
     * 
*/ public void getOrderBook(ru.tinkoff.piapi.contract.v1.GetOrderBookRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ClientCalls.asyncUnaryCall( getChannel().newCall(getGetOrderBookMethod(), getCallOptions()), request, responseObserver); } /** *
     *Метод запроса статуса торгов по инструментам.
     * 
*/ public void getTradingStatus(ru.tinkoff.piapi.contract.v1.GetTradingStatusRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ClientCalls.asyncUnaryCall( getChannel().newCall(getGetTradingStatusMethod(), getCallOptions()), request, responseObserver); } /** *
     *Метод запроса статуса торгов по инструментам.
     * 
*/ public void getTradingStatuses(ru.tinkoff.piapi.contract.v1.GetTradingStatusesRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ClientCalls.asyncUnaryCall( getChannel().newCall(getGetTradingStatusesMethod(), getCallOptions()), request, responseObserver); } /** *
     *Метод запроса обезличенных сделок за последний час.
     * 
*/ public void getLastTrades(ru.tinkoff.piapi.contract.v1.GetLastTradesRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ClientCalls.asyncUnaryCall( getChannel().newCall(getGetLastTradesMethod(), getCallOptions()), request, responseObserver); } /** *
     *Метод запроса цен закрытия торговой сессии по инструментам.
     * 
*/ public void getClosePrices(ru.tinkoff.piapi.contract.v1.GetClosePricesRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ClientCalls.asyncUnaryCall( getChannel().newCall(getGetClosePricesMethod(), getCallOptions()), request, responseObserver); } } /** * A stub to allow clients to do synchronous rpc calls to service MarketDataService. *
   *Сервис получения биржевой информации:</br> **1**. свечи;</br> **2**. стаканы;</br> **3**. торговые статусы;</br> **4**. лента сделок.
   * 
*/ public static final class MarketDataServiceBlockingStub extends io.grpc.stub.AbstractBlockingStub { private MarketDataServiceBlockingStub( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } @java.lang.Override protected MarketDataServiceBlockingStub build( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new MarketDataServiceBlockingStub(channel, callOptions); } /** *
     *Метод запроса исторических свечей по инструменту.
     * 
*/ public ru.tinkoff.piapi.contract.v1.GetCandlesResponse getCandles(ru.tinkoff.piapi.contract.v1.GetCandlesRequest request) { return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getGetCandlesMethod(), getCallOptions(), request); } /** *
     *Метод запроса цен последних сделок по инструментам.
     * 
*/ public ru.tinkoff.piapi.contract.v1.GetLastPricesResponse getLastPrices(ru.tinkoff.piapi.contract.v1.GetLastPricesRequest request) { return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getGetLastPricesMethod(), getCallOptions(), request); } /** *
     *Метод получения стакана по инструменту.
     * 
*/ public ru.tinkoff.piapi.contract.v1.GetOrderBookResponse getOrderBook(ru.tinkoff.piapi.contract.v1.GetOrderBookRequest request) { return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getGetOrderBookMethod(), getCallOptions(), request); } /** *
     *Метод запроса статуса торгов по инструментам.
     * 
*/ public ru.tinkoff.piapi.contract.v1.GetTradingStatusResponse getTradingStatus(ru.tinkoff.piapi.contract.v1.GetTradingStatusRequest request) { return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getGetTradingStatusMethod(), getCallOptions(), request); } /** *
     *Метод запроса статуса торгов по инструментам.
     * 
*/ public ru.tinkoff.piapi.contract.v1.GetTradingStatusesResponse getTradingStatuses(ru.tinkoff.piapi.contract.v1.GetTradingStatusesRequest request) { return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getGetTradingStatusesMethod(), getCallOptions(), request); } /** *
     *Метод запроса обезличенных сделок за последний час.
     * 
*/ public ru.tinkoff.piapi.contract.v1.GetLastTradesResponse getLastTrades(ru.tinkoff.piapi.contract.v1.GetLastTradesRequest request) { return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getGetLastTradesMethod(), getCallOptions(), request); } /** *
     *Метод запроса цен закрытия торговой сессии по инструментам.
     * 
*/ public ru.tinkoff.piapi.contract.v1.GetClosePricesResponse getClosePrices(ru.tinkoff.piapi.contract.v1.GetClosePricesRequest request) { return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getGetClosePricesMethod(), getCallOptions(), request); } } /** * A stub to allow clients to do ListenableFuture-style rpc calls to service MarketDataService. *
   *Сервис получения биржевой информации:</br> **1**. свечи;</br> **2**. стаканы;</br> **3**. торговые статусы;</br> **4**. лента сделок.
   * 
*/ public static final class MarketDataServiceFutureStub extends io.grpc.stub.AbstractFutureStub { private MarketDataServiceFutureStub( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } @java.lang.Override protected MarketDataServiceFutureStub build( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new MarketDataServiceFutureStub(channel, callOptions); } /** *
     *Метод запроса исторических свечей по инструменту.
     * 
*/ public com.google.common.util.concurrent.ListenableFuture getCandles( ru.tinkoff.piapi.contract.v1.GetCandlesRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getGetCandlesMethod(), getCallOptions()), request); } /** *
     *Метод запроса цен последних сделок по инструментам.
     * 
*/ public com.google.common.util.concurrent.ListenableFuture getLastPrices( ru.tinkoff.piapi.contract.v1.GetLastPricesRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getGetLastPricesMethod(), getCallOptions()), request); } /** *
     *Метод получения стакана по инструменту.
     * 
*/ public com.google.common.util.concurrent.ListenableFuture getOrderBook( ru.tinkoff.piapi.contract.v1.GetOrderBookRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getGetOrderBookMethod(), getCallOptions()), request); } /** *
     *Метод запроса статуса торгов по инструментам.
     * 
*/ public com.google.common.util.concurrent.ListenableFuture getTradingStatus( ru.tinkoff.piapi.contract.v1.GetTradingStatusRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getGetTradingStatusMethod(), getCallOptions()), request); } /** *
     *Метод запроса статуса торгов по инструментам.
     * 
*/ public com.google.common.util.concurrent.ListenableFuture getTradingStatuses( ru.tinkoff.piapi.contract.v1.GetTradingStatusesRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getGetTradingStatusesMethod(), getCallOptions()), request); } /** *
     *Метод запроса обезличенных сделок за последний час.
     * 
*/ public com.google.common.util.concurrent.ListenableFuture getLastTrades( ru.tinkoff.piapi.contract.v1.GetLastTradesRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getGetLastTradesMethod(), getCallOptions()), request); } /** *
     *Метод запроса цен закрытия торговой сессии по инструментам.
     * 
*/ public com.google.common.util.concurrent.ListenableFuture getClosePrices( ru.tinkoff.piapi.contract.v1.GetClosePricesRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getGetClosePricesMethod(), getCallOptions()), request); } } private static final int METHODID_GET_CANDLES = 0; private static final int METHODID_GET_LAST_PRICES = 1; private static final int METHODID_GET_ORDER_BOOK = 2; private static final int METHODID_GET_TRADING_STATUS = 3; private static final int METHODID_GET_TRADING_STATUSES = 4; private static final int METHODID_GET_LAST_TRADES = 5; private static final int METHODID_GET_CLOSE_PRICES = 6; private static final class MethodHandlers implements io.grpc.stub.ServerCalls.UnaryMethod, io.grpc.stub.ServerCalls.ServerStreamingMethod, io.grpc.stub.ServerCalls.ClientStreamingMethod, io.grpc.stub.ServerCalls.BidiStreamingMethod { private final AsyncService serviceImpl; private final int methodId; MethodHandlers(AsyncService serviceImpl, int methodId) { this.serviceImpl = serviceImpl; this.methodId = methodId; } @java.lang.Override @java.lang.SuppressWarnings("unchecked") public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) { switch (methodId) { case METHODID_GET_CANDLES: serviceImpl.getCandles((ru.tinkoff.piapi.contract.v1.GetCandlesRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; case METHODID_GET_LAST_PRICES: serviceImpl.getLastPrices((ru.tinkoff.piapi.contract.v1.GetLastPricesRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; case METHODID_GET_ORDER_BOOK: serviceImpl.getOrderBook((ru.tinkoff.piapi.contract.v1.GetOrderBookRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; case METHODID_GET_TRADING_STATUS: serviceImpl.getTradingStatus((ru.tinkoff.piapi.contract.v1.GetTradingStatusRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; case METHODID_GET_TRADING_STATUSES: serviceImpl.getTradingStatuses((ru.tinkoff.piapi.contract.v1.GetTradingStatusesRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; case METHODID_GET_LAST_TRADES: serviceImpl.getLastTrades((ru.tinkoff.piapi.contract.v1.GetLastTradesRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; case METHODID_GET_CLOSE_PRICES: serviceImpl.getClosePrices((ru.tinkoff.piapi.contract.v1.GetClosePricesRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; default: throw new AssertionError(); } } @java.lang.Override @java.lang.SuppressWarnings("unchecked") public io.grpc.stub.StreamObserver invoke( io.grpc.stub.StreamObserver responseObserver) { switch (methodId) { default: throw new AssertionError(); } } } public static final io.grpc.ServerServiceDefinition bindService(AsyncService service) { return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) .addMethod( getGetCandlesMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( new MethodHandlers< ru.tinkoff.piapi.contract.v1.GetCandlesRequest, ru.tinkoff.piapi.contract.v1.GetCandlesResponse>( service, METHODID_GET_CANDLES))) .addMethod( getGetLastPricesMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( new MethodHandlers< ru.tinkoff.piapi.contract.v1.GetLastPricesRequest, ru.tinkoff.piapi.contract.v1.GetLastPricesResponse>( service, METHODID_GET_LAST_PRICES))) .addMethod( getGetOrderBookMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( new MethodHandlers< ru.tinkoff.piapi.contract.v1.GetOrderBookRequest, ru.tinkoff.piapi.contract.v1.GetOrderBookResponse>( service, METHODID_GET_ORDER_BOOK))) .addMethod( getGetTradingStatusMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( new MethodHandlers< ru.tinkoff.piapi.contract.v1.GetTradingStatusRequest, ru.tinkoff.piapi.contract.v1.GetTradingStatusResponse>( service, METHODID_GET_TRADING_STATUS))) .addMethod( getGetTradingStatusesMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( new MethodHandlers< ru.tinkoff.piapi.contract.v1.GetTradingStatusesRequest, ru.tinkoff.piapi.contract.v1.GetTradingStatusesResponse>( service, METHODID_GET_TRADING_STATUSES))) .addMethod( getGetLastTradesMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( new MethodHandlers< ru.tinkoff.piapi.contract.v1.GetLastTradesRequest, ru.tinkoff.piapi.contract.v1.GetLastTradesResponse>( service, METHODID_GET_LAST_TRADES))) .addMethod( getGetClosePricesMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( new MethodHandlers< ru.tinkoff.piapi.contract.v1.GetClosePricesRequest, ru.tinkoff.piapi.contract.v1.GetClosePricesResponse>( service, METHODID_GET_CLOSE_PRICES))) .build(); } private static abstract class MarketDataServiceBaseDescriptorSupplier implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier { MarketDataServiceBaseDescriptorSupplier() {} @java.lang.Override public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { return ru.tinkoff.piapi.contract.v1.Marketdata.getDescriptor(); } @java.lang.Override public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { return getFileDescriptor().findServiceByName("MarketDataService"); } } private static final class MarketDataServiceFileDescriptorSupplier extends MarketDataServiceBaseDescriptorSupplier { MarketDataServiceFileDescriptorSupplier() {} } private static final class MarketDataServiceMethodDescriptorSupplier extends MarketDataServiceBaseDescriptorSupplier implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { private final String methodName; MarketDataServiceMethodDescriptorSupplier(String methodName) { this.methodName = methodName; } @java.lang.Override public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() { return getServiceDescriptor().findMethodByName(methodName); } } private static volatile io.grpc.ServiceDescriptor serviceDescriptor; public static io.grpc.ServiceDescriptor getServiceDescriptor() { io.grpc.ServiceDescriptor result = serviceDescriptor; if (result == null) { synchronized (MarketDataServiceGrpc.class) { result = serviceDescriptor; if (result == null) { serviceDescriptor = result = io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) .setSchemaDescriptor(new MarketDataServiceFileDescriptorSupplier()) .addMethod(getGetCandlesMethod()) .addMethod(getGetLastPricesMethod()) .addMethod(getGetOrderBookMethod()) .addMethod(getGetTradingStatusMethod()) .addMethod(getGetTradingStatusesMethod()) .addMethod(getGetLastTradesMethod()) .addMethod(getGetClosePricesMethod()) .build(); } } } return result; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy