refactor: Move OpenSim.Framework.PacketPool to OpenSim.Region.Clientstack.Linden.UDP

This is to allow it to use OpenSim.Framework.Monitoring in the future.
This is also a better location since the packet pool is linden udp specific
connector_plugin
Justin Clark-Casey (justincc) 2012-10-05 01:12:56 +01:00
parent d98af79f77
commit f0178a6a41
1 changed files with 5 additions and 3 deletions

View File

@ -32,9 +32,8 @@ using OpenMetaverse;
using OpenMetaverse.Packets;
using log4net;
namespace OpenSim.Framework
namespace OpenSim.Region.ClientStack.LindenUDP
{
public sealed class PacketPool
{
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
@ -44,6 +43,9 @@ namespace OpenSim.Framework
private bool packetPoolEnabled = true;
private bool dataBlockPoolEnabled = true;
/// <summary>
/// Pool of packets available for reuse.
/// </summary>
private readonly Dictionary<PacketType, Stack<Packet>> pool = new Dictionary<PacketType, Stack<Packet>>();
private static Dictionary<Type, Stack<Object>> DataBlocks =
@ -244,4 +246,4 @@ namespace OpenSim.Framework
}
}
}
}
}