Class HumanizedLabelsDisplayMetadataProvider
Data Annotations Model Metadata Provider that transforms camel-case view model property names to sentence case for their display name unless the display name has already been overriden.
Inheritance
System.Object
HumanizedLabelsDisplayMetadataProvider
Implements
Microsoft.AspNetCore.Mvc.ModelBinding.Metadata.IDisplayMetadataProvider
Microsoft.AspNetCore.Mvc.ModelBinding.Metadata.IMetadataDetailsProvider
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: ChameleonForms
Assembly: ChameleonForms.dll
Syntax
public class HumanizedLabelsDisplayMetadataProvider : IDisplayMetadataProvider, IMetadataDetailsProvider
Constructors
| Improve this Doc View SourceHumanizedLabelsDisplayMetadataProvider(IStringTransformer)
Declaration
public HumanizedLabelsDisplayMetadataProvider(IStringTransformer to = null)
Parameters
Type | Name | Description |
---|---|---|
Humanizer.IStringTransformer | to | The string transformer to use when creating display labels |
Methods
| Improve this Doc View SourceCreateDisplayMetadata(DisplayMetadataProviderContext)
Creates the display metadata for a property that results in humanized labels.
Declaration
public void CreateDisplayMetadata(DisplayMetadataProviderContext context)
Parameters
Type | Name | Description |
---|---|---|
Microsoft.AspNetCore.Mvc.ModelBinding.Metadata.DisplayMetadataProviderContext | context | The display metadata provider context for the property |
Implements
Microsoft.AspNetCore.Mvc.ModelBinding.Metadata.IDisplayMetadataProvider
Microsoft.AspNetCore.Mvc.ModelBinding.Metadata.IMetadataDetailsProvider