public virtual Release Release(PriorityRequest request)
 {
     var release = new Release(Environment, request, TriggerRequest);
       ReleaseQueue.Enqueue(release);
       TriggerRelease();
       return release;
 }
예제 #2
0
 public virtual PriorityRequest Request(int priority = 1) {
   var request = new PriorityRequest(Environment, TriggerRelease, DisposeCallback, priority);
   if (!RequestQueue.ContainsKey(priority))
     RequestQueue.Add(priority, new LinkedList<PriorityRequest>());
   RequestQueue[priority].AddLast(request);
   TriggerRequest();
   return request;
 }
        public virtual Release Release(PriorityRequest request)
        {
            var release = new Release(Environment, request, TriggerRequest);

            ReleaseQueue.Enqueue(release);
            TriggerRelease();
            return(release);
        }
        public virtual PriorityRequest Request(int priority = 1)
        {
            var request = new PriorityRequest(Environment, TriggerRelease, DisposeCallback, priority);

            if (!RequestQueue.ContainsKey(priority))
            {
                RequestQueue.Add(priority, new LinkedList <PriorityRequest>());
            }
            RequestQueue[priority].AddLast(request);
            TriggerRequest();
            return(request);
        }