I'm developing a Swing application for the first time, so please forgive me if my doubt is a little naive.
To test my application, I have currently hardcoded some text labels and fields in a JPanel, so that a user can enter input details for a maximum of 3 segments. But this limits the maximum number of segments to 3. However, the requirement is that when the user enters the number of segments (could be greater than 3 as well), corresponding number of input sets need to be taken.
Screenshot attached, with values entered.
Basically I want to know how I should go about taking the inputs from the user.