System.Web.ModelBinding 命名空间

System.Web.ModelBinding 命名空间提供让你能够将数据对象绑定到 ASP.NET Web 窗体服务器控件的类。 The System.Web.ModelBinding namespace provides classes that enable you to bind data objects to ASP.NET Web Forms server controls.

ArrayModelBinder<TElement>

将浏览器请求映射到数组。Maps a browser request to an array.

ArrayModelBinderProvider

为数组提供模型绑定器。Provides a model binder for arrays.

AssociatedMetadataProvider

提供用于实现元数据提供程序的抽象类。Provides an abstract class to implement a metadata provider.

AssociatedValidatorProvider

为用于实现验证提供程序的类提供抽象类。Provides an abstract class for classes that implement a validation provider.

BinaryDataModelBinderProvider

获取二进制数据的模型绑定器。Gets a model binder for binary data.

BindingBehaviorAttribute

为模型绑定行为属性提供基类。Provides a base class for model-binding behavior attributes.

BindNeverAttribute

提供属性,其可指定模型绑定应排除的属性。Provides an attribute that specifies that model binding should exclude a property.

BindRequiredAttribute

提供属性,其可指定某个属性为模型绑定必需。Provides an attribute that specifies that a property is required for model binding.

CollectionModelBinder<TElement>

将浏览器请求映射到集合。Maps a browser request to a collection.

CollectionModelBinderProvider

为集合提供模型绑定器。Provides a model binder for a collection.

ComplexModel

使用集合而不是各个属性如数据存储区来描述复杂模型。Describes a complex model, using a collection rather than individual properties as the data store.

ComplexModelBinder

将浏览器请求映射到复杂数据模型。Maps a browser request to a complex data model.

ComplexModelBinderProvider

为复杂模型提供模型绑定器。Provides a model binder for a complex model.

ComplexModelResult

提供按 ComplexModel 类存储的数据的容器。Provides a container for data that is stored by the ComplexModel class.

ControlAttribute

表示属性,其指定模型绑定的值由控件提供。Represents an attribute that specifies that values for model binding are provided by a control.

ControlValueProvider

表示控件值的值提供程序。Represents a value provider for control values.

CookieAttribute

表示属性,其指定模型绑定值由 cookie 提供。Represents an attribute that specifies that the values for model binding are provided by a cookie.

CookieValueProvider

表示 cookie 值的值提供程序。Represents a value provider for cookie values.

DataAnnotationsModelMetadata

为数据模型的公共元数据、DataAnnotationsModelMetadataProvider 类和 DataAnnotationsModelValidator 类提供容器。Provides a container for common metadata, for the DataAnnotationsModelMetadataProvider class, and for the DataAnnotationsModelValidator class for a data model.

DataAnnotationsModelMetadataProvider

实现默认模型元数据提供程序。Implements the default model metadata provider.

DataAnnotationsModelValidator

提供模型验证程序。Provides a model validator.

DataAnnotationsModelValidator<TAttribute>

为指定的验证类型提供模型验证程序。Provides a model validator for a specified validation type.

DataAnnotationsModelValidatorProvider

实现默认验证提供程序。Implements the default validator provider.

DefaultModelBinder

将浏览器请求映射到数据对象。Maps a browser request to a data object. 该类提供模型联编程序的具体实现。This class provides a concrete implementation of a model binder.

DictionaryModelBinder<TKey,TValue>

将浏览器请求映射到字典数据对象。Maps a browser request to a dictionary data object.

DictionaryModelBinderProvider

为词典提供模型绑定器。Provides a model binder for a dictionary.

DictionaryValueProvider<TValue>

表示值提供程序的基类,这些值提供程序的值来自实现 IDictionary<TKey,TValue> 接口的集合。Represents the base class for value providers whose values come from a collection that implements the IDictionary<TKey,TValue> interface.

EmptyModelMetadataProvider

为不需要元数据的数据模型提供空的元数据提供程序。Provides an empty metadata provider for data models that do not require metadata.

ExtensibleModelBinderAttribute

为模型类型指定联编程序类型。Specifies the binder type for a model type.

FormAttribute

表示属性,其指定模型绑定的值由表格字段提供。Represents an attribute that specifies that values for model binding are provided by a form field.

FormValueProvider

表示表格值的值提供程序。Represents a value provider for form values.

GenericModelBinderProvider

获取泛型类型的模型绑定器。Gets a model binder for a generic type.

KeyValuePairModelBinder<TKey,TValue>

将浏览器请求映射到键/值对数据对象。Maps a browser request to a key/value pair data object.

KeyValuePairModelBinderProvider

为键值/值对的集合提供模型绑定器。Provides a model binder for a collection of key/value pairs.

MaxLengthAttributeAdapter

MaxLengthAttribute 特性提供适配器。Provides an adapter for the MaxLengthAttribute attribute.

MinLengthAttributeAdapter

MinLengthAttribute 特性提供适配器。Provides an adapter for the MinLengthAttribute attribute.

ModelBinderDictionary

为应用程序的所有模型绑定器(按绑定器类型列出)提供容器。Provides a container for all model binders for the application, listed by binder type.

ModelBinderErrorMessageProviders

为模型绑定器错误消息提供程序提供容器。Provides a container for model-binder error message providers.

ModelBinderProvider

为模型绑定器提供程序提供摘要基类。Provides an abstract base class for model binder providers.

ModelBinderProviderCollection

为模型绑定器提供程序的集合提供容器。Provides a container for a collection of model binder providers.

ModelBinderProviderOptionsAttribute

表示对模型绑定器提供程序指定选项的属性。Represents an attribute that specifies options for a model-binder provider.

ModelBinderProviders

为应用程序的模型绑定器提供程序提供容器。Provides a container for model binder providers for the application.

ModelBinders

提供对应用程序的模型联编程序的全局访问。Provides global access to the model binders for the application.

ModelBindingContext

提供运行模型联编程序的上下文。Provides the context in which a model binder functions.

ModelBindingExecutionContext

封装模型绑定系统所需的外部所有信息。Encapsulates all of the information that is external to the model binding system that the model binding system needs.

ModelError

表示在模型绑定期间发生的错误。Represents an error that occurs during model binding.

ModelErrorCollection

为模型验证错误提供一个容器。Provides a container for model validation errors.

ModelMetadata

提供容器,用于模型元数据。Provides a container for metadata for a model.

ModelMetadataProvider

为自定义元数据提供程序提供抽象基类。Provides an abstract base class for a custom metadata provider.

ModelMetadataProviders

为当前的 ModelMetadataProvider 实例提供容器。Provides a container for the current ModelMetadataProvider instance.

ModelState

封装模型绑定状态。Encapsulates the state of model binding.

ModelStateDictionary

表示模型绑定状态。Represents the state of model binding.

ModelValidatedEventArgs

Validated 事件提供数据。Provides data for the Validated event.

ModelValidatingEventArgs

Validating 事件提供数据。Provides data for the Validating event.

ModelValidationNode

为模型验证信息提供容器。Provides a container for model validation information.

ModelValidationResult

为验证结果提供容器。Provides a container for a validation result.

ModelValidator

提供用于实现验证逻辑的基类。Provides a base class for implementing validation logic.

ModelValidatorProvider

提供模型验证程序的集合。Provides a collection of model validators.

ModelValidatorProviderCollection

为验证提供程序的集合提供容器。Provides a container for a collection of validation providers.

ModelValidatorProviders

为当前验证提供程序提供容器。Provides a container for the current validation provider.

MutableObjectModelBinder

将浏览器请求映射到可变数据对象。Maps a browser request to a mutable data object.

MutableObjectModelBinderProvider

为可变对象提供模型绑定器。Provides a model binder for mutable objects.

NameValueCollectionValueProvider

表示值提供程序的基类,这些值提供程序的值来自名称/值集合。Represents the base class for value providers whose values come from a name/value collection.

ProfileAttribute

表示属性,其指定模型绑定的值由配置文件提供。Represents an attribute that specifies that values for model binding are provided by a profile.

ProfileValueProvider

表示配置文件值的值提供程序。Represents a value provider for profile values.

QueryStringAttribute

表示属性,其指定模型绑定值由查询字符串值提供。Represents an attribute that specifies that model binding values are provided by a query string value.

QueryStringValueProvider

表示查询字符串值的值提供程序。Represents a value provider for query-string values.

RangeAttributeAdapter

RangeAttribute 特性提供适配器。Provides an adapter for the RangeAttribute attribute.

RegularExpressionAttributeAdapter

RegularExpressionAttribute 特性提供适配器。Provides an adapter for the RegularExpressionAttribute attribute.

RequiredAttributeAdapter

RequiredAttribute 特性提供适配器。Provides an adapter for the RequiredAttribute attribute.

RouteDataAttribute

表示属性,其指定模型绑定的值由路由数据提供。Represents an attribute that specifies that values for model binding are provided by route data.

RouteDataValueProvider

表示路由数据的值提供程序。Represents a value provider for route data.

SessionAttribute

表示属性,其指定模型绑定的值由会话状态提供。Represents an attribute that specifies that values for model binding are provided by session state.

SimpleModelBinderProvider

为简单类型提供模型绑定器。Provides a model binder for a simple type.

SimpleValueProvider

委托单个键值/值查找的值提供程序。Represents a value provider for single key/value lookups.

StringLengthAttributeAdapter

StringLengthAttribute 特性提供适配器。Provides an adapter for the StringLengthAttribute attribute.

TypeConverterModelBinder

将浏览器请求映射到数据对象。Maps a browser request to a data object. 当模型绑定需要通过 .NET Framework 类型转换器转换时使用此类型。This type is used when model binding requires conversions using a .NET Framework type converter.

TypeConverterModelBinderProvider

对需要类型转换的模型提供一个模型绑定器。Provides a model binder for a model that requires type conversion.

TypeMatchModelBinder

将浏览器请求映射到数据对象。Maps a browser request to a data object. 此类用于当模型绑定不需要类型转换时。This class is used when model binding does not require type conversion.

TypeMatchModelBinderProvider

对不需要类型转换的模型提供一个模型绑定器。Provides a model binder for a model that does not require type conversion.

UserProfileAttribute

表示属性,其指定模型绑定的值由用户配置文件提供。Represents an attribute that specifies that values for model binding are provided by a user profile.

UserProfileValueProvider

表示用户配置文件值的值提供程序。Represents a value provider for user profiles.

ValidatableObjectAdapter

对实现 IValidatableObject 接口的对象提供适配器。Provides an adapter for objects that implement the IValidatableObject interface.

ValueProviderCollection

表示应用程序的值提供程序对象的集合。Represents the collection of value-provider objects for the application.

ValueProviderResult

表示来自值提供程序的检索值的结果。Represents the result of retrieving a value from a value provider.

ValueProviderSourceAttribute

提供值提供程序属性的基本类,其可用在方法参数中以指定模型绑定的源,例如 FormAttributeQueryStringAttributeViewStateAttributeProvides a base class for value-provider attributes that can be used in method parameters to specify the source of values for model binding, such as FormAttribute, QueryStringAttribute, and ViewStateAttribute.

ViewStateAttribute

表示属性,其指定模型绑定的值由视图状态提供。Represents an attribute that specifies that values for model binding are provided by view state.

ViewStateValueProvider

表示视图状态的值提供程序。Represents a value provider for view state values.

接口

IMetadataAware

定义一种必须由类执行的元数据识别方法。Defines a method that must be implemented by classes that are metadata-aware.

IModelBinder

定义模型联编程序所需的方法。Defines the method that is required for a model binder.

IModelNameProvider

提供指一种方式,用于指定用于模型绑定的备用名称,而不是使用参数名。Provides a way to specify an alternate name to use for model binding instead of using the parameter name.

IUnvalidatedValueProvider

定义未经过验证值提供程序所需的方法。Defines the method that is required for an unvalidated value provider.

IUnvalidatedValueProviderSource

定义对于值提供程序所需的跳转请求测试支持的方法。Defines the methods that are required for a value provider that supports skipping request validation.

IValueProvider

定义值提供程序所需的方法。Defines the methods that are required for a value provider.

IValueProviderSource

定义一个值提供程序源所需的方法。Defines the method that is required for a value provider source.

枚举

BindingBehavior

枚举模型绑定的行为选项。Enumerates model-binding behavior options.

委托

DataAnnotationsModelValidationFactory

表示创建 DataAnnotationsModelValidatorProvider 实例的方法。Represents the method that creates a DataAnnotationsModelValidatorProvider instance.

DataAnnotationsValidatableObjectAdapterFactory

表示验证器的出厂设置,其基于 IValidatableObject 接口。Represents a factory for validators that are based on the IValidatableObject interface.

ModelBinderErrorMessageProvider

表示方法,其可提供模型绑定错误消息。Represents a method that provides a model-binding error message.

注解

在 Web 窗体中使用模型绑定系列教程,请参阅模型绑定和 Web 窗体For a tutorial series on using model binding with Web Forms, see Model Binding and Web Forms.