Module 3.1
Module 3.1
Module 3.1
• Each subsystem listens for messages on that infrastructure and picks up the
messages that are intended for them. This “listener model” is a commonly
used architectural style for distributed systems.
2. Use tangible entities (things) in the application domain such as aircraft, roles such
as manager, events such as request, interactions such as meetings, locations such as
offices, organizational units such as companies, and so on.
3. Use a scenario-based analysis where various scenarios of system use are identified
and analyzed in turn.
Weather station objects
Design Models:
• These models are the bridge between the system requirements and the
implementation of a system.
3. State machine models, which show how objects change their state in
response to events. These are represented in the UML using state
diagrams. State machine models are dynamic models.
• A subsystem model is a useful static model that shows how a
design is organized into logically related groups of objects.
• Sequence models are dynamic models that describe, for each
mode of interaction, the sequence of object interactions that
take place.
• Sequence diagrams are used to model the combined behavior of
a group of objects, but you may also want to summarize the
behavior of an object or a subsystem in response to messages
and events.
• State diagrams are useful high-level models of a system or an
object’s operation.
Sequence diagram describing data collection
1. The SatComms object receives a request from the weather information system
to collect a weather report from a weather station. It acknowledges receipt of
this request. The stick arrowhead on the sent message indicates that the external
system does not wait for a reply but can carry on with other processing.
2. SatComms sends a message to WeatherStation, via a satellite link, to create a
summary of the collected weather data. Again, the stick arrowhead indicates that
SatComms does not suspend itself waiting for a reply.
3. WeatherStation sends a message to a Commslink object to summarize the
weather data. In this case, the squared-off style of arrowhead indicates that the
instance of the WeatherStation object class waits for a reply.
4. Commslink calls the summarize method in the object WeatherData and waits
for a reply
5. The weather data summary is computed and returned to WeatherStation via
the Commslink object.
6. WeatherStation then calls the SatComms object to transmit the summarized
data to the weather information system, through the satellite communications
Weather station state diagram
1. If the system state is Shutdown, then it can respond to a restart(), a reconfigure() or a
powerSave() message. The unlabeled arrow with the black blob indicates that the
Shutdown state is the initial state. A restart() message causes a transition to normal
operation. Both the powerSave() and reconfigure() messages cause a transition to a state in
which the system reconfigures itself. The state diagram shows that reconfiguration is
allowed only if the system has been shut down.
2. In the Running state, the system expects further messages. If a shutdown() message is
received, the object returns to the shutdown state.
3. If a reportWeather() message is received, the system moves to the Summarizing state.
When the summary is complete, the system moves to a Transmitting state where the
information is transmitted to the remote system. It then returns to the Running state.
4. If a signal from the clock is received, the system moves to the Collecting state, where it
collects data from the instruments. Each instrument is instructed in turn to collect its data
from the associated sensors.
5. If a remoteControl() message is received, the system moves to a controlled state in
which it responds to a different set of messages from the remote control room. These are
not shown on this diagram.
Interface Specification:
• Interfaces need to specified so that objects and subsystems can be
designed in parallel.
• Interface design is concerned with specifying the detail of the interface to
an object or to a group of objects. This means defining the signatures and
semantics of the services that are provided by the object or by a group of
objects.
• Interfaces can be specified in the UML using the same notation as a
class diagram.
• You should not include details of the data representation in an interface
design, as attributes are not defined in an interface specification.
• You should include operations to access and update data.
Interface specification
Weather station interfaces
DESIGN PATTERNS
• Pattern a description of the problem and the essence of its
solution, so that the solution may be reused in different settings.
• not a detailed specification.
• It is a description of accumulated wisdom and experience, a well-
tried solution to a common problem.
• “Patterns and Pattern Languages are ways to describe best
practices, good designs, and capture experience in a way that it is
possible for others to reuse this experience” -- Hillside Group
website.
Design Patterns