Entity Framework 5 and XElement fields

Pogosheep

New Member
Started playing with Visual Studio 2012 RC and Entity Framework 5... absolutely loving it but wondering if there's a cleaner way to do this.I would like to cut out the middle-man of parsing the XML every time, and setting it via .ToString()\[code\]public class MyEFEntity{ [NotMapped()] public XElement Tags { get { return XElement.Parse(tags); } set { tags = value.ToString(); } } [Column("Tags", TypeName = "xml"), Required] public string tags { get; set; }}\[/code\]
 
Back
Top