-
Notifications
You must be signed in to change notification settings - Fork 0
/
Store.java
39 lines (35 loc) · 1013 Bytes
/
Store.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
import java.util.ArrayList;
import java.util.HashMap;
import javax.swing.plaf.synth.SynthFormattedTextFieldUI;
public class Store implements Runnable {
String name;
ArrayList<employee> emps;
HashMap<grocery, Integer> stock;
int dimensionX;
int dimensionY;
tile[][] storeField;
boolean inBusiness;
public Store(String name, ArrayList<employee> emps, HashMap<grocery, Integer> stock, boolean inBusiness){
this.name = name;
this.emps = emps;
this.stock = stock;
this.inBusiness = inBusiness;
dimensionX = 10;
dimensionY = 10;
this.storeField = new tile[10][10];
this.storeInit();
}
public void storeInit(){
new Thread(this).start();
}
public void storePeriodic(){
// System.out.println("store");
}
@Override
public void run() {
do {
this.storePeriodic();
// System.out.println("success");
}while(inBusiness);
}
}