Beispiel #1
0
        protected IDisposable EnterScope()
        {
            var scope = this.Scope;

            this.Scope = this.Scope.CreateSubScope();

            return(new ActionOnDispose(() => this.Scope = scope));
        }
Beispiel #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ValidationScope"/> class.
 /// </summary>
 /// <param name="parent">
 /// The parent.
 /// </param>
 private ValidationScope([NotNull] ValidationScope parent)
     : this(parent.context)
 {
     this.Parent = parent;
 }