示例#1
0
 /// <summary>
 /// Adds the next middleware in the execution chain.
 /// </summary>
 /// <param name="nextMiddleware"></param>
 public void Use(AbstractMiddleware <TContext> nextMiddleware)
 {
     if (ReferenceEquals(null, nextMiddleware))
     {
         throw new ArgumentNullException(nameof(nextMiddleware), "Who are you?");
     }
     ExecutionChain.Append(nextMiddleware);
 }
示例#2
0
 public void Append(AbstractMiddleware <TContext> next)
 {
     executionQueue.Enqueue(next);
 }