StructuralTypeConfiguration<TStructuralType>.CollectionProperty<TElementType> Method
Adds a collection property to the EDM type.
Namespace: System.Web.Http.OData.Builder
Assembly: System.Web.Http.OData (in System.Web.Http.OData.dll)
Syntax
'Declaration
Public Function CollectionProperty(Of TElementType) ( _
propertyExpression As Expression(Of Func(Of TStructuralType, IEnumerable(Of TElementType))) _
) As CollectionPropertyConfiguration
'Usage
Dim instance As StructuralTypeConfiguration
Dim propertyExpression As Expression(Of Func(Of TStructuralType, IEnumerable(Of TElementType)))
Dim returnValue As CollectionPropertyConfiguration
returnValue = instance.CollectionProperty(propertyExpression)
public CollectionPropertyConfiguration CollectionProperty<TElementType>(
Expression<Func<TStructuralType, IEnumerable<TElementType>>> propertyExpression
)
public:
generic<typename TElementType>
CollectionPropertyConfiguration^ CollectionProperty(
Expression<Func<TStructuralType, IEnumerable<TElementType>^>^>^ propertyExpression
)
member CollectionProperty :
propertyExpression:Expression<Func<'TStructuralType, IEnumerable<'TElementType>>> -> CollectionPropertyConfiguration
JScript does not support generic types and methods.
Type Parameters
- TElementType
The element type of the collection.
Parameters
- propertyExpression
Type: System.Linq.Expressions.Expression<Func<TStructuralType, IEnumerable<TElementType>>>
A lambda expression representing the navigation property for the relationship. For example, in C# t => t.MyProperty and in Visual Basic .NET Function(t) t.MyProperty .
Return Value
Type: System.Web.Http.OData.Builder.CollectionPropertyConfiguration
A configuration object that can be used to further configure the property.