Commit | Line | Data |
---|---|---|
089fcbfc JB |
1 | import javax.swing.*; |
2 | ||
3 | public class FirstnameView extends JComponent { | |
6977e614 | 4 | private Firstname firstnameObj; |
089fcbfc JB |
5 | private JTextField textField; |
6 | private JLabel label; | |
6977e614 | 7 | |
089fcbfc JB |
8 | FirstnameView(int length) { |
9 | this.label = new JLabel(); | |
10 | this.label.setText("Firstname"); | |
11 | this.textField = new JTextField(length); | |
12 | add(label); | |
13 | add(textField); | |
6977e614 JB |
14 | } |
15 | ||
16 | public Firstname getFirstnameObj() { | |
17 | return firstnameObj; | |
18 | } | |
19 | ||
20 | public void setFirstnameObj(Firstname firstnameObj) { | |
21 | this.firstnameObj = firstnameObj; | |
22 | } | |
23 | } |