예제 #1
0
 @Override
 public void build() {
   buildCallsCount++;
   // add the callback
   mlTable.notify(
       new Callback3<MAC, UUID, UUID>() {
         @Override
         public void call(MAC mac, UUID oldPortID, UUID newPortID) {
           notifiedMAC[0] = mac;
           notifiedUUID[0] = oldPortID;
           notifiedUUID[1] = newPortID;
         }
       });
 }
예제 #2
0
 public void removePort(MAC mac, UUID portId) {
   mlTable.remove(mac, portId);
 }
예제 #3
0
 public UUID getPort(MAC mac) {
   final UUID result[] = new UUID[1];
   result[0] = mlTable.get(mac);
   return result[0];
 }
예제 #4
0
 public void simulateNewPacket(MAC mac, UUID portId) {
   mlTable.add(mac, portId);
 }