Half metal↔semiconductor reversible switch in bimetallic sandwich molecular wire via redox reactions