Futurescale, Inc. PureMVC Home

The PureMVC Framework Code at the Speed of Thought


Over 10 years of community discussion and knowledge are maintained here as a read-only archive.

New discussions should be taken up in issues on the appropriate projects at https://github.com/PureMVC

Show Posts

| * |

  Show Posts
Pages: [1]
1  PureMVC Manifold / Bug Report / [FIXED] Mediator Class: listNotificationInterests returns null on: June 09, 2010, 06:39:11
In the base Mediator class, the listNotificiationInterests method returns 'null' by default.
:
public String[] listNotificationInterests( )
{
return null;
}

If you try to create a Mediator subclass and don't implement a listNotificationsInterests method, you will get a NullPointer exception because it is being referenced in registerMediator method of the View Class.
:
// Get Notification interests, if any.
String[] noteInterests = mediator.listNotificationInterests();
if (noteInterests.length == 0) {
return;
}

I think the default listNotificationsInterests should probably return a new String[] instead.

Thoughts?
Pages: [1]