views:

88

answers:

0

I try to write a (fluent) mapping against an interface

public interface IOrderDiscount : IDomainObject<long>

where

public interface IDomainObject<IdT> : IDomainObject
{
   IdT Id { get; }
}

like so (and all other thinkable varieties of access strategies)

Id(d => d.Id, "DiscountId")
    .GeneratedBy.HiLo("9")
    .WithUnsavedValue(0)
    .Access.AsReadOnlyPropertyThroughCamelCaseField();

but all I get are variations of

Could not find field 'id' in class 'IOrderDiscount'

My base class implements this as

public virtual IdT Id { get; protected set; }

but event using a backing field does not change a thing.

So I am left to wonder, how I could get this to work...
Anyone with an idea?