View on GitHub

Notes

reference notes

Design and implementation:

Object oriented design using the UML

An object-oriented design process

Object:

Object Oriented Design:

Process stages:

  1. Define - define the context and modes of use of the system
  2. Design - design the system architecture
  3. Identify - identify the principal system objects
  4. Develop - develop design models
  5. Specify - specify object behavior

1. System context and interactions

Understanding the relationships between the software that is being designed and its external environment

essential for deciding how to provide the required system functionality and how to structure the system to communicate with its environment.

The system context establish the boundaries of the system on deciding what features are implemented in the system being designed and what features are in other associated systems.

Includes:

2. Architectural design

Identify the major components that make up the system and their interactions

organize the components using an architectural pattern such as a layered or client-server model.

Weather station example:

Includes:

The difficult part of object-oriented design.

No ‘magic formula’ for object identification.

It relies on the skill, experience and domain knowledge of system designers.

Object identification is an iterative process. Might have to do it several times to get the right one.

Approaches to object identification:

4. Design models

Design models show the objects and object classes and relationships between these entities.

There are two kinds of design model:

Three common UML Models:

  1. Subsystem models(structural model, because it shows the object calsses and the interactions between them)
    • show logical groupings of objects into coherent subsystems.
  2. Sequence models(dynamic model)
    • show the sequence of object interactions.
  3. State machine models(dynamic model)
    • show how individual objects change their state in response to events.

Subsystem models

Sequence models

State machine models

5. Interface specification

Object interfaces have to be specified so that the objects and other components can be designed in parallel.

Designers should avoid designing the interface representation but should hide this in the object itself.

Objects may have several interfaces which are viewpoints on the methods provided.

The UML uses class diagrams for interface specification but Java may also be used.

Implementation issues

The main focus is not on programming, but on implementation issues

Levels of Software Reuse

  1. The abstraction level
    • don’t reuse software directly but rather use knowledge of successful abstractions in the design of your software
  2. The object level(we dont modify the code we just use it as it is e.g. using a library like iomanip)
    • directly reuse objects from a library rather than writing the code yourself. Find appropriate libraries and discover if the objects and methods offer the functionality that you need.
  3. The component level
    • Components are collections of objects and object classes that operate together to provide related functions and services
    • adapt and extend the component by adding some code of your own.
  4. The system level
    • reuse entire application systems.
    • involves configuration of these systems by adding and modifying code (if you are reusing a software product line) or by using the system’s own configuration interface

The costs of the time spent in looking for software to reuse and assessing whether it meets your needs

The costs of buying the reusable software

The costs of adapting and configuring the reusable software components or systems to reflect the requirements of the system that you are developing.

The costs of integrating reusable software elements with each other (if you are using software from different sources) and with the new code that you have developed.

Configuration Management

process of managing a changing software system.

to support the system integration process so that all developers can :

Fundamental configuration management activities

  1. Version management
    • to keep track of the different versions of software components.
    • include facilities to coordinate development by several programmers.
    • stop one developer from overwriting code that has been submitted to the system by someone else.
  2. System integration
    • to help developers define what versions of components are used to create each version of a system.
    • This description is then used to build a system automatically by compiling and linking the required components.
  3. Problem tracking
    • to allow users to report bugs and other problems,
    • to allow all developers to see who is working on these problems and when they are fixed.
  4. Release management
    • new versions of a software system are released to customers.
    • concerned with planning the functionality of new releases and organizing the software for distribution

Host-target development

Software is developed on one computer (the host) but runs on a separate machine (the target).

Development platform (host):

Simulators

Tools to support software engineering processes

Integrated Development Environment (IDE)

Consideration issues in choosing development platform or development IDE

Open source development

The source code of a software system is published and volunteers are invited to participate in the development process

The source code should not be proprietary but rather should always be available for users to examine and modify as they wish.

Example : LINUX, Java, the Apache web server and the mySQL database management system.

Open source issues

Should the product that is being developed make use of open source components?

Should an open source approach be used for the software’s development?

Open-source licensing

A fundamental principle of open-source development is that source code should be freely available, this does not mean that anyone can do as they wish with that code.

License models

  1. The GNU General Public License (GPL)
    • if you use open source software that is licensed under the GPL license, then you must make that software open source.
  2. The GNU Lesser General Public License (LGPL)
    • you can write components that link to open source code without having to publish the source of these components.
  3. The BSD license
    • you are not obliged to re-publish any changes or modifications made to open source code. You can include the code in proprietary systems that are sold
    • If you use open-source components, you must acknowledge the original creator of the code. The MIT license is a variant of the BSD license with similar conditions.