This case statement is the same on the public and private methods. What do you think about extracting it for a method?