/// <summary> /// Removes the element at the end of the update. /// </summary> public void Remove(T element) { if (list.Contains(element)) { remove.Add(element); } }
/// <summary> /// Adds the element to the list. Returns false if the element already existed and wasn't added. /// </summary> public bool Add(T element) { remove.Remove(element); return(list.Add(element)); }