Chapter - 2.Pptx Tools
Chapter - 2.Pptx Tools
Institute of Technology
Faculty of Computing & Software
Engineering
SE TOOLS AND
P RA C T I C E S
(SENG4144)
Addisu M. (Asst. Prof) G4 IT - SUMMER
CHAPTER 2
S Y N C H R O N I Z AT I O N
BETWEEN MODELS
A N D S O U RC E C O D E
INTRODUCTION
June 9, 2025
In modern SW dev’t, alignment between
conceptual models and the corresponding source
code is crucial for maintaining consistency,
June 9, 2025
Models: In software dev’t, models are abstract
representations of a system, includes:
– UML Diagrams: Unified Modeling Language (UML)
diagrams like class diagrams, sequence diagrams, state
June 9, 2025
Modeling – process of creating a simplified
representation of real-world system or concept
to understand, analyze, and predict their
June 9, 2025
It supports an approach to SE where the UML
modeling tools are completely integrated
with in RAD studio IDE.
June 9, 2025
DEV’T
Types of Models
Conceptual Models
used To outline high-level ideas and r/nships
June 9, 2025
DEV’T
Types of Models
Behavioral Models
Used to capture dynamic aspects of the system and
how it responds to events
June 9, 2025
DEV’T
Types of Models
Process Models
Used to represent workflows and processes
9
MODEL ELEMENTS AND
June 9, 2025
THEIR RELATIONSHIPS
To model elements and their relationships, use various
approaches depending on the context, such as UML for
software design, ERD for databases, or simple
conceptual frameworks
June 9, 2025
THEIR RELATIONSHIPS
Example:
– Entities and Relationships
User
– Attributes: UserID, UserName, Email
June 9, 2025
MANAGEMENT
SCM – a vital aspect of SW dev’t that involves
tracking and managing changes to source code
over time.
June 9, 2025
MANAGEMENT
Benefits of SCM
– Collaboration and Teamwork:
allows multiple developers to work together efficiently,
reducing conflicts and improving communication.
June 9, 2025
MANAGEMENT
Popular SCM Tools
– Git: distributed version control system that allows
developers to work offline and manage repositories
efficiently
June 9, 2025
SYNCHRONIZATION
process of maintaining consistency
between abstract models and their
corresponding implementation in source
June 9, 2025
SYNCHRONIZATION
Importance of Model-Code Synchronization
– Consistency: Ensures that the design reflected in
the models is accurately implemented in the code,
June 9, 2025
SYNCHRONIZATION
Approaches to Achieve Synchronization
– Model-Driven Development (MDD):
Emphasizes the use of models as primary artifacts,
often generating code directly from these models.
June 9, 2025
DEVELOPMENT
Model-Driven Development (MDD) - an
approach to software dev’t that emphasizes the
use of models as primary artifacts in the dev’t
June 9, 2025
Increased Abstraction: MDD allows developers to
work at a higher level of abstraction, making it
easier to understand and manipulate complex
June 9, 2025
MDD often employs standardized modeling
languages, such as:
Unified Modeling Language (UML): Widely
June 9, 2025
ILLUSTRATING MDD IN
Case Study #1: Airline Reservation
PRACTICE
System
Overview
An airline company aimed to develop a new reservation
June 9, 2025
ILLUSTRATING MDD IN
Case Study #2: Banking Software
PRACTICE
System
Overview
financial institution needed to develop banking software
June 9, 2025
Model Creation
Developers create abstract models that define the
system's architecture, components, and
June 9, 2025
Code Implementation
Generated code is then implemented, tested, and
validated to ensure it meets the specified
June 9, 2025
Types of Models
1. Conceptual Models
– provide a high-level view of the system, focusing on the
June 9, 2025
Types of Models
3. Physical Models
– represent the actual implementation of the system,
June 9, 2025
DIAGRAMS
Unified Modeling Language (UML) – a
standardized modeling language that provides a
set of diagrams for visualizing the design of a
June 9, 2025
DIAGRAMS
Steps to Create UML Diagrams
Identify Key Components: Determine the main
entities, processes, and relationships in the
June 9, 2025
MODELS TO CODE
Code Generation
Automated Code Generation: Use tools to
automatically generate code from models, reducing
manual coding errors and speeding up dev’t.
June 9, 2025
MODELS
Code generation from models is a key aspect of
MDD
It involves the automatic creation of source code
from high-level abstract models, significantly
June 9, 2025
CODE GENERATION
Automated code generation tools can enhance
productivity and reduce errors in software
development.
June 9, 2025
CODE GENERATION
List of some popular tools:
Framework-Specific Tools
– Spring Roo: A RAD tool for Spring applications,
June 9, 2025
CODE GENERATION
List of some popular tools:
Database Code Generation
– Hibernate Tools: Generates Hibernate mapping files
and Java classes from database schemas.
June 9, 2025
GENERATION TEMPLATES
Customizing code generation templates is
essential for tailoring generated code to meet
specific project requirements and coding
June 9, 2025
GENERATION TEMPLATES
Using Existing Templates
– Start with Default Templates: Use out-of-the-box
templates provided by the tool as a base. This saves
time and helps you understand the framework.
June 9, 2025
GENERATION TEMPLATES
Creating New Templates
– Define New Templates: If existing templates
don’t meet your needs, create new ones from
scratch, defining the required output format and
June 9, 2025
GENERATION TEMPLATES
Integration with Build Processes
– Automate Generation: Integrate the
code generation process into your build
Version Control
– Manage Templates: Keep your templates
in version control (e.g., Git) to track
changes and collaborate with team 37
SYNCHRONIZATION
June 9, 2025
CHALLENGES
Complexity of Models: Models often have complex
r/nships and dependencies that can be difficult to
track, leading to inconsistencies when underlying
code changes.