public ProcessingStateData
     (
     WorkItemSlotsConfiguration
         configuration
     )
 {
     _retrievedItems = WorkItemSlotCollection.Create(configuration);
     _submittedItems = new WorkItemCollection();
 }
 // TODO: Sync (SD)
 public static WorkItemSlotCollection Create(WorkItemSlotsConfiguration configuration)
 {
     // TODO: Sync (SD)
     return new WorkItemSlotCollection
         (
         configuration
         );
 }
        protected WorkItemSlotCollection
            (
            WorkItemSlotsConfiguration configuration
            )
        //: this()
        {
            _configuration = configuration;
            int currentStartIndex = 0;
            int currentEndIndex = 0;

            for (int i = 0; i < _configuration.PrioritySlotCounts.Count; i++)
            {
                if (i > 0) currentStartIndex += currentEndIndex;
                currentEndIndex += _configuration.PrioritySlotCounts[i].Count;

                _indexes.Add
                    (
                    new PrioritySlotsIndex
                        (
                        _configuration.PrioritySlotCounts[i].SubmissionPriority,
                        currentStartIndex,
                        currentEndIndex
                        ));
                _counters.Add
                    (
                    new PriorityWorkItemsRequestedCounter
                        (
                        _configuration.PrioritySlotCounts[i].SubmissionPriority
                        ));

                for (int k = 0; k < _configuration.PrioritySlotCounts[i].Count; k++)
                {
                    Add
                        (
                        WorkItemSlot.Create(_configuration.PrioritySlotCounts[i].SubmissionPriority)
                        );
                }
            }
        }