Why does Iodine form Cations sometimes?
Iodine is the biggest halogen and by extension the most polarizable. 

Diatomic iodine can be oxidized with nitric acid to facilitate electrophilic aromatic substitution.

Iodide ion, as found in sodium iodide, can also be oxidized by concentrated household bleach to facilitate EAS as well. 

In the examples you give, there are strong electron withdrawing groups (such as oxygen, which is found in each of your examples). It is plausible that the oxygen has stripped the iodine of its electron(s) in each of your examples.