import java.util.*;
/** this is a generic inbox which stores <32-bit items (tokens or data) */
-public class Inbox extends InstructionBenkoBox {
+public class Inbox extends InstructionPump {
public boolean dataReadyForShip() { return itemReadyForShip; }
public Packet removePacketForShip() { remove(); return register; }
// private data //////////////////////////////////////////////////////////////////////////////
- private Packet register = null;
+ private Packet register = new Packet(null, null, 0, null);
/** data which has arrived from the switch fabric but not been acted on */
private Queue<Packet> itemsFromFabric = new LinkedList<Packet>();
// and make note of the fact that we need to send an ack (if requested)
if (instruction.tokenOut)
- bufferedAck = new Packet(getInterpreter(), this, 0, (InterpreterBenkoBox)instruction.dest);
+ bufferedAck = new Packet(getInterpreter(), this, 0, (InterpreterDestination)instruction.dest);
} else if (instruction.tokenOut) {
// if dataOut is not set, we can send the data immediately
- new Packet(getInterpreter(), this, 0, (InterpreterBenkoBox)instruction.dest).send();
+ new Packet(getInterpreter(), this, 0, (InterpreterDestination)instruction.dest).send();
}
return true;
}