C# Class Rebel.Cms.Web.Mvc.Metadata.RebelModelMetadataProvider

Rebel meta data provider
Inheritance: Rebel.Framework.Localization.Web.Mvc.LocalizingModelMetadataProvider
Mostra file Open project: RebelCMS/rebelcmsxu5

Protected Methods

Method Description
CreateMetadata ( IEnumerable attributes, Type containerType, Func modelAccessor, Type modelType, string propertyName ) : ModelMetadata

Performs some custom meta data binding based on custom attributes, etc...

IsEmbeddedView ( IEnumerable attributes, Type modelType, string &viewPath ) : bool

Checks for the EmbeddedViewAttribute

Because view paths can be quite long and we are limited to 260 characters based on the .Net framework, we need to hash the URL, and store a reference to it. Then we can look up the hash again later. This will also improve performance when determining if a virtual URL is in fact a virtual URL.

Private Methods

Method Description
DocTypePropOverride ( IEnumerable attributes ) : bool
ShowLabel ( IEnumerable attributes ) : bool

Method Details

CreateMetadata() protected method

Performs some custom meta data binding based on custom attributes, etc...
protected CreateMetadata ( IEnumerable attributes, Type containerType, Func modelAccessor, Type modelType, string propertyName ) : ModelMetadata
attributes IEnumerable
containerType System.Type
modelAccessor Func
modelType System.Type
propertyName string
return ModelMetadata

IsEmbeddedView() protected method

Checks for the EmbeddedViewAttribute
Because view paths can be quite long and we are limited to 260 characters based on the .Net framework, we need to hash the URL, and store a reference to it. Then we can look up the hash again later. This will also improve performance when determining if a virtual URL is in fact a virtual URL.
protected IsEmbeddedView ( IEnumerable attributes, Type modelType, string &viewPath ) : bool
attributes IEnumerable
modelType System.Type
viewPath string Returns the hash code for the view path
return bool