Interesting feature.Please create a JIRA as Improv or NewFeature.
Thanks.
2008/10/1 Roger Kratz <[EMAIL PROTECTED]>
> I mean that sometimes the concrete type or rather; an interface of all
> the concrete type's member is not interesting, only some more fine grained
> interface.
>
>
>
> An extremely bad example would be that I have a Person class mapped, but in
> this particular application an IPerson is quite uninteresting - I'm working
> with animals and nationalities. In this case I would have
>
>
>
> class Person : IEntity, IAnimal, INationality
>
> …
>
> interface IEntity
>
> {
>
> Guid Id { get; set; }
>
> […]
>
> }
>
> interface IAnimal
>
> {
>
> int Weight { get; set; }
>
> […]
>
> }
>
> interface INationality
>
> {
>
> INation Country { get; set; }
>
> […]
>
> }
>
>
>
> Here it would be nice if the proxy would derive from/implement the three
> interfaces above…
>
> <class name="Person" proxy=(IEntity, IAnimal, INationality)
>
> …instead I need to create an IPerson deriving from these three interfaces
> even though it's not needed anywhere in the application.
>
>
>
> Sorry for not coming up with a more "real life example", but I hope you get
> the picture.
>
>
>
> Simply put – without nhibernate, I wouldn't have that many "1:1
> relationships" between entities and their interfaces as I do when using
> nhibernate. Maybe I've missed something?
>
>
>
> /Roger
>
>
>
> PS: Yes, I do know I can skip the proxy definition all together and let the
> proxy derive from the concrete type instead.
>
>
>
>
>
> *From:* [email protected] [mailto:[EMAIL PROTECTED] *On
> Behalf Of *Ayende Rahien
> *Sent:* den 1 oktober 2008 13:45
> *To:* [email protected]
> *Subject:* [nhusers] Re: Proxy and fine grained interfaces
>
>
>
> Um, what are you tryig to do?
>
> On Wed, Oct 1, 2008 at 2:40 PM, Roger Kratz <[EMAIL PROTECTED]>
> wrote:
>
> Hi
>
>
>
> As far as I know there is no way to let nhib create a proxy out of multiple
> interfaces? It would from time to time be nice to be able to do something
> like…
>
> <class name="foo" proxy="app.interfaces.IBar1, app.interfaces |
> app.interfaces.IBar2, app.interfaces" ….>
>
> …instead of merging the IBar1 and IBar2 into a single one just to get the
> proxy capabilities to rock.
>
>
>
> Is this a limitation in nhib or castle proxy?
>
>
>
> /Roger
>
>
>
>
>
>
>
>
>
> >
>
--
Fabio Maulo
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---