Show / Hide Table of Contents

    Interface IForm<TModel>

    Interface for a Chameleon Form.

    Inherited Members
    IForm.CreatePartialForm<TPartialModel>(LambdaExpression, IHtmlHelper<TPartialModel>)
    System.IDisposable.Dispose()
    Namespace: ChameleonForms
    Assembly: ChameleonForms.dll
    Syntax
    public interface IForm<TModel> : IForm, IDisposable
    Type Parameters
    Name Description
    TModel

    The view model type for the current view

    Properties

    | Improve this Doc View Source

    HtmlHelper

    The HTML helper for the current view.

    Declaration
    IHtmlHelper<TModel> HtmlHelper { get; }
    Property Value
    Type Description
    Microsoft.AspNetCore.Mvc.Rendering.IHtmlHelper<TModel>
    | Improve this Doc View Source

    Template

    The template renderer for the current view.

    Declaration
    IFormTemplate Template { get; }
    Property Value
    Type Description
    IFormTemplate

    Methods

    | Improve this Doc View Source

    CreatePartialForm(IHtmlHelper<TModel>)

    Returns a wrapped ChameleonForms.PartialViewForm`1 for the given partial view helper.

    Declaration
    IForm<TModel> CreatePartialForm(IHtmlHelper<TModel> partialViewHelper)
    Parameters
    Type Name Description
    Microsoft.AspNetCore.Mvc.Rendering.IHtmlHelper<TModel> partialViewHelper

    The HTML Helper from the partial view

    Returns
    Type Description
    IForm<TModel>

    The PartialViewForm wrapping the original form

    | Improve this Doc View Source

    GetFieldGenerator<T>(Expression<Func<TModel, T>>)

    The field generator for the given field.

    Declaration
    IFieldGenerator GetFieldGenerator<T>(Expression<Func<TModel, T>> property)
    Parameters
    Type Name Description
    System.Linq.Expressions.Expression<System.Func<TModel, T>> property

    The property to return the field generator for

    Returns
    Type Description
    IFieldGenerator
    Type Parameters
    Name Description
    T
    | Improve this Doc View Source

    Write(IHtmlContent)

    Writes a HTML String directly to the view's output.

    Declaration
    void Write(IHtmlContent htmlContent)
    Parameters
    Type Name Description
    Microsoft.AspNetCore.Html.IHtmlContent htmlContent

    The HTML to write to the view's output

    Extension Methods

    HtmlAttributesExtensions.ToHtmlAttributes(Object)
    ChameleonFormExtensions.PartialForAsync<TModel, TPartialModel>(IForm<TModel>, Expression<Func<TModel, TPartialModel>>, String)
    FieldExtensions.FieldElementFor<TModel, T>(IForm<TModel>, Expression<Func<TModel, T>>, IFieldConfiguration)
    FieldExtensions.LabelFor<TModel, T>(IForm<TModel>, Expression<Func<TModel, T>>, IFieldConfiguration)
    FieldExtensions.ValidationMessageFor<TModel, T>(IForm<TModel>, Expression<Func<TModel, T>>, IFieldConfiguration)
    MessageExtensions.BeginMessage<TModel>(IForm<TModel>, MessageType, String)
    MessageExtensions.BeginMessage<TModel>(IForm<TModel>, MessageType, IHtmlContent)
    MessageExtensions.BeginMessage<TModel>(IForm<TModel>, MessageType, Func<Object, IHtmlContent>)
    NavigationExtensions.BeginNavigation<TModel>(IForm<TModel>)
    SectionExtensions.BeginSection<TModel>(IForm<TModel>, String, IHtmlContent, HtmlAttributes)
    SectionExtensions.BeginSection<TModel>(IForm<TModel>, String, Func<Object, IHtmlContent>, HtmlAttributes)
    SectionExtensions.BeginSection<TModel>(IForm<TModel>, IHtmlContent, IHtmlContent, HtmlAttributes)
    SectionExtensions.BeginSection<TModel>(IForm<TModel>, Func<Object, IHtmlContent>, Func<Object, IHtmlContent>, HtmlAttributes)
    • Improve this Doc
    • View Source
    Back to top © Copyright 2012-2020 MRCollective, Rob Moore, Matt Davies and the contributors to ChameleonForms.