add switch rule