Hi, I have a javabean; in my program i have to analyze the bean , then put in a list all properties name (String) that have a set method and also a get method. (some properties could have only get or set method).
What can i use to do this work..??
I thinked to use the java.lang.reflect showMethods(bean) but i have to parse all stings and make checks for get and set.. it is cumbersome.
Use Introspector's getBeanInfo() method and provide the class that has your bean properties as an argument. This method returns a BeanInfo object which will then return a list of properties from the class.
The challenge to you is to try it; post your code here for review if you like. More than happy to help you with code that isn't quite doing what you want.
Make visible what, without you, might perhaps never have been seen. - Robert Bresson