I assume that you are learning how to "convert" a string to a class name.
You can use reflection, which allows you to find a class by name, but it is slow, and if you ever want to rename your class in a future version, your code will not work.
Another way is that at some point in the initialization, there is a search dictionary (curse word!) That links each class to a string.
source share