예제 #1
0
        public void ProcessItemElement(string rootDirectory, ProjectItemElement itemElement, bool conditionResult)
        {
            LazyItemOperation operation = null;

            if (itemElement.IncludeLocation != null)
            {
                operation = BuildIncludeOperation(rootDirectory, itemElement, conditionResult);
            }
            else if (itemElement.RemoveLocation != null)
            {
                operation = BuildRemoveOperation(rootDirectory, itemElement, conditionResult);
            }
            else if (itemElement.UpdateLocation != null)
            {
                operation = BuildUpdateOperation(rootDirectory, itemElement, conditionResult);
            }
            else
            {
                ErrorUtilities.ThrowInternalErrorUnreachable();
            }

            LazyItemList previousItemList = GetItemList(itemElement.ItemType);
            LazyItemList newList          = new LazyItemList(previousItemList, operation);

            _itemLists[itemElement.ItemType] = newList;
        }
예제 #2
0
        public void ProcessItemElement(string rootDirectory, ProjectItemElement itemElement, bool conditionResult)
        {
            LazyItemOperation operation = null;

            if (itemElement.IncludeLocation != null)
            {
                operation = BuildIncludeOperation(rootDirectory, itemElement, conditionResult);
            }
            else if (itemElement.RemoveLocation != null)
            {
                operation = BuildRemoveOperation(rootDirectory, itemElement);
            }
            else if (itemElement.UpdateLocation != null)
            {
                operation = BuildUpdateOperation(rootDirectory, itemElement);
            }
            else
            {
                throw new NotImplementedException();
            }

            LazyItemList previousItemList = GetItemList(itemElement.ItemType);
            LazyItemList newList          = new LazyItemList(previousItemList, operation);

            _itemLists[itemElement.ItemType] = newList;
        }
예제 #3
0
 public LazyItemList(LazyItemList previous, LazyItemOperation operation)
 {
     _previous          = previous;
     _memoizedOperation = new MemoizedOperation(operation);
 }
예제 #4
0
 public LazyItemList(LazyItemList previous, LazyItemOperation operation)
 {
     _previous  = previous;
     _operation = operation;
 }
예제 #5
0
 public MemoizedOperation(LazyItemOperation operation)
 {
     Operation = operation;
 }