certain event types share the same interface type

Description

events like PostUpdate and PostCommitUpdate share the same type (IPostUpdateEventListener)
by itself this is ok, but it causes lots of problems because of the way the events are identified by the interface that they use.

the problems that i know which are caused by this:

  • NHEventListeners.GetEventListenerTypes() returns duplicates. Because of this, ActiveRecord registers certain events twice because it relies on this list not containing duplicates.

  • NHEventListeners.GetProperty() may not return the property which you are after. which causes other things to not necessarily return what you are after.

this is mainly annoying me because of how this effects ActiveRecord (because active record uses the interface type to determine the event type), but it is likely to to affect many other things aswell.

Environment

None

Activity

Show:

Matthew Fenner June 6, 2009 at 8:19 AM

if anyone else is interested in this, the AR issue can be found at:
http://support.castleproject.org/projects/AR/issues/view/AR-ISSUE-261

Matthew Fenner June 6, 2009 at 7:35 AM

oh. sorry. NHEventListeners is a ActiveRecord class. my mistake. i will log this in AR

Fabio Maulo June 6, 2009 at 6:42 AM

Inside NH listeners are classified by ListenerType (enum).
If you want access to each listener you can use, separately, you can use Configuration.EventListeners property.

NHEventListeners in not a class of NHibernate so I don't know what you are talking about.

Fabio Maulo June 6, 2009 at 6:33 AM

Which is the reason to classify this matter as bug ?

External Issue

Details

Assignee

Reporter

Components

Affects versions

Priority

Who's Looking?

Open Who's Looking?
Created June 6, 2009 at 5:26 AM
Updated June 6, 2009 at 8:19 AM
Resolved June 6, 2009 at 6:42 AM
Who's Looking?