Skip to content

Commit

Permalink
Mostly implemented clearAllTables
Browse files Browse the repository at this point in the history
  • Loading branch information
Tarrasch committed Feb 18, 2011
1 parent ee63d1c commit 7785db8
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 5 deletions.
16 changes: 14 additions & 2 deletions Assistant.jr
Expand Up @@ -34,10 +34,22 @@ public class Assistant extends Person {
}
}


// This includes cleaning the glasses etc.
private void clearAllTables()
{

List<BeverageWare> glasses = new ArrayList<BeverageWare>();
for(Table t : Global.tables)
{
glasses.addAll(t.clearTable());
}
JR.nap(100); // clean glasses

// ADD CODE FOR GLOBAL CUPBOARD HERE
Cupboard cb = null;
for(BeverageWare bw : glasses)
{
cb.putBackItem(bw);
}
}


Expand Down
4 changes: 2 additions & 2 deletions jrGen/Door.java
Expand Up @@ -238,7 +238,7 @@ else if ((handler != null) && !(JRe instanceof java.rmi.RemoteException))
@SuppressWarnings(value = "unchecked")
private void startLoop() {
InStatObj JRInstmt2 = new InStatObj(3, false);
JRLoop9: while (true) {
JRLoop11: while (true) {
{
// Inni Statement without quantifier
JRInstmt2.armArray[0] = new QuantRec(new Cap_ext_(op_lock_Cap_voidTovoidTojavadotutildotArrayList, "java.util.ArrayList<Person>"), 0, 0);
Expand Down Expand Up @@ -502,7 +502,7 @@ else if ((JRrrecv2.handler != null) && !(JRe instanceof java.rmi.RemoteException
if (isLocked && entrants.size() == 0) {
{ if (JRrrecv2.retOp != null)
JRrrecv2.retOp.send(jrvm.getTimestamp(), (java.lang.Object []) null);
break JRLoop9;}
break JRLoop11;}
}
}
} catch (Exception JRe) {
Expand Down
2 changes: 1 addition & 1 deletion jrGen/Person.java
Expand Up @@ -273,7 +273,7 @@ else if ((handler != null) && !(JRe instanceof java.rmi.RemoteException))


private void startLoop() {
JRLoop10: while (!shouldGoHome()) {
JRLoop12: while (!shouldGoHome()) {
// Begin Expr2
oneIteration();
}
Expand Down

0 comments on commit 7785db8

Please sign in to comment.