package clarity.match;

import java.util.ArrayList;
import java.util.List;

import clarity.model.GameEvent;

import com.rits.cloning.Cloner;

public class GameEventCollection implements Cloneable {
    
    private static final Cloner CLONER = new Cloner();
    
    private final List<GameEvent> gameEvents = new ArrayList<GameEvent>();

    public void add(GameEvent event) {
        gameEvents.add(event);
    }
    
    public void clear() {
        gameEvents.clear();
    }
    
    @Override
    public GameEventCollection clone() {
       return CLONER.deepClone(this);
    }
    
}

@@ -48,16 +48,47 @@
 yList;%0D%0A
+import java.util.Collections;%0D%0A
 import j
@@ -528,24 +528,134 @@
    %7D%0D%0A    %0D%0A
+    public List%3CGameEvent%3E getAll() %7B%0D%0A        return Collections.unmodifiableList(gameEvents);%0D%0A    %7D%0D%0A    %0D%0A
     @Overrid

add getter for game events