-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathBoxModel.java
More file actions
36 lines (30 loc) · 785 Bytes
/
BoxModel.java
File metadata and controls
36 lines (30 loc) · 785 Bytes
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
package ca.umontreal.iro.geodes.boxspl;
import java.util.ArrayList;
import java.util.List;
/**
* A POJO metamodel of a universe of boxes. You can see the metamodel
* <a href="http://yuml.me/preview/27938e54">on yUML</a>.
* </p>
* <img src=
* "https://yuml.me/diagram/boring/class/[BoxModel]<>model-boxes>[Box|id:String]<>contents-[Box]"/>
*
* @author Michalis Famelis
*
*/
public class BoxModel {
private ArrayList<Box> contents = new ArrayList<>();
/**
* Adds more box elements to the model.
* @param box to add
*/
public void addBox(Box box) {
this.contents.add(box);
}
/**
* Returns the list of all elements of the model.
* @return a list of Boxes
*/
public List<Box> getBoxes() {
return this.contents;
}
}