|
@@ -1,95 +1,101 @@
|
|
|
-using System;
|
|
|
-using WingServerCommon.Log;
|
|
|
-using WingServerCommon.Interfaces.OpLog;
|
|
|
-namespace WingServerCommon.Interfaces.Cache
|
|
|
-{
|
|
|
- public interface IDistributedServerInfosManager : IBaseCacheManager<CacheDistributedServerInfosDTO>
|
|
|
- {
|
|
|
-
|
|
|
- }
|
|
|
-
|
|
|
- public class DistributedServerInfosManager : CacheManager<CacheDistributedServerInfosDTO>, IDistributedServerInfosManager
|
|
|
- {
|
|
|
- public DistributedServerInfosManager() : base()
|
|
|
- {
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- public class CacheDistributedServerInfosDTO : ICacheObject
|
|
|
- {
|
|
|
- /// <summary>
|
|
|
- /// 编码
|
|
|
- /// </summary>
|
|
|
- public string Code { get; set; }
|
|
|
- /// <summary>
|
|
|
- /// 是否主服务器
|
|
|
- /// </summary>
|
|
|
- /// <value></value>
|
|
|
- public bool IsMaster { get; set; }
|
|
|
- /// <summary>
|
|
|
- /// 服务器名称
|
|
|
- /// </summary>
|
|
|
- public string Name { get; set; }
|
|
|
- /// <summary>
|
|
|
- /// 描述
|
|
|
- /// </summary>
|
|
|
- /// <value></value>
|
|
|
- public string Description { get; set; }
|
|
|
- /// <summary>
|
|
|
- /// 启用
|
|
|
- /// </summary>
|
|
|
- /// <value></value>
|
|
|
- public bool Enable { get; set; }
|
|
|
- /// <summary>
|
|
|
- /// 功能区分 官方或私有服务器
|
|
|
- /// </summary>
|
|
|
- /// <value></value>
|
|
|
- public int ServerType { get; set; }
|
|
|
- /// <summary>
|
|
|
- /// 云服务地址
|
|
|
- /// </summary>
|
|
|
- public string ServerUrl { get; set; }
|
|
|
- /// <summary>
|
|
|
- /// 纬度
|
|
|
- /// </summary>
|
|
|
- /// <value></value>
|
|
|
- public string Lat { get; set; }
|
|
|
- /// <summary>
|
|
|
- /// 经度
|
|
|
- /// </summary>
|
|
|
- /// <value></value>
|
|
|
- public string Lng { get; set; }
|
|
|
- /// <summary>
|
|
|
- /// 指定客户端IP访问此服务器
|
|
|
- /// </summary>
|
|
|
- /// <value></value>
|
|
|
- public List<CacheIPAddressInfoDTO> AssignClientIPList { get; set; }
|
|
|
- }
|
|
|
-
|
|
|
- /// <summary>
|
|
|
- /// IP 字段信息
|
|
|
- /// </summary>
|
|
|
- public class CacheIPAddressInfoDTO
|
|
|
- {
|
|
|
- /// <summary>
|
|
|
- /// 起始IP段
|
|
|
- /// </summary>
|
|
|
- /// <value></value>
|
|
|
- public string StartIp { get; set; }
|
|
|
- /// <summary>
|
|
|
- /// 结束IP段
|
|
|
- /// </summary>
|
|
|
- /// <value></value>
|
|
|
- public string EndIp { get; set; }
|
|
|
- /// <summary>
|
|
|
- /// 起始IP段 Long类型
|
|
|
- /// </summary>
|
|
|
- /// <value></value>
|
|
|
- public long LongStartIP { get; set; }
|
|
|
- /// <summary>
|
|
|
- /// 结束IP段 Long类型
|
|
|
- /// </summary>
|
|
|
- /// <value></value>
|
|
|
- public long LongEndIP { get; set; }
|
|
|
- }
|
|
|
+using System;
|
|
|
+using WingServerCommon.Log;
|
|
|
+using WingServerCommon.Interfaces.OpLog;
|
|
|
+namespace WingServerCommon.Interfaces.Cache
|
|
|
+{
|
|
|
+ public interface IDistributedServerInfosManager : IBaseCacheManager<CacheDistributedServerInfosDTO>
|
|
|
+ {
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+ public class DistributedServerInfosManager : CacheManager<CacheDistributedServerInfosDTO>, IDistributedServerInfosManager
|
|
|
+ {
|
|
|
+ public DistributedServerInfosManager() : base()
|
|
|
+ {
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ public class CacheDistributedServerInfosDTO : ICacheObject
|
|
|
+ {
|
|
|
+ /// <summary>
|
|
|
+ /// 编码
|
|
|
+ /// </summary>
|
|
|
+ public string Code { get; set; }
|
|
|
+ /// <summary>
|
|
|
+ /// 是否主服务器
|
|
|
+ /// </summary>
|
|
|
+ /// <value></value>
|
|
|
+ public bool IsMaster { get; set; }
|
|
|
+ /// <summary>
|
|
|
+ /// 服务器名称
|
|
|
+ /// </summary>
|
|
|
+ public string Name { get; set; }
|
|
|
+ /// <summary>
|
|
|
+ /// 描述
|
|
|
+ /// </summary>
|
|
|
+ /// <value></value>
|
|
|
+ public string Description { get; set; }
|
|
|
+ /// <summary>
|
|
|
+ /// 启用
|
|
|
+ /// </summary>
|
|
|
+ /// <value></value>
|
|
|
+ public bool Enable { get; set; }
|
|
|
+ /// <summary>
|
|
|
+ /// 功能区分 官方或私有服务器
|
|
|
+ /// </summary>
|
|
|
+ /// <value></value>
|
|
|
+ public int ServerType { get; set; }
|
|
|
+ /// <summary>
|
|
|
+ /// 云服务地址
|
|
|
+ /// </summary>
|
|
|
+ public string ServerUrl { get; set; }
|
|
|
+ /// <summary>
|
|
|
+ /// 纬度
|
|
|
+ /// </summary>
|
|
|
+ /// <value></value>
|
|
|
+ public string Lat { get; set; }
|
|
|
+ /// <summary>
|
|
|
+ /// 经度
|
|
|
+ /// </summary>
|
|
|
+ /// <value></value>
|
|
|
+ public string Lng { get; set; }
|
|
|
+ /// <summary>
|
|
|
+ /// 指定客户端IP访问此服务器
|
|
|
+ /// </summary>
|
|
|
+ /// <value></value>
|
|
|
+ public List<CacheIPAddressInfoDTO> AssignClientIPList { get; set; }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ /// 内网地址含端口
|
|
|
+ /// </summary>
|
|
|
+ /// <value></value>
|
|
|
+ public string LANHost { get; set; }
|
|
|
+ }
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ /// IP 字段信息
|
|
|
+ /// </summary>
|
|
|
+ public class CacheIPAddressInfoDTO
|
|
|
+ {
|
|
|
+ /// <summary>
|
|
|
+ /// 起始IP段
|
|
|
+ /// </summary>
|
|
|
+ /// <value></value>
|
|
|
+ public string StartIp { get; set; }
|
|
|
+ /// <summary>
|
|
|
+ /// 结束IP段
|
|
|
+ /// </summary>
|
|
|
+ /// <value></value>
|
|
|
+ public string EndIp { get; set; }
|
|
|
+ /// <summary>
|
|
|
+ /// 起始IP段 Long类型
|
|
|
+ /// </summary>
|
|
|
+ /// <value></value>
|
|
|
+ public long LongStartIP { get; set; }
|
|
|
+ /// <summary>
|
|
|
+ /// 结束IP段 Long类型
|
|
|
+ /// </summary>
|
|
|
+ /// <value></value>
|
|
|
+ public long LongEndIP { get; set; }
|
|
|
+ }
|
|
|
}
|