ToolboxItem.ValidatePropertyType(String, Object, Type, Boolean) 메서드

정의

개체가 지정된 형식인지 유효성을 검사합니다.

protected:
 void ValidatePropertyType(System::String ^ propertyName, System::Object ^ value, Type ^ expectedType, bool allowNull);
protected void ValidatePropertyType (string propertyName, object value, Type expectedType, bool allowNull);
protected void ValidatePropertyType (string propertyName, object? value, Type expectedType, bool allowNull);
member this.ValidatePropertyType : string * obj * Type * bool -> unit
Protected Sub ValidatePropertyType (propertyName As String, value As Object, expectedType As Type, allowNull As Boolean)

매개 변수

propertyName
String

유효성을 검사할 속성의 이름입니다.

value
Object

유효성을 검사할 선택적 값입니다.

expectedType
Type

속성의 필요한 형식입니다.

allowNull
Boolean

true을 허용하면 null이고, 그렇지 않으면 false입니다.

예외

valuenull이고 allowNullfalse인 경우

valueexpectedType에 지정된 형식이 아닌 경우

설명

메서드는 ValidatePropertyType 메서드에 대한 도우미 메서드로 호출됩니다 ValidatePropertyValue .

적용 대상