Class LearningSwitchManagerSimpleImpl
java.lang.Object
org.opendaylight.openflowplugin.learningswitch.LearningSwitchManagerSimpleImpl
- All Implemented Interfaces:
AutoCloseable
,DataTreeChangeListenerRegistrationHolder
public final class LearningSwitchManagerSimpleImpl
extends Object
implements DataTreeChangeListenerRegistrationHolder, AutoCloseable
Listens to packetIn notification.
- in HUB mode simply floods all switch ports (except ingress port)
- in LSWITCH mode collects source MAC address of packetIn and bind it with ingress port. If target MAC address is already bound then a flow is created (for direct communication between corresponding MACs)
-
Constructor Summary
ConstructorDescriptionLearningSwitchManagerSimpleImpl
(org.opendaylight.mdsal.binding.api.DataBroker dataBroker, org.opendaylight.mdsal.binding.api.NotificationService notificationService, org.opendaylight.mdsal.binding.api.RpcService rpcService) -
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
org.opendaylight.yangtools.concepts.Registration
Returns the DataTreeChangeListenerRegistration.
-
Constructor Details
-
LearningSwitchManagerSimpleImpl
public LearningSwitchManagerSimpleImpl(org.opendaylight.mdsal.binding.api.DataBroker dataBroker, org.opendaylight.mdsal.binding.api.NotificationService notificationService, org.opendaylight.mdsal.binding.api.RpcService rpcService)
-
-
Method Details
-
close
public void close()- Specified by:
close
in interfaceAutoCloseable
-
getDataTreeChangeListenerRegistration
public org.opendaylight.yangtools.concepts.Registration getDataTreeChangeListenerRegistration()Description copied from interface:DataTreeChangeListenerRegistrationHolder
Returns the DataTreeChangeListenerRegistration.- Specified by:
getDataTreeChangeListenerRegistration
in interfaceDataTreeChangeListenerRegistrationHolder
-