blob: f199f99420add751fcfab357080e0a1167aef41f [file] [log] [blame]
<?xml version="1.0" encoding="UTF-8"?>
<xmi:XMI xmi:version="20131001" xmlns:xmi="http://www.omg.org/spec/XMI/20131001" xmlns:RTCppProperties="http://www.eclipse.org/papyrus/umlrt/cppproperties" xmlns:UMLRealTime="http://www.eclipse.org/papyrus/umlrt" xmlns:UMLRealTimeStateMach="http://www.eclipse.org/papyrus/umlrt/statemachine" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" xmlns:uml="http://www.eclipse.org/uml2/5.0.0/UML">
<uml:Model xmi:id="_2marEDwrEeWGsfTt0s_XkQ" name="HeartRateMonitor">
<packageImport xmi:type="uml:PackageImport" xmi:id="_2yXcYDwrEeWGsfTt0s_XkQ">
<importedPackage xmi:type="uml:Model" href="pathmap://UML_LIBRARIES/UMLPrimitiveTypes.library.uml#_0"/>
</packageImport>
<packageImport xmi:type="uml:PackageImport" xmi:id="_8MSlkD13EeWrrcZfkKNPAg">
<importedPackage xmi:type="uml:Profile" href="pathmap://PapyrusC_Cpp_PROFILES/C_Cpp.profile.uml#_j9REUByGEduN1bTiWJ0lyw"/>
</packageImport>
<packagedElement xmi:type="uml:Class" xmi:id="_-VR-wDwsEeWGsfTt0s_XkQ" name="HeartRateMonitor" classifierBehavior="_SAQk8D44EeWrrcZfkKNPAg">
<ownedAttribute xmi:type="uml:Port" xmi:id="_ZhQmYD12EeWrrcZfkKNPAg" name="HeartRatePort" type="_Mh5ZADwuEeWGsfTt0s_XkQ" isOrdered="true" aggregation="composite" isBehavior="true"/>
<ownedAttribute xmi:type="uml:Port" xmi:id="__7bQED5DEeWrrcZfkKNPAg" name="timer" visibility="protected" isOrdered="true" aggregation="composite" isBehavior="true" isService="false">
<type xmi:type="uml:Collaboration" href="platform:/plugin/org.eclipse.papyrusrt.rts/libraries/UMLRT-RTS.uml#_MxQZgGXsEeS_4daqvwyFrg"/>
</ownedAttribute>
<ownedAttribute xmi:type="uml:Property" xmi:id="_M49WID5HEeWrrcZfkKNPAg" name="timerID" visibility="protected" aggregation="composite">
<type xmi:type="uml:Class" href="platform:/plugin/org.eclipse.papyrusrt.rts/libraries/UMLRT-RTS.uml#_6qkTMGXmEeS_4daqvwyFrg"/>
</ownedAttribute>
<ownedBehavior xmi:type="uml:StateMachine" xmi:id="_SAQk8D44EeWrrcZfkKNPAg" name="HeartRateMonitor_SM" isReentrant="false">
<region xmi:type="uml:Region" xmi:id="_UYYS4D44EeWrrcZfkKNPAg" name="Region1">
<transition xmi:type="uml:Transition" xmi:id="_iFjYED45EeWrrcZfkKNPAg" name="init" source="_YZT8QD45EeWrrcZfkKNPAg" target="_d08egD45EeWrrcZfkKNPAg">
<effect xmi:type="uml:OpaqueBehavior" xmi:id="_XviM4D-hEeWyF-87NFNwWw" name="onInit">
<language>C++</language>
<body>std::cout &lt;&lt; getName() &lt;&lt; &quot; initialized&quot; &lt;&lt; std::endl;
</body>
</effect>
</transition>
<transition xmi:type="uml:Transition" xmi:id="_0uQ_oD45EeWrrcZfkKNPAg" name="onRegisterListener" source="_dTLOMD45EeWrrcZfkKNPAg" target="_d08egD45EeWrrcZfkKNPAg">
<effect xmi:type="uml:OpaqueBehavior" xmi:id="_sHT6sEAXEeWuMdCV7Og4wQ">
<language>C++</language>
<body>std::cout &lt;&lt; getName() &lt;&lt; &quot;: Listener Registered&quot; &lt;&lt; std::endl;
</body>
</effect>
<trigger xmi:type="uml:Trigger" xmi:id="_SBhvQD5DEeWrrcZfkKNPAg" name="onRegisterListener" event="_K1a2QD41EeWrrcZfkKNPAg" port="_ZhQmYD12EeWrrcZfkKNPAg"/>
</transition>
<transition xmi:type="uml:Transition" xmi:id="_1pqQ4D45EeWrrcZfkKNPAg" name="onUnregisterListener" source="_d08egD45EeWrrcZfkKNPAg" target="_dTLOMD45EeWrrcZfkKNPAg">
<effect xmi:type="uml:OpaqueBehavior" xmi:id="_2OfmEEAXEeWuMdCV7Og4wQ">
<language>C++</language>
<body>std::cout &lt;&lt; getName() &lt;&lt; &quot;: Listener Unregistered&quot; &lt;&lt; std::endl;
timer.cancelTimer(timerID);
</body>
</effect>
<trigger xmi:type="uml:Trigger" xmi:id="_aRRX4D5DEeWrrcZfkKNPAg" name="onUnregisterListener" event="_ODdfkD41EeWrrcZfkKNPAg" port="_ZhQmYD12EeWrrcZfkKNPAg"/>
</transition>
<transition xmi:type="uml:Transition" xmi:id="_4CP44D45EeWrrcZfkKNPAg" name="onTimeout" source="_d08egD45EeWrrcZfkKNPAg" target="_d08egD45EeWrrcZfkKNPAg">
<effect xmi:type="uml:OpaqueBehavior" xmi:id="_msKXgEICEeWokcdArFCMyQ" name="tout">
<language>C++</language>
<body>std::cout &lt;&lt; &quot;timeout transition taken&quot; &lt;&lt; std::endl;
timer.cancelTimer(timerID);
</body>
</effect>
<trigger xmi:type="uml:Trigger" xmi:id="_y7wfMD5EEeWrrcZfkKNPAg" name="onTimeout" port="__7bQED5DEeWrrcZfkKNPAg">
<event xmi:type="uml:CallEvent" href="platform:/plugin/org.eclipse.papyrusrt.rts/libraries/UMLRT-RTS.uml#_IaEO8HDxEeSwWKwNKw1iAA"/>
</trigger>
</transition>
<subvertex xmi:type="uml:Pseudostate" xmi:id="_YZT8QD45EeWrrcZfkKNPAg" name="Initial"/>
<subvertex xmi:type="uml:State" xmi:id="_dTLOMD45EeWrrcZfkKNPAg" name="idle"/>
<subvertex xmi:type="uml:State" xmi:id="_d08egD45EeWrrcZfkKNPAg" name="monitoring">
<entry xmi:type="uml:OpaqueBehavior" xmi:id="_5q8qID47EeWrrcZfkKNPAg" name="monitoring_EN">
<language>C++</language>
<body>std::cout &lt;&lt; getName() &lt;&lt; &quot;: Updating heartbeat&quot; &lt;&lt; std::endl;
timerID=timer.informIn(UMLRTTimespec(6,0));
if(!timerID.isValid()) { std::cout &lt;&lt; &quot;Error setting timer&quot; &lt;&lt; std::endl; } else {{ std::cout &lt;&lt; &quot;timer set&quot; &lt;&lt; std::endl; }};
</body>
</entry>
</subvertex>
</region>
</ownedBehavior>
</packagedElement>
<packagedElement xmi:type="uml:Package" xmi:id="_Me69gDwuEeWGsfTt0s_XkQ" name="HeartRateMonitorProtocol">
<packagedElement xmi:type="uml:Collaboration" xmi:id="_Mh5ZADwuEeWGsfTt0s_XkQ" name="HeartRateMonitorProtocol"/>
<packagedElement xmi:type="uml:Interface" xmi:id="_Mh6AETwuEeWGsfTt0s_XkQ" name="HeartRateMonitorProtocol"/>
<packagedElement xmi:type="uml:Realization" xmi:id="_Mh7OMDwuEeWGsfTt0s_XkQ" name="ProtocolRealizesIncomingInterface" client="_Mh5ZADwuEeWGsfTt0s_XkQ" supplier="_Mh6AETwuEeWGsfTt0s_XkQ"/>
<packagedElement xmi:type="uml:Interface" xmi:id="_Mh7OMTwuEeWGsfTt0s_XkQ" name="HeartRateMonitorProtocol~"/>
<packagedElement xmi:type="uml:Usage" xmi:id="_Mh71QTwuEeWGsfTt0s_XkQ" name="ProtocolUsesOutgoingInterface" client="_Mh5ZADwuEeWGsfTt0s_XkQ" supplier="_Mh7OMTwuEeWGsfTt0s_XkQ"/>
<packagedElement xmi:type="uml:Interface" xmi:id="_Mh8cUDwuEeWGsfTt0s_XkQ" name="HeartRateMonitorProtocolSym">
<ownedOperation xmi:type="uml:Operation" xmi:id="_K1YaAD41EeWrrcZfkKNPAg" name="registerListener"/>
<ownedOperation xmi:type="uml:Operation" xmi:id="_ODcRcD41EeWrrcZfkKNPAg" name="unregisterListener"/>
<ownedOperation xmi:type="uml:Operation" xmi:id="_dzMH0D41EeWrrcZfkKNPAg" name="updateHeartRate">
<ownedParameter xmi:type="uml:Parameter" xmi:id="_s-xAgD49EeWrrcZfkKNPAg" name="heartRate">
<type xmi:type="uml:PrimitiveType" href="pathmap://UML_LIBRARIES/UMLPrimitiveTypes.library.uml#Integer"/>
</ownedParameter>
</ownedOperation>
</packagedElement>
<packagedElement xmi:type="uml:Realization" xmi:id="_Mh9DYDwuEeWGsfTt0s_XkQ" name="ProtocolRealizesSymInterface" client="_Mh5ZADwuEeWGsfTt0s_XkQ" supplier="_Me69gDwuEeWGsfTt0s_XkQ"/>
<packagedElement xmi:type="uml:Usage" xmi:id="_Mh9DYTwuEeWGsfTt0s_XkQ" name="ProtocolUsesSymInterface" client="_Mh5ZADwuEeWGsfTt0s_XkQ" supplier="_Mh8cUDwuEeWGsfTt0s_XkQ"/>
<packagedElement xmi:type="uml:AnyReceiveEvent" xmi:id="_Mh9DYjwuEeWGsfTt0s_XkQ" name="*"/>
<packagedElement xmi:type="uml:CallEvent" xmi:id="_K1a2QD41EeWrrcZfkKNPAg" name="registerListener" operation="_K1YaAD41EeWrrcZfkKNPAg"/>
<packagedElement xmi:type="uml:CallEvent" xmi:id="_ODdfkD41EeWrrcZfkKNPAg" name="unregisterListener" operation="_ODcRcD41EeWrrcZfkKNPAg"/>
<packagedElement xmi:type="uml:CallEvent" xmi:id="_dzMu4D41EeWrrcZfkKNPAg" name="updateHeartRate_Integer" operation="_dzMH0D41EeWrrcZfkKNPAg"/>
</packagedElement>
<packagedElement xmi:type="uml:Usage" xmi:id="_kR6xMDz1EeWGsfTt0s_XkQ" client="_-VR-wDwsEeWGsfTt0s_XkQ" supplier="_Mh5ZADwuEeWGsfTt0s_XkQ"/>
<packagedElement xmi:type="uml:Class" xmi:id="_A0xT8D11EeWrrcZfkKNPAg" name="Top" isActive="true">
<ownedAttribute xmi:type="uml:Property" xmi:id="_UliTQD12EeWrrcZfkKNPAg" name="HeartRateMonitor" visibility="protected" type="_-VR-wDwsEeWGsfTt0s_XkQ"/>
</packagedElement>
<packagedElement xmi:type="uml:Class" xmi:id="_gkREMD14EeWrrcZfkKNPAg" name="GPSWatch" classifierBehavior="_BR7W8EAbEeWuMdCV7Og4wQ" isActive="true">
<ownedAttribute xmi:type="uml:Port" xmi:id="_5_jy0D14EeWrrcZfkKNPAg" name="GPSPort" type="_Mh5ZADwuEeWGsfTt0s_XkQ" aggregation="composite"/>
<ownedBehavior xmi:type="uml:StateMachine" xmi:id="_BR7W8EAbEeWuMdCV7Og4wQ" name="StateMachine1">
<region xmi:type="uml:Region" xmi:id="_Csi60EAbEeWuMdCV7Og4wQ" name="Region1">
<transition xmi:type="uml:Transition" xmi:id="_HlTZgEAbEeWuMdCV7Og4wQ" name="initialize" source="_DlnQ0EAbEeWuMdCV7Og4wQ" target="_ECVCAEAbEeWuMdCV7Og4wQ">
<effect xmi:type="uml:OpaqueBehavior" xmi:id="_U4-PAEAbEeWuMdCV7Og4wQ" name="onInit">
<language>C++</language>
<body>std::cout &lt;&lt; getName() &lt;&lt; &quot;: Initialized&quot; &lt;&lt; std::endl;</body>
</effect>
</transition>
<transition xmi:type="uml:Transition" xmi:id="_b0fA4EAhEeWuMdCV7Og4wQ" name="update" source="_ECVCAEAbEeWuMdCV7Og4wQ" target="_YTPHsEAhEeWuMdCV7Og4wQ">
<trigger xmi:type="uml:Trigger" xmi:id="_mD2-8EAhEeWuMdCV7Og4wQ" event="_dzMu4D41EeWrrcZfkKNPAg" port="_5_jy0D14EeWrrcZfkKNPAg"/>
</transition>
<transition xmi:type="uml:Transition" xmi:id="_cSDtsEAhEeWuMdCV7Og4wQ" name="reupdate" source="_YTPHsEAhEeWuMdCV7Og4wQ" target="_YTPHsEAhEeWuMdCV7Og4wQ">
<trigger xmi:type="uml:Trigger" xmi:id="_tnFf0EAhEeWuMdCV7Og4wQ" event="_dzMu4D41EeWrrcZfkKNPAg" port="_5_jy0D14EeWrrcZfkKNPAg"/>
</transition>
<subvertex xmi:type="uml:Pseudostate" xmi:id="_DlnQ0EAbEeWuMdCV7Og4wQ" name="Initial1"/>
<subvertex xmi:type="uml:State" xmi:id="_ECVCAEAbEeWuMdCV7Og4wQ" name="Initializing">
<entry xmi:type="uml:OpaqueBehavior" xmi:id="_eYLUYEAbEeWuMdCV7Og4wQ" name="onEntry">
<language>C++</language>
<body>GPSPort.registerListener().send();</body>
</entry>
</subvertex>
<subvertex xmi:type="uml:State" xmi:id="_YTPHsEAhEeWuMdCV7Og4wQ" name="Updating">
<entry xmi:type="uml:OpaqueBehavior" xmi:id="_yNKTEEAhEeWuMdCV7Og4wQ" name="onEntry">
<language>C++</language>
<body>std::cout &lt;&lt; getName() &lt;&lt; &quot;: Heart rate update&quot; &lt;&lt; std::endl;</body>
</entry>
</subvertex>
</region>
</ownedBehavior>
</packagedElement>
<packagedElement xmi:type="uml:Usage" xmi:id="_-t9mMD15EeWrrcZfkKNPAg" client="_gkREMD14EeWrrcZfkKNPAg" supplier="_Mh5ZADwuEeWGsfTt0s_XkQ"/>
<profileApplication xmi:type="uml:ProfileApplication" xmi:id="_2marETwrEeWGsfTt0s_XkQ">
<eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_2marEjwrEeWGsfTt0s_XkQ" source="http://www.eclipse.org/uml2/2.0.0/UML">
<references xmi:type="ecore:EPackage" href="http://www.eclipse.org/papyrus/umlrt#/"/>
</eAnnotations>
<appliedProfile xmi:type="uml:Profile" href="pathmap://UML_RT_PROFILE/uml-rt.profile.uml#_1h74oEeVEeO0lv5O1DTHOQ"/>
</profileApplication>
<profileApplication xmi:type="uml:ProfileApplication" xmi:id="_LnUb0EB7EeWkof8MBMoFQQ">
<eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_uT4MAJ9mEeW4K_Uu7ZGVxg" source="PapyrusVersion">
<details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_uT4MAZ9mEeW4K_Uu7ZGVxg" key="Version" value="0.0.11"/>
<details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_uT4MAp9mEeW4K_Uu7ZGVxg" key="Comment" value=""/>
<details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_uT4MA59mEeW4K_Uu7ZGVxg" key="Copyright" value=""/>
<details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_uT4MBJ9mEeW4K_Uu7ZGVxg" key="Date" value="2015-12-10"/>
<details xmi:type="ecore:EStringToStringMapEntry" xmi:id="_uT4MBZ9mEeW4K_Uu7ZGVxg" key="Author" value=""/>
</eAnnotations>
<eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_LncXoEB7EeWkof8MBMoFQQ" source="http://www.eclipse.org/uml2/2.0.0/UML">
<references xmi:type="ecore:EPackage" href="http://www.eclipse.org/papyrus/umlrt/cppproperties#/"/>
</eAnnotations>
<appliedProfile xmi:type="uml:Profile" href="pathmap://UMLRT_CPP/RTCppProperties.profile.uml#_vl5LALs8EeSTjNEQkASznQ"/>
</profileApplication>
<profileApplication xmi:type="uml:ProfileApplication" xmi:id="_skeJAEDhEeWvDaLCVFSwpw">
<eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_skn6AEDhEeWvDaLCVFSwpw" source="http://www.eclipse.org/uml2/2.0.0/UML">
<references xmi:type="ecore:EPackage" href="http://www.eclipse.org/papyrus/C_Cpp/1#/"/>
</eAnnotations>
<appliedProfile xmi:type="uml:Profile" href="pathmap://PapyrusC_Cpp_PROFILES/C_Cpp.profile.uml#_j9REUByGEduN1bTiWJ0lyw"/>
</profileApplication>
<profileApplication xmi:type="uml:ProfileApplication" xmi:id="_vDmd4EDhEeWvDaLCVFSwpw">
<eAnnotations xmi:type="ecore:EAnnotation" xmi:id="_vDoTEEDhEeWvDaLCVFSwpw" source="http://www.eclipse.org/uml2/2.0.0/UML">
<references xmi:type="ecore:EPackage" href="http://www.eclipse.org/papyrus/umlrt/statemachine#/"/>
</eAnnotations>
<appliedProfile xmi:type="uml:Profile" href="pathmap://UML_RT_PROFILE/UMLRealTimeSM-addendum.profile.uml#_KLcn0FDtEeOA4ecmvfqvaw"/>
</profileApplication>
</uml:Model>
<UMLRealTime:Capsule xmi:id="_KsGxgDwtEeWGsfTt0s_XkQ" base_Class="_-VR-wDwsEeWGsfTt0s_XkQ"/>
<UMLRealTime:ProtocolContainer xmi:id="_Me-n4DwuEeWGsfTt0s_XkQ" base_Package="_Me69gDwuEeWGsfTt0s_XkQ"/>
<UMLRealTime:Protocol xmi:id="_Mh6AEDwuEeWGsfTt0s_XkQ" base_Collaboration="_Mh5ZADwuEeWGsfTt0s_XkQ"/>
<UMLRealTime:RTMessageSet xmi:id="_Mh6nIDwuEeWGsfTt0s_XkQ" base_Interface="_Mh6AETwuEeWGsfTt0s_XkQ"/>
<UMLRealTime:RTMessageSet xmi:id="_Mh71QDwuEeWGsfTt0s_XkQ" base_Interface="_Mh7OMTwuEeWGsfTt0s_XkQ" rtMsgKind="out"/>
<UMLRealTime:RTMessageSet xmi:id="_Mh8cUTwuEeWGsfTt0s_XkQ" base_Interface="_Mh8cUDwuEeWGsfTt0s_XkQ" rtMsgKind="inOut"/>
<UMLRealTime:Capsule xmi:id="_A00-UD11EeWrrcZfkKNPAg" base_Class="_A0xT8D11EeWrrcZfkKNPAg"/>
<UMLRealTime:CapsulePart xmi:id="_UllWkD12EeWrrcZfkKNPAg" base_Property="_UliTQD12EeWrrcZfkKNPAg"/>
<UMLRealTime:RTPort xmi:id="_ZhVe4D12EeWrrcZfkKNPAg" base_Port="_ZhQmYD12EeWrrcZfkKNPAg"/>
<UMLRealTime:Capsule xmi:id="_gkSSUD14EeWrrcZfkKNPAg" base_Class="_gkREMD14EeWrrcZfkKNPAg"/>
<UMLRealTime:RTPort xmi:id="_5_mPED14EeWrrcZfkKNPAg" base_Port="_5_jy0D14EeWrrcZfkKNPAg"/>
<UMLRealTime:RTPort xmi:id="__7dFQD5DEeWrrcZfkKNPAg" isWired="false" base_Port="__7bQED5DEeWrrcZfkKNPAg"/>
<RTCppProperties:CapsuleProperties xmi:id="_e58jEEB7EeWkof8MBMoFQQ" implementationPreface="#include &lt;iostream>" base_Class="_-VR-wDwsEeWGsfTt0s_XkQ"/>
<RTCppProperties:CapsuleProperties xmi:id="_pLUFMEB7EeWkof8MBMoFQQ" implementationPreface="#include &lt;iostream>" base_Class="_gkREMD14EeWrrcZfkKNPAg"/>
<UMLRealTimeStateMach:RTState xmi:id="_tCbh0EFZEeWKlPoc4JJJ5w" base_State="_d08egD45EeWrrcZfkKNPAg"/>
<UMLRealTimeStateMach:RTState xmi:id="_uVBLEEFZEeWKlPoc4JJJ5w" base_State="_dTLOMD45EeWrrcZfkKNPAg"/>
<UMLRealTimeStateMach:RTStateMachine xmi:id="_wgVMEEFZEeWKlPoc4JJJ5w" base_StateMachine="_SAQk8D44EeWrrcZfkKNPAg"/>
<UMLRealTimeStateMach:RTStateMachine xmi:id="_5uHxUEFZEeWKlPoc4JJJ5w" base_StateMachine="_BR7W8EAbEeWuMdCV7Og4wQ"/>
<UMLRealTimeStateMach:RTState xmi:id="_9RCecEFZEeWKlPoc4JJJ5w" base_State="_ECVCAEAbEeWuMdCV7Og4wQ"/>
<UMLRealTimeStateMach:RTState xmi:id="_-UjJ4EFZEeWKlPoc4JJJ5w" base_State="_YTPHsEAhEeWuMdCV7Og4wQ"/>
<UMLRealTimeStateMach:RTRegion xmi:id="_AoHH8EFaEeWKlPoc4JJJ5w" base_Region="_Csi60EAbEeWuMdCV7Og4wQ"/>
<UMLRealTimeStateMach:RTRegion xmi:id="_Cc0m0EFaEeWKlPoc4JJJ5w" base_Region="_UYYS4D44EeWrrcZfkKNPAg"/>
</xmi:XMI>