{
String methodName = method.getName();
if (methodName.equals("addNotificationListener") && args != null)
{
NotificationListener notiListener = (NotificationListener) args[0];
NotificationFilter filter = (NotificationFilter) args[1];
Object handback = args[2];
// This will send along the real ObjectName and not the Proxy name.
server.addNotificationListener(objectName, notiListener, filter, handback);
return null;
}
else if (methodName.equals("removeNotificationListener") && args != null)
{
NotificationListener notiListener = (NotificationListener) args[0];
// This will send along the real ObjectName and not the Proxy name.
server.removeNotificationListener(objectName, notiListener);
return null;
}