/** You should instantiate a bunch of Inboxes and Outboxes in your constructor */
public SlipwayShip(Slipway fleet, String name, String type, ShipDescription sd) {
this.fleet = fleet; this.type = type;
- for(BenkoBoxDescription sdbb : sd)
- new SlipwayBenkoBox(sdbb.isInbox(), this, sdbb.getName());
+ for(BenkoBoxDescription sdbb : sd) {
+ SlipwayBenkoBox sbb = new SlipwayBenkoBox(sdbb.isInbox(), this, sdbb.getName());
+ for(String port : sdbb) {
+ if (port.equals("")) continue;
+ sbb.addDestination(port);
+ }
+ }
if (type.equals("Debug")) {
new SlipwayBenkoBox(false, this, "out", true);