Generic, iteratorable ListModels and foreach loops
posted 6 years ago
I am writing my own ListModel that supports generics and provides an API to ArrayLists. I decided to implement the Iterable interface so I could use foreach loops on my ListModels but I'm running into trouble.
My iterator implementation in MyListModel looks like this: