>I have component X that writes xml and gets name and value from components
> Y,Z.
[quoted text clipped - 8 lines]
>
> How do i get the name of every component?
Your subject line clashes with your question: the subject line asks about
event names but your question asks about component names. Since events don't
have names, I'll assume you mean component names....
This may not be the _only_ way or the best way but many GUI components have
methods so that you can assign them a name of your own choosing. Therefore,
if you have three JPanels in a GUI, you can give them each a unique name,
like Alpha, Beta, and Gamma. Then, you can query the name with another
method.
I just checked the API and everything that descends from java.awt.Component
has access to the setName() and getName() methods of the Component class.
That should cover you for most GUI components.
Non-GUI components may have similar methods; check the API.
--
Rhino