//
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: lobby.proto
//
#pragma warning disable 0414, 1591
#region Designer generated code
using grpc = global::Grpc.Core;
namespace Lobby {
///
/// Lobby functionality (client_id required for most of them)
///
public static partial class Lobby
{
static readonly string __ServiceName = "lobby.Lobby";
static void __Helper_SerializeMessage(global::Google.Protobuf.IMessage message, grpc::SerializationContext context)
{
#if !GRPC_DISABLE_PROTOBUF_BUFFER_SERIALIZATION
if (message is global::Google.Protobuf.IBufferMessage)
{
context.SetPayloadLength(message.CalculateSize());
global::Google.Protobuf.MessageExtensions.WriteTo(message, context.GetBufferWriter());
context.Complete();
return;
}
#endif
context.Complete(global::Google.Protobuf.MessageExtensions.ToByteArray(message));
}
static class __Helper_MessageCache
{
public static readonly bool IsBufferMessage = global::System.Reflection.IntrospectionExtensions.GetTypeInfo(typeof(global::Google.Protobuf.IBufferMessage)).IsAssignableFrom(typeof(T));
}
static T __Helper_DeserializeMessage(grpc::DeserializationContext context, global::Google.Protobuf.MessageParser parser) where T : global::Google.Protobuf.IMessage
{
#if !GRPC_DISABLE_PROTOBUF_BUFFER_SERIALIZATION
if (__Helper_MessageCache.IsBufferMessage)
{
return parser.ParseFrom(context.PayloadAsReadOnlySequence());
}
#endif
return parser.ParseFrom(context.PayloadAsNewBuffer());
}
static readonly grpc::Marshaller __Marshaller_lobby_CardID = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Lobby.CardID.Parser));
static readonly grpc::Marshaller __Marshaller_lobby_Image = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Lobby.Image.Parser));
static readonly grpc::Marshaller __Marshaller_google_protobuf_Empty = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Protobuf.WellKnownTypes.Empty.Parser));
static readonly grpc::Marshaller __Marshaller_common_Name = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Common.Name.Parser));
static readonly grpc::Marshaller __Marshaller_lobby_SingleVote = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Lobby.SingleVote.Parser));
static readonly grpc::Marshaller __Marshaller_lobby_LastStatusTimestamp = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Lobby.LastStatusTimestamp.Parser));
static readonly grpc::Marshaller __Marshaller_lobby_HasNewStatus = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Lobby.HasNewStatus.Parser));
static readonly grpc::Marshaller __Marshaller_lobby_LobbyStatus = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Lobby.LobbyStatus.Parser));
static readonly grpc::Method __Method_getCardImage = new grpc::Method(
grpc::MethodType.Unary,
__ServiceName,
"getCardImage",
__Marshaller_lobby_CardID,
__Marshaller_lobby_Image);
static readonly grpc::Method __Method_users = new grpc::Method(
grpc::MethodType.ServerStreaming,
__ServiceName,
"users",
__Marshaller_google_protobuf_Empty,
__Marshaller_common_Name);
static readonly grpc::Method __Method_vote = new grpc::Method(
grpc::MethodType.Unary,
__ServiceName,
"vote",
__Marshaller_lobby_SingleVote,
__Marshaller_google_protobuf_Empty);
static readonly grpc::Method __Method_ready = new grpc::Method(
grpc::MethodType.Unary,
__ServiceName,
"ready",
__Marshaller_google_protobuf_Empty,
__Marshaller_google_protobuf_Empty);
static readonly grpc::Method __Method_hasNewStatus = new grpc::Method(
grpc::MethodType.Unary,
__ServiceName,
"hasNewStatus",
__Marshaller_lobby_LastStatusTimestamp,
__Marshaller_lobby_HasNewStatus);
static readonly grpc::Method __Method_getStatus = new grpc::Method(
grpc::MethodType.Unary,
__ServiceName,
"getStatus",
__Marshaller_google_protobuf_Empty,
__Marshaller_lobby_LobbyStatus);
static readonly grpc::Method __Method_leave = new grpc::Method(
grpc::MethodType.Unary,
__ServiceName,
"leave",
__Marshaller_google_protobuf_Empty,
__Marshaller_google_protobuf_Empty);
/// Service descriptor
public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor
{
get { return global::Lobby.LobbyReflection.Descriptor.Services[0]; }
}
/// Base class for server-side implementations of Lobby
[grpc::BindServiceMethod(typeof(Lobby), "BindService")]
public abstract partial class LobbyBase
{
public virtual global::System.Threading.Tasks.Task getCardImage(global::Lobby.CardID request, grpc::ServerCallContext context)
{
throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
}
public virtual global::System.Threading.Tasks.Task users(global::Google.Protobuf.WellKnownTypes.Empty request, grpc::IServerStreamWriter responseStream, grpc::ServerCallContext context)
{
throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
}
public virtual global::System.Threading.Tasks.Task vote(global::Lobby.SingleVote request, grpc::ServerCallContext context)
{
throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
}
public virtual global::System.Threading.Tasks.Task ready(global::Google.Protobuf.WellKnownTypes.Empty request, grpc::ServerCallContext context)
{
throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
}
public virtual global::System.Threading.Tasks.Task hasNewStatus(global::Lobby.LastStatusTimestamp request, grpc::ServerCallContext context)
{
throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
}
public virtual global::System.Threading.Tasks.Task getStatus(global::Google.Protobuf.WellKnownTypes.Empty request, grpc::ServerCallContext context)
{
throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
}
public virtual global::System.Threading.Tasks.Task leave(global::Google.Protobuf.WellKnownTypes.Empty request, grpc::ServerCallContext context)
{
throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
}
}
/// Client for Lobby
public partial class LobbyClient : grpc::ClientBase
{
/// Creates a new client for Lobby
/// The channel to use to make remote calls.
public LobbyClient(grpc::ChannelBase channel) : base(channel)
{
}
/// Creates a new client for Lobby that uses a custom CallInvoker.
/// The callInvoker to use to make remote calls.
public LobbyClient(grpc::CallInvoker callInvoker) : base(callInvoker)
{
}
/// Protected parameterless constructor to allow creation of test doubles.
protected LobbyClient() : base()
{
}
/// Protected constructor to allow creation of configured clients.
/// The client configuration.
protected LobbyClient(ClientBaseConfiguration configuration) : base(configuration)
{
}
public virtual global::Lobby.Image getCardImage(global::Lobby.CardID request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
{
return getCardImage(request, new grpc::CallOptions(headers, deadline, cancellationToken));
}
public virtual global::Lobby.Image getCardImage(global::Lobby.CardID request, grpc::CallOptions options)
{
return CallInvoker.BlockingUnaryCall(__Method_getCardImage, null, options, request);
}
public virtual grpc::AsyncUnaryCall getCardImageAsync(global::Lobby.CardID request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
{
return getCardImageAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
}
public virtual grpc::AsyncUnaryCall getCardImageAsync(global::Lobby.CardID request, grpc::CallOptions options)
{
return CallInvoker.AsyncUnaryCall(__Method_getCardImage, null, options, request);
}
public virtual grpc::AsyncServerStreamingCall users(global::Google.Protobuf.WellKnownTypes.Empty request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
{
return users(request, new grpc::CallOptions(headers, deadline, cancellationToken));
}
public virtual grpc::AsyncServerStreamingCall users(global::Google.Protobuf.WellKnownTypes.Empty request, grpc::CallOptions options)
{
return CallInvoker.AsyncServerStreamingCall(__Method_users, null, options, request);
}
public virtual global::Google.Protobuf.WellKnownTypes.Empty vote(global::Lobby.SingleVote request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
{
return vote(request, new grpc::CallOptions(headers, deadline, cancellationToken));
}
public virtual global::Google.Protobuf.WellKnownTypes.Empty vote(global::Lobby.SingleVote request, grpc::CallOptions options)
{
return CallInvoker.BlockingUnaryCall(__Method_vote, null, options, request);
}
public virtual grpc::AsyncUnaryCall voteAsync(global::Lobby.SingleVote request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
{
return voteAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
}
public virtual grpc::AsyncUnaryCall voteAsync(global::Lobby.SingleVote request, grpc::CallOptions options)
{
return CallInvoker.AsyncUnaryCall(__Method_vote, null, options, request);
}
public virtual global::Google.Protobuf.WellKnownTypes.Empty ready(global::Google.Protobuf.WellKnownTypes.Empty request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
{
return ready(request, new grpc::CallOptions(headers, deadline, cancellationToken));
}
public virtual global::Google.Protobuf.WellKnownTypes.Empty ready(global::Google.Protobuf.WellKnownTypes.Empty request, grpc::CallOptions options)
{
return CallInvoker.BlockingUnaryCall(__Method_ready, null, options, request);
}
public virtual grpc::AsyncUnaryCall readyAsync(global::Google.Protobuf.WellKnownTypes.Empty request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
{
return readyAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
}
public virtual grpc::AsyncUnaryCall readyAsync(global::Google.Protobuf.WellKnownTypes.Empty request, grpc::CallOptions options)
{
return CallInvoker.AsyncUnaryCall(__Method_ready, null, options, request);
}
public virtual global::Lobby.HasNewStatus hasNewStatus(global::Lobby.LastStatusTimestamp request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
{
return hasNewStatus(request, new grpc::CallOptions(headers, deadline, cancellationToken));
}
public virtual global::Lobby.HasNewStatus hasNewStatus(global::Lobby.LastStatusTimestamp request, grpc::CallOptions options)
{
return CallInvoker.BlockingUnaryCall(__Method_hasNewStatus, null, options, request);
}
public virtual grpc::AsyncUnaryCall hasNewStatusAsync(global::Lobby.LastStatusTimestamp request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
{
return hasNewStatusAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
}
public virtual grpc::AsyncUnaryCall hasNewStatusAsync(global::Lobby.LastStatusTimestamp request, grpc::CallOptions options)
{
return CallInvoker.AsyncUnaryCall(__Method_hasNewStatus, null, options, request);
}
public virtual global::Lobby.LobbyStatus getStatus(global::Google.Protobuf.WellKnownTypes.Empty request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
{
return getStatus(request, new grpc::CallOptions(headers, deadline, cancellationToken));
}
public virtual global::Lobby.LobbyStatus getStatus(global::Google.Protobuf.WellKnownTypes.Empty request, grpc::CallOptions options)
{
return CallInvoker.BlockingUnaryCall(__Method_getStatus, null, options, request);
}
public virtual grpc::AsyncUnaryCall getStatusAsync(global::Google.Protobuf.WellKnownTypes.Empty request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
{
return getStatusAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
}
public virtual grpc::AsyncUnaryCall getStatusAsync(global::Google.Protobuf.WellKnownTypes.Empty request, grpc::CallOptions options)
{
return CallInvoker.AsyncUnaryCall(__Method_getStatus, null, options, request);
}
public virtual global::Google.Protobuf.WellKnownTypes.Empty leave(global::Google.Protobuf.WellKnownTypes.Empty request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
{
return leave(request, new grpc::CallOptions(headers, deadline, cancellationToken));
}
public virtual global::Google.Protobuf.WellKnownTypes.Empty leave(global::Google.Protobuf.WellKnownTypes.Empty request, grpc::CallOptions options)
{
return CallInvoker.BlockingUnaryCall(__Method_leave, null, options, request);
}
public virtual grpc::AsyncUnaryCall leaveAsync(global::Google.Protobuf.WellKnownTypes.Empty request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
{
return leaveAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
}
public virtual grpc::AsyncUnaryCall leaveAsync(global::Google.Protobuf.WellKnownTypes.Empty request, grpc::CallOptions options)
{
return CallInvoker.AsyncUnaryCall(__Method_leave, null, options, request);
}
/// Creates a new instance of client from given ClientBaseConfiguration.
protected override LobbyClient NewInstance(ClientBaseConfiguration configuration)
{
return new LobbyClient(configuration);
}
}
/// Creates service definition that can be registered with a server
/// An object implementing the server-side handling logic.
public static grpc::ServerServiceDefinition BindService(LobbyBase serviceImpl)
{
return grpc::ServerServiceDefinition.CreateBuilder()
.AddMethod(__Method_getCardImage, serviceImpl.getCardImage)
.AddMethod(__Method_users, serviceImpl.users)
.AddMethod(__Method_vote, serviceImpl.vote)
.AddMethod(__Method_ready, serviceImpl.ready)
.AddMethod(__Method_hasNewStatus, serviceImpl.hasNewStatus)
.AddMethod(__Method_getStatus, serviceImpl.getStatus)
.AddMethod(__Method_leave, serviceImpl.leave).Build();
}
/// Register service method with a service binder with or without implementation. Useful when customizing the service binding logic.
/// Note: this method is part of an experimental API that can change or be removed without any prior notice.
/// Service methods will be bound by calling AddMethod on this object.
/// An object implementing the server-side handling logic.
public static void BindService(grpc::ServiceBinderBase serviceBinder, LobbyBase serviceImpl)
{
serviceBinder.AddMethod(__Method_getCardImage, serviceImpl == null ? null : new grpc::UnaryServerMethod(serviceImpl.getCardImage));
serviceBinder.AddMethod(__Method_users, serviceImpl == null ? null : new grpc::ServerStreamingServerMethod(serviceImpl.users));
serviceBinder.AddMethod(__Method_vote, serviceImpl == null ? null : new grpc::UnaryServerMethod(serviceImpl.vote));
serviceBinder.AddMethod(__Method_ready, serviceImpl == null ? null : new grpc::UnaryServerMethod(serviceImpl.ready));
serviceBinder.AddMethod(__Method_hasNewStatus, serviceImpl == null ? null : new grpc::UnaryServerMethod(serviceImpl.hasNewStatus));
serviceBinder.AddMethod(__Method_getStatus, serviceImpl == null ? null : new grpc::UnaryServerMethod(serviceImpl.getStatus));
serviceBinder.AddMethod(__Method_leave, serviceImpl == null ? null : new grpc::UnaryServerMethod(serviceImpl.leave));
}
}
}
#endregion