Do not instantiate a Consumer for registration 54/88154/1
authorRobert Varga <robert.varga@pantheon.tech>
Sat, 29 Feb 2020 10:51:34 +0000 (11:51 +0100)
committerRobert Varga <robert.varga@pantheon.tech>
Sat, 29 Feb 2020 10:51:34 +0000 (11:51 +0100)
commitca904da16e245610b2ae8163ebe85bcdee86686f
treeccca8146270e8f466d8bde1f2d491cb9b443e043
parent37df6c5ab6f1a06ad5a64c0f97f2a24670a35031
Do not instantiate a Consumer for registration

Taking a Consumer forces us to instantiate it to capture listeners
Set. We can do the same by simply moving the reference away. For
safety we only get a Collection<?>, for which remove(Object) is just
what we want.

Change-Id: I4f3bd473a75dabee1d1a31e10cf0fefe57c4896b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
common/util/src/main/java/org/opendaylight/yangtools/util/ListenerRegistry.java