Yeah unfortunately James, the automapping code just can't deal with a
member of a generic type with more than one argument. It doesn't get
anywhere near applying overrides.

Marcus, you should exclude the entire class from automapping and
fluently map it.

2009/12/29 marcus <[email protected]>:
> The problem is that I get an exception just by adding a dictionary in
> my class and it does not even work to use the ignore property thingy
>
> On 28 Dec, 12:57, James Gregory <[email protected]> wrote:
>> Aye, just use an IAutomappingOverride for the entity in question.
>>
>> On Mon, Dec 28, 2009 at 11:47 AM, Paul Batum <[email protected]> wrote:
>> > It's not supported. I estimate that none of the regular contributors
>> > consider this a high priority so its unlikely to get attention any
>> > time soon, unless a member of the community submits a patch.
>>
>> > On Sat, Dec 26, 2009 at 9:42 PM, marcus <[email protected]> wrote:
>> > > I don't think the automapper supports dictionaries, I have asked the
>> > > question myself but I sadly did not get an answer.
>>
>> > > On 24 Dec, 00:59, DanielT <[email protected]> wrote:
>> > >> I have an entity like so in a test project:
>>
>> > >> ------------------------------------------------------------
>>
>> > >> public class Land {
>> > >>     public virtual IDictionary<string, int> Damages { get; set; }
>>
>> > >> }
>>
>> > >> ------------------------------------------------------------
>>
>> > >> I'm using this code to try and automap it:
>>
>> > >> ------------------------------------------------------------
>>
>> > >> var model = AutoMap.AssemblyOf<Land>().Where(t => t.Namespace ==
>> > >> "Test.DomainModel");
>>
>> > >> Fluently.Configure()
>> > >>     .Database(SQLiteConfiguration.Standard.InMemory)
>> > >>     .Mappings(m => m.AutoMappings.Add(model)
>> > >>     .BuildSessionFactory();
>>
>> > >> ------------------------------------------------------------
>>
>> > >> When I execute the configurer, I get the following exception:
>>
>> > >> "The type or method has 2 generic parameter(s), but 1 generic argument
>> > >> (s) were provided. A generic argument must be provided for each
>> > >> generic parameter."
>>
>> > >> A search on Google seems to indicate that this issue has been around
>> > >> for a while now, but no solutions have turned up. Does the automapper
>> > >> support dictionaries? Or is this a known issue that hasn't been
>> > >> resolved yet?
>>
>> > > --
>>
>> > > You received this message because you are subscribed to the Google Groups
>> > "Fluent NHibernate" group.
>> > > To post to this group, send email to [email protected].
>> > > To unsubscribe from this group, send email to
>> > [email protected]<fluent-nhibernate%[email protected]>
>> > .
>> > > For more options, visit this group at
>> >http://groups.google.com/group/fluent-nhibernate?hl=en.
>>
>> > --
>>
>> > You received this message because you are subscribed to the Google Groups
>> > "Fluent NHibernate" group.
>> > To post to this group, send email to [email protected].
>> > To unsubscribe from this group, send email to
>> > [email protected]<fluent-nhibernate%[email protected]>
>> > .
>> > For more options, visit this group at
>> >http://groups.google.com/group/fluent-nhibernate?hl=en.
>
> --
>
> You received this message because you are subscribed to the Google Groups 
> "Fluent NHibernate" 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/fluent-nhibernate?hl=en.
>
>
>

--

You received this message because you are subscribed to the Google Groups 
"Fluent NHibernate" 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/fluent-nhibernate?hl=en.


Reply via email to