As the title implies: what are the pros and cons using Annotations instead of the Fluent API (or reversed)?
Asked
Active
Viewed 370 times
0

BenMorel
- 34,448
- 50
- 182
- 322

Savvas Sopiadis
- 8,213
- 10
- 34
- 53
-
1Here was a similar question: http://stackoverflow.com/q/5354900/270591 – Slauma Apr 15 '11 at 15:02
1 Answers
3
If you are purist you will not use Data Annotations because they make your POCO class little bit dirty. Also data annotations are only for simple mapping features. If you need more complex mapping you have to use fluent API anyway. Final choice for basic mapping is subjective.

Ladislav Mrnka
- 360,892
- 59
- 660
- 670