6

I keep searching the web for examples of the new fluent API syntax in Microsoft's Entity Framework technology previews ... I come up with bits and pieces here and there.

Is there any reliable place to go to find ALL the possibilities? And maybe something that explains them a bit ("HasRequired", "WithMany", etc.)?

FYI, I am specifically trying to figure out how to define a foreign key/primary key relationship explicitly through fluent API.

Cynthia
  • 2,100
  • 5
  • 34
  • 48

3 Answers3

7

No, unfortunately, not at this time. The current syntax is a preview and subject to change. There is no official documentation yet. There is nothing in MSDN. The best one-stop example I found is here. See also this post and the items linked there.

Folks on the leading edge can expect turbulence. :)

Update: The API documentation was just released.

Craig Stuntz
  • 125,891
  • 12
  • 252
  • 273
2

I know this question has more than one year old, but for those who arrive here: MSDN now has an entry on Code First Fluent API with introductory examples and common tasks.

Alpha
  • 7,586
  • 8
  • 59
  • 92
2

The best reference at the moment are blog posts (=> google). You can start with ADO.NET Team blog where are announced new features with examples.

Glorfindel
  • 21,988
  • 13
  • 81
  • 109
Ladislav Mrnka
  • 360,892
  • 59
  • 660
  • 670