djutils v2.1.1
Changes in djutils project, event package:
EventProducer
implementsRemoteException
for all methods. This enables the usage of theEventProducer
andEventListener
as remote objects, where a remoteEventListener
can calladdListener()
on a remoteEventProducer
, and theEventProducer
can callnotify()
on a remoteEventListener
.- The
LocalEventProducer
wraps all methods withRemoteException
. Since it is a local (non-remote) class, noRemoteException
s will be thrown. Therefore, the class wraps all methods and throws theRemoteException
embedded in aRuntimeException
. - The Event-producing collections now extend
LocalEventProducer
. This to avoid having to wrap all methods to avoid throwingRemoteExceptions
for all methods. Of course, a more generic version that also acts as a remote event producing collection could be built as well. - The
RmiObject
can throw aRemoteException
on thegetRegistry()
method. - The
RmiEventProducer
throwsRemoteException
on all methods.
These changes should make remote publish/subscribe through the event package more robust.