// Copyright (c) .NET Foundation. All rights reserved.
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
using System;
namespace Microsoft.AspNetCore.Mvc.Rendering
{
///
/// Form-related extensions for .
///
public static class HtmlHelperFormExtensions
{
///
/// Renders a <form> start tag to the response. The <form>'s action attribute value will
/// match the current request.
///
/// The instance this method extends.
///
/// An instance which renders the </form> end tag when disposed.
///
///
/// In this context, "renders" means the method writes its output using .
///
public static MvcForm BeginForm(this IHtmlHelper htmlHelper)
{
if (htmlHelper == null)
{
throw new ArgumentNullException(nameof(htmlHelper));
}
// Generates