Presentation is loading. Please wait.

Presentation is loading. Please wait.

Test Postmortem Dennis Burford

Similar presentations


Presentation on theme: "Test Postmortem Dennis Burford"— Presentation transcript:

1 Test Postmortem Dennis Burford dburford@cs.uct.ac.za

2 Question 1a Draw a component hierarchy for the following Java application.[5]

3 Question 1a JPanel JFrame (with its own content pane) JPanel JTextFieldJLabelJTextFieldJLabel JButton

4 Question 1b Name any three of the Layout Managers in Java.[3]

5 Question 1b Name any three of the Layout Managers in Java.[3] BorderLayout GridLayout FlowLayout GridBagLayout BoxLayout

6 Question 1c Give a statement in Java to set the Layout of myPanel to any Layout Manager. [2] JPanel myPanel = new JPanel();

7 Question 1c Give a statement in Java to set the Layout of myPanel to any Layout Manager. [2] JPanel myPanel = new JPanel(); myPanel.setLayout( new BorderLayout() );

8 Question 2a You are writing a Swing application and want the program to print out the message “Ouch!” every time you press a button. Show how you would do this for the following button:[4] JButton button = new JButton(“Press Me”);

9 Question 2a button.addActionListener( new ActionListener() { public void actionPerformed( ActionEvent e ) { System.out.println(“Ouch!”); } );

10 Question 2b Indicate what type of Listener is used for each of the following components:[2] i. JTextfield ii. JSlider

11 Question 2b Indicate what type of Listener is used for each of the following components:[2] i. JTextfield ActionListener ii. JSlider ChangeListener

12 Question 2c What is the difference between a Listener and an Adapter in Java?[2]

13 Question 2c What is the difference between a Listener and an Adapter in Java?[2] A Listener is an interface (have to implement methods). An Adapter implements a Listener interface using empty methods.

14 Question 3a Name the five stages of the traditional Software Lifecycle.[5]

15 Question 3a Name the five stages of the traditional Software Lifecycle.[5] 1. Specification 2. Design 3. Implementation 4. Testing 5. Maintenance

16 Question 3b Give two constraints you would consider when planning a software project.[2]

17 Question 3b Give two constraints you would consider when planning a software project.[2] Time, Money, Equipment, People,….

18 Question 4a What is the difference between a Milestone and a Deliverable?[2]

19 Question 4a What is the difference between a Milestone and a Deliverable?[2] A Milestone is the end of a distinct stage. A deliverable is a milestone with tangible results that are delivered to the client.

20 Question 4b Name two commonly used techniques for documenting/illustrating a project schedule. [2]

21 Question 4b Name two commonly used techniques for documenting/illustrating a project schedule. [2] 1. Table of Tasks 2. Gantt Chart

22 Question 4c Give an example of a common project pitfall (be sure to say what the problem is, rather than just giving a name). [1]

23 Question 4c Give an example of a common project pitfall (be sure to say what the problem is, rather than just giving a name). [1] One person taking all the responsibility for the project and doing all the work. (many others….)

24 Question 5a What are the two forms that an IP address can take? Give an example of each (they do not have to be real addresses). [2]

25 Question 5a What are the two forms that an IP address can take? Give an example of each (they do not have to be real addresses). [2] 1. DNS Form:casper2.cs.uct.ac.za 2. Dotted Quad Form:137.158.128.58

26 Question 5b What two things together identify a program offering a service on a machine? [2]

27 Question 5b What two things together identify a program offering a service on a machine? [2] 1. IP Address 2. Port Number

28 Question 5c Give an example of a type of Internet application that uses the Client-Server model. [1]

29 Question 5c Give an example of a type of Internet application that uses the Client-Server model. [1] email, web browser, irc, telnet, ftp, ….


Download ppt "Test Postmortem Dennis Burford"

Similar presentations


Ads by Google