Dear,

Sorry for my simple question.

I tried to put False in dpset in order to track the disconnection from the
switch. Is there any example to put False.

class EventDP(EventDPBase):
"""
An event class to notify connect/disconnect of a switch.
For OpenFlow switches, one can get the same notification by observing
ryu.controller.ofp_event.EventOFPStateChange.
An instance has at least the following attributes.
========= =================================================================
Attribute Description
========= =================================================================
dp A ryu.controller.controller.Datapath instance of the switch
enter True when the switch connected to our controller. False for
disconnect.
ports A list of port instances.
========= =================================================================
"""
def __init__(self, dp, enter_leave):
# enter_leave
# True: dp entered
# False: dp leaving
super(EventDP, self).__init__(dp)
self.enter = enter_leave
self.ports = [] # port list when enter or leave
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Ryu-devel mailing list
Ryu-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ryu-devel

Reply via email to