DRAG DROP
There is MS Visual Studio 2010 and MS .NET Framework 4 application PassGuideApp.
PassGuideApp uses the ADO.NET Entity Framework.
POCO is used for entity modeling.
There is a POCO class.
The POCO class is to be used by change-tracking proxies and by an ObjectContext.
How can this be ensured?
Leave a Reply
Action #1 is incorrect. See the following link:
http://msdn.microsoft.com/en-us/library/vstudio/dd468057%28v=vs.100%29.aspx
Specifically, it mentions the following requirements for change tracking proxies:
Each property that is mapped to a property of an entity type in the data model must have non-sealed (NotOverridable in Visual Basic), public, and virtual (Overridable in Visual Basic) get and set accessors.
A navigation property that represents the “many” end of a relationship must return a type that implements ICollection, where T is the type of the object at the other end of the relationship.
So we have for Accessors:
○ non-sealed
○ public
○ virtual
And Navigation Property
○ should implement ICollection.
So Action#1 should be:
The navigation property…
…modified to…
…returning a type implementing the interface…
IColleciton