Пример #1
0
 def removePort (self, dpid, num):
   p = Port()
   p.dpid = dpid
   p.num = num
   self.ports.remove(p)
   AppData._updatePGData()
Пример #2
0
 def addPort (self, dpid, num):
   p = Port()
   p.dpid = dpid
   p.num = num
   self.ports.add(p)
   AppData._updatePGData()