How to work with Enums in Entity Framework?

Solution 1:

There is a somewhat better way to do it in EF 4. Unfortunately, it won't work in EF 1.

Here's another approach.

Update: Real enum support was added in the June 2011 EF CTP.

Solution 2:

Update:
Entity Framework now supports Enums nativity.

Original:
This is one of those irritating things about EF. Will not be supporting it yet!

Or you can do something like:

public MyEnum MyEnumProperty  
{  
  get { return (MyEnum) InnerEnumProperty; }  
  set { InnerEnumProperty = (int) value; }  
}

But it makes me feel dirty.