![Page 1: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/1.jpg)
1
Presenter: Dr. Nikolai Mansurov
Chief Scientist, Klocwork
Knowledge Discovery Meta-model:
TutorialADM workshop, 24th October 2005
Washington DC
![Page 2: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/2.jpg)
2
Supporters:
2nd joint revised submission published 3-04-2005
![Page 3: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/3.jpg)
3
Outline of the tutorial
1. Introduction2. Core package3. System and environment packages4. Code and Action packages5. Data package6. Logical, Run-time, Build packages7. Conceptual and Behavior packages8. UI package
![Page 4: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/4.jpg)
4
Introduction
![Page 5: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/5.jpg)
5
Business case for KDM
![Page 6: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/6.jpg)
6
Business case for KDM
• Existing software: complex, multiple technologies; multiple vendors;
• Need to extract knowledge in order to:– understand, – maintain, – improve, – transform, – modernize
• Need cooperation between vendors – starting with common knowledge representation
![Page 7: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/7.jpg)
7
KDM as tool interchange format
Tool 1
Tool 2
Tool 4
Tool 3
![Page 8: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/8.jpg)
8
KDM as tool interchange format
Tool 1
Tool 2
Tool 4
Tool 3
KDM-compliant XMI
![Page 9: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/9.jpg)
9
What is KDM ? (excerpt from RFP)
• The RFP solicits proposals for a Knowledge-Discovery Meta-model (KDM) for exchanging information related to transformation of existing software assets. Specifically, the proposal seeks a common repository structure for representing information about existing software assets and its operating environments.
• KDM represents the structure of the existing software and its related artifacts. It provides the ability to document existing systems, discover reusable components in existing software, support transformations to other languages and MDA, or enable other potential transformations.
• The meta-models will enable exchange of information about existing software artifacts among different tools. This will enable vendors that specialize on certain languages, platforms or types of transformations to deliver customer solutions in conjunction with other vendors.
![Page 10: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/10.jpg)
10
What is KDM ? (summary)
• Meta-model for representing information about existing software assets
• Includes software and its operating environment• Exchange of information between tool vendors
![Page 11: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/11.jpg)
11
What exactly is KDM ? (excerpt from RFP)
• KDM represents the principal artifacts of existing software as entities (the structural elements, the “things”), their relationships and attributes
• KDM spans multiple levels of abstraction:– Implementation– Design– Architecture– Business rules
• KDM provides traceability to artifacts• KDM is independent of implementation language and platform• KDM can represent multiple heterogeneous systems• KDM is extensible
![Page 12: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/12.jpg)
12
What exactly is KDM ? (summary)
• Represents existing software as Entities, Relationships and Attributes
• Language-independent yet extensible• Spans multiple abstractions yet traceable back to
artifacts• Focuses on structure of existing software to
provide context for modernizations
![Page 13: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/13.jpg)
13
Language-independent KDM
repository
Java
extension
extends
C++extension
extends
Cobol
extension
extends
C++
extension
extends
KDM
Constraints aredefined in Core KDM package:All language-specific extensionsare uniform
Cobol KDM Tool 1uses
Cobol KDM Tool 2
uses
C++ KDM Tool
uses
Java KDM Tool
uses
KDM in action: extraction
![Page 14: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/14.jpg)
14
Language-independent KDM
repository
Java
extension
extends
C++extension
extends
Cobol
extension
extends
C++
extension
extends
integrates
Language-independent KDM Tool
modifies
KDM in action: integration
![Page 15: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/15.jpg)
15
Language-independent KDM
repository
Java
extension
extends
C++extension
extends
Cobol
extension
extends
C++
extension
extends
Language-aware KDM Tool
readsuses
Transformation Tool
Language-independent KDM Tool
analyst
modifies
KDM in action: analysis
![Page 16: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/16.jpg)
16
Where KDM adds value?
• Information exchange between vendors• Architectural context for
– Understanding software– Modularization, untangling “hairballs”– Discovering reusable components– Inventory, estimations of effort– Modernization
• Architecture management– Before modernization– After modernization
• Application Portfolio Management• Transition into MDA
![Page 17: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/17.jpg)
17
Knowledge “dimensions” in KDMand separation of concerns
UI “things”
Data “things”Structural “things”
Behavior “things” Code “things”
Conceptual architecture
Domain model
Requirements,Features,Use Cases
Approximates modeling world from the ground up
Based on Architecture Views
![Page 18: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/18.jpg)
18
How KDM is designed ?
• KDM is partitioned into several packages • Each package represents software artifacts as entities and relations
– Code, Data and Action entities– Logical, RunTime, Build entities – UI entities– Conceptual entities– Behavior entities– Environment entities
• Since KDM focuses on representing structures, most KDM entities are containers for other entities
• KDM can represent multiple container hierarchies• Uniform mechanism of derived relations bottom-up through container
hierarchies to address scalability of abstractions
![Page 19: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/19.jpg)
19
Structure of KDM packages
Core
Data Code Actions
Logical RunTime
UI
Build
Conceptual BehaviorEnvironment
SourceRef
meta-model
Primitives, explicit, automatically extracted
Higher-level, implicit, experts, analysts
SystemEntry point
Type
![Page 20: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/20.jpg)
20
Core Package
![Page 21: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/21.jpg)
21
Core KDM package
• Core package is used by all other KDM packages
• Core package defines key KDM concepts and constraints– KDMEntity– KDMRelationship– KDMContainer– KDMModel
• Core package defines KDM light-weight extension mechanism– Stereotype– TagValue
Element
ModelElement
KDMRelationship<<Interface>>
KDMModel<<Interface>>
KDMEntityname : Name
<<Interface>>
10..*
+from1
+/outbound
0..* 10..* +to 1
+/inbound
0..*
1
0..*
+/model1
+/entities
0..*
KDMContainer<<Interface>>
0..*
0..*
+/contents0..*
+/container0..*
1
0..*
+/parent1
0..*
KDMDerivedRelationshipdensity : Integer
<<Interface>>
1..*0.. *+from
1..*+outDerived
0.. *1..*
0..*
+to 1..*
+inDerived0..*
![Page 22: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/22.jpg)
22
Container Diagram AB
Container A Container B
Derived relation between containers
Derived relation between a container and its environment
100 15 3
number of relations from B to A
Container B1
Container B3
Container B2
Container B4Container A
25 15
50
25
3
Container C
collection of
Derived relationships
represents
Relation from B to A represents relations from B1, B3 and B4 to A
100=25+25+50
![Page 23: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/23.jpg)
23
Light-weight extension example<?xml version="1.0" encoding="UTF-8"?>
<null:System xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:null="null">
<Executable name="AMilanProgram" extension="//@stereotype.0" ><TaggedValue tag="reenterable" value="false"/>
</Executable>
<CallableUnit name="aFunc" parent="//@Executable.0"/><Data name="aLocalVar1" extension="//@MetaEntity.11" parent="//@CallableUnit.0"
extension="//@stereotype.4"/><Data name="aParam1" kind="//@MetaEntity.12" parent="//@CallableUnit.0"
extension="//@stereotype.5"/>
<Data name="aParam2" kind="//@MetaEntity.12" parent="//@CallableUnit.0"extension="//@stereotype.5"/>
<DataType name="int" kind="//@MetaEntity.8" parent="//@Executable.0"
extension="//@stereotype.2"/><Data name="aVar" kind="//@MetaEntity.7" parent="//@Executable.0"
extension="//@stereotype.1"/>
<stereotype baseClass="Executable" name="MilanProgram" family="Milan">
<TaggedValue tag="reenterable" type="Boolean"/></stereotype>
<stereotype name="MilanVariable" baseClass="Global" family="Milan" />
<stereotype name="MilanType" baseClass="DataType" family="Milan"/><stereotype name="MilanFunction" baseClass="CallableUnit" family="Milan"/>
<stereotype name="MilanLocal" baseClass="LocalData" family="Milan"/><stereotype name="MilanParam" baseClass="ParamData" family="Milan"/><stereotype name="UsesType" baseClass="HasType" family="Milan"/>
</null:System>
StereotypebaseClass : Namefamily : Namename : Name
TaggedValuetag : Nametype : Stringvalue : String
0..1
0..*
0..1
+requiredTag0..*
ModelElement
0..1
1
+extension
0..1
+extendedElement1
0..*
+taggedValue
0..*
Element
![Page 24: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/24.jpg)
24
System and Environment packages
![Page 25: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/25.jpg)
25
System
• System is a collection of various models
• System is an entry point to various facets of knowledge
KDMContainer(from Core)
<<Interface>>
StructureModel
/ entities : StructureElement(from Structure)
RunTimeModel(from RunTime)
DataModel(from Data)
BuildModel(from Build)
BehaviorModel(from Behavior)
UIModel(from UI)
ConceptualModel(from Conceptual)
CodeModel(from Code)
EnvironmentModel(from Environment)
ActionModel(from Act ion)
TypeModel(from Type)
EventModel(from Event)
System
0..*
+structureModel
0..*
+system
0..*
1
+runTimeModel0..*
+system
1
0..*
+dataModel0..*
+system
0..*
1
+buildModel0..*
+system1
0..*
1
+scenarioModel0..*
+system1
0..*
1
+UIModel0..*
+system1
0..*
1
+conceptualModel0..*
+system
1 0..*
1 +codeModel
0..*+system1
0..*
1
+environmentModel0..*
1
0..*1
+actrionModel
0..*+system1
0..*
1
+typeModel0..*
+system
1
0..*
1
+eventModel 0..*
+system
1
![Page 26: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/26.jpg)
26
Environment Package
• EnvironmentEntity represents “things” in the operational environment of the system
• Relationships are derived from UI
KDMModel(from Core)
<<Interface>>
EnvironmentModel
EnvironmentElement
0..*
1
+entities
0..*
+model1
EnvironmentGroup
0..* 0..1+contents0..* +container 0..1
KDMContainer(from Core)
<<Interface>>KDMEntity
name : Name(from Core)
<<Interface>>
![Page 27: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/27.jpg)
27
Environment Package - services
• 3rd party components and services
EnvironmentElement
Utility
Service
Complies
0..*
1
+outComplies 0..*
+from 1
Interface(from Type)
1
0..*
+interface1
0..*
1
0..*
+interface1
0..*
0..*
1
+inComplies0..*
+to1
InterfaceRelationship
(from Type)
KDMRelationship(from Core)
<<Interface>>
service may be a container for certain interfaces
![Page 28: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/28.jpg)
28
Environment Package - technology
• 3rd party implementations of platform elementKDMRelationship
(from Core)
<<Interface>>
RunTimeGroup(from RunTime)TechnologyEntity
Requires
1
0..*+from
1
+outRequires
0..*
1
0..*
+to1
+inRequires 0..*
EnvironmentElementTechnologyRela
tionship
![Page 29: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/29.jpg)
29
Conceptual and Behavior Packages
![Page 30: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/30.jpg)
30
Interchange between Mining and Modeling Tools
Mining Tool 1
Mining Tool 2
Software Modeling Tool
Business Modeling ToolKDM-compliant XMI
• Integration of Modeling Tools with multiple Code Mining Tools
• Preservation of IP in a standard based repository
• Knowledge Mining and Abstraction to the required model abstraction level (e.g. Business Model)
• Enabling Forward Engineering Tools with discovered knowledge
![Page 31: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/31.jpg)
31
Conceptual Package
• ConceptualEntityrepresents a concept which is significant outside of the code in some external model
• ConceptulEntity is a set of CodeEntities
• ConceptualEntity allows composition
• Relationships are derived from CodeEntities
• Currently, there are 2 ConceptualEntities: TermUnit and FactUnit
KDMModel(from Core)
<<Interface>>
KDMContainer(from Core)
<<Interface>>
TermUnit FactUnit
ConceptualModel
ProgramElement(from Code)
<<Interface>>ConceptualElement
0..*
1
+entities0..*
+model1
0..1
0..*
+container
0..1
+contents
0..*0..*0..*
+entities
0..*0..*
![Page 32: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/32.jpg)
32
Behavior Package
• BehaviorEntityrepresents behavior significant outside of the code in some external model
• BehaviorEntity is a directed graph of Actions
• BehaviorEntity allows composition
• Relationships are derived from Actions
• Currently there are 3 BehaviorEntities: BehaviorUnit, ScenarioUnit and RuleUnit
KDMModel(from Core)
<<Interface>>
KDMContainer(from Core)
<<Interface>>
BehaviorUnit ScenarioUnit RuleUnit
BehaviorModel
ActionElement(from Action)
ProgramElement(from Code)
<<Interface>>
BehaviorElement0..*
1
+entities
0..*
+model1
0..1
0..*
+container
0..1
+contents
0..*
0..*0..*
+actions
0..*0..*
{ordered}
0..*0..*
+entities
0..*0..*
![Page 33: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/33.jpg)
33
C onceptualModel
E xternalBRM
FactUni t(from ConceptualM odel)
Fact
0..n
0..n
+factUnit0..n
+fact 0..n
Term Uni t(from ConceptualM odel)
Term
0..n
0.. n
+termUnit 0..n
+term 0.. n
B ehaviorModel
Rule
RuleUni t(from B ehaviorM odel)
0..n
0..n
+rule 0..n
+ruleU nit 0..n
• KDM conceptual and behavior entities mapped to External BRM entities using many to many relationships• KDM entities serve as implementation of BRM entities.
Mapping of External BRM to KDM
![Page 34: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/34.jpg)
34
Code and Action packages
![Page 35: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/35.jpg)
35
Code and Action Packages
• Code Package:– Capture system artifacts that represents a block of
instruction statements. For example a function in C or a paragraph in Cobol.
– Code Package links to data package.• Type Package:
– Captures system artifacts that represent types• Action Package:
– Represents language independent executable statements behavior. For example Call, Control flow, IO.
![Page 36: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/36.jpg)
36
Code package - main
• Module is the container for code, data and actions
• CodeGroup allows composition
CodeElement
KDMModel(from Core)
<<Interface>>
CodeGroup
CodeModel
0..*
0..1
+contents
0..*
+container
0..1
0..*
1
+entities0..*
+model 1
10..*
+parent1
0..*
KDMContainer(from Core)
<<Interface>>
KDMEntity
name : Name(from Core)
<<Interface>>
ProgramElement<<Interface>>
![Page 37: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/37.jpg)
37
Code package – Code Elements
• CodeElements are implementation “things” in source files:– CallableUnit– ClassUnit– DataUnit– MacroUnit– PrototypeUnit– TemplateUnit
• This models defines some specific relations
• Data type elements are defined in a separate package
CallableUnit
CallableInterfaceentry : EntryKindisExternal : booleanvisibi li ty : Visibi li tyKind
<<Interface>> CodeGroup
Module
BlockUnit
![Page 38: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/38.jpg)
38
Code package – Code Entities
• CodeEntities are implementation “things” in source files:– CallableUnit– ClassUnit– DataUnit– MacroUnit– DeclarationUnit– DataTypeUnit
• This models defines some specific relations
DataUnitvisibi lity : VisibilityKindreference : ReferenceKindisInstance : Boolean
DataInterface(from Act ion)
<<Interface>>
GlobalDataLocalData
CodeElement
![Page 39: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/39.jpg)
39
Code package – callable unit
• CallableUnit contains Signature (includingParameterData)
Signature(from Type)
CallableInterfaceentry : EntryKindisExternal : booleanvisibility : VisibilityKind
<<Interface>>
1
0..*
+signature1
0..*
Element(from Core)
![Page 40: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/40.jpg)
40
Code package – class Unit
• ClassUnit contains MethodData and MemberData
• Constructors are represented separately from methods
• ClassUnit can subclass other ClassUnits
CallableInterfaceentry : EntryKindisExternal : booleanvisibility : VisibilityKind
<<Interface>>
TypeRelationship(from Type)
DataUnitvisibility : VisibilityKindreference : ReferenceKindisInstance : Boolean
CodeGroupTypeInterface
isInterface : booleanisAbstract : boolean
(from Type)
<<Interface>>
Extends
MethodUnit MemberData
ConstructorUnit
ClassUnit0..*
1
+outClass0..*
+from1
0..*
1
+inClass0..*
+to1
1
0..*
+class1
+methods
0..*
1
0..*
+class1
+members 0..*
1..*
1
+constructors1..*
+class
1
![Page 41: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/41.jpg)
41
Code package - prototypes
• PrototypeUnit defines some specific relations
PrototypeRelationship
KDMRelationship(from Core)
<<Interface>>
PrototypeUnit
CodeElement
PrototypedBy
1
0..*+to1+inPrototypedBy
0..*
0..*
+from
+outPrototypedBy
0..*
![Page 42: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/42.jpg)
42
Code package – other elements
• MacroUnit• TemplateUnit, TemplateInstance and TemplateParameter
![Page 43: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/43.jpg)
43
Type package - main
• Type package represents program element that are related to types
TypeModel
TypeGroupTypeElement
0..*
1
+entities0..*
+model1
0..10..* 0..10..*
TypeInterfaceisInterface : booleanisAbstract : boolean
<<Interface>>
KDMModel(from Core)
<<Interface>>
KDMContainer(from Core)
<<Interface>>
KDMEntity
name : Name(from Core)
<<Interface>>
ProgramElement(from Code)
<<Interface>>
![Page 44: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/44.jpg)
44
Type package – Type Relations
• Type Relation is a placeholder for light-weight extensions
• HasType is a relationship between a DataInterface and a TypeInterface
DataInterface(from Action)
<<Interface>>
TypeInterfaceisInterface : booleanisAbstract : boolean
<<Interface>>
HasType
10..*
+from
1
+outHasType
0..*
1
0..*
+to1
+inHasType0..*
TypeRelationship
KDMRelationship(from Core)
<<Interface>>
![Page 45: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/45.jpg)
45
Type package - Signature
• Signature contains Formal Parameters
Element(from Core)
TypeGroup
TypeRelationship
TypeInterfaceisInterface : booleanisAbstract : boolean
<<Interface>>
FormalParameterinout : ParameterKindaccess : AccessKind
ReturnsType
1
0..*
+to 1
+inReturnsType0..*
Signature0..*
+parameters
0..*
+signature
0..*1 0..*
+parent
1
0..*
1
+outReturnsType0..*
+from1
![Page 46: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/46.jpg)
46
Type package - Interface
• Interface is a collection of types
TypeGroup
CodeElement(from Code)
Implements
1
0..*
+from 1
+outInterface0..*
Signature
Trigger(from Event)
TypeElement
Interface
1
0..*
+to1
+inImplements
0..*0..*
0..*
+signatures
0..*
0..*
0..*
0..*
+triggrers
0..*
0..*
0..*
0..*
+types0..*
0..*
InterfaceRelationship
![Page 47: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/47.jpg)
47
Type package – Composite Type Elements
• Composite Type Elements are containers
EnumerationLiteral
EnumerationType
1..*
1
+literals1..*
+enumeration 1UnionType
TypeInterfaceisInterface : booleanisAbstract : boolean
<<Interface>>
1..*
0..*
+types 1..*
0..*
CompositeType
1..*
0..*
+types1..*
0..*
TypeGroup
TypeElement
![Page 48: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/48.jpg)
48
Type package – Type Elements
• Non-composite typesTypeElement
RefinementType
RefinementOf
1
0..*
+from1
+outRefinementOf0..*
PointerType
TypeInterfaceisInterface : booleanisAbstract : boolean
<<Interface>>1
0..*
+to
1
+inRefinementOf0..*
PointerTo
10..* +from1
+outPointerTo0..*
1
0..*
+to1
+inPointerTo 0..*
TypeRelationship
![Page 49: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/49.jpg)
49
Action package – Action Entities
• ActionEntity represents behavior “things”, like statements, features, business rules, etc.
• ActionGroup allows composition
• ActionEntities are endpoints for some specific relations
KDMContainer(from Core)
<<Interface>>
KDMEntity
name : Name(from Core)
<<Interface>>
KDMModel(from Core)
<<Interface>>
ActionGroup
CallableInterface
entry : EntryKindisExternal : booleanvisibility : VisibilityKind
(from Code)
<<Interface>>ActionElement
0..1
0..*
+container0..1
+contents
0..*
0..1 0..*0..1
+actions
0..*
+parent
ActionModel
0..*
1
+entities0..*
+model1
![Page 50: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/50.jpg)
50
Action package – action flow
ControlFlow
ActionEntity+to
+from
KDMRelationship
density : Integer(from Core)
• There is ControlFlow relation between ActionEntities
![Page 51: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/51.jpg)
51
Action package – Code relationships
• ActionEntities are endpoints for some specific relations
KDMRelationship(from Core)
<<Interface>>
CodeRelationship
CallableInterface
entry : EntryKindisExternal : booleanvisibility : VisibilityKind
(from Code)
<<Interface>>
Calls
1
0..*
+to 1
+inCalls0..*
CodeElement(from Code)
ActionElement
10..*+from
1
+outCalls
0..*
UsesCode
1
0..*
+to1
+inUsesCode 0..*
1
0..*
+from 1
+outUsesCode0..*
![Page 52: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/52.jpg)
52
Action package – data relationships
• ActionEntities are endpoints for some specific relations to Data via DataInterface
Reads
Writes
Creates
UsesData
Destroys
DataInterface<<Interface>>
1
0..*
+to1
+inReads
0..*
1
0..*
+to1
+inWrites
0..*
1
0..*
+to 1
+inCreates0..*
1
0..*
+to1
+inUsesData
0..*
1
0..*
+to1
+inDestroys0..*
ActionElement1
0..*
1
+outReads0..*
1
0..*
+from1
+outWrites0..*
1
0..*+from
1
+outCreates0..*
1
0..*
+from1
+outUsesData0..*
1
0..*+from
1
+outDestroys
0..*
Updates
1
0..*
+to 1
+inUpdates0..*
10..*
+from
1+outUpdates
0..*
DataRelationship
KDMRelationship(from Core)
<<Interface>>
![Page 53: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/53.jpg)
53
Action package – other relationships
• Import relations• Macro relations• Prototype relations• Type relations
![Page 54: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/54.jpg)
54
Data package
![Page 55: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/55.jpg)
55
Data Package
• Data Package:– Defines types for elements– Represents system artifacts that define system
data– Artifact representations include persistent and non-
persistent data• Data Package defines data elements and data
groups along with links to persistent data representations and data models
• Data Package links to data definitions as expressed in the Code Package
![Page 56: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/56.jpg)
56
DataInterface(from Action)
<<Interface>>
KDMModel(from Core)
<<Interface>>
DataModel
DataEntityisKey : Boolean
0..*
1
+entities0..*
+model1
DataGroup
0..*
0..1
+contents
0..*
+container0..1
KDMContainer(from Core)
<<Interface>>
KDMEntity
name : Name(from Core)
<<Interface>>
DataElement
ProgramElement(from Code)
<<Interface>>
Data Package
![Page 57: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/57.jpg)
57
Data Elements
• Data Element: Named data field extracted from a system that may be a group or an individual element.
• Data Entity: Logical data element that represents a relational entity in a data model
• Data Group: A collection of data elements, typically derived from existing system record, table, segment or similar grouping structures.
• A Data Element may be tied directly to Persistent Data. Persistent data may be represented in a data model.
![Page 58: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/58.jpg)
58
Data Package – persistent data
RelationalDBHierarchicalDB
ObjectDB
FileStore
NetworkDB
IndexedFile
DataGroup
PersistentData
![Page 59: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/59.jpg)
59
Logical, RunTime and Build Packages
![Page 60: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/60.jpg)
60
Logical Package• Logical package
describes components of existing software
• It represents structural “elements”:– Package– Subsystem– Layer– LogicalGroup which
allows composition• Module is the container
for code, data and actions• Relationships between
components are derived from Modules
SubsystemLayer
KDMContainer(from Core)
<<Interface>>
KDMEntity
name : Name(from Core)
<<Interface>>KDMModel(from Core)
<<Interface>>
LogicalGroup
LogicalModel/ entities : LogicalEntity
LogicalEntity 0..*
0..1
+contents
0..*{redefines}
+container0..1
1
0..*
+model 1
+entities 0..*{redefines}
Package
0..*0..1
+packages0..*
+parent0..1
Module(from CodeModel) 0..*
0..1
+modules0..*
+logicalEntity
0..1
1
0..*
+package1
+modules0..*
![Page 61: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/61.jpg)
61
Build Package - main
• Build package represents physical “things”:
• BuildGroup allows composition
• BuildComponent contains Modules
• Module is the container for code, data and actions
• BuildComponent contains Files
• This model defines specific relations
Resource
BuildDescriptionSymbolicLink
KDMModel(from Core)
<<Interface>>
BuildModel
BuildGroup
Module(from CodeModel)
BuildEntity0..*
+entities0..*
+model
0..*
0..1
+contents
0..*
+container
0..1
0..*0..1 +modules
0..*
+buildEntity
0..1
KDMContainer(from Core)
<<Interface>> KDMEntity
name : Name(from Core)
<<Interface>>
SourceFile
Image
![Page 62: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/62.jpg)
62
Build Package – build relations
• Specific build relations:– File generates file– File imports file– Files depends on file– SymbolicLink points
to File
KDMRelationship(from Core)
<<Interface>>
SymbolicLink
LinksTo
0..*
1
+outLink0..*+from
1
Depends
Resource0..*
+to+inLink
0..* 1
0..*
+from
1
+outDepend0..*
1
0..*
+to
1
+inDepend
0..*Generates
1
0..*
+from
1
+outGenerate0..*
1
0..*
+to1
+inGenerate0..*
BuildRelationship
![Page 63: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/63.jpg)
63
RunTime Package• RunTime package represents
common runtime platform aspects:
– Platform Resource– Application Component– Platform Service– Platform Binding
• It addresses such things as:– Application– Executable– Process– Thread
• RunTime model also represents inter-component communication:– Communication object– Shared data
RunTimeEntity
KDMModel(from Core)
<<Interface>>
RunTimeModel
Module(from CodeModel)
RunTimeGroup
1
0.. *
+model1
+entities 0.. *
0..*0..*
+modules
0..*
+runTimeEntity
0..*
0..1
0..*
+container0..1
+contents 0..*
KDMContainer(from Core)
<<Interface>>
KDMEntity
name : Name(from Core)
<<Interface>>
![Page 64: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/64.jpg)
64
RunTime model - Groups
• LogicalGroup allows composition
• Module is the container for code, data and actions
• Relationships are derived from Data
• This model defines some specific relations
RunTimeGroup
SharedData
Process
Executable
Thread
Application
CommunicationObject
RunTimeEntityDataInterface(from CodeModel)
<<Interface>>
DynamicData
DataPort
![Page 65: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/65.jpg)
65
UI package
![Page 66: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/66.jpg)
66
User Interface Package
• Overview– The UI Package takes a broad view of visual (elements,
views) and behavioral aspects (events) of the user interface of a software application
• Dependencies (other than KDM Core)– Resources defined in the BuildModel may be used in a
view– DataInterfaces from the CodeModel may be presented
in a view– CodeInterfaces from the CodeModel may be
associated with a UI element and with UI events
![Page 67: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/67.jpg)
67
UI Package diagrams
• UI core entities and relations• UI layout• UI behavior• UI events
![Page 68: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/68.jpg)
68
UI core entities and relations
• From KDM Core– UIModel from
KDMModel– UIEntity from
KDMEntity– UIGroup from
KDMContainer
![Page 69: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/69.jpg)
69
UI core entities and relations (cont.)
• Trigger –events (e.g. key, mouse, timer) linked to display orCodeInterfaces
• DisplayUnit –single UI entity (e.g. a control on a form)– May be a resource
from BuildModel– May be a
DataInterface from CodeModel
![Page 70: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/70.jpg)
70
UI core entities and relations (cont.)
• UIGroup –composition of other UI entities
• Display – a compound unit of display (e.g. a Web page) that is composed of other display elements– Screens– Reports
![Page 71: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/71.jpg)
71
UI layout
• One aspect of UI layout is captured in the UI core model just presented: the UIGroup is composed of instances of UIEntity, such as DisplayUnits
![Page 72: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/72.jpg)
72
UI layout (cont.)
• These classes and relationships further define the linkage between DisplayUnits and the information they render
• A FixedDisplayUnit is static information
• A VariableDisplayUnitis dynamic information
![Page 73: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/73.jpg)
73
UI layout (cont.)
• UsesResource is the relationship class linking the UI model to the BuildModel for interface content (e.g. images)
• DisplayData is the relationship class linking the UI model to the CodeModel for data
![Page 74: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/74.jpg)
74
UI behavior
• The high-level behavior of the user interface is recorded as the flow from one Display instance to another, using the UIFlow relationship class
![Page 75: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/75.jpg)
75
UI behavior (cont.)
• The relationship between the software application software and the UI Display is recorded in the Displays relationship class.
• The CodeModel’s CallableInterface activates an instance of Display
![Page 76: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/76.jpg)
76
UI behavior (cont.)
• Refresher:– Display is a
compound unit of display (e.g. a Web page) that is composed of other display elements
• Separation of layout and content is modeled by the UsesLayout relationship class
![Page 77: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/77.jpg)
77
UI events
• This portion of the UI model describes lower-level behavior, linking events to the Display and to the application software (via CallableInterface)
![Page 78: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/78.jpg)
78
UI events (cont.)
• A Trigger is an event in the UI which activates an application operation or changes the Display
• Three subtypes of Trigger– KeyEvent– MouseEvent– TimerEvent
![Page 79: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/79.jpg)
79
UI events (cont.)
• When a Trigger leads to execution of application code, the Triggers as the relationship is used to connect to the CallableInterface from the CodeModel
![Page 80: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/80.jpg)
80
UI events (cont.)
• When a Trigger does not lead to invocation of application code, the Trigger’s Display changes are modeled using the Renders relationship class
![Page 81: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/81.jpg)
81
User Interface Package
• Covers content and layout of UI– Relationships to Build package and Code
package• Covers behavior
– Flow within UI model constructs– Relationships to Code package for software
activation of UI, and for UI event-driven dispatching of application
![Page 82: Knowledge Discovery Meta-model: Tutorial - omg.org · 18 How KDM is designed ? • KDM is partitioned into several packages • Each package represents software artifacts as entities](https://reader030.vdocuments.net/reader030/viewer/2022020319/5cc7fa6288c993c4398ca68c/html5/thumbnails/82.jpg)
82
Questions ?