2 * Copyright (c) 2013 Cisco Systems, Inc. and others. All rights reserved.
4 * This program and the accompanying materials are made available under the
5 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6 * and is available at http://www.eclipse.org/legal/epl-v10.html
8 package org.opendaylight.controller.sal.binding.impl;
10 import org.opendaylight.controller.sal.binding.spi.NotificationInvokerFactory.NotificationInvoker;
11 import org.opendaylight.yangtools.concepts.AbstractObjectRegistration;
12 import org.opendaylight.yangtools.concepts.ListenerRegistration;
13 import org.opendaylight.yangtools.yang.binding.NotificationListener;
15 public class GeneratedListenerRegistration extends AbstractObjectRegistration<NotificationListener> implements ListenerRegistration<NotificationListener> {
16 private final NotificationInvoker _invoker;
18 public NotificationInvoker getInvoker() {
22 private NotificationBrokerImpl notificationBroker;
24 public GeneratedListenerRegistration(final NotificationListener instance, final NotificationInvoker invoker, final NotificationBrokerImpl broker) {
26 this._invoker = invoker;
27 this.notificationBroker = broker;
31 protected void removeRegistration() {
32 this.notificationBroker.unregisterListener(this);
33 this.notificationBroker = null;
34 NotificationInvoker _invoker = this.getInvoker();