package seedu.jobs.model;

import java.util.Stack;

/**
 * Data structure to store modified tasks.
 * @author Yue
 *
 * @param <T>
 */
public class FixedStack<T> extends Stack<T> {

    private int maxSize = 10;

    public FixedStack(int size) {
        super();
        this.maxSize = size;
    }

    @Override
    public T push(T object) {
        while (this.size() >= maxSize) {
            this.remove(0);
        }
        return super.push(object);
    }
}

@@ -206,16 +206,66 @@
  = 10;%0A%0A
+    public FixedStack() %7B%0A        super();%0A    %7D%0A%0A
     publ

Fix FixedStack