Modelling object-oriented software – an introduction
Modelling object-oriented software – an introduction

Start this free course now. Just create an account and sign in. Enrol and complete the course for a free statement of participation or digital badge if available.

Free course

Modelling object-oriented software – an introduction

3.3 Identifying classes and attributes for the Hospital System

3.3.1 Identifying the classes for the Hospital System

Now that you have been armed with a number of techniques for identifying appropriate classes for a conceptual model, you can apply them to the requirements document for the Hospital System.

The requirements document for the Hospital System is set out in the PDF document below – you will need this in order to complete Activity 3.

Click the link below to view the hospital requirements.

Requirements [Tip: hold Ctrl and click a link to open it in a new tab. (Hide tip)]

Activity 3

Use the textual analysis technique described earlier in this section to identify the nouns and noun phrases in the first part of the document, headed System domain, and then eliminate any duplicates or synonyms so as to produce a partial list of entities in the system domain. (To identify all the relevant entities, you would also need to analyse the section of the document entitled Use cases, but you are only required to carry out part of the process).

Discussion

Figure 4 contains the description with the nouns and noun phrases underlined.

Figure 4
Figure 4 Identifying nouns and noun phrases

This is not an exact science, so do not worry if your underlining does not exactly match ours.

After eliminating duplicates, we are left with the following list of entities (synonyms are shown in parentheses):

  • hospital

  • number of wards

  • patient

  • type of ward

  • male ward

  • female ward

  • ward

  • sex

  • capacity (maximum number of patients, number of beds)

  • name of ward

  • Administration department

  • information

  • doctor

  • team

  • team code

  • Orthopaedics A

  • Paediatrics

  • grade 1

  • consultant doctor (consultant)

  • junior doctor

  • record of teams and doctors

  • care

  • number of doctors

  • number of patients

Your list may not have been identical to ours, but we would expect you to have included most of the entities above.

Applying the guidelines for rejection to our solution to Activity 3, the following can be eliminated:

  • hospital, Administration department (outside the scope of the system)

  • number of wards (language idiom – the requirements document could equally well have referred to ‘wards’ or ‘some wards’)

  • type, capacity, name (attributes of ward)

  • sex (attribute of patient)

  • information (generic term referring to the behaviour of the system)

  • team code (attribute of team)

  • record of teams and doctors (part of the behaviour required of the system)

  • number of doctors, number of patients (language idiom)

You may have noticed that there are three nouns, ‘Orthopaedics A, ‘Paediatrics’ and ‘grade 1’, which have not been eliminated using the guidelines for rejection, yet which common sense suggests should not be modelled by classes. ‘Orthopaedics A and ‘Paediatrics’ are in fact given in the requirements document as example values of ‘team code’, which was identified above as an attribute of team, and ‘grade 1’ is a value of an attribute, ‘grade’, of junior doctor. (The grade attribute will be identified in Activity 4 below).

This leaves, so far, the following list of entities which give rise to candidate classes:

  • male ward

  • female ward

  • ward

  • patient

  • doctor team

  • consultant doctor

  • junior doctor

  • care

M256_1

Take your learning further

Making the decision to study can be a big step, which is why you'll want a trusted University. The Open University has 50 years’ experience delivering flexible learning and 170,000 students are studying with us right now. Take a look at all Open University courses.

If you are new to University-level study, we offer two introductory routes to our qualifications. You could either choose to start with an Access module, or a module which allows you to count your previous learning towards an Open University qualification. Read our guide on Where to take your learning next for more information.

Not ready for formal University study? Then browse over 1000 free courses on OpenLearn and sign up to our newsletter to hear about new free courses as they are released.

Every year, thousands of students decide to study with The Open University. With over 120 qualifications, we’ve got the right course for you.

Request an Open University prospectus371