SlideShare a Scribd company logo
COMPONENT BASED SOFTWARE
      ENGINEERING



1
Introduction




2
What is a component?


    • A component is a basic building block for the
      computer software.
    • It is a higher level abstractions defined by their
      interfaces.
    • It helps in achieving the objectives & requirements
      of system to be built.




3
Definition for a component…


    A famous definition proposed by Council and Heinemann::
       “Component is a software element that conforms to a
    standard component model and can be independently
    deployed and composed without modification according to a
    composition standard. “




4
Characteristics of component



     Standardized
     Independent
     Composable
     Deployable
     Documented




5
STANDARDIZED



     A component used in a CBSE process has to conform to
      a standardized component model.
     The model may define: component
      interfaces, component metadata, documentation and
      deployment.




6
INDEPENDEND




     It should be possible to compose and deploy it without
      having to use other specific components.
     In case of need of external service these should be
      explicitly set out in a ‘requires’ interface specification.




7
COMPOSABLE




     All external interactions must take place through publicly
      defined interfaces.
     Also it must provide external access to information about
      itself such as its methods and attributes.




8
DEPLOYABLE




     A component has to be self contained.
     It should be able to stand alone entity on a component
      platform that provides an implementation of component
      model.




9
DOCUMENTED



      Components have to be fully documented so that the
       users can decide whether or not the components meet
       their needs.
      Each and every details of the component interfaces
       should be specified clearly.




10
Software Component
      An individual software component is a
       software package, a Web service, or a
       module that encapsulates a set of related
       functions (or data).
      Software components are modular and
       cohesive.
      Components communicate with each other
       via interfaces.
      Component based development embodies
       good software engineering practice.
11
 Component level design establishes the algorithmic
       detail required to manipulate data structures, effect
       communication between software components via their
       interfaces, and implement the processing algorithms
       allocated to each component.




12
Essentials of a CBSE…


      Independent components that are completely specified
       by their interfaces.
      Component standards that facilitates the integration of
       components.
      Middleware that provides support for integration of
       components.




13
Software Component




14
Defined
• A software component is a modular building block for
  computer software
     – It is a modular, deployable, and replaceable part of a
       system that encapsulates implementation and exposes a
       set of interfaces


• A component communicates and collaborates with
     – Other components
     – Entities outside the boundaries of the system


• Three different views of a component
     – An object-oriented view
     – A conventional view
     – A process-related view
15
Object-oriented View



•        A component is viewed as a set of one or more
         collaborating classes

•        Each problem domain (i.e., analysis) class and
         infrastructure (i.e., design) class is elaborated
         to identify all attributes and operations that
         apply to its implementation

     –     This also involves defining the interfaces that enable
           classes to communicate and collaborate
16
Object-oriented View                        contd..
•         This elaboration activity is applied to every
          component defined as part of the architectural
          design

•         Once this is completed, the following steps are
          performed

         1)   Provide further elaboration of each
              attribute, operation, and interface
         2)   Specify the data structure appropriate for each attribute
         3)   Design the algorithmic detail required to implement the
              processing logic associated with each operation
         4)   Design the mechanisms required to implement the
              interface to include the messaging that occurs between
              objects


    17
Conventional View
     • A component is viewed as a functional
       element (i.e., a module) of a program that
       incorporates

        – The processing logic


        – The internal data structures that are required to
          implement the processing logic


        – An interface that enables the component to be
          invoked and data to be passed to it


18
Conventional View
     contd…
     • A component serves one of the following roles

        – A control component that coordinates the invocation of
          all other problem domain components


        – A problem domain component that implements a
          complete or partial function that is required by the
          customer


        – An infrastructure component that is responsible for
          functions that support the processing required in the
          problem domain


19
Conventional View
     contd… software components are
     • Conventional
           derived from the data flow diagrams (DFDs)
           in the analysis model

       –     Each transform bubble (i.e., module)
             represented at the lowest levels of the DFD is
             mapped into a module hierarchy

       –     Control components reside near the top

       –     Problem domain components and infrastructure
             components migrate toward the bottom

       –     Functional independence is strived for between
             the transforms


20
Conventional View
     contd…
     •    Once this is completed, the following
          steps are performed for each transform

         1)   Define the interface for the transform (the
              order, number and types of the parameters)

         2)   Define the data structures used internally by
              the transform

         3) Design the algorithm used by the transform
            (using a stepwise refinement approach)



21
Process-related View

• Emphasis is placed on building systems from existing
  components maintained in a library rather than creating
  each component from scratch

• As the software architecture is formulated, components are
  selected from the library and used to populate the
  architecture

• Because the components in the library have been created
  with reuse in mind, each contains the following:
   – A complete description of their interface

   – The functions they perform


 22– The communication and collaboration they require
Designing Class-Based Components




 23
Component-level Design Principles
•    Open-closed principle

     – A module or component should be open for extension but closed
       for modification

     – The designer should specify the component in a way that allows it
       to be extended without the need to make internal code or design
       modifications to the existing parts of the component

•    Liskov substitution principle

     – Subclasses should be substitutable for their base classes

     – A component that uses a base class should continue to function
       properly if a subclass of the base class is passed to the component
       instead

     – This principle says that inheritance should be well designed and
       well behaved. In any case a user should be able to instantiate an
       object as a subclass and use all the base class functionality
       invisibly.
    24
Component-level Design Principles
•     Dependency inversion principle

       – Depend on abstractions (i.e., interfaces); do not depend on
         concretions

       – The more a component depends on other concrete components
         (rather than on the interfaces) the more difficult it will be to
         extend


•     Interface segregation principle
       – Many client-specific interfaces are better than one general purpose
         interface

       – For a server class, specialized interfaces should be created to
         serve major categories of clients

      – Only those operations that are relevant to a particular category of
    25 clients should be specified in the interface
Component Packaging Principles
     • Release reuse equivalency principle
         – The granularity of reuse is the granularity of release
         – Group the reusable classes into packages that can be
           managed, upgraded, and controlled as newer versions are created


     •   Common closure principle
         – Classes that change together belong together
         – Classes should be packaged cohesively; they should address the same
           functional or behavioral area on the assumption that if one class
           experiences a change then they all will experience a change


     •   Common reuse principle
         – Classes that aren't reused together should not be grouped together
         – Classes that are grouped together may go through unnecessary integration
           and testing when they have experienced no changes but when other
           classes in the package have been upgraded
26
Component-Level Design
•    Components
      Guidelines
         – Establish naming conventions for components that are
           specified as part of the architectural model and then
           refined and elaborated as part of the component-level
           model

         – Obtain architectural component names from the problem
           domain and ensure that they have meaning to all
           stakeholders who view the architectural model
           (e.g., Floor plan)

         – Use infrastructure component names that reflect their
           implementation-specific meaning (e.g., Linked List)

         – Use stereotypes to identify the nature of components at
           the detailed design level (e.g., <<database>>)
    27
Cohesion “single-mindedness’ of a
 • Cohesion is the
      component

 • It implies that a component or class encapsulates
   only attributes and operations that are closely
   related to one another and to the class or
   component itself

 • The objective is to keep cohesion as high as
   possible



 28
Cohesion                                               contd…
•    Kinds of cohesion (continued)


     – Procedural
         • Components or operations are grouped in a manner that allows
           one to be invoked immediately after the preceding one was
           invoked, even when no data passed between them


     – Temporal
         • Operations are grouped to perform a specific behavior or establish
           a certain state such as program start-up or when an error is
           detected


     – Utility
         • Components, classes, or operations are grouped within the same
29         category because of similar general functions but are otherwise
           unrelated to each other
Coupling
     • As the amount of communication and
       collaboration increases between
       operations and classes, the complexity of
       the computer-based system also increases

     • As complexity rises, the difficulty of
       implementing, testing, and maintaining
       software also increases

     • Coupling is a qualitative measure of the
       degree to which operations and classes
       are connected to one another

     • The objective is to keep coupling as low as
30     possible
Coupling                                             contd…
• The kinds of coupling can be ranked in order from lowest
  (best) to highest (worst)


     – Data coupling
        • Data coupling is when modules share data through, for
          example, parameters.


     – Stamp coupling
        • A whole data structure or class instantiation is passed as a
          parameter to an operation


     – Control coupling
        • Control coupling is one module controlling the flow of another, by
          passing it information on what to do
31
Coupling                                     contd…


     – Common coupling

        • Common coupling (also known as Global coupling) is
          when two modules share the same global data (e.g., a
          global variable).


     – Content coupling

        • One component secretly modifies data that is stored
          internally in another component

32
Designing Conventional Components




  33
• Conventional design constructs emphasize the
   Introduction
  maintainability of a functional/procedural program
     – Sequence, condition, and repetition


• Each construct has a predictable logical structure where
  control enters at the top and exits at the bottom, enabling
  a maintainer to easily follow the procedural flow


• Various notations depict the use of these constructs
     – Graphical design notation

        • Sequence, if-then-else, selection, repetition (see next slide)
     – Tabular design notation (see upcoming slide)
     – Program design language

        • Similar to a programming language; however, it uses narrative
34        text embedded directly within the program statements
Graphical Design Notation




35
Tabular Design Notation
1) List all actions that can be associated with a
   specific procedure (or module)


2) List all conditions (or decisions made) during
   execution of the procedure


3) Associate specific sets of conditions with specific
   actions, eliminating impossible combinations of
   conditions; alternatively, develop every possible
   permutation of conditions


4) Define rules by indicating what action(s) occurs
 36
    for a set of conditions
Tabular Design Notation       contd..
                                      Rule
 Conditions                    1     2s 3    4
 Condition A                   T     T       F
 Condition B                         F   T
 Condition C                   T             T
 Actions

 Action X                               
 Action Y                                    
 Action Z                                  
37

More Related Content

PPTX
Component based software engineering
PPT
Architecture design in software engineering
PPT
Pressman ch-11-component-level-design
PDF
Software Engineering : OOAD using UML
PPT
Function Oriented Design
PPTX
Scenario based methods
PPTX
Software engineering rogers pressman chapter 7
PPTX
Design Model & User Interface Design in Software Engineering
Component based software engineering
Architecture design in software engineering
Pressman ch-11-component-level-design
Software Engineering : OOAD using UML
Function Oriented Design
Scenario based methods
Software engineering rogers pressman chapter 7
Design Model & User Interface Design in Software Engineering

What's hot (20)

PPT
Software design
PPT
Software estimation
PPTX
Chapter 2 software process models
PPT
Object Oriented Analysis and Design
ODP
Evolutionary process models se.ppt
PPTX
Unified process Model
PPT
REQUIREMENT ENGINEERING
PPTX
Cohesion and coupling
PPT
Agile development, software engineering
PPTX
Use case diagram
PPT
Object Oriented Design
PPTX
PPTX
Artifacts
PPTX
Functional and non functional
PPTX
System testing
PPTX
Ch5- Software Engineering 9
PPTX
Software development process models
PPT
Software Requirements in Software Engineering SE5
PPTX
Requirements modeling
Software design
Software estimation
Chapter 2 software process models
Object Oriented Analysis and Design
Evolutionary process models se.ppt
Unified process Model
REQUIREMENT ENGINEERING
Cohesion and coupling
Agile development, software engineering
Use case diagram
Object Oriented Design
Artifacts
Functional and non functional
System testing
Ch5- Software Engineering 9
Software development process models
Software Requirements in Software Engineering SE5
Requirements modeling
Ad

Similar to Component level design (20)

PPT
Seii unit7 component-level-design
PPT
Ch 11-component-level-design
PPT
Software engg. pressman_ch-11
PPTX
UNIT-3_SE_PPT1.pptx software engineering
PPT
Ch19
PPTX
Component based development | what, why and how
DOC
term paper for cbd models
PPTX
9 Component Based SE.pptx9 Component Based SE.pptx9 Component Based SE.pptx
PPTX
L5 m256 block2_unit5
PDF
An Introduction to Software Architecture - Summary
PDF
Framework Engineering
PPTX
A glimpse-of-cbd
PPTX
Software Process Models
PPTX
Presentation on component based software engineering(cbse)
PPTX
KIOIO jert fill for a art and design .pptx
PDF
Component-Based and Model-Driven Engineering: what is the difference? A CBSE ...
DOCX
An Analysis of Component-based Software Development -Maximize the reuse of ex...
PPTX
Ch16 - Component Based Software Engineering
PPTX
Ch16 component based software engineering
Seii unit7 component-level-design
Ch 11-component-level-design
Software engg. pressman_ch-11
UNIT-3_SE_PPT1.pptx software engineering
Ch19
Component based development | what, why and how
term paper for cbd models
9 Component Based SE.pptx9 Component Based SE.pptx9 Component Based SE.pptx
L5 m256 block2_unit5
An Introduction to Software Architecture - Summary
Framework Engineering
A glimpse-of-cbd
Software Process Models
Presentation on component based software engineering(cbse)
KIOIO jert fill for a art and design .pptx
Component-Based and Model-Driven Engineering: what is the difference? A CBSE ...
An Analysis of Component-based Software Development -Maximize the reuse of ex...
Ch16 - Component Based Software Engineering
Ch16 component based software engineering
Ad

Recently uploaded (20)

PDF
Anesthesia in Laparoscopic Surgery in India
PPTX
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
PPTX
Introduction_to_Human_Anatomy_and_Physiology_for_B.Pharm.pptx
PDF
3rd Neelam Sanjeevareddy Memorial Lecture.pdf
PDF
01-Introduction-to-Information-Management.pdf
PPTX
Introduction to Child Health Nursing – Unit I | Child Health Nursing I | B.Sc...
PPTX
PPH.pptx obstetrics and gynecology in nursing
PPTX
Renaissance Architecture: A Journey from Faith to Humanism
PDF
BÀI TẬP BỔ TRỢ 4 KỸ NĂNG TIẾNG ANH 9 GLOBAL SUCCESS - CẢ NĂM - BÁM SÁT FORM Đ...
PDF
Classroom Observation Tools for Teachers
PDF
TR - Agricultural Crops Production NC III.pdf
PDF
Abdominal Access Techniques with Prof. Dr. R K Mishra
PDF
Module 4: Burden of Disease Tutorial Slides S2 2025
PDF
Supply Chain Operations Speaking Notes -ICLT Program
PDF
Basic Mud Logging Guide for educational purpose
PDF
Physiotherapy_for_Respiratory_and_Cardiac_Problems WEBBER.pdf
PDF
O5-L3 Freight Transport Ops (International) V1.pdf
PDF
Origin of periodic table-Mendeleev’s Periodic-Modern Periodic table
PPTX
Microbial diseases, their pathogenesis and prophylaxis
PDF
Chapter 2 Heredity, Prenatal Development, and Birth.pdf
Anesthesia in Laparoscopic Surgery in India
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
Introduction_to_Human_Anatomy_and_Physiology_for_B.Pharm.pptx
3rd Neelam Sanjeevareddy Memorial Lecture.pdf
01-Introduction-to-Information-Management.pdf
Introduction to Child Health Nursing – Unit I | Child Health Nursing I | B.Sc...
PPH.pptx obstetrics and gynecology in nursing
Renaissance Architecture: A Journey from Faith to Humanism
BÀI TẬP BỔ TRỢ 4 KỸ NĂNG TIẾNG ANH 9 GLOBAL SUCCESS - CẢ NĂM - BÁM SÁT FORM Đ...
Classroom Observation Tools for Teachers
TR - Agricultural Crops Production NC III.pdf
Abdominal Access Techniques with Prof. Dr. R K Mishra
Module 4: Burden of Disease Tutorial Slides S2 2025
Supply Chain Operations Speaking Notes -ICLT Program
Basic Mud Logging Guide for educational purpose
Physiotherapy_for_Respiratory_and_Cardiac_Problems WEBBER.pdf
O5-L3 Freight Transport Ops (International) V1.pdf
Origin of periodic table-Mendeleev’s Periodic-Modern Periodic table
Microbial diseases, their pathogenesis and prophylaxis
Chapter 2 Heredity, Prenatal Development, and Birth.pdf

Component level design

  • 1. COMPONENT BASED SOFTWARE ENGINEERING 1
  • 3. What is a component? • A component is a basic building block for the computer software. • It is a higher level abstractions defined by their interfaces. • It helps in achieving the objectives & requirements of system to be built. 3
  • 4. Definition for a component… A famous definition proposed by Council and Heinemann:: “Component is a software element that conforms to a standard component model and can be independently deployed and composed without modification according to a composition standard. “ 4
  • 5. Characteristics of component  Standardized  Independent  Composable  Deployable  Documented 5
  • 6. STANDARDIZED  A component used in a CBSE process has to conform to a standardized component model.  The model may define: component interfaces, component metadata, documentation and deployment. 6
  • 7. INDEPENDEND  It should be possible to compose and deploy it without having to use other specific components.  In case of need of external service these should be explicitly set out in a ‘requires’ interface specification. 7
  • 8. COMPOSABLE  All external interactions must take place through publicly defined interfaces.  Also it must provide external access to information about itself such as its methods and attributes. 8
  • 9. DEPLOYABLE  A component has to be self contained.  It should be able to stand alone entity on a component platform that provides an implementation of component model. 9
  • 10. DOCUMENTED  Components have to be fully documented so that the users can decide whether or not the components meet their needs.  Each and every details of the component interfaces should be specified clearly. 10
  • 11. Software Component  An individual software component is a software package, a Web service, or a module that encapsulates a set of related functions (or data).  Software components are modular and cohesive.  Components communicate with each other via interfaces.  Component based development embodies good software engineering practice. 11
  • 12.  Component level design establishes the algorithmic detail required to manipulate data structures, effect communication between software components via their interfaces, and implement the processing algorithms allocated to each component. 12
  • 13. Essentials of a CBSE…  Independent components that are completely specified by their interfaces.  Component standards that facilitates the integration of components.  Middleware that provides support for integration of components. 13
  • 15. Defined • A software component is a modular building block for computer software – It is a modular, deployable, and replaceable part of a system that encapsulates implementation and exposes a set of interfaces • A component communicates and collaborates with – Other components – Entities outside the boundaries of the system • Three different views of a component – An object-oriented view – A conventional view – A process-related view 15
  • 16. Object-oriented View • A component is viewed as a set of one or more collaborating classes • Each problem domain (i.e., analysis) class and infrastructure (i.e., design) class is elaborated to identify all attributes and operations that apply to its implementation – This also involves defining the interfaces that enable classes to communicate and collaborate 16
  • 17. Object-oriented View contd.. • This elaboration activity is applied to every component defined as part of the architectural design • Once this is completed, the following steps are performed 1) Provide further elaboration of each attribute, operation, and interface 2) Specify the data structure appropriate for each attribute 3) Design the algorithmic detail required to implement the processing logic associated with each operation 4) Design the mechanisms required to implement the interface to include the messaging that occurs between objects 17
  • 18. Conventional View • A component is viewed as a functional element (i.e., a module) of a program that incorporates – The processing logic – The internal data structures that are required to implement the processing logic – An interface that enables the component to be invoked and data to be passed to it 18
  • 19. Conventional View contd… • A component serves one of the following roles – A control component that coordinates the invocation of all other problem domain components – A problem domain component that implements a complete or partial function that is required by the customer – An infrastructure component that is responsible for functions that support the processing required in the problem domain 19
  • 20. Conventional View contd… software components are • Conventional derived from the data flow diagrams (DFDs) in the analysis model – Each transform bubble (i.e., module) represented at the lowest levels of the DFD is mapped into a module hierarchy – Control components reside near the top – Problem domain components and infrastructure components migrate toward the bottom – Functional independence is strived for between the transforms 20
  • 21. Conventional View contd… • Once this is completed, the following steps are performed for each transform 1) Define the interface for the transform (the order, number and types of the parameters) 2) Define the data structures used internally by the transform 3) Design the algorithm used by the transform (using a stepwise refinement approach) 21
  • 22. Process-related View • Emphasis is placed on building systems from existing components maintained in a library rather than creating each component from scratch • As the software architecture is formulated, components are selected from the library and used to populate the architecture • Because the components in the library have been created with reuse in mind, each contains the following: – A complete description of their interface – The functions they perform 22– The communication and collaboration they require
  • 24. Component-level Design Principles • Open-closed principle – A module or component should be open for extension but closed for modification – The designer should specify the component in a way that allows it to be extended without the need to make internal code or design modifications to the existing parts of the component • Liskov substitution principle – Subclasses should be substitutable for their base classes – A component that uses a base class should continue to function properly if a subclass of the base class is passed to the component instead – This principle says that inheritance should be well designed and well behaved. In any case a user should be able to instantiate an object as a subclass and use all the base class functionality invisibly. 24
  • 25. Component-level Design Principles • Dependency inversion principle – Depend on abstractions (i.e., interfaces); do not depend on concretions – The more a component depends on other concrete components (rather than on the interfaces) the more difficult it will be to extend • Interface segregation principle – Many client-specific interfaces are better than one general purpose interface – For a server class, specialized interfaces should be created to serve major categories of clients – Only those operations that are relevant to a particular category of 25 clients should be specified in the interface
  • 26. Component Packaging Principles • Release reuse equivalency principle – The granularity of reuse is the granularity of release – Group the reusable classes into packages that can be managed, upgraded, and controlled as newer versions are created • Common closure principle – Classes that change together belong together – Classes should be packaged cohesively; they should address the same functional or behavioral area on the assumption that if one class experiences a change then they all will experience a change • Common reuse principle – Classes that aren't reused together should not be grouped together – Classes that are grouped together may go through unnecessary integration and testing when they have experienced no changes but when other classes in the package have been upgraded 26
  • 27. Component-Level Design • Components Guidelines – Establish naming conventions for components that are specified as part of the architectural model and then refined and elaborated as part of the component-level model – Obtain architectural component names from the problem domain and ensure that they have meaning to all stakeholders who view the architectural model (e.g., Floor plan) – Use infrastructure component names that reflect their implementation-specific meaning (e.g., Linked List) – Use stereotypes to identify the nature of components at the detailed design level (e.g., <<database>>) 27
  • 28. Cohesion “single-mindedness’ of a • Cohesion is the component • It implies that a component or class encapsulates only attributes and operations that are closely related to one another and to the class or component itself • The objective is to keep cohesion as high as possible 28
  • 29. Cohesion contd… • Kinds of cohesion (continued) – Procedural • Components or operations are grouped in a manner that allows one to be invoked immediately after the preceding one was invoked, even when no data passed between them – Temporal • Operations are grouped to perform a specific behavior or establish a certain state such as program start-up or when an error is detected – Utility • Components, classes, or operations are grouped within the same 29 category because of similar general functions but are otherwise unrelated to each other
  • 30. Coupling • As the amount of communication and collaboration increases between operations and classes, the complexity of the computer-based system also increases • As complexity rises, the difficulty of implementing, testing, and maintaining software also increases • Coupling is a qualitative measure of the degree to which operations and classes are connected to one another • The objective is to keep coupling as low as 30 possible
  • 31. Coupling contd… • The kinds of coupling can be ranked in order from lowest (best) to highest (worst) – Data coupling • Data coupling is when modules share data through, for example, parameters. – Stamp coupling • A whole data structure or class instantiation is passed as a parameter to an operation – Control coupling • Control coupling is one module controlling the flow of another, by passing it information on what to do 31
  • 32. Coupling contd… – Common coupling • Common coupling (also known as Global coupling) is when two modules share the same global data (e.g., a global variable). – Content coupling • One component secretly modifies data that is stored internally in another component 32
  • 34. • Conventional design constructs emphasize the Introduction maintainability of a functional/procedural program – Sequence, condition, and repetition • Each construct has a predictable logical structure where control enters at the top and exits at the bottom, enabling a maintainer to easily follow the procedural flow • Various notations depict the use of these constructs – Graphical design notation • Sequence, if-then-else, selection, repetition (see next slide) – Tabular design notation (see upcoming slide) – Program design language • Similar to a programming language; however, it uses narrative 34 text embedded directly within the program statements
  • 36. Tabular Design Notation 1) List all actions that can be associated with a specific procedure (or module) 2) List all conditions (or decisions made) during execution of the procedure 3) Associate specific sets of conditions with specific actions, eliminating impossible combinations of conditions; alternatively, develop every possible permutation of conditions 4) Define rules by indicating what action(s) occurs 36 for a set of conditions
  • 37. Tabular Design Notation contd.. Rule Conditions 1 2s 3 4 Condition A T T F Condition B F T Condition C T T Actions Action X   Action Y  Action Z    37

Editor's Notes

  • #12: All system processes are placed into separate components so that all of the data and functions inside each component are semantically related. Because of this principle, it is often said that components are modular and cohesive.