• Post Reply Bookmark Topic Watch Topic
  • New Topic

MVC Pattern  RSS feed

 
Greenhorn
Posts: 1
Eclipse IDE IntelliJ IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

I've searched the whole web and haven't been successful yet, really the whole. ;)

I understand MVC Pattern by and large although when I was programming today the question came across when
I tried to get "data" from the view. How is it done in the right way? Ofc in the Controller but how do I get the data from lets say a JList or a JTextarea?

In specific how do I respond to the graphic components? At the moment I declared them public final in the View is that the way to go?

View:



Controller:


Or do I have to use getter and setter for each component?

Greetings
Slevin

 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!