When I make a custom collection type class (due to the fact that I needed better control over the array then inheriting from an arraylist) and create an IEnumerator class, I want an error to be thrown when an object is added while in that foreach loop, like it does by an arraylist. How can I accomplish this?