Optimal switching for hybrid semilinear evolutions. (November 2016)