Premium Resources

We know the secret of your success

M256/D Software development with Java Undergraduate Level Course Examination 2014

$39.00

PAPER TITLE: SOFTWARE DEVELOPMENT WITH JAVA

DATE: Wednesday, 17 September 2014

 

PART 1

Question 1

Which two of the following statements about software development are true? (Select two options)

  1. The waterfall method is an example of an adaptive software development method.
  2. The Javadoc program produces information about public, protected and private elements of a class definition.
  3. An initial structural model of a system describes dynamic aspects of the system such as ways in which objects of the classes will interact.
  4. The UML is useful for producing diagrams at an appropriate level of abstraction.
  5. Enhancing the system by adding extra facilities is part of the maintenance phase.

 

ANSWERS(Purchase full paper to get all the solution)

B. The Javadoc program produces information about public, protected and private elements of a class definition.

C. An initial structural model of a system describes dynamic aspects of the system such as ways in which objects of the classes will interact.

 

Question 2         Based on the information in Figure 1 which two of the following statements are true? (Select two options)

  1. The diagram shows a collaboration between vetTeam3 and appointment1.
  2. The line between vetTeam3 and appointment1 represents a relationship between these objects that is an instance of the consults association.
  3. The diagram is a static model of part of the veterinary administration system at a particular time.
  4. The diagram shows how the objects vetTeam3, appointment1 and appointment3 interact.
  5. The diagram shows that 14/03/2014 is an attribute of appointment3.

 

 

Question 3         Which two of the following statements relating to the requirements specification process are true? (Select two options)

 

  1. The following could be an example of a constraint that is not a behavioural requirement:

‘A patient’s medical record should be accessible from any of the terminals in the hospital within 600 milliseconds of its being requested.’

  1. The following could be an example of a constraint that is not a behavioural requirement:

‘A library member who has an overdue book must not be allowed to borrow any more books until the overdue book has been returned.’

  1. Requirements specification is only concerned with eliciting the behaviour required of a software system.
  2. Requirements creep occurs when the software developers deliver less than what was originally agreed, usually due to a shortfall in the budget.
  3. The requirements document may include details of the budget.

 

Question 4         Which two of the following statements about conceptual modelling are true? (Select two options)

  1.  The multiplicity of an association between class X and Y, at the Y end, defines how many objects of class Y may be linked to a single object of class X.
  2.  In M256, a conceptual model specifies the behaviour of the system.
  3.  If classes A and B are specialisations of class C then class C must be an abstract class.
  4.  If a class has a derived attribute then there must be an invariant that provides the derivation of the attribute.
  5.  A recursive association is one via which an object of one class may be linked to more than one object of another class.

 

Question 5         The following is an extract from a requirements document for a system for a ski school. The incomplete class diagram below forms part of a conceptual model for the system.

Extract from requirements document:

Each ski class is led by one ski instructor and each ski instructor leads between one and ten ski classes.

Class diagram:

On the basis of the above information which two of the following statements are true? (Select two options)

  1. The multiplicity of the leads association at the SkiClass end should be 1.
  2. The multiplicity of the leads association at the SkiClass end should be 10.
  3. The multiplicity of the leads association at the SkiClass end should be 1..10.
  4. The class Pupil generalises the class Intermediate.
  5. It is not possible for the system to record information about more than ten pupils at the same time.
  6. It is possible for there to be more than ten pupils in a ski class.

 

Question 6         The following is an extract from a requirements document for a property management company’s system. The (incomplete) class diagram forms part of a conceptual model for the system.

 

Extract from requirements document:

Each client of the company is either a tenant, who rents at least one property, or a landlord, who owns at least one property. Landlords may also rent property, though a landlord cannot rent a property they own. The company deals with property of many kinds, including houses and apartments.

Class diagram:

On the basis of the above information, which three of the following statements are true? (Select three options)

  1. owns is a derived association.
  2. The following is an invariant that is required in addition to the class diagram, as part of the conceptual model:

If a Landlord object aLandlord and a Property object aProperty are linked via owns then aLandlord and aProperty are not linked via rents.

  1. The class Client should be labelled as an abstract class.
  2. The following is an invariant that is required in addition to the class diagram, as part of the conceptual model:

Each Tenant object must be linked to at least one Property object via rents.

  1. The following is an invariant that is required in addition to the class diagram, as part of the conceptual model:

Each Landlord object must be linked to at least one Property object via owns.

  1. The following is an invariant that is required in addition to the class diagram, as part of the conceptual model:

If a Tenant object aTenant and a Property object aProperty are linked via rents then aTenant and aProperty are not linked via owns.

 

Question 7         Which two of the following statements are true? (Select two options)

 

  1.  It is often possible to identify some of a method’s pre-conditions from the Javadoc specification of the exceptions that the method throws.
  2.  The specification of a component should include a description of any other components it depends on.
  3.  A method can only be properly specified after it has been implemented.
  4.  Cohesion is a measure of the extent to which a component is dependent on other components.
  5.  The terms “data hiding” and “encapsulation” mean the same thing.

 

 

Question 8         Which two of the following statements about object-oriented software development are true? (Select two options)

  1.  Polymorphism provides a basis for protecting the integrity of objects.
  2.  A method’s post-condition states what the method achieves assuming any pre-conditions are satisfied.
  3.  One benefit of component-based software development is that implementation errors are separated from specification errors.
  4.  A defensive copy of an object must be an immutable object.
  5.  In Java an object that is an element in an unmodifiable collection must be immutable.

 

Figure 5

 

Question 9         Which one of the following statements is a correct identification of the missing text indicated by the labels X, Y and Z in the sequence diagram in Figure 5? (Select one option)

  1.  X is customer6; Y is DINNER; Z is table1
  2.  X is customer5; Y is LUNCH; Z is table6
  3.  X is customer6; Y is DINNER; Z is table1
  4.  X is customer6; Y is LUNCH; Z is table6
  5.  X is customer6; Y is LUNCH; Z is table1

 

Question 10       On the basis of the information above which two of the following statements are true? (Select two options)

  1.  reservation7 is not linked to any Table object.
  2.  Step 2 of the walk-through is carried out by restaurant.
  3.  Step 4 of the walk-through is carried out by restaurant.
  4.  Step 4 of the walk-through is carried out three times.
  5.  table1 is linked to customer6.

 

Question 11       On the basis of the information above which two of the following statements are true? (Select two options)

  1. A method whose specification begins as follows is appropriate for the protocol of Reservation:

Customer getCustomer()

  1. A method whose specification begins as follows is appropriate for the protocol of RestaurantCoord:

Table getTable()

  1. A method whose specification begins as follows is appropriate for the protocol of RestaurantCoord:

Map getTablesAndCustomers(M256Date aDate, Sitting aSitting)

  1. A method whose specification begins as follows is appropriate for the protocol of RestaurantCoord:

Map getTablesAndCustomers(M256Date aDate, Sitting aSitting)

  1. A method whose specification begins as follows is appropriate for the protocol of Sitting:

Sitting getSitting()

 

Question 12       Which two of the following statements about the M256 approach to designing software are true? (Select two options)

 

  1.  For a one-way association navigated in the direction from a class P to a class Q, each Q object needs to hold references to the P objects to which it is linked.
  2.  When creating links of a two-way association, an object of the class at one end of the association should, if possible, be made responsible for managing the process, by prompting the other object to take action, as well as performing its own actions.
  3.  If a class Q has a method which takes as an argument an object of class P, then the classes Q and P are coupled.
  4.  An information expert is an object that initiates a cascade of messages.
  5.  A design for a valid scenario should illustrate a situation where a pre-condition is not met.

 

Question 13    Which two of the following statements about detailed design and implementation are true? (Select two options)

  1.  A compareTo() method should be specified for each class whose

objects have a natural ordering that can be used when storing them in sorted collections.

  1.  A utility class is a helper class that is only intended to be used within the system for which it was developed.
  2.  The Java documentation for the toString() method in class Object recommends that where toString() is overridden, compareTo() and hashcode() are overridden to be consistent with toString().
  3.  Refactoring can result in the creation of additional classes.
  4.  An attribute can be implemented using an enumerated type only if all its possible values are integers.

 

Question 14       Which two of the following statements about implementation and testing are true? (Select two options)

 

  1.  White box testing is an example of validation testing.
  2.  JUnit facilitates regression testing.
  3.  The process of rerunning previous tests to check that a change to one aspect of the implementation of a system has not damaged another is known as integration testing.
  4.  In test-driven development, unit tests are specified before any dynamic models have been chosen.
  5.  It is a standard practice to carry out tests around boundaries as a part of black box testing.

 

Question 15       Which two of the following statements about the M256 approach to implementing software in Java are true? (Recall that in M256 the first code iteration is the first stage in implementing a core system.) (Select two options)

  1.  The coordinating method for each use case is normally implemented in the first code iteration.
  2.  Getter methods for each non-derived attribute should be implemented in the first code iteration.
  3.  A toString() method for each class is normally implemented in the first code iteration.
  4.  Normally, only the dynamic part of the implementation model is used by the developer when adopting a use case-driven approach to implementation.
  5.  Implementing the methods required for a particular use case is always based on a single scenario.

 

Question 16       Which two of the following statements about user interfaces and their design are true? (Select two options)

 

  1.  The effectiveness of a prototype interface is evaluated during usability testing by determining how much time is taken to complete a task.
  2. Think-aloud is an alternative to direct manipulation for user interaction as it is not based on the metaphor of physical manipulation.
  3.  User interface metaphors can enhance the visibility of widgets by exploiting the familiar mental models of users.
  4.  Not all graphical user interfaces use direct manipulation.
  5.  To say that a widget has good visibility means it is apparent how to use that widget.

 

Question 17       Which two of the following statements about user interfaces and their design are true? (Select two options)

  1.  One aspect of direct manipulation is that small operations can be used to incrementally cause an overall big effect.
  2.  The object-oriented concept of polymorphism is related to the HCI concept that different users may require differently designed interfaces.
  3.  Design heuristics are typically universally applicable.
  4.  ‘Extraordinary HCI’ refers to a set of interactive products that have exceptionally good usability.
  5.  The object-oriented concept of inheritance can help to achieve the consistent use of a user’s familiar mental model.

 

Question 18       Which two of the following statements about building a graphical user interface (GUI) are true? (Select two options)

  1.  Acceptance testing is carried out in order to test the usability of the GUI.
  2.  Listeners are Java objects that are attached to interface components to initiate the handling of user interactions with the interface.
  3.  When developing a GUI, the implementation stage includes determining what kinds of information should be displayed on each screen.
  4.  In the M256 approach to communication between the core system and the GUI, the core system usually acts both as a server and as a client of the GUI.
  5.  Coordinating messages are not the only kind of messages that a user interface may send to core system objects.

 

Question 19       Which two of the following statements are true? (Select two options)

 

  1.  eXtreme programming is an example of an agile development method.
  2.  The Publish-Subscribe pattern is an example of a creational design pattern.
  3.  A coordinating class with low cohesion is likely to be difficult to test and maintain.
  4.  Timeboxing is a key element of the rational unified process (RUP).
  5.  In a classic three-tiered architecture, the third tier is normally the business domain tier.

 

Question 20       Which two of the following statements are true? (Select two options)

  1.  

Last updated: Sep 02, 2021 12:24 PM

Can't find a resource? Get in touch

AcademicianHelp

Your one-stop website for academic resources, tutoring, writing, editing, study abroad application, cv writing & proofreading needs.

Get Quote
TOP