Exemplo n.º 1
0
        /// <summary>
        /// Matches a request by HTTP method.
        /// </summary>
        /// <param name="builder">The request matching builder instance.</param>
        /// <param name="httpMethod">The HTTP method.</param>
        /// <returns>The request matching builder instance.</returns>
        public static RequestMatching Method(this RequestMatching builder, string httpMethod)
        {
            if (httpMethod is null)
            {
                throw new ArgumentNullException(nameof(httpMethod));
            }

            return(builder.Method(new HttpMethod(httpMethod)));
        }