Validator.ValidateProperty 方法

定义

对属性执行验证并返回包含验证结果的 ValidationErrorCollection

protected public:
 System::Workflow::ComponentModel::Compiler::ValidationErrorCollection ^ ValidateProperty(System::Reflection::PropertyInfo ^ propertyInfo, System::Object ^ propertyOwner, System::Object ^ propertyValue, System::Workflow::ComponentModel::Compiler::ValidationManager ^ manager);
protected internal System.Workflow.ComponentModel.Compiler.ValidationErrorCollection ValidateProperty (System.Reflection.PropertyInfo propertyInfo, object propertyOwner, object propertyValue, System.Workflow.ComponentModel.Compiler.ValidationManager manager);
member this.ValidateProperty : System.Reflection.PropertyInfo * obj * obj * System.Workflow.ComponentModel.Compiler.ValidationManager -> System.Workflow.ComponentModel.Compiler.ValidationErrorCollection
Protected Friend Function ValidateProperty (propertyInfo As PropertyInfo, propertyOwner As Object, propertyValue As Object, manager As ValidationManager) As ValidationErrorCollection

参数

propertyInfo
PropertyInfo

有关主题属性的 PropertyInfo

propertyOwner
Object

属性的所有者。

propertyValue
Object

该属性的值。

manager
ValidationManager

此操作的 ValidationManager

返回

ValidationErrorCollection

包含验证结果的 ValidationErrorCollection

注解

如果验证没有产生错误,则返回空 ValidationErrorCollection

适用于