while (refineInPorts.hasNext()) {
IOPort refineInPort = (IOPort) refineInPorts.next();
// Get all of the input ports this port is linked to on
// the outside (should only consist of 1 port).
Iterator inPortsOutside = refineInPort.deepConnectedInPortList()
.iterator();
if (!inPortsOutside.hasNext()) {
throw new IllegalActionException("Current "
+ "state's refining actor has an input port not"