Self-healing coatings with multiple functionalities for the corrosion protection of metals