This question has already been answered:
- Parsing methods [closed] 2 responses
Suppose there is a class with tens / hundreds of fields. There are getters and setters. It is necessary to display the names of all fields. Let be:
int var = 666; String field = "El Diablo"; In the console you need to get: var field and all! Well, at the very least , getVar getField names , for example, will disappear .
In general, ideally, I would also use the types of variables to display on the screen in a simple way, otherwise I had to write a separate TypeOfVar class .