How to map collection of enum list<enum>
I am using fluent automapping. I was trying to map a collection list but it failed. I tried googling for it and nothing made sense. only thing i found was to wrap the enum as a class...i hopping for something more better than this. i am open to doing fluent mapping even nhibernate hbm mapping.
Support Staff 2 Posted by James Gregory on 09 Sep, 2010 06:39 AM
How is it failing?
3 Posted by yayadavid on 16 Sep, 2010 08:56 PM
Hi Glant,
Using list to combine enum values is always difficult to work with even outside FN. I noticed asp.net mvc will always flag it as an error during model binding.
You may want to consider using bit operations to combine your enums. I have used it this way with much success with FN and asp.net mvc.
You may also want to check out this article (http://www.codeproject.com/Articles/37921/Enums-Flags-and-Csharp-Oh...) on codeproject for further information on bit operation on enum.
Happy coding.