Move GetAllLevels to the utility class