[DF-1152] deprecated mark for commands

add cancel to SetSwitchIndexCommand