Class LLDPSpeaker
java.lang.Object
org.opendaylight.openflowplugin.applications.lldpspeaker.LLDPSpeaker
- All Implemented Interfaces:
AutoCloseable
,Runnable
,NodeConnectorEventsObserver
public final class LLDPSpeaker
extends Object
implements NodeConnectorEventsObserver, Runnable, AutoCloseable
Objects of this class send LLDP frames over all flow-capable ports that can be discovered through inventory.
-
Constructor Summary
ConstructorsConstructorDescriptionLLDPSpeaker
(DeviceOwnershipService deviceOwnershipService, org.opendaylight.mdsal.binding.api.RpcService rpcService, org.opendaylight.mdsal.binding.api.RpcProviderService rpcProviderService, LldpSpeakerConfig config) -
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
Closes this resource, relinquishing any underlying resources.void
onNodeConnectorDown
(org.opendaylight.yangtools.binding.DataObjectIdentifier.WithKey<NodeConnector, NodeConnectorKey> nodeConnectorInstanceId) This method is called when some node connector is removed from inventory or when existing node connector changed its status to DOWN.void
onNodeConnectorUp
(org.opendaylight.yangtools.binding.DataObjectIdentifier.WithKey<NodeConnector, NodeConnectorKey> nodeConnectorInstanceId, FlowCapableNodeConnector flowConnector) This method is called when new node connector is added to inventory or when existing node connector changed its status to UP.void
run()
Send LLDPDU frames to all known openflow switch ports.
-
Constructor Details
-
LLDPSpeaker
public LLDPSpeaker(DeviceOwnershipService deviceOwnershipService, org.opendaylight.mdsal.binding.api.RpcService rpcService, org.opendaylight.mdsal.binding.api.RpcProviderService rpcProviderService, LldpSpeakerConfig config)
-
-
Method Details
-
close
public void close()Closes this resource, relinquishing any underlying resources.- Specified by:
close
in interfaceAutoCloseable
-
run
public void run()Send LLDPDU frames to all known openflow switch ports. -
onNodeConnectorUp
public void onNodeConnectorUp(org.opendaylight.yangtools.binding.DataObjectIdentifier.WithKey<NodeConnector, NodeConnectorKey> nodeConnectorInstanceId, FlowCapableNodeConnector flowConnector) Description copied from interface:NodeConnectorEventsObserver
This method is called when new node connector is added to inventory or when existing node connector changed its status to UP.- Specified by:
onNodeConnectorUp
in interfaceNodeConnectorEventsObserver
- Parameters:
nodeConnectorInstanceId
- Object that uniquely identify added node connectorflowConnector
- object containing almost all of details about node connector
-
onNodeConnectorDown
public void onNodeConnectorDown(org.opendaylight.yangtools.binding.DataObjectIdentifier.WithKey<NodeConnector, NodeConnectorKey> nodeConnectorInstanceId) Description copied from interface:NodeConnectorEventsObserver
This method is called when some node connector is removed from inventory or when existing node connector changed its status to DOWN.- Specified by:
onNodeConnectorDown
in interfaceNodeConnectorEventsObserver
- Parameters:
nodeConnectorInstanceId
- Object that uniquely identify added node connector
-