Archive

Ruurd Boeke has recently released PostSharp4ET, a PostSharp plug-in allowing to use Microsoft Entity Framework without plumbing code -- PostSharp generates it for you at build-time. PostSharp4ET is released as a part of Entity Framework Contrib hosted on CodePlex.com.

With PostSharp4ET, enabling persistency on a class should be as easy as decorating it with a custom attribute:

[Poco("ConnectionName")]
public class Person
{
   public int PersonID { get; set; }
   public string Firstname { get; set; }
   public string Lastname { get; set; }
}

Under the hood, EF-specific interfaces are implemented automatically at build time.

Ruurd explains everything extensively on his blog. And even if you are not interested in Microsoft Entity Framework, Ruurd's blog is a great introduction to how to write more complex aspect libraries with PostSharp.

Thank you Ruurd for this excellent work!

Comments are closed