Is there a way to get all the classes that are defined within base R? My expected output is a character vector containing the class names. Something like this:
"character" "factor" "function" "dataframe" "list" ...
Background: I made a function that is supposed to be applied to as many classes as possible. I can't explain what I'm doing in detail but consider functions like str that as far as I know can be applied to any class. On the other hand, there are functions like sum that expect certain input, i.e., numeric input. I want to know all predefined classes so that I can see on what classes my function works and which ones don't.