/// <summary> /// Log that a behavior was applied, modifying the normal /// execution flow. /// </summary> /// <param name="operation">The executing operation</param> /// <param name="behavior">The beahvior being applied</param> /// <param name="description">A description of how the behavior modified the exectuion /// flow</param> public void BehaviorWasApplied(IOperation operation, OperationBehavior behavior, string description) { Verify.NotNull(operation, nameof(operation)); Verify.NotNull(behavior, nameof(behavior)); Verify.NotNull(description, nameof(description)); Verify.Operation(_levelInfo.Count > 0, "No operation was logged as started so an operation behavior cannot be logged."); PrepareForChildItem(); _writer.Write(behavior.GetType().Name + ": " + description); }
public void BehaviorWasApplied(IOperation operation, OperationBehavior behavior, string description) { AppliedBehaviors.Add(new BehaviorApplication{ Behavior = behavior, Operation = operation, Description = description }); }