Find all variable names in class

Is there a way to find all the public variable names in a class (given the instance of the class)?

Thanks!!