Could you output the generated hbm.xml for your mappings and post it here.
We'll have a look see if anything seems wrong with it.

If you're using the Fluently.Configure method of configuration, on the
FluentMappings property there's a ExportTo method you can point to a
directory and have the mappings written out there.

On Thu, May 13, 2010 at 2:02 PM, TigerShark <kenneth.siew...@gmail.com>wrote:

> No one?
>
> On 12 Maj, 17:46, TigerShark <kenneth.siew...@gmail.com> wrote:
> > Sure... Thought it might have been a known bug, so it wouldn't be
> > necessary...
> >
> > public class Foo
> > {
> >     private int _id;
> >
> >     public virtual int Id
> >     {
> >         get { return _id; }
> >     }
> >
> >     public virtual Bar Bar { get; set; }
> >
> > }
> >
> > public class Bar
> > {
> >     private string _property1;
> >     private string _property2;
> >
> >     public virtual string Property1
> >     {
> >         get { return _property1; }
> >     }
> >
> >     public virtual string Property2
> >     {
> >         get { return _property2; }
> >     }
> >
> > }
> >
> > My default access strategy is backing field, and it works with the Id
> > and Bar property, but not the properties of the component (Bar).
> >
> > Kenneth
> >
> > On 12 Maj, 15:58, cliff vaughn <cliftonfvau...@gmail.com> wrote:
> >
> >
> >
> >
> >
> > > how about including the definition of Foo?
> >
> > > On Wed, May 12, 2010 at 5:58 AM, TigerShark <kenneth.siew...@gmail.com
> >wrote:
> >
> > > > Okay, something is seriously wrong here.
> > > > If I change the class properties to automatic, and keep the custom
> > > > access, I get an error telling me that the manual backingfields for
> > > > the properties are missing ("_property1" and "_property2").
> >
> > > > On 12 Maj, 11:40, TigerShark <kenneth.siew...@gmail.com> wrote:
> > > > > I'm facing a strange problem.
> >
> > > > > I have a class with a nested component containing two properties.
> > > > > My default access strategy is backing field, but for the component,
> > > > > I'd like to use camelcase field. When I try to set the access
> strategy
> > > > > explicitly for the component, I get an error telling me that the
> > > > > backing field for the property, couldn't be found.
> >
> > > > > Is this a bug?
> >
> > > > > I can override the access strategy for properties on my normal
> class
> > > > > maps, but not on components.
> >
> > > > > Example mapping:
> >
> > > > > public sealed class FooMap : ClassMap<Foo>
> > > > > {
> > > > >    public FooMap()
> > > > >    {
> > > > >        Table("foo");
> > > > >        Id(x => x.Id, "id")
> > > > >            .Access.CamelCaseField(Prefix.Underscore);
> >
> > > > >        Component(x => x.Bar, b =>
> > > > >        {
> > > > >            b.Map(x => x.Property1, "col1")
> > > > >                .Access.CamelCaseField(Prefix.Underscore); // <-
> Fails
> > > > >            b.Map(x => x.Property2, "col2")
> > > > >                .Access.CamelCaseField(Prefix.Underscore); // <-
> Fails
> > > > >         });
> > > > >    }
> >
> > > > > }
> >
> > > > > --
> > > > > You received this message because you are subscribed to the Google
> Groups
> > > > "Fluent NHibernate" group.
> > > > > To post to this group, send email to
> fluent-nhibern...@googlegroups.com.
> > > > > To unsubscribe from this group, send email to
> > > > fluent-nhibernate+unsubscr...@googlegroups.com<fluent-nhibernate%2bunsubscr...@googlegroups.com><fluent-nhibernate%2Bunsubscr
> i...@googlegroups.com>
> > > > .
> > > > > For more options, visit this group athttp://
> > > > 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
> fluent-nhibern...@googlegroups.com.
> > > > To unsubscribe from this group, send email to
> > > > fluent-nhibernate+unsubscr...@googlegroups.com<fluent-nhibernate%2bunsubscr...@googlegroups.com><fluent-nhibernate%2Bunsubscr
> i...@googlegroups.com>
> > > > .
> > > > For more options, visit this group at
> > > >http://groups.google.com/group/fluent-nhibernate?hl=en.
> >
> > > --
> > > thanks
> >
> > > cliff
> >
> > > --
> > > You received this message because you are subscribed to the Google
> Groups "Fluent NHibernate" group.
> > > To post to this group, send email to
> fluent-nhibern...@googlegroups.com.
> > > To unsubscribe from this group, send email to
> fluent-nhibernate+unsubscr...@googlegroups.com<fluent-nhibernate%2bunsubscr...@googlegroups.com>
> .
> > > For more options, visit this group athttp://
> 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 fluent-nhibern...@googlegroups.com.
> > To unsubscribe from this group, send email to
> fluent-nhibernate+unsubscr...@googlegroups.com<fluent-nhibernate%2bunsubscr...@googlegroups.com>
> .
> > For more options, visit this group athttp://
> 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 fluent-nhibern...@googlegroups.com.
> To unsubscribe from this group, send email to
> fluent-nhibernate+unsubscr...@googlegroups.com<fluent-nhibernate%2bunsubscr...@googlegroups.com>
> .
> 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 fluent-nhibern...@googlegroups.com.
To unsubscribe from this group, send email to 
fluent-nhibernate+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/fluent-nhibernate?hl=en.

Reply via email to