EdmReferentialConstraint.Create Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Creates a new EdmReferentialConstraint using the provided dependentProperties
and principalProperties
to form the pairs.
public static Microsoft.OData.Edm.EdmReferentialConstraint Create (System.Collections.Generic.IEnumerable<Microsoft.OData.Edm.IEdmStructuralProperty> dependentProperties, System.Collections.Generic.IEnumerable<Microsoft.OData.Edm.IEdmStructuralProperty> principalProperties);
static member Create : seq<Microsoft.OData.Edm.IEdmStructuralProperty> * seq<Microsoft.OData.Edm.IEdmStructuralProperty> -> Microsoft.OData.Edm.EdmReferentialConstraint
Public Shared Function Create (dependentProperties As IEnumerable(Of IEdmStructuralProperty), principalProperties As IEnumerable(Of IEdmStructuralProperty)) As EdmReferentialConstraint
Parameters
- dependentProperties
- IEnumerable<IEdmStructuralProperty>
The dependent properties that participate in the referential constraint. Assumed to be in the correct order relative to the principal entity's properties.
- principalProperties
- IEnumerable<IEdmStructuralProperty>
The principal properties that participate in the referential constraint. Assumed to be in the correct order relative to the dependent entity's properties.
Returns
The newly created referential constraint.
Exceptions
Thrown if the number of dependent properties given does not match the number of key properties in the principal entity type.