예제 #1
0
        public Task <ActionResult> GetRouteWithDashAsync([FromServices] IGetRouteWithDashHandler handler, CancellationToken cancellationToken)
        {
            if (handler is null)
            {
                throw new ArgumentNullException(nameof(handler));
            }

            return(InvokeGetRouteWithDashAsync(handler, cancellationToken));
        }
예제 #2
0
 private static async Task <ActionResult> InvokeGetRouteWithDashAsync([FromServices] IGetRouteWithDashHandler handler, CancellationToken cancellationToken)
 {
     return(await handler.ExecuteAsync(cancellationToken));
 }