A regular Enum property mapped as an int?,
I've heard something about that
I think in that case you have a _ghost_:
http://fabiomaulo.blogspot.com/2008/10/how-test-your-mappings-ghostbuster.html

<http://fabiomaulo.blogspot.com/2008/10/how-test-your-mappings-ghostbuster.html>Execute
the ghostbuster with that entity and let us know what Dr. Egon think about
that.

2009/10/27 Mark <[email protected]>

>
> Thanks for the observation, but if I just have a regular property of
> an enum it maps it no problem, so why not in this case ? why is it
> inconsistent ?
>
> Are you saying that it is impossible to map an enum keyed
> IDictionary ?
>
>
>
> On Oct 27, 4:42 am, Fabio Maulo <[email protected]> wrote:
> > enum!=int
> >
> > 2009/10/26 Mark <[email protected]>
> >
> >
> >
> >
> >
> >
> >
> > > I'm using castle activerecord to map a generic IDictionary<enum, bool>
> >
> > > I've got it running and am able to save data but if I try to retrieve
> > > I get this exception:
> > > {"The value \"0\" is not of type \"Project.PropertyType\" and cannot
> > > be used in this generic collection. Parameter name: key"}
> >
> > > PropertyType is my enum,
> > > The mapping that AR has created is:
> > > <class name="MyProject.Item, MyProject" table="Item">
> > > ...
> > > <map name="Properties" access="property" table="ItemProperties"
> > > lazy="false">
> > > <key column="ItemID" />
> > > <index column="Idx" type="int" />
> > > <element column="Value" type="System.Boolean, mscorlib"/>
> > > </map>
> >
> > > I'm trying to figure out whats wrong here, as the examples I see seem
> > > to follow the same mapping..
> >
> > > Thanks
> >
> > --
> > Fabio Maulo- Hide quoted text -
> >
> > - Show quoted text -
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"nhusers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/nhusers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to