I hope I can explain.
I don’t have a problem, just I want to know how to build my users system control and I want to know if my idea is correct:
My idea:
*One class (file 1) to functions, methods and operations
*Other class (file 2) to swing elements, buttons, textbox, etc.
*But I don’t know how connect these two classes.
For example:: I have 2 textbox (user, password) and one button, then when press the button, send data of each textbox(file 2) to a function (file 1) and process.
If you have any other choice, I’d read it.
Thank you in advance
You should use the Model-View-Controller pattern to solve your problem. Basically, your view (the swing files) only know how to display content, and let the user of the class (the controller) subscribe to receive notifications when the content is changed (this is done with swing listeners). When the content is changed the controller can act on it, modify the model if necessary and also update the view (again, using methods provided by the view).
The GUI should never involve functionality. It should only have code that is used to display what you want. This helps create a better architecture.