switched encryption class