ModelAttributes Class

Definition

Provides access to the combined list of attributes associated with a Type, property, or parameter.

public ref class ModelAttributes
public class ModelAttributes
type ModelAttributes = class
Public Class ModelAttributes
Inheritance
ModelAttributes

Constructors

ModelAttributes(IEnumerable<Object>, IEnumerable<Object>)
Obsolete.

Creates a new ModelAttributes for a property.

ModelAttributes(IEnumerable<Object>)
Obsolete.

Creates a new ModelAttributes for a Type.

Properties

Attributes

Gets the set of all attributes. If this instance represents the attributes for a property, the attributes on the property definition are before those on the property's Type. If this instance represents the attributes for a parameter, the attributes on the parameter definition are before those on the parameter's Type.

ParameterAttributes

Gets the set of attributes on the parameter, or null if this instance does not represent the attributes for a parameter.

PropertyAttributes

Gets the set of attributes on the property, or null if this instance does not represent the attributes for a property.

TypeAttributes

Gets the set of attributes on the Type. If this instance represents a property, then TypeAttributes contains attributes retrieved from PropertyType. If this instance represents a parameter, then contains attributes retrieved from ParameterType.

Methods

GetAttributesForParameter(ParameterInfo, Type)

Gets the attributes for the given parameterInfo with the specified modelType.

GetAttributesForParameter(ParameterInfo)

Gets the attributes for the given parameterInfo.

GetAttributesForProperty(Type, PropertyInfo, Type)

Gets the attributes for the given property with the specified modelType.

GetAttributesForProperty(Type, PropertyInfo)

Gets the attributes for the given property.

GetAttributesForType(Type)

Gets the attributes for the given type.

Applies to