csharp/2881099/FreeRedis/src/FreeRedis/RedisClient/Adapter/BaseAdapter.cs

BaseAdapter.cs
using FreeRedis.Internal;
using System;
using System.Collections.Generic;
using System.Text;
using System.Threading;
using System.Threading.Tasks;

namespace FreeRedis
{
    partial clast RedisClient
    {
        protected internal enum UseType
        {
            Pooling,
            Cluster,
            Sentinel,
            SingleInside,
            SingleTemp,

            Pipeline,
            Transaction,
        }

        protected internal abstract partial clast BaseAdapter
        {
            public static ThreadLocal _rnd = new ThreadLocal(() => new Random());
            public UseType UseType { get; protected set; }
            protected internal RedisClient TopOwner { get; protected set; }

            public abstract void Refersh(IRedisSocket redisSocket);
            public abstract IRedisSocket GetRedisSocket(CommandPacket cmd);
            public abstract void Dispose();

            public abstract TValue AdapterCall(CommandPacket cmd, Func parse);

#if isasync
            public abstract Task AdapterCallAsync(CommandPacket cmd, Func parse);
#endif

        }
    }
}