private void PopOperations() { for (int i = 0; i < _propertyOperations.Count; i++) { PropertyOperationCollection propertyOperations = _propertyOperations[i]; for (int j = propertyOperations.Count - 1; j >= 0; j--) { if (propertyOperations[j].Depth == _depth) { propertyOperations.RemoveAt(j); } } } }
private void PushOperations(XElement element) { foreach (Operation operation in CreateOperationsFromElement(element)) { _propertyOperations ??= new StringKeyedCollection <PropertyOperationCollection>(); if (!_propertyOperations.TryGetValue(operation.PropertyName, out PropertyOperationCollection propertyOperations)) { propertyOperations = new PropertyOperationCollection(operation.PropertyDefinition); _propertyOperations.Add(propertyOperations); } propertyOperations.Add(operation); } }