6 major server modules (PdkFriendServer/GlobalSever/ServerCore/GameModule/GameNetModule) + game logic (GameFix/GameDAL/ServerData) + network layer (NetWorkMessage) + data layer (ObjectModel) + utilities (MrWu/Core/Config/CloudAPI/dll) + adapters (zyxAdapter/base) .NET 8.0 C# solution, 16 projects, 958 source files
58 lines
1.2 KiB
C#
58 lines
1.2 KiB
C#
/********************************
|
|
*
|
|
* 作者:吴隆健
|
|
* 创建时间: 2019-05-31 19:31:37
|
|
*
|
|
********************************/
|
|
|
|
using System;
|
|
|
|
namespace MrWu.Model {
|
|
/// <summary>
|
|
/// 池模型
|
|
/// </summary>
|
|
/// <typeparam name="T"></typeparam>
|
|
public interface IPool<T> {
|
|
|
|
/// <summary>
|
|
/// 池容量 0表示不限制
|
|
/// </summary>
|
|
int capSize {
|
|
get;
|
|
}
|
|
|
|
/// <summary>
|
|
/// 最大的存活数量 0表示不限制
|
|
/// </summary>
|
|
int surviveCountSize {
|
|
get;
|
|
}
|
|
|
|
/// <summary>
|
|
/// 当前池中的数量
|
|
/// </summary>
|
|
int capCount {
|
|
get;
|
|
}
|
|
|
|
/// <summary>
|
|
/// 当前存活的两
|
|
/// </summary>
|
|
int surviveCount {
|
|
get;
|
|
}
|
|
|
|
/// <summary>t
|
|
/// 取出
|
|
/// </summary>
|
|
/// <returns></returns>
|
|
T TakeOut(params object[] pms);
|
|
|
|
/// <summary>
|
|
/// 放入
|
|
/// </summary>
|
|
/// <param name="data">放入池中的数据</param>
|
|
void PutInto(T data);
|
|
}
|
|
}
|