Exemplo n.º 1
0
 def _send_packet(self, listener, key, value, domain, type):
     packet = Packet(Packet.STORAGE, StoragePacketContent([(key, value, domain, type)]))
     packet.src = self._myself
     packet.dst = Device.deserialize(listener)
     core.forwarding.forward(packet)
Exemplo n.º 2
0
 def _send_packet(self, listener, tasks):
     packet = Packet(Packet.STORAGE, StoragePacketContent(tasks))
     packet.src = self._myself
     packet.dst = Device.deserialize(listener)
     core.forwarding.forward(packet)
Exemplo n.º 3
0
 def _send_packet(self, pox_content, controllers):
     packet = Packet(Packet.CONTROL_FROM_SWITCH, pox_content)
     packet.src = self._myself
     for controller in controllers:
         packet.dst = controller
         core.forwarding.forward(packet)
Exemplo n.º 4
0
 def data_to_packet(self, data):
     return Packet.deserialize(cPickle.loads(data))