Reworked Ports collection classes to use iteration protocol.

Removes use of __getitem__(index) to implement for loops. This leaves
__getitem__ for implementaiton of alternative attribute access through
[]. e.g. workflow.input[label] instead of getattr(workflow.input, label)
Add iterator protocol to task collection