text:
using grpc = global::Grpc.Core;

namespace Google.Cloud.Redis.V1Beta1 {
  ///
  /// Configures and manages Cloud Memorystore for Redis instances
  ///
  /// Google Cloud Memorystore for Redis v1beta1
  ///
  /// The `redis.googleapis.com` service implements the Google Cloud Memorystore
  /// for Redis API and defines the following resource model for managing Redis
  /// instances:
  /// * The service works with a collection of cloud projects, named: `/projects/*`
  /// * Each project has a collection of available locations, named: `/locations/*`
  /// * Each location has a collection of Redis instances, named: `/instances/*`
  /// * As such, Redis instances are resources of the form:
  ///   `/projects/{project_id}/locations/{location_id}/instances/{instance_id}`
  ///
  /// Note that location_id must be referring to a GCP `region`; for example:
  /// * `projects/redpepper-1290/locations/us-central1/instances/my-redis`
  ///
  public static partial class CloudRedis
  {
    static readonly string __ServiceName = "google.cloud.redis.v1beta1.CloudRedis";

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    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));
    }

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static class __Helper_MessageCache<T>
    {
      public static readonly bool IsBufferMessage = global::System.Reflection.IntrospectionExtensions.GetTypeInfo(typeof(global::Google.Protobuf.IBufferMessage)).IsAssignableFrom(typeof(T));
    }

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static T __Helper_DeserializeMessage<T>(grpc::DeserializationContext context, global::Google.Protobuf.MessageParser<T> parser) where T : global::Google.Protobuf.IMessage<T>
    {
      #if !GRPC_DISABLE_PROTOBUF_BUFFER_SERIALIZATION
      if (__Helper_MessageCache<T>.IsBufferMessage)
      {
        return parser.ParseFrom(context.PayloadAsReadOnlySequence());
      }
      #endif
      return parser.ParseFrom(context.PayloadAsNewBuffer());
    }

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Cloud.Redis.V1Beta1.ListInstancesRequest> __Marshaller_google_cloud_redis_v1beta1_ListInstancesRequest = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Cloud.Redis.V1Beta1.ListInstancesRequest.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Cloud.Redis.V1Beta1.ListInstancesResponse> __Marshaller_google_cloud_redis_v1beta1_ListInstancesResponse = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Cloud.Redis.V1Beta1.ListInstancesResponse.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Cloud.Redis.V1Beta1.GetInstanceRequest> __Marshaller_google_cloud_redis_v1beta1_GetInstanceRequest = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Cloud.Redis.V1Beta1.GetInstanceRequest.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Cloud.Redis.V1Beta1.Instance> __Marshaller_google_cloud_redis_v1beta1_Instance = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Cloud.Redis.V1Beta1.Instance.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Cloud.Redis.V1Beta1.GetInstanceAuthStringRequest> __Marshaller_google_cloud_redis_v1beta1_GetInstanceAuthStringRequest = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Cloud.Redis.V1Beta1.GetInstanceAuthStringRequest.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Cloud.Redis.V1Beta1.InstanceAuthString> __Marshaller_google_cloud_redis_v1beta1_InstanceAuthString = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Cloud.Redis.V1Beta1.InstanceAuthString.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Cloud.Redis.V1Beta1.CreateInstanceRequest> __Marshaller_google_cloud_redis_v1beta1_CreateInstanceRequest = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Cloud.Redis.V1Beta1.CreateInstanceRequest.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.LongRunning.Operation> __Marshaller_google_longrunning_Operation = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.LongRunning.Operation.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Cloud.Redis.V1Beta1.UpdateInstanceRequest> __Marshaller_google_cloud_redis_v1beta1_UpdateInstanceRequest = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Cloud.Redis.V1Beta1.UpdateInstanceRequest.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Cloud.Redis.V1Beta1.UpgradeInstanceRequest> __Marshaller_google_cloud_redis_v1beta1_UpgradeInstanceRequest = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Cloud.Redis.V1Beta1.UpgradeInstanceRequest.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Cloud.Redis.V1Beta1.ImportInstanceRequest> __Marshaller_google_cloud_redis_v1beta1_ImportInstanceRequest = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Cloud.Redis.V1Beta1.ImportInstanceRequest.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Cloud.Redis.V1Beta1.ExportInstanceRequest> __Marshaller_google_cloud_redis_v1beta1_ExportInstanceRequest = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Cloud.Redis.V1Beta1.ExportInstanceRequest.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Cloud.Redis.V1Beta1.FailoverInstanceRequest> __Marshaller_google_cloud_redis_v1beta1_FailoverInstanceRequest = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Cloud.Redis.V1Beta1.FailoverInstanceRequest.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Cloud.Redis.V1Beta1.DeleteInstanceRequest> __Marshaller_google_cloud_redis_v1beta1_DeleteInstanceRequest = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Cloud.Redis.V1Beta1.DeleteInstanceRequest.Parser));
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Marshaller<global::Google.Cloud.Redis.V1Beta1.RescheduleMaintenanceRequest> __Marshaller_google_cloud_redis_v1beta1_RescheduleMaintenanceRequest = grpc::Marshallers.Create(__Helper_SerializeMessage, context => __Helper_DeserializeMessage(context, global::Google.Cloud.Redis.V1Beta1.RescheduleMaintenanceRequest.Parser));

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Method<global::Google.Cloud.Redis.V1Beta1.ListInstancesRequest, global::Google.Cloud.Redis.V1Beta1.ListInstancesResponse> __Method_ListInstances = new grpc::Method<global::Google.Cloud.Redis.V1Beta1.ListInstancesRequest, global::Google.Cloud.Redis.V1Beta1.ListInstancesResponse>(
        grpc::MethodType.Unary,
        __ServiceName,
        "ListInstances",
        __Marshaller_google_cloud_redis_v1beta1_ListInstancesRequest,
        __Marshaller_google_cloud_redis_v1beta1_ListInstancesResponse);

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Method<global::Google.Cloud.Redis.V1Beta1.GetInstanceRequest, global::Google.Cloud.Redis.V1Beta1.Instance> __Method_GetInstance = new grpc::Method<global::Google.Cloud.Redis.V1Beta1.GetInstanceRequest, global::Google.Cloud.Redis.V1Beta1.Instance>(
        grpc::MethodType.Unary,
        __ServiceName,
        "GetInstance",
        __Marshaller_google_cloud_redis_v1beta1_GetInstanceRequest,
        __Marshaller_google_cloud_redis_v1beta1_Instance);

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Method<global::Google.Cloud.Redis.V1Beta1.GetInstanceAuthStringRequest, global::Google.Cloud.Redis.V1Beta1.InstanceAuthString> __Method_GetInstanceAuthString = new grpc::Method<global::Google.Cloud.Redis.V1Beta1.GetInstanceAuthStringRequest, global::Google.Cloud.Redis.V1Beta1.InstanceAuthString>(
        grpc::MethodType.Unary,
        __ServiceName,
        "GetInstanceAuthString",
        __Marshaller_google_cloud_redis_v1beta1_GetInstanceAuthStringRequest,
        __Marshaller_google_cloud_redis_v1beta1_InstanceAuthString);

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Method<global::Google.Cloud.Redis.V1Beta1.CreateInstanceRequest, global::Google.LongRunning.Operation> __Method_CreateInstance = new grpc::Method<global::Google.Cloud.Redis.V1Beta1.CreateInstanceRequest, global::Google.LongRunning.Operation>(
        grpc::MethodType.Unary,
        __ServiceName,
        "CreateInstance",
        __Marshaller_google_cloud_redis_v1beta1_CreateInstanceRequest,
        __Marshaller_google_longrunning_Operation);

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Method<global::Google.Cloud.Redis.V1Beta1.UpdateInstanceRequest, global::Google.LongRunning.Operation> __Method_UpdateInstance = new grpc::Method<global::Google.Cloud.Redis.V1Beta1.UpdateInstanceRequest, global::Google.LongRunning.Operation>(
        grpc::MethodType.Unary,
        __ServiceName,
        "UpdateInstance",
        __Marshaller_google_cloud_redis_v1beta1_UpdateInstanceRequest,
        __Marshaller_google_longrunning_Operation);

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Method<global::Google.Cloud.Redis.V1Beta1.UpgradeInstanceRequest, global::Google.LongRunning.Operation> __Method_UpgradeInstance = new grpc::Method<global::Google.Cloud.Redis.V1Beta1.UpgradeInstanceRequest, global::Google.LongRunning.Operation>(
        grpc::MethodType.Unary,
        __ServiceName,
        "UpgradeInstance",
        __Marshaller_google_cloud_redis_v1beta1_UpgradeInstanceRequest,
        __Marshaller_google_longrunning_Operation);

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Method<global::Google.Cloud.Redis.V1Beta1.ImportInstanceRequest, global::Google.LongRunning.Operation> __Method_ImportInstance = new grpc::Method<global::Google.Cloud.Redis.V1Beta1.ImportInstanceRequest, global::Google.LongRunning.Operation>(
        grpc::MethodType.Unary,
        __ServiceName,
        "ImportInstance",
        __Marshaller_google_cloud_redis_v1beta1_ImportInstanceRequest,
        __Marshaller_google_longrunning_Operation);

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Method<global::Google.Cloud.Redis.V1Beta1.ExportInstanceRequest, global::Google.LongRunning.Operation> __Method_ExportInstance = new grpc::Method<global::Google.Cloud.Redis.V1Beta1.ExportInstanceRequest, global::Google.LongRunning.Operation>(
        grpc::MethodType.Unary,
        __ServiceName,
        "ExportInstance",
        __Marshaller_google_cloud_redis_v1beta1_ExportInstanceRequest,
        __Marshaller_google_longrunning_Operation);

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Method<global::Google.Cloud.Redis.V1Beta1.FailoverInstanceRequest, global::Google.LongRunning.Operation> __Method_FailoverInstance = new grpc::Method<global::Google.Cloud.Redis.V1Beta1.FailoverInstanceRequest, global::Google.LongRunning.Operation>(
        grpc::MethodType.Unary,
        __ServiceName,
        "FailoverInstance",
        __Marshaller_google_cloud_redis_v1beta1_FailoverInstanceRequest,
        __Marshaller_google_longrunning_Operation);

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Method<global::Google.Cloud.Redis.V1Beta1.DeleteInstanceRequest, global::Google.LongRunning.Operation> __Method_DeleteInstance = new grpc::Method<global::Google.Cloud.Redis.V1Beta1.DeleteInstanceRequest, global::Google.LongRunning.Operation>(
        grpc::MethodType.Unary,
        __ServiceName,
        "DeleteInstance",
        __Marshaller_google_cloud_redis_v1beta1_DeleteInstanceRequest,
        __Marshaller_google_longrunning_Operation);

    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    static readonly grpc::Method<global::Google.Cloud.Redis.V1Beta1.RescheduleMaintenanceRequest, global::Google.LongRunning.Operation> __Method_RescheduleMaintenance = new grpc::Method<global::Google.Cloud.Redis.V1Beta1.RescheduleMaintenanceRequest, global::Google.LongRunning.Operation>(
        grpc::MethodType.Unary,
        __ServiceName,
        "RescheduleMaintenance",
        __Marshaller_google_cloud_redis_v1beta1_RescheduleMaintenanceRequest,
        __Marshaller_google_longrunning_Operation);

    /// Service descriptor
    public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor
    {
      get { return global::Google.Cloud.Redis.V1Beta1.CloudRedisReflection.Descriptor.Services[0]; }
    }

    /// Base class for server-side implementations of CloudRedis
    [grpc::BindServiceMethod(typeof(CloudRedis), "BindService")]
    public abstract partial class CloudRedisBase
    {
      ///
      /// Lists all Redis instances owned by a project in either the specified
      /// location (region) or all locations.
      ///
      /// The location should have the following format:
      ///
      /// * `projects/{project_id}/locations/{location_id}`
      ///
      /// If `location_id` is specified as `-` (wildcard), then all regions
      /// available to the project are queried, and the results are aggregated.
      ///
      /// <param name="request">The request received from the client.</param>
      /// <param name="context">The context of the server-side call handler being invoked.</param>
      /// <returns>The response to send back to the client (wrapped by a task).</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::System.Threading.Tasks.Task<global::Google.Cloud.Redis.V1Beta1.ListInstancesResponse> ListInstances(global::Google.Cloud.Redis.V1Beta1.ListInstancesRequest request, grpc::ServerCallContext context)
      {
        throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
      }

      ///
      /// Gets the details of a specific Redis instance.
      ///
      /// <param name="request">The request received from the client.</param>
      /// <param name="context">The context of the server-side call handler being invoked.</param>
      /// <returns>The response to send back to the client (wrapped by a task).</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::System.Threading.Tasks.Task<global::Google.Cloud.Redis.V1Beta1.Instance> GetInstance(global::Google.Cloud.Redis.V1Beta1.GetInstanceRequest request, grpc::ServerCallContext context)
      {
        throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
      }

      ///
      /// Gets the AUTH string for a Redis instance. If AUTH is not enabled for the
      /// instance the response will be empty. This information is not included in
      /// the details returned to GetInstance.
      ///
      /// <param name="request">The request received from the client.</param>
      /// <param name="context">The context of the server-side call handler being invoked.</param>
      /// <returns>The response to send back to the client (wrapped by a task).</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::System.Threading.Tasks.Task<global::Google.Cloud.Redis.V1Beta1.InstanceAuthString> GetInstanceAuthString(global::Google.Cloud.Redis.V1Beta1.GetInstanceAuthStringRequest request, grpc::ServerCallContext context)
      {
        throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
      }

      ///
      /// Creates a Redis instance based on the specified tier and memory size.
      ///
      /// By default, the instance is accessible from the project's
      /// [default network](https://cloud.google.com/vpc/docs/vpc).
      ///
      /// The creation is executed asynchronously and callers may check the returned
      /// operation to track its progress. Once the operation is completed the Redis
      /// instance will be fully functional. The completed longrunning.Operation will
      /// contain the new instance object in the response field.
      ///
      /// The returned operation is automatically deleted after a few hours, so there
      /// is no need to call DeleteOperation.
      ///
      /// <param name="request">The request received from the client.</param>
      /// <param name="context">The context of the server-side call handler being invoked.</param>
      /// <returns>The response to send back to the client (wrapped by a task).</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::System.Threading.Tasks.Task<global::Google.LongRunning.Operation> CreateInstance(global::Google.Cloud.Redis.V1Beta1.CreateInstanceRequest request, grpc::ServerCallContext context)
      {
        throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
      }

      ///
      /// Updates the metadata and configuration of a specific Redis instance.
      ///
      /// Completed longrunning.Operation will contain the new instance object
      /// in the response field. The returned operation is automatically deleted
      /// after a few hours, so there is no need to call DeleteOperation.
      ///
      /// <param name="request">The request received from the client.</param>
      /// <param name="context">The context of the server-side call handler being invoked.</param>
      /// <returns>The response to send back to the client (wrapped by a task).</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::System.Threading.Tasks.Task<global::Google.LongRunning.Operation> UpdateInstance(global::Google.Cloud.Redis.V1Beta1.UpdateInstanceRequest request, grpc::ServerCallContext context)
      {
        throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
      }

      ///
      /// Upgrades Redis instance to the newer Redis version specified in the
      /// request.
      ///
      /// <param name="request">The request received from the client.</param>
      /// <param name="context">The context of the server-side call handler being invoked.</param>
      /// <returns>The response to send back to the client (wrapped by a task).</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::System.Threading.Tasks.Task<global::Google.LongRunning.Operation> UpgradeInstance(global::Google.Cloud.Redis.V1Beta1.UpgradeInstanceRequest request, grpc::ServerCallContext context)
      {
        throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
      }

      ///
      /// Import a Redis RDB snapshot file from Cloud Storage into a Redis instance.
      ///
      /// Redis may stop serving during this operation. Instance state will be
      /// IMPORTING for entire operation. When complete, the instance will contain
      /// only data from the imported file.
      ///
      /// The returned operation is automatically deleted after a few hours, so
      /// there is no need to call DeleteOperation.
      ///
      /// <param name="request">The request received from the client.</param>
      /// <param name="context">The context of the server-side call handler being invoked.</param>
      /// <returns>The response to send back to the client (wrapped by a task).</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::System.Threading.Tasks.Task<global::Google.LongRunning.Operation> ImportInstance(global::Google.Cloud.Redis.V1Beta1.ImportInstanceRequest request, grpc::ServerCallContext context)
      {
        throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
      }

      ///
      /// Export Redis instance data into a Redis RDB format file in Cloud Storage.
      ///
      /// Redis will continue serving during this operation.
      ///
      /// The returned operation is automatically deleted after a few hours, so
      /// there is no need to call DeleteOperation.
      ///
      /// <param name="request">The request received from the client.</param>
      /// <param name="context">The context of the server-side call handler being invoked.</param>
      /// <returns>The response to send back to the client (wrapped by a task).</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::System.Threading.Tasks.Task<global::Google.LongRunning.Operation> ExportInstance(global::Google.Cloud.Redis.V1Beta1.ExportInstanceRequest request, grpc::ServerCallContext context)
      {
        throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
      }

      ///
      /// Initiates a failover of the primary node to current replica node for a
      /// specific STANDARD tier Cloud Memorystore for Redis instance.
      ///
      /// <param name="request">The request received from the client.</param>
      /// <param name="context">The context of the server-side call handler being invoked.</param>
      /// <returns>The response to send back to the client (wrapped by a task).</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::System.Threading.Tasks.Task<global::Google.LongRunning.Operation> FailoverInstance(global::Google.Cloud.Redis.V1Beta1.FailoverInstanceRequest request, grpc::ServerCallContext context)
      {
        throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
      }

      ///
      /// Deletes a specific Redis instance.  Instance stops serving and data is
      /// deleted.
      ///
      /// <param name="request">The request received from the client.</param>
      /// <param name="context">The context of the server-side call handler being invoked.</param>
      /// <returns>The response to send back to the client (wrapped by a task).</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::System.Threading.Tasks.Task<global::Google.LongRunning.Operation> DeleteInstance(global::Google.Cloud.Redis.V1Beta1.DeleteInstanceRequest request, grpc::ServerCallContext context)
      {
        throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
      }

      ///
      /// Reschedule maintenance for a given instance in a given project and
      /// location.
      ///
      /// <param name="request">The request received from the client.</param>
      /// <param name="context">The context of the server-side call handler being invoked.</param>
      /// <returns>The response to send back to the client (wrapped by a task).</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::System.Threading.Tasks.Task<global::Google.LongRunning.Operation> RescheduleMaintenance(global::Google.Cloud.Redis.V1Beta1.RescheduleMaintenanceRequest request, grpc::ServerCallContext context)
      {
        throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
      }

    }

    /// Client for CloudRedis
    public partial class CloudRedisClient : grpc::ClientBase<CloudRedisClient>
    {
      /// Creates a new client for CloudRedis
      /// <param name="channel">The channel to use to make remote calls.</param>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public CloudRedisClient(grpc::ChannelBase channel) : base(channel)
      {
      }
      /// Creates a new client for CloudRedis that uses a custom <c>CallInvoker</c>.
      /// <param name="callInvoker">The callInvoker to use to make remote calls.</param>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public CloudRedisClient(grpc::CallInvoker callInvoker) : base(callInvoker)
      {
      }
      /// Protected parameterless constructor to allow creation of test doubles.
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      protected CloudRedisClient() : base()
      {
      }
      /// Protected constructor to allow creation of configured clients.
      /// <param name="configuration">The client configuration.</param>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      protected CloudRedisClient(ClientBaseConfiguration configuration) : base(configuration)
      {
      }

      ///
      /// Lists all Redis instances owned by a project in either the specified
      /// location (region) or all locations.
      ///
      /// The location should have the following format:
      ///
      /// * `projects/{project_id}/locations/{location_id}`
      ///
      /// If `location_id` is specified as `-` (wildcard), then all regions
      /// available to the project are queried, and the results are aggregated.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.Cloud.Redis.V1Beta1.ListInstancesResponse ListInstances(global::Google.Cloud.Redis.V1Beta1.ListInstancesRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return ListInstances(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Lists all Redis instances owned by a project in either the specified
      /// location (region) or all locations.
      ///
      /// The location should have the following format:
      ///
      /// * `projects/{project_id}/locations/{location_id}`
      ///
      /// If `location_id` is specified as `-` (wildcard), then all regions
      /// available to the project are queried, and the results are aggregated.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.Cloud.Redis.V1Beta1.ListInstancesResponse ListInstances(global::Google.Cloud.Redis.V1Beta1.ListInstancesRequest request, grpc::CallOptions options)
      {
        return CallInvoker.BlockingUnaryCall(__Method_ListInstances, null, options, request);
      }
      ///
      /// Lists all Redis instances owned by a project in either the specified
      /// location (region) or all locations.
      ///
      /// The location should have the following format:
      ///
      /// * `projects/{project_id}/locations/{location_id}`
      ///
      /// If `location_id` is specified as `-` (wildcard), then all regions
      /// available to the project are queried, and the results are aggregated.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.Cloud.Redis.V1Beta1.ListInstancesResponse> ListInstancesAsync(global::Google.Cloud.Redis.V1Beta1.ListInstancesRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return ListInstancesAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Lists all Redis instances owned by a project in either the specified
      /// location (region) or all locations.
      ///
      /// The location should have the following format:
      ///
      /// * `projects/{project_id}/locations/{location_id}`
      ///
      /// If `location_id` is specified as `-` (wildcard), then all regions
      /// available to the project are queried, and the results are aggregated.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.Cloud.Redis.V1Beta1.ListInstancesResponse> ListInstancesAsync(global::Google.Cloud.Redis.V1Beta1.ListInstancesRequest request, grpc::CallOptions options)
      {
        return CallInvoker.AsyncUnaryCall(__Method_ListInstances, null, options, request);
      }
      ///
      /// Gets the details of a specific Redis instance.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.Cloud.Redis.V1Beta1.Instance GetInstance(global::Google.Cloud.Redis.V1Beta1.GetInstanceRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return GetInstance(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Gets the details of a specific Redis instance.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.Cloud.Redis.V1Beta1.Instance GetInstance(global::Google.Cloud.Redis.V1Beta1.GetInstanceRequest request, grpc::CallOptions options)
      {
        return CallInvoker.BlockingUnaryCall(__Method_GetInstance, null, options, request);
      }
      ///
      /// Gets the details of a specific Redis instance.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.Cloud.Redis.V1Beta1.Instance> GetInstanceAsync(global::Google.Cloud.Redis.V1Beta1.GetInstanceRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return GetInstanceAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Gets the details of a specific Redis instance.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.Cloud.Redis.V1Beta1.Instance> GetInstanceAsync(global::Google.Cloud.Redis.V1Beta1.GetInstanceRequest request, grpc::CallOptions options)
      {
        return CallInvoker.AsyncUnaryCall(__Method_GetInstance, null, options, request);
      }
      ///
      /// Gets the AUTH string for a Redis instance. If AUTH is not enabled for the
      /// instance the response will be empty. This information is not included in
      /// the details returned to GetInstance.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.Cloud.Redis.V1Beta1.InstanceAuthString GetInstanceAuthString(global::Google.Cloud.Redis.V1Beta1.GetInstanceAuthStringRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return GetInstanceAuthString(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Gets the AUTH string for a Redis instance. If AUTH is not enabled for the
      /// instance the response will be empty. This information is not included in
      /// the details returned to GetInstance.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.Cloud.Redis.V1Beta1.InstanceAuthString GetInstanceAuthString(global::Google.Cloud.Redis.V1Beta1.GetInstanceAuthStringRequest request, grpc::CallOptions options)
      {
        return CallInvoker.BlockingUnaryCall(__Method_GetInstanceAuthString, null, options, request);
      }
      ///
      /// Gets the AUTH string for a Redis instance. If AUTH is not enabled for the
      /// instance the response will be empty. This information is not included in
      /// the details returned to GetInstance.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.Cloud.Redis.V1Beta1.InstanceAuthString> GetInstanceAuthStringAsync(global::Google.Cloud.Redis.V1Beta1.GetInstanceAuthStringRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return GetInstanceAuthStringAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Gets the AUTH string for a Redis instance. If AUTH is not enabled for the
      /// instance the response will be empty. This information is not included in
      /// the details returned to GetInstance.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.Cloud.Redis.V1Beta1.InstanceAuthString> GetInstanceAuthStringAsync(global::Google.Cloud.Redis.V1Beta1.GetInstanceAuthStringRequest request, grpc::CallOptions options)
      {
        return CallInvoker.AsyncUnaryCall(__Method_GetInstanceAuthString, null, options, request);
      }
      ///
      /// Creates a Redis instance based on the specified tier and memory size.
      ///
      /// By default, the instance is accessible from the project's
      /// [default network](https://cloud.google.com/vpc/docs/vpc).
      ///
      /// The creation is executed asynchronously and callers may check the returned
      /// operation to track its progress. Once the operation is completed the Redis
      /// instance will be fully functional. The completed longrunning.Operation will
      /// contain the new instance object in the response field.
      ///
      /// The returned operation is automatically deleted after a few hours, so there
      /// is no need to call DeleteOperation.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.LongRunning.Operation CreateInstance(global::Google.Cloud.Redis.V1Beta1.CreateInstanceRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return CreateInstance(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Creates a Redis instance based on the specified tier and memory size.
      ///
      /// By default, the instance is accessible from the project's
      /// [default network](https://cloud.google.com/vpc/docs/vpc).
      ///
      /// The creation is executed asynchronously and callers may check the returned
      /// operation to track its progress. Once the operation is completed the Redis
      /// instance will be fully functional. The completed longrunning.Operation will
      /// contain the new instance object in the response field.
      ///
      /// The returned operation is automatically deleted after a few hours, so there
      /// is no need to call DeleteOperation.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.LongRunning.Operation CreateInstance(global::Google.Cloud.Redis.V1Beta1.CreateInstanceRequest request, grpc::CallOptions options)
      {
        return CallInvoker.BlockingUnaryCall(__Method_CreateInstance, null, options, request);
      }
      ///
      /// Creates a Redis instance based on the specified tier and memory size.
      ///
      /// By default, the instance is accessible from the project's
      /// [default network](https://cloud.google.com/vpc/docs/vpc).
      ///
      /// The creation is executed asynchronously and callers may check the returned
      /// operation to track its progress. Once the operation is completed the Redis
      /// instance will be fully functional. The completed longrunning.Operation will
      /// contain the new instance object in the response field.
      ///
      /// The returned operation is automatically deleted after a few hours, so there
      /// is no need to call DeleteOperation.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.LongRunning.Operation> CreateInstanceAsync(global::Google.Cloud.Redis.V1Beta1.CreateInstanceRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return CreateInstanceAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Creates a Redis instance based on the specified tier and memory size.
      ///
      /// By default, the instance is accessible from the project's
      /// [default network](https://cloud.google.com/vpc/docs/vpc).
      ///
      /// The creation is executed asynchronously and callers may check the returned
      /// operation to track its progress. Once the operation is completed the Redis
      /// instance will be fully functional. The completed longrunning.Operation will
      /// contain the new instance object in the response field.
      ///
      /// The returned operation is automatically deleted after a few hours, so there
      /// is no need to call DeleteOperation.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.LongRunning.Operation> CreateInstanceAsync(global::Google.Cloud.Redis.V1Beta1.CreateInstanceRequest request, grpc::CallOptions options)
      {
        return CallInvoker.AsyncUnaryCall(__Method_CreateInstance, null, options, request);
      }
      ///
      /// Updates the metadata and configuration of a specific Redis instance.
      ///
      /// Completed longrunning.Operation will contain the new instance object
      /// in the response field. The returned operation is automatically deleted
      /// after a few hours, so there is no need to call DeleteOperation.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.LongRunning.Operation UpdateInstance(global::Google.Cloud.Redis.V1Beta1.UpdateInstanceRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return UpdateInstance(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Updates the metadata and configuration of a specific Redis instance.
      ///
      /// Completed longrunning.Operation will contain the new instance object
      /// in the response field. The returned operation is automatically deleted
      /// after a few hours, so there is no need to call DeleteOperation.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.LongRunning.Operation UpdateInstance(global::Google.Cloud.Redis.V1Beta1.UpdateInstanceRequest request, grpc::CallOptions options)
      {
        return CallInvoker.BlockingUnaryCall(__Method_UpdateInstance, null, options, request);
      }
      ///
      /// Updates the metadata and configuration of a specific Redis instance.
      ///
      /// Completed longrunning.Operation will contain the new instance object
      /// in the response field. The returned operation is automatically deleted
      /// after a few hours, so there is no need to call DeleteOperation.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.LongRunning.Operation> UpdateInstanceAsync(global::Google.Cloud.Redis.V1Beta1.UpdateInstanceRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return UpdateInstanceAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Updates the metadata and configuration of a specific Redis instance.
      ///
      /// Completed longrunning.Operation will contain the new instance object
      /// in the response field. The returned operation is automatically deleted
      /// after a few hours, so there is no need to call DeleteOperation.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.LongRunning.Operation> UpdateInstanceAsync(global::Google.Cloud.Redis.V1Beta1.UpdateInstanceRequest request, grpc::CallOptions options)
      {
        return CallInvoker.AsyncUnaryCall(__Method_UpdateInstance, null, options, request);
      }
      ///
      /// Upgrades Redis instance to the newer Redis version specified in the
      /// request.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.LongRunning.Operation UpgradeInstance(global::Google.Cloud.Redis.V1Beta1.UpgradeInstanceRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return UpgradeInstance(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Upgrades Redis instance to the newer Redis version specified in the
      /// request.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.LongRunning.Operation UpgradeInstance(global::Google.Cloud.Redis.V1Beta1.UpgradeInstanceRequest request, grpc::CallOptions options)
      {
        return CallInvoker.BlockingUnaryCall(__Method_UpgradeInstance, null, options, request);
      }
      ///
      /// Upgrades Redis instance to the newer Redis version specified in the
      /// request.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.LongRunning.Operation> UpgradeInstanceAsync(global::Google.Cloud.Redis.V1Beta1.UpgradeInstanceRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return UpgradeInstanceAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Upgrades Redis instance to the newer Redis version specified in the
      /// request.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.LongRunning.Operation> UpgradeInstanceAsync(global::Google.Cloud.Redis.V1Beta1.UpgradeInstanceRequest request, grpc::CallOptions options)
      {
        return CallInvoker.AsyncUnaryCall(__Method_UpgradeInstance, null, options, request);
      }
      ///
      /// Import a Redis RDB snapshot file from Cloud Storage into a Redis instance.
      ///
      /// Redis may stop serving during this operation. Instance state will be
      /// IMPORTING for entire operation. When complete, the instance will contain
      /// only data from the imported file.
      ///
      /// The returned operation is automatically deleted after a few hours, so
      /// there is no need to call DeleteOperation.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.LongRunning.Operation ImportInstance(global::Google.Cloud.Redis.V1Beta1.ImportInstanceRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return ImportInstance(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Import a Redis RDB snapshot file from Cloud Storage into a Redis instance.
      ///
      /// Redis may stop serving during this operation. Instance state will be
      /// IMPORTING for entire operation. When complete, the instance will contain
      /// only data from the imported file.
      ///
      /// The returned operation is automatically deleted after a few hours, so
      /// there is no need to call DeleteOperation.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.LongRunning.Operation ImportInstance(global::Google.Cloud.Redis.V1Beta1.ImportInstanceRequest request, grpc::CallOptions options)
      {
        return CallInvoker.BlockingUnaryCall(__Method_ImportInstance, null, options, request);
      }
      ///
      /// Import a Redis RDB snapshot file from Cloud Storage into a Redis instance.
      ///
      /// Redis may stop serving during this operation. Instance state will be
      /// IMPORTING for entire operation. When complete, the instance will contain
      /// only data from the imported file.
      ///
      /// The returned operation is automatically deleted after a few hours, so
      /// there is no need to call DeleteOperation.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.LongRunning.Operation> ImportInstanceAsync(global::Google.Cloud.Redis.V1Beta1.ImportInstanceRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return ImportInstanceAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Import a Redis RDB snapshot file from Cloud Storage into a Redis instance.
      ///
      /// Redis may stop serving during this operation. Instance state will be
      /// IMPORTING for entire operation. When complete, the instance will contain
      /// only data from the imported file.
      ///
      /// The returned operation is automatically deleted after a few hours, so
      /// there is no need to call DeleteOperation.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.LongRunning.Operation> ImportInstanceAsync(global::Google.Cloud.Redis.V1Beta1.ImportInstanceRequest request, grpc::CallOptions options)
      {
        return CallInvoker.AsyncUnaryCall(__Method_ImportInstance, null, options, request);
      }
      ///
      /// Export Redis instance data into a Redis RDB format file in Cloud Storage.
      ///
      /// Redis will continue serving during this operation.
      ///
      /// The returned operation is automatically deleted after a few hours, so
      /// there is no need to call DeleteOperation.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.LongRunning.Operation ExportInstance(global::Google.Cloud.Redis.V1Beta1.ExportInstanceRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return ExportInstance(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Export Redis instance data into a Redis RDB format file in Cloud Storage.
      ///
      /// Redis will continue serving during this operation.
      ///
      /// The returned operation is automatically deleted after a few hours, so
      /// there is no need to call DeleteOperation.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.LongRunning.Operation ExportInstance(global::Google.Cloud.Redis.V1Beta1.ExportInstanceRequest request, grpc::CallOptions options)
      {
        return CallInvoker.BlockingUnaryCall(__Method_ExportInstance, null, options, request);
      }
      ///
      /// Export Redis instance data into a Redis RDB format file in Cloud Storage.
      ///
      /// Redis will continue serving during this operation.
      ///
      /// The returned operation is automatically deleted after a few hours, so
      /// there is no need to call DeleteOperation.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.LongRunning.Operation> ExportInstanceAsync(global::Google.Cloud.Redis.V1Beta1.ExportInstanceRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return ExportInstanceAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Export Redis instance data into a Redis RDB format file in Cloud Storage.
      ///
      /// Redis will continue serving during this operation.
      ///
      /// The returned operation is automatically deleted after a few hours, so
      /// there is no need to call DeleteOperation.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.LongRunning.Operation> ExportInstanceAsync(global::Google.Cloud.Redis.V1Beta1.ExportInstanceRequest request, grpc::CallOptions options)
      {
        return CallInvoker.AsyncUnaryCall(__Method_ExportInstance, null, options, request);
      }
      ///
      /// Initiates a failover of the primary node to current replica node for a
      /// specific STANDARD tier Cloud Memorystore for Redis instance.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.LongRunning.Operation FailoverInstance(global::Google.Cloud.Redis.V1Beta1.FailoverInstanceRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return FailoverInstance(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Initiates a failover of the primary node to current replica node for a
      /// specific STANDARD tier Cloud Memorystore for Redis instance.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.LongRunning.Operation FailoverInstance(global::Google.Cloud.Redis.V1Beta1.FailoverInstanceRequest request, grpc::CallOptions options)
      {
        return CallInvoker.BlockingUnaryCall(__Method_FailoverInstance, null, options, request);
      }
      ///
      /// Initiates a failover of the primary node to current replica node for a
      /// specific STANDARD tier Cloud Memorystore for Redis instance.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.LongRunning.Operation> FailoverInstanceAsync(global::Google.Cloud.Redis.V1Beta1.FailoverInstanceRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return FailoverInstanceAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Initiates a failover of the primary node to current replica node for a
      /// specific STANDARD tier Cloud Memorystore for Redis instance.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.LongRunning.Operation> FailoverInstanceAsync(global::Google.Cloud.Redis.V1Beta1.FailoverInstanceRequest request, grpc::CallOptions options)
      {
        return CallInvoker.AsyncUnaryCall(__Method_FailoverInstance, null, options, request);
      }
      ///
      /// Deletes a specific Redis instance.  Instance stops serving and data is
      /// deleted.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.LongRunning.Operation DeleteInstance(global::Google.Cloud.Redis.V1Beta1.DeleteInstanceRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return DeleteInstance(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Deletes a specific Redis instance.  Instance stops serving and data is
      /// deleted.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.LongRunning.Operation DeleteInstance(global::Google.Cloud.Redis.V1Beta1.DeleteInstanceRequest request, grpc::CallOptions options)
      {
        return CallInvoker.BlockingUnaryCall(__Method_DeleteInstance, null, options, request);
      }
      ///
      /// Deletes a specific Redis instance.  Instance stops serving and data is
      /// deleted.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.LongRunning.Operation> DeleteInstanceAsync(global::Google.Cloud.Redis.V1Beta1.DeleteInstanceRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return DeleteInstanceAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Deletes a specific Redis instance.  Instance stops serving and data is
      /// deleted.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.LongRunning.Operation> DeleteInstanceAsync(global::Google.Cloud.Redis.V1Beta1.DeleteInstanceRequest request, grpc::CallOptions options)
      {
        return CallInvoker.AsyncUnaryCall(__Method_DeleteInstance, null, options, request);
      }
      ///
      /// Reschedule maintenance for a given instance in a given project and
      /// location.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.LongRunning.Operation RescheduleMaintenance(global::Google.Cloud.Redis.V1Beta1.RescheduleMaintenanceRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return RescheduleMaintenance(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Reschedule maintenance for a given instance in a given project and
      /// location.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The response received from the server.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual global::Google.LongRunning.Operation RescheduleMaintenance(global::Google.Cloud.Redis.V1Beta1.RescheduleMaintenanceRequest request, grpc::CallOptions options)
      {
        return CallInvoker.BlockingUnaryCall(__Method_RescheduleMaintenance, null, options, request);
      }
      ///
      /// Reschedule maintenance for a given instance in a given project and
      /// location.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
      /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
      /// <param name="cancellationToken">An optional token for canceling the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.LongRunning.Operation> RescheduleMaintenanceAsync(global::Google.Cloud.Redis.V1Beta1.RescheduleMaintenanceRequest request, grpc::Metadata headers = null, global::System.DateTime? deadline = null, global::System.Threading.CancellationToken cancellationToken = default(global::System.Threading.CancellationToken))
      {
        return RescheduleMaintenanceAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
      }
      ///
      /// Reschedule maintenance for a given instance in a given project and
      /// location.
      ///
      /// <param name="request">The request to send to the server.</param>
      /// <param name="options">The options for the call.</param>
      /// <returns>The call object.</returns>
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      public virtual grpc::AsyncUnaryCall<global::Google.LongRunning.Operation> RescheduleMaintenanceAsync(global::Google.Cloud.Redis.V1Beta1.RescheduleMaintenanceRequest request, grpc::CallOptions options)
      {
        return CallInvoker.AsyncUnaryCall(__Method_RescheduleMaintenance, null, options, request);
      }
      /// Creates a new instance of client from given <c>ClientBaseConfiguration</c>.
      [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
      protected override CloudRedisClient NewInstance(ClientBaseConfiguration configuration)
      {
        return new CloudRedisClient(configuration);
      }
    }

    /// Creates service definition that can be registered with a server
    /// <param name="serviceImpl">An object implementing the server-side handling logic.</param>
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    public static grpc::ServerServiceDefinition BindService(CloudRedisBase serviceImpl)
    {
      return grpc::ServerServiceDefinition.CreateBuilder()
          .AddMethod(__Method_ListInstances, serviceImpl.ListInstances)
          .AddMethod(__Method_GetInstance, serviceImpl.GetInstance)
          .AddMethod(__Method_GetInstanceAuthString, serviceImpl.GetInstanceAuthString)
          .AddMethod(__Method_CreateInstance, serviceImpl.CreateInstance)
          .AddMethod(__Method_UpdateInstance, serviceImpl.UpdateInstance)
          .AddMethod(__Method_UpgradeInstance, serviceImpl.UpgradeInstance)
          .AddMethod(__Method_ImportInstance, serviceImpl.ImportInstance)
          .AddMethod(__Method_ExportInstance, serviceImpl.ExportInstance)
          .AddMethod(__Method_FailoverInstance, serviceImpl.FailoverInstance)
          .AddMethod(__Method_DeleteInstance, serviceImpl.DeleteInstance)
          .AddMethod(__Method_RescheduleMaintenance, serviceImpl.RescheduleMaintenance).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.
    /// <param name="serviceBinder">Service methods will be bound by calling <c>AddMethod</c> on this object.</param>
    /// <param name="serviceImpl">An object implementing the server-side handling logic.</param>
    [global::System.CodeDom.Compiler.GeneratedCode("grpc_csharp_plugin", null)]
    public static void BindService(grpc::ServiceBinderBase serviceBinder, CloudRedisBase serviceImpl)
    {
      serviceBinder.AddMethod(__Method_ListInstances, serviceImpl == null ? null : new grpc::UnaryServerMethod<global::Google.Cloud.Redis.V1Beta1.ListInstancesRequest, global::Google.Cloud.Redis.V1Beta1.ListInstancesResponse>(serviceImpl.ListInstances));
      serviceBinder.AddMethod(__Method_GetInstance, serviceImpl == null ? null : new grpc::UnaryServerMethod<global::Google.Cloud.Redis.V1Beta1.GetInstanceRequest, global::Google.Cloud.Redis.V1Beta1.Instance>(serviceImpl.GetInstance));
      serviceBinder.AddMethod(__Method_GetInstanceAuthString, serviceImpl == null ? null : new grpc::UnaryServerMethod<global::Google.Cloud.Redis.V1Beta1.GetInstanceAuthStringRequest, global::Google.Cloud.Redis.V1Beta1.InstanceAuthString>(serviceImpl.GetInstanceAuthString));
      serviceBinder.AddMethod(__Method_CreateInstance, serviceImpl == null ? null : new grpc::UnaryServerMethod<global::Google.Cloud.Redis.V1Beta1.CreateInstanceRequest, global::Google.LongRunning.Operation>(serviceImpl.CreateInstance));
      serviceBinder.AddMethod(__Method_UpdateInstance, serviceImpl == null ? null : new grpc::UnaryServerMethod<global::Google.Cloud.Redis.V1Beta1.UpdateInstanceRequest, global::Google.LongRunning.Operation>(serviceImpl.UpdateInstance));
      serviceBinder.AddMethod(__Method_UpgradeInstance, serviceImpl == null ? null : new grpc::UnaryServerMethod<global::Google.Cloud.Redis.V1Beta1.UpgradeInstanceRequest, global::Google.LongRunning.Operation>(serviceImpl.UpgradeInstance));
      serviceBinder.AddMethod(__Method_ImportInstance, serviceImpl == null ? null : new grpc::UnaryServerMethod<global::Google.Cloud.Redis.V1Beta1.ImportInstanceRequest, global::Google.LongRunning.Operation>(serviceImpl.ImportInstance));
      serviceBinder.AddMethod(__Method_ExportInstance, serviceImpl == null ? null : new grpc::UnaryServerMethod<global::Google.Cloud.Redis.V1Beta1.ExportInstanceRequest, global::Google.LongRunning.Operation>(serviceImpl.ExportInstance));
      serviceBinder.AddMethod(__Method_FailoverInstance, serviceImpl == null ? null : new grpc::UnaryServerMethod<global::Google.Cloud.Redis.V1Beta1.FailoverInstanceRequest, global::Google.LongRunning.Operation>(serviceImpl.FailoverInstance));
      serviceBinder.AddMethod(__Method_DeleteInstance, serviceImpl == null ? null : new grpc::UnaryServerMethod<global::Google.Cloud.Redis.V1Beta1.DeleteInstanceRequest, global::Google.LongRunning.Operation>(serviceImpl.DeleteInstance));
      serviceBinder.AddMethod(__Method_RescheduleMaintenance, serviceImpl == null ? null : new grpc::UnaryServerMethod<global::Google.Cloud.Redis.V1Beta1.RescheduleMaintenanceRequest, global::Google.LongRunning.Operation>(serviceImpl.RescheduleMaintenance));
    }

  }
}
#endregion


text:
package pl.matisoft.soy.global.runtime.resolvers;

import com.google.template.soy.data.SoyMapData;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.Enumeration;
import java.util.Map;

/**
 * Created with IntelliJ IDEA.
 * User: mati
 * Date: 01/11/2013
 * Time: 16:36
 */
@Deprecated
public class RequestHeadersDataResolver implements RuntimeDataResolver {

    private String prefix = "_request.header.";

    @Override
    public void resolveData(final HttpServletRequest request, final HttpServletResponse response, Map<String, ? extends Object> model, final SoyMapData root) {
        for (final Enumeration e = request.getHeaderNames(); e.hasMoreElements();) {
            final String headerName = (String) e.nextElement();
            final String requestHeader = request.getHeader(headerName);
            if (requestHeader != null) {
                root.put(prefix + headerName, requestHeader);
            }
        }
    }

    public void setPrefix(String prefix) {
        this.prefix = prefix;
    }

    public String getPrefix() {
        return prefix;
    }

}

redpajama_set_name: RedPajamaGithub


text:
/******************************************************************************\
** download.c                                                                 **
** Implementation file for file download routine                              **
\******************************************************************************/

#include "download.h"
#include "log.h"

#include <memory.h>
#include <stdlib.h>

#include <curl/curl.h>

/*****************************************************************************/
static size_t write_download(char *ptr, size_t size, size_t nmemb, void *userdata)
{
    DOWNLOAD *download = (DOWNLOAD*)userdata;
    /* reallocate storage for the data to fit the extra size */
    size_t length = size * nmemb;
    download->data = (uint8_t*)realloc(download->data, download->length + length);

    /* store the new data and update the data length */
    memcpy(download->data + download->length, ptr, length);
    download->length += length;
    return length;
}

/*****************************************************************************/
int download_file(const char *url, DOWNLOAD *download)
{
    int result;
    CURL *curl = curl_easy_init();
    if (!curl)
    {
        write_log(1, "Unable to initialise libcurl\n");
        return 1;
    }

    download->data   = 0;
    download->length = 0;

    curl_easy_setopt(curl, CURLOPT_URL, url);
    curl_easy_setopt(curl, CURLOPT_NOPROGRESS, 1);
    curl_easy_setopt(curl, CURLOPT_USERAGENT, "curl/7.35.0");
    curl_easy_setopt(curl, CURLOPT_MAXREDIRS, 50);
    curl_easy_setopt(curl, CURLOPT_TCP_KEEPALIVE, 1);
    curl_easy_setopt(curl, CURLOPT_WRITEDATA, download);
    curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, write_download);

    result = curl_easy_perform(curl);
    curl_easy_cleanup(curl);
    if (result != CURLE_OK)
    {
        write_log(1, "Unable to download file: %s (%d)\n", url, result);
        return 1;
    }
    return 0;
}


text:
prefix=@CMAKE_INSTALL_PREFIX@
exec_prefix=${prefix}/@CMAKE_INSTALL_BINDIR@
libdir=${prefix}/@CMAKE_INSTALL_LIBDIR@
includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@

Name: c-ares
URL: https://c-ares.haxx.se/
Description: asynchronous DNS lookup library
Version: @CARES_VERSION@
Requires:
Requires.private:
Cflags: -I${includedir} @CPPFLAG_CARES_STATICLIB@
Libs: -L${libdir} -lcares
Libs.private: @CARES_PRIVATE_LIBS@


text:
import React from 'react';
import { PropTypes } from 'prop-types';
import injectSheet from 'react-jss';
import classNames from 'classnames';

const ColorSample = ({ classes, className, children }) => (
  <p className={classNames(classes.container, className)}>
    {children}
  </p>
);

ColorSample.propTypes = {
  dark : PropTypes.bool,
  children: PropTypes.node,
};

ColorSample.defaultProps = {
  dark: false,
  children: null,
};

export default injectSheet({
  container: {
    color: ({ dark }) => dark ? '#000000' : '#9ea0a6',
    fontSize: 14,
    fontWeight: 400,
    marginBottom: 50
  },
})(ColorSample);


text:
/**
 * Imports
 */

import test from 'tape'
import PlaylistOptions from '.'

/**
 * <Playlist Options/> tests
 */

test('<PlaylistOptions/> should work', t => {

})


text:
// Copyright (c) .NET Foundation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.

using System;
using System.Collections.Generic;
using System.Threading.Tasks;
using Microsoft.Azure.WebJobs.Host.Converters;
using Microsoft.Azure.WebJobs.Host.Protocols;

namespace Microsoft.Azure.WebJobs.Host.Bindings.Data
{
    internal class ClassDataBinding<TBindingData> : IBinding
        where TBindingData : class
    {
        private static readonly IObjectToTypeConverter<TBindingData> Converter =
            ObjectToTypeConverterFactory.CreateForClass<TBindingData>();

        private readonly string _parameterName;
        private readonly IArgumentBinding<TBindingData> _argumentBinding;

        public ClassDataBinding(string parameterName, IArgumentBinding<TBindingData> argumentBinding)
        {
            _parameterName = parameterName;
            _argumentBinding = argumentBinding;
        }

        public bool FromAttribute
        {
            get { return false; }
        }

        private Task<IValueProvider> BindAsync(TBindingData bindingDataItem, ValueBindingContext context)
        {
            return _argumentBinding.BindAsync(bindingDataItem, context);
        }

        public Task<IValueProvider> BindAsync(object value, ValueBindingContext context)
        {
            TBindingData typedValue;

            if (!Converter.TryConvert(value, out typedValue))
            {
                throw new InvalidOperationException("Unable to convert value to " + typeof(TBindingData).Name + ".");
            }

            return BindAsync(typedValue, context);
        }

        public Task<IValueProvider> BindAsync(BindingContext context)
        {
            if (context == null)
            {
                throw new ArgumentNullException("context");
            }

            var bindingData = context.BindingData;
            if (bindingData == null || !bindingData.ContainsKey(_parameterName))
            {
                throw new InvalidOperationException($"Binding data does not contain expected value '{_parameterName}'.");
            }

            object untypedValue = bindingData[_parameterName];
            if (!(untypedValue is TBindingData) && untypedValue != null)
            {
                throw new InvalidOperationException($"Binding data for '{_parameterName}' is not of expected type {typeof(TBindingData).Name}.");
            }

            return BindAsync((TBindingData)untypedValue, context.ValueContext);
        }

        public ParameterDescriptor ToParameterDescriptor()
        {
            return new BindingDataParameterDescriptor
            {
                Name = _parameterName
            };
        }
    }
}


text:
var files = require("../config/files.js");
var readJSON = require("./readJSON.js");

module.exports = function (json) {

    if (!json) {
        json = readJSON(files.package);
    }

    return json.version;
};


text:
.. django cms documentation master file, created by
   sphinx-quickstart on Tue Sep 15 10:47:03 2009.
   You can adapt this file completely to your liking, but it should at least
   contain the root `toctree` directive.

######################################
Welcome to django cms's documentation!
######################################

This document refers to version |release|

***************
Getting Started
***************

.. toctree::
    :maxdepth: 2
    :numbered:

    getting_started/installation
    getting_started/tutorial
    getting_started/using_south
    getting_started/configuration
    getting_started/navigation
    getting_started/plugin_reference

********
Advanced
********

.. toctree::
    :maxdepth: 2
    :numbered:

    advanced/i18n
    advanced/sitemap
    advanced/templatetags

*****************
Extending the CMS
*****************

.. toctree::
    :maxdepth: 2
    :numbered:

    extending_cms/extending_examples
    extending_cms/custom_plugins
    extending_cms/app_integration
    extending_cms/api_references
    extending_cms/placeholders
    extending_cms/searchdocs

***********************
Contributing to the CMS
***********************

.. toctree::
    :maxdepth: 2
    :numbered:

    contribution

Indices and tables
==================

* :ref:`genindex`
* :ref:`modindex`
* :ref:`search`


text:
<?php

namespace GanbaroDigital\Versions\SemanticVersions\Operators;

use GanbaroDigital\NumberTools\Operators\CompareTwoNumbers;
use GanbaroDigital\Versions\SemanticVersions\Values\SemanticVersion;
use GanbaroDigital\Versions\SemanticVersions\Internal\Operators\CompareTwoPreReleases;

/**
 * Compares two versions
 */
class CompareSemanticVersions
{
    /**
     * compare two semantic version numbers
     *
     * @param  SemanticVersion $a
     * @param  SemanticVersion $b
     * @return int
     *         one of the CompareTwoNumbers::* consts
     */
    public function __invoke(SemanticVersion $a, SemanticVersion $b)
    {
        return self::calculate($a, $b);
    }

    /**
     * compare two semantic version numbers
     *
     * @param  SemanticVersion $a
     * @param  SemanticVersion $b
     * @return int
     *         one of the CompareTwoNumbers::* consts
     */
    public static function calculate(SemanticVersion $a, SemanticVersion $b)
    {
        // save us some processing time
        $aVer = $a->toArray();
        $bVer = $b->toArray();

        // compare major.minor.patchLevel first
        $retval = self::compareXyz($aVer, $bVer);
        if ($retval !== CompareTwoNumbers::BOTH_ARE_EQUAL) {
            return $retval;
        }

        // it's up to the pre-release section(s) to help us out
        return self::comparePreRelease($aVer, $bVer);
    }

    /**
     * compare the X.Y.Z parts of two version numbers
     *
     * @param  array $a
     * @param  array $b
     * @return int
     *         -1 if $aVer is smaller
     *          0 if both are equal
     *          1 if $aVer is larger
     */
    private static function compareXyz($a, $b)
    {
        // compare each part in turn
        foreach (['major', 'minor', 'patchLevel'] as $key) {
            $aN = self::getVersionPart($a, $key, 0);
            $bN = self::getVersionPart($b, $key, 0);

            // compare the two parts
            $res = CompareTwoNumbers::calculate($aN, $bN);

            // are they different?
            if ($res !== CompareTwoNumbers::BOTH_ARE_EQUAL) {
                return $res;
            }
        }

        // if we get here, then both $a and $b have the same X.Y.Z
        return CompareTwoNumbers::BOTH_ARE_EQUAL;
    }

    /**
     * fill in any missing fields in a version number
     *
     * @param  array $ver
     *         the version number as an array
     * @param  string $key
     *         the part of the version number we want
     * @param  mixed $default
     *         the value to return if the part does not exist
     * @return mixed
     *         the part of the version number required
     */
    private static function getVersionPart($ver, $key, $default)
    {
        if (isset($ver[$key])) {
            return $ver[$key];
        }

        return $default;
    }

    /**
     * compare the pre-release section of two versions
     *
     * @param  array $aVer
     * @param  array $bVer
     * @return int
     */
    private static function comparePreRelease($aVer, $bVer)
    {
        $aPre = self::getVersionPart($aVer, 'preRelease', null);
        $bPre = self::getVersionPart($bVer, 'preRelease', null);

        return CompareTwoPreReleases::calculate($aPre, $bPre);
    }
}


text:
ACCEPTED

#### According to
Index Fungorum

#### Published in
Ceské Houby 3: 500 (1921)

#### Original name
Pholiota rostrata Velen.

### Remarks
null


text:
$LOAD_PATH.unshift File.expand_path('../../lib', __FILE__)
require 'ip_net_active_record_type'

require 'minitest/autorun'


text:
package org.ehcache.impl.serialization;

import org.ehcache.core.spi.service.FileBasedPersistenceContext;
import org.ehcache.spi.serialization.Serializer;

import java.nio.ByteBuffer;

/**
 * Default {@link Serializer} for {@code Float} type. Simply writes the float value
 * to a byte buffer.
 */
public class FloatSerializer implements Serializer<Float> {

  /**
   * No arg constructor
   */
  public FloatSerializer() {
  }

  /**
   * Constructor to enable this serializer as a transient one.
   *

   *   Parameter is ignored as {@link Float} is a base java type.
   *

   *
   * @param classLoader the classloader to use
   *
   * @see Serializer
   */
  public FloatSerializer(ClassLoader classLoader) {
  }

  /**
   * Constructor to enable this serializer as a persistent one.
   *

   *   Parameters are ignored as {@link Float} is a base java type and this implementation requires no state.
   *

   *
   * @param classLoader the classloader to use
   * @param persistenceContext the persistence context
   *
   * @see Serializer
   */
  public FloatSerializer(ClassLoader classLoader, FileBasedPersistenceContext persistenceContext) {

  }

  /**
   * {@inheritDoc}
   */
  @Override
  public ByteBuffer serialize(Float object) {
    ByteBuffer byteBuffer = ByteBuffer.allocate(4);
    byteBuffer.putFloat(object).flip();
    return byteBuffer;
  }

  /**
   * {@inheritDoc}
   */
  @Override
  public Float read(ByteBuffer binary) throws ClassNotFoundException {
    float f = binary.getFloat();
    return f;
  }

  /**
   * {@inheritDoc}
   */
  @Override
  public boolean equals(Float object, ByteBuffer binary) throws ClassNotFoundException {
    return object.equals(read(binary));
  }
}


text:
package net.java.bd.tools.clipinf;

import javax.xml.bind.DatatypeConverter;
import javax.xml.bind.annotation.adapters.XmlAdapter;

/**
 *
 * @author A. Sundararajan
 * @author ggeorg
 */
public class HexStringBinaryAdapter extends XmlAdapter<String, byte[]> {

    public byte[] unmarshal(String str) throws Exception {
        if (str.startsWith("0x") || str.startsWith("0X")) {
            return DatatypeConverter.parseHexBinary(str.substring(2));
        }
        return DatatypeConverter.parseHexBinary(str);
    }

    public String marshal(byte[] value) throws Exception {
        return "0x" + DatatypeConverter.printHexBinary(value);
    }
}


text:
'use strict';

angular.module('ngShowcaseApp').controller('ctrl.thirdparty.baiduueditor', function ($scope,$sce) {
    var vm = $scope.vm = {};
    $scope.editorConfig={
        focus:true //自动把光标放到UEditor中。测试config配置
    }

    $scope.$watch('content',function(){
        $scope.html = $sce.trustAsHtml($scope.content);
    })
});