StructuralObject.VerifyComplexObjectIsNotNull<TComplex>(TComplex, String) 方法

定义

验证复杂对象不为 nullVerifies that a complex object is not null.

protected public:
generic <typename TComplex>
 where TComplex : System::Data::Objects::DataClasses::ComplexObject static TComplex VerifyComplexObjectIsNotNull(TComplex complexObject, System::String ^ propertyName);
protected internal static TComplex VerifyComplexObjectIsNotNull<TComplex> (TComplex complexObject, string propertyName) where TComplex : System.Data.Objects.DataClasses.ComplexObject;
static member VerifyComplexObjectIsNotNull : 'Complex * string -> 'Complex (requires 'Complex :> System.Data.Objects.DataClasses.ComplexObject)
Protected Friend Shared Function VerifyComplexObjectIsNotNull(Of TComplex As ComplexObject) (complexObject As TComplex, propertyName As String) As TComplex

类型参数

TComplex

正在验证的复杂对象的类型。The type of the complex object being verified.

参数

complexObject
TComplex

正在检验的复杂对象。The complex object that is being validated.

propertyName
String

父对象上与 complexObject 关联的复杂属性。The complex property on the parent object that is associated with complexObject.

返回

TComplex

正在验证的复杂对象。The complex object being validated.

例外

当复杂类型为 NULL 时。When the complex type is null.

适用于