
CSI 3471
Swing Interface Components
Reference: Chapter 9 of Core Java
Please answer the questions in Part A before we have class tomorrow (in the lab).
A. Model-View-Controller Design Pattern
1. Every component has three characteristics. Please list them.
2. In the model-view-controller pattern, identify what each of the three parts does:
a. model:
b. view:
c. controller:
3. What is the content of a JButton?
4. What happens if the content for a text field is larger than the view of the text field?
5. Why does the author think that the term “model” is unfortunate?
6. Does the view know why its contents would change?
7. If the user presses a cursor key, what tells the view to change?
8. Which of the three parts of model, view, and controller is(are) stored within a JButton or
a JTextField?