Model-Driven Evolution of Software Architectures - Software and ...
Model-Driven Evolution of Software Architectures - Software and ...
Model-Driven Evolution of Software Architectures - Software and ...
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
118 Chapter6. ConformanceCheckingII<br />
The Java platform for the micro controller <strong>of</strong>fers a special type <strong>of</strong><br />
(buffered)streamclassforwhichwecreateaSharedDataconnectorinthe<br />
CPADLtargetmodel.Byidentifyingeachthreadthatreadsfromorwrites<br />
toaninstance<strong>of</strong>thatclassweidentify Ports(inputoroutput), Roles(source<br />
orsink),<strong>and</strong> Attachments.<br />
Identification<strong>of</strong> Messageconnectorsinthetransformationexplained<br />
above,resultsinaseparateconnectorinstanceforeachdistinctmethodinvocationbetweentwothreads.Ingeneral,connectorsdescribeacomplete<br />
protocolfortheinteractionsallowedbetweentwocomponents. Therefore,<br />
usinganothermodeltransformation,weabstractall Messageconnectors<br />
betweentwocomponentsintoasingleconnectorrepresentingtheallowed<br />
message-basedinteractionbetweenthosecomponents.<br />
TheresultinggraphisgiveninFigure6.8(b).Werepresentcomponents<br />
byrectangles<strong>and</strong>connectorsbyellipses.Attachmentsarerepresentedby<br />
edges<strong>and</strong>theirarrowheadsindicatethe‘direction’<strong>of</strong>theinvolvedports<br />
<strong>and</strong>roles.<br />
ThearchitecturalinputwastheC&Cview<strong>of</strong>Figure6.3(a)onpage107.<br />
ToturnthisviewintoaCPADLmodel,wemapeachstereotyped Objecttoa<br />
ProcessintheCPADLtargetmodel.Each Linkismappedtoanappropriate<br />
Connectordependingontheappliedstereotype. Ports, Roles,<strong>and</strong> Attachments<br />
arecreatedwherenecessary.Notethatwecannotdistinguishbetweeninoroutputportsorsourceorsinkconnectorshere,asnodirectionisprovided.TheCPADLmodelpopulatedfromthearchitectureisgiveninFigure6.8(a).<br />
6.5.2 <strong>Model</strong>Comparison<br />
Thecomparisontransformationshavetwosourcemodels(derivedfrom<br />
implementation<strong>and</strong>fromarchitecture)<strong>and</strong>generateanattributedtarget<br />
model,containingtheelements<strong>of</strong>thesourcemodelsattributedwithone<strong>of</strong><br />
thefollowinglabels:convergent,divergent,orabsent.<br />
ModuleViews Foreachmoduleinbothsourcemodelsitischeckedwhether<br />
itisaconvergent,divergentorabsentmodule. Thisissimplydoneusing<br />
namematching.<br />
Ausesrelationintheimplementationsourcemodelisconsideredconvergentifausesrelationexistsbetweentwomodulesinthearchitecture<br />
sourcemodelthatcorrespondwiththetwomodulesinvolvedinthatuses<br />
relationintheimplementationsourcemodel. Theresultisvisualisedin<br />
Figure6.9.Convergent,divergent,<strong>and</strong>absententitiesarerepresentedby<br />
solid,dashed,<strong>and</strong>dottedlinesrespectively.