Components vs. Objects

Similar documents
LELCTURE 4: ENHANCED ENTITY-RELATIONSHIP MODELING (EER)

CHAPTER 5 GENERAL OOP CONCEPTS

CHAPTER 9 DESIGN ENGINEERING. Overview

Software Development. Modular Design and Algorithm Analysis

Data Structures and Algorithms Design Goals Implementation Goals Design Principles Design Techniques. Version 03.s 2-1

Object-Oriented Modeling Using UML. CS151 Chris Pollett Aug. 29, 2005.

Architectural Blueprint

Solved Question Paper June 2017

Chapter 8 The Enhanced Entity- Relationship (EER) Model

Chapter 8: Enhanced ER Model

Tutorial notes on. Object relational structural patterns

Chapter 11 Object and Object- Relational Databases

Model Driven Engineering (MDE)

Object-Oriented Concepts and Principles (Adapted from Dr. Osman Balci)

Object-Oriented Design

Chapter 5 Object-Oriented Programming

Module Outline. What is Object-Oriented? Some Possible Definitions. Why Object-oriented? Fundamentals of Object Orientation

Object oriented programming Concepts

ER to Relational Mapping

For 100% Result Oriented IGNOU Coaching and Project Training Call CPD TM : ,

Chapter No. 2 Class modeling CO:-Sketch Class,object models using fundamental relationships Contents 2.1 Object and Class Concepts (12M) Objects,

Copyright 2007 Ramez Elmasri and Shamkant B. Navathe Slide 4-1

Inheritance (Chapter 7)

Architectures in Context

Object Orientated Analysis and Design. Benjamin Kenwright

Index. Index. More information. block statements 66 y 107 Boolean 107 break 55, 68 built-in types 107

Object-Oriented Software Engineering Practical Software Development using UML and Java. Chapter 2: Review of Object Orientation

Chapter 4. Enhanced Entity- Relationship Modeling. Enhanced-ER (EER) Model Concepts. Subclasses and Superclasses (1)

Chapter 8: Class and Method Design

Enhanced Entity-Relationship (EER) Modeling

Relational DB Design by ER- and EER-to-Relational Mapping Design & Analysis of Database Systems

Copyright 2016 Ramez Elmasri and Shamkant B. Navathe

Chapter 9: Relational DB Design byer/eer to Relational Mapping Relational Database Design Using ER-to- Relational Mapping Mapping EER Model

«Computer Science» Requirements for applicants by Innopolis University

Accessibility. EEC 521: Software Engineering. Classes and Objects. Inheritance. Classes and Objects (OO Analysis)

COIS Databases

Software Engineering Fall 2014

Programming II (CS300)

COMP102: Introduction to Databases, 13

Chapter (4) Enhanced Entity-Relationship and Object Modeling

Software Engineering Fall 2015 (CSC 4350/6350) TR. 5:30 pm 7:15 pm. Rao Casturi 11/03/2015

Architectural Blueprint The 4+1 View Model of Software Architecture. Philippe Kruchten

Rushikesh K Joshi. Department of Computer Science and Engineering Indian Institute of Technology Bombay

DESIGNING A TOOL TO MAP UML CLASS DIAGRAM INTO RELATIONAL DATABASE

System Analysis and Design/ Object-Oriented System Modeling

Object Oriented System Development

Interactive Intelligent Systems Workshop: Music Constraint Programming (2) Music Representation

Copyright 2016 Ramez Elmasri and Shamkant B. Navathe

Introduction to Object- Oriented Programming

ECE 122. Engineering Problem Solving with Java

Introducing the UML Eng. Mohammed T. Abo Alroos

OBJECT ORIENTED SYSTEM DEVELOPMENT Software Development Dynamic System Development Information system solution Steps in System Development Analysis

Chapter 5: Procedural abstraction. Function procedures. Function procedures. Proper procedures and function procedures

THE ENHANCED ER (EER) MODEL CHAPTER 8 (6/E) CHAPTER 4 (5/E)

Component-based software engineering. Ian Sommerville 2004 Software Engineering, 7th edition. Chapter 19 Slide 1

Introduction to Software Engineering

Inheritance. Inheritance Reserved word protected Reserved word super Overriding methods Class Hierarchies Reading for this lecture: L&L

ΗΜΥ 317 Τεχνολογία Υπολογισμού

Object-Oriented Software Engineering. Chapter 2: Review of Object Orientation

What are the characteristics of Object Oriented programming language?

C++ Inheritance and Encapsulation

CMP-3440 Database Systems

Vesa Halava Tero Harju. Walks on Borders of Polygons

Fundamental Concepts (Principles) of Object Oriented Programming These slides are based on:

Inheritance and Polymorphism

Object Model. Object Orientated Analysis and Design. Benjamin Kenwright

Chapter 2: Entity-Relationship Model

Geog 469 GIS Workshop. System Requirements - Data

2. The object-oriented paradigm

SEEM4570 System Design and Implementation. Lecture 11 From Design to Implementation

Application-Oriented System Design

Object-Oriented Technology. Rick Mercer

Classes and Objects. Object Orientated Analysis and Design. Benjamin Kenwright

Sorting. Sorting. Selection sort

OOAD - OBJECT MODEL. The concepts of objects and classes are intrinsically linked with each other and form the foundation of object oriented paradigm.

Java. Representing Data. Representing data. Primitive data types

UML 2.0 UML 2.0. Scott Uk-Jin Lee. Division of Computer Science, College of Computing Hanyang University ERICA Campus

Lecture 1. Abstraction

Lecturer: Sebastian Coope Ashton Building, Room G.18 COMP 201 web-page:

Object-Oriented Programming Paradigm

Programmazione. Prof. Marco Bertini

ArchiMate 2.0. Structural Concepts Behavioral Concepts Informational Concepts. Business. Application. Technology

The Entity-Relationship Model. Steps in Database Design

Metamodeling with Metamodels. Using. UML/MOF including OCL

Programming II. Modularity 2017/18

Lecture 16: Object Programming Languages

Principles of Software Design. Software Engineering Alessio Gambi Saarland University

Overview of OOP. Dr. Zhang COSC 1436 Summer, /18/2017

Object Oriented Features. Inheritance. Inheritance. CS257 Computer Science I Kevin Sahr, PhD. Lecture 10: Inheritance

Chapter 17. Methodology Logical Database Design for the Relational Model

Object- Oriented Design with UML and Java Part I: Fundamentals

PROGRAMMING LANGUAGE PARADIGMS & THE MAIN PRINCIPLES OF OBJECT-ORIENTED PROGRAMMING

Déjà Vu: A Hierarchical Case-Based Reasoning System for Software Design

Model-based Transition from Requirements to High-level Software Design

Chapter 17 - Component-based software engineering. Chapter 17 So-ware reuse

Object-Oriented Programming

COURSE 2 DESIGN PATTERNS

Lecture 13 Introduction to Software Architecture

Architecting for autonomy

The major elements of the object-oriented model

Transcription:

Components vs. Objects Luigia Petre Turku Centre for Computer Science & Abo Akademi University, FIN-20520 Turku, Finland (Presented at Nordic Workshop on Programming Theory, Bergen, Norway, Oct 11-13, 2000)

Software Engineering Abstractions Component-based SE = constructing new systems from already existing, service-providing components Object-based SE = constructing a new system in terms of interacting, distinct units of information and services called objects

Motivation Both components and objects have encapsulation properties are accessed via well-defined interfaces are considered to improve the reuse of software are considered to alleviate the software evolution phase are thought of being natural abstractions of real-world entities a real-world entity can be modelled / implemented using either notion

Our Aim...is to answer to: (a) What is the essential difference between components and objects? (b) (Why) do we need them both?

Components (1) Software components = units of composition with contractually specified interfaces and context dependencies only A SW component can be deployed independently is subject to composition by third parties

Components (2) => possibly 3 parties involved: one specifies the component, one implements the specification of a component, one deploys / use the component Component (binary unit) contractual interfaces contractual dependencies

Component (binary unit) contractual interfaces contractual dependencies

Components (3) A system built up from components is more robust is more flexible (alleviates evolution) has a shorter development time / process The foremost advantage: reuse of software

Objects (1) Object - abstraction from a real-world entity, with associated items of information and a set of specific operations It has a unique and invariant identifier a class to which it belongs a state that has a certain value

Classes (1) Class - abstract data type with a set of properties (attributes and operations) common to its objects - has the means of creating objects with these properties

Classes (2) Person?Person}???Driver}?Person}???Physician} superclass / base class inheritance Driver Physician subclasses / derived classes

Objects (2) Objects interaction -- using each others operations Objects visibility -- the state and the implementation of the operations is hidden A system built up from objects is modular (designing classes rather than the whole system) is reusable (inheritance) alleviates evolution (objects are fundamental and stable, implementation is hidden)

The conceptual difference: their role Objects describe / implement real-world entities (and their hierarchies) mathematical modelling approach to software partition the state space Components describe / implement services of real-world entities engineering approach to software partition the service space

Example: Mail Delivery System Services: input mail send mail (MDS) load mail into the transportation means transport mail to destination confirm delivery

MDS Component View We need a component (PostCar) that is able to move to have a certain loading capacity We need a component (Driver) that is able to drive for x hours in a row to drive certain types of cars to receive a salary of no more than y

MDS Object View We need a class PostCar, with a move operation a capacity attribute We need a class Driver, with attributes in some ranges

Components vs.. Objects = Service vs.. Identity Using a service from a component: specify the required service and use any component providing an implementation of that service Using a service from an object: specify what object is used and use the service that particular object (with the particular state) can provide

Using Components and Objects Components -- service-oriented => they describe best the functionality of a system Objects -- identity-oriented => they describe best the problem domain of a system Consequently, we should start the software development with components develop each component in terms of objects

UML Diagrams Outline (1) MDS Drive Input Mail Load Customer Confirm Delivery Unload Dispatch Send Mail Transport

UML Diagrams Outline (2) MDS Drive Input Mail Load Customer Confirm Delivery Unload Dispatch Send Mail Transport

UML Diagrams Outline (3) Driver Drive Load Unload Outage On leave 1 Driver 1 On Duty 0..1 Task 0..1 TruckDriver CarDriver BusDriver

Conclusions Components -- service-oriented => best as functional abstractions Objects -- identity-oriented => best as problem domain abstractions Components and objects -- best as software construction abstractions