fossar / selfoss

multipurpose rss reader, live stream, mashup, aggregation web application
https://selfoss.aditu.de
GNU General Public License v3.0
2.36k stars 343 forks source link

Use value object for spout items #1342

Closed jtojnar closed 2 years ago

jtojnar commented 2 years ago

Previously, spouts would implement Iterator interface and individual items’ data could be accessed by iterating the spout object and calling its methods.

With this change, each spout has getItems() method that returns an Iterator of Item objects for each item.

This is much cleaner design and having separate object for each source item allows for handling them independently even after iteration switched to a next step.