Optical switching with high-Q Fano resonance of all-dielectric metasurface governed by bound states in the continuum