Files
spark/src/client/spark_api/api/ClientChannel.cs
T

22 lines
800 B
C#

using Google.Protobuf;
using System;
using System.Threading.Tasks;
namespace bts.api.core {
internal abstract class ClientChannel : IDisposable
{
protected readonly ServiceContext _context;
public ClientChannel(ServiceContext context) {
_context = context;
}
public abstract void Dispose();
public abstract Task<Result<Response>> send<Request, Response>(int method_id, Request request)
where Request: IImmutableMessage where Response : class,IMessage,new();
public abstract IObservable<RawUpdate<TOut>> subscribe<TParse,TOut>(int method_id, string method, string qualifier, MessageParser<TParse> parser, Func<TParse,TOut> converter=null)
where TParse : IMessage<TParse>;
public abstract bool is_sync_call_ok();
}
}