I used the following statement to construct an EntityShapeGraph with RIA Services. Note that the first two properties (Sector and Owner) return single entities while the third and fourth (AssetAllocation and Option_Platform) return collections.
Edge(Of [Option], Sector)(Function(x) x.Sector).
Edge(Of [Option], Owner)(Function(x) x.Owner).
Edge(Of [Option], AssetAllocation)(Function(x) x.AssetAllocations).
Edge(Of [Option], Option_Platform)(Function(x) x.Option_Platform)
I am finding that only the properties that return single entitites are being included in the EntityGraphShape. The documentation indicated that collection properties are supported through the Carpark example and the following EntityGraphShape and the edges
related to Cars, Wheels and Doors.
.Edge<CarPark, Car>(CarPark => CarPark.Cars)
.Edge<Car, Wheel>(Car => Car.Wheels)
.Edge<Car, Door>(Car => Car.Doors)
.Edge<Car, Engine>(Car => Car.Engine)
.Edge<Truck, Trailer>(Truck => Truck.Trailer);
I guess that the problem is somewhere within the Edge method but don't see any obvious cause.
public EntityGraphShape Edge<TLHS, TRHS>(Expression<EdgeEnumType<TLHS, TRHS>> edge)
Type type = edge.Parameters.Single<ParameterExpression>().Type;
if (edge.Body as MemberExpression)
MemberExpression body = (MemberExpression)edge.Body;
PropertyInfo member = body.Member as PropertyInfo;
if (type != null && member != null)
this.edges.Add(new Tuple<Type, PropertyInfo>(type, member));
Is there something that I am missing here?