NivaarExam PrepOfficial exam papers ↗

25-Comp-A6 Software Engineering · December 2013

Question 3 of 9: Function-oriented Design

Nivaar worked solution (AI-drafted; not reviewed by a licensed engineer)

Notes on this paper

National Exams — December 2013 — 98-Comp-A6 Software Engineering. Three-hour, closed-book exam, no calculator permitted. Format: nine questions, candidates answer any five of the nine (all questions equal weight — each of the five counted questions is worth 20%; only the first five questions as they appear in the answer book are marked). All nine questions are solved below for completeness.

Reference texts: Sommerville, Software Engineering (10th ed., Pearson) — software process models, object-oriented and function-oriented design, requirements engineering, software testing, software reuse, rapid development and prototyping, client-server architectures, software validation; Pressman, Software Engineering: A Practitioner's Approach (9th ed.) — supplementary process, testing and architecture coverage; Gamma, Helm, Johnson & Vlissides, Design Patterns — object-oriented design/reuse vocabulary.

Question 3: Function-oriented Design (20 marks)

Question text not reproduced: the examination questions are © Engineers and Geoscientists BC. Open the official past paper (linked at the top of this page) to read the question, then follow the worked solution below.

High-Level Function-Oriented Design

The date-book decomposes into an interaction function, a data-integrity function, a scheduling function, persistent storage, and a background notification function — a straightforward pipeline from "user enters an appointment" through to "system reminds the user of it."

User Interface(entry / query)AppointmentValidatorAppointmentStoreScheduler /Conflict CheckReminder /Alarm Notifiernew / editappointmentcandidateentryvalidatedentryacceptedentryqueryresultsdueappointmentsreminderalert
Fig. Q3 — data-flow design of the automatic date-book system.

The User Interface function accepts new/edited appointment entries and answers queries (e.g. "show today's appointments," "show next week"). Every candidate entry first passes through the Appointment Validator, which checks it for basic integrity — a valid date, a valid time, a non-negative duration, and a non-empty description — before it is allowed further into the system. A validated entry then passes to the Scheduler / Conflict Check function, which compares the candidate's date/time/duration window against every appointment already held in the Appointment Store for that day and flags an overlap back to the user (who may still choose to accept a double-booking). Accepted entries are written to the Appointment Store, which is the single persistent record of all appointments and answers the UI's query requests directly. Independently of user interaction, the Reminder / Alarm Notifier runs continuously (or on a periodic timer) scanning the store for appointments whose reminder time has arrived and raises an alert to the user.

Check — assumptions
Single-user, single-device system (no networking or multi-user concurrent access, consistent with an early personal electronic organizer). Each appointment record holds date, start time, duration, a text description, and an optional reminder lead-time. Conflict checking flags but does not forbid an overlapping entry, since a user may deliberately double-book (e.g. a tentative appointment). The notifier is assumed to poll the store at a fine enough interval (e.g. once per minute) that no reminder is missed by more than that interval.