public MessageQueue(MessageModule module) { excuteMap = Framework.GlobalAllocate <Dictionary <StablePriorityQueueNode, Message> >(); int count = Framework.GetGlbalPoolCount <StablePriorityQueue <StablePriorityQueueNode> >(); _priorityQueue = count == 0 ? new StablePriorityQueue <StablePriorityQueueNode>() : Framework.GlobalAllocate <StablePriorityQueue <StablePriorityQueueNode> >(); _updatelist = Framework.GlobalAllocate <List <StablePriorityQueueNode> >(); this.module = module; }
public MessageQueue(MessageModule module) { nodePool = new StablePriorityQueueNodePool(); excuteMap = new Dictionary <StablePriorityQueueNode, Message>(); _pool = new MessagePool(); _queue = new StablePriorityQueue <StablePriorityQueueNode>(); _list = new List <StablePriorityQueueNode>(); _tmp = new Queue <Message>(); this.module = module; }