Statistics
| Branch: | Revision:

urtware / doc / activitydiagrams / service / urtServiceInit.svg @ ee83a495

History | View | Annotate | Download (26.104 KB)

1
<?xml version="1.0" encoding="UTF-8" standalone="no"?><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" contentScriptType="application/ecmascript" contentStyleType="text/css" height="977px" preserveAspectRatio="none" style="width:1146px;height:977px;" version="1.1" viewBox="0 0 1146 977" width="1146px" zoomAndPan="magnify"><defs><filter height="300%" id="f1snfj7r7itc1b" width="300%" x="-1" y="-1"><feGaussianBlur result="blurOut" stdDeviation="2.0"/><feColorMatrix in="blurOut" result="blurOut2" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .4 0"/><feOffset dx="4.0" dy="4.0" in="blurOut2" result="blurOut3"/><feBlend in="SourceGraphic" in2="blurOut3" mode="normal"/></filter></defs><g><text fill="#000000" font-family="sans-serif" font-size="18" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="89" x="527.5" y="26.708">µRtWare</text><text fill="#000000" font-family="sans-serif" font-size="18" lengthAdjust="spacingAndGlyphs" textLength="135" x="504.5" y="47.6611">urtServiceInit()</text><text fill="#000000" font-family="sans-serif" font-size="18" lengthAdjust="spacingAndGlyphs" textLength="0" x="575" y="68.6143"/><path d="M355,72.8594 L355,259.3203 L920,259.3203 L920,82.8594 L910,72.8594 L355,72.8594 " fill="#FBFB77" filter="url(#f1snfj7r7itc1b)" style="stroke: #A80036; stroke-width: 1.0;"/><path d="M910,72.8594 L910,82.8594 L920,82.8594 L910,72.8594 " fill="#FBFB77" style="stroke: #A80036; stroke-width: 1.0;"/><line style="stroke: #A80036; stroke-width: 1.0;" x1="355" x2="557" y1="85.4258" y2="85.4258"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="0" x="561" y="89.4263"/><text fill="#000000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="52" x="561" y="89.4263">service</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="97" x="617" y="89.4263">: urt_service_t*</text><line style="stroke: #A80036; stroke-width: 1.0;" x1="718" x2="920" y1="85.4258" y2="85.4258"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="148" x="361" y="105.0591">The service to initialize.</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="76" x="361" y="120.1919">Must not be</text><text fill="#000000" font-family="monospace" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="32" x="441" y="120.1919">NULL</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="4" x="473" y="120.1919">.</text><line style="stroke: #A80036; stroke-width: 1.0;" x1="355" x2="574" y1="130.8242" y2="130.8242"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="0" x="578" y="134.8247"/><text fill="#000000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="14" x="578" y="134.8247">id</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="101" x="596" y="134.8247">: urt_serviceid_t</text><line style="stroke: #A80036; stroke-width: 1.0;" x1="701" x2="920" y1="130.8242" y2="130.8242"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="258" x="361" y="150.4575">Unique, numeric identifier of the service.</text><line style="stroke: #A80036; stroke-width: 1.0;" x1="355" x2="539" y1="161.0898" y2="161.0898"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="0" x="543" y="165.0903"/><text fill="#000000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="61" x="543" y="165.0903">callback</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="124" x="608" y="165.0903">: urt_servicefunc_t*</text><line style="stroke: #A80036; stroke-width: 1.0;" x1="736" x2="920" y1="161.0898" y2="161.0898"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="307" x="361" y="180.7231">Callabck function to be executed by this service.</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="76" x="361" y="195.856">Must not be</text><text fill="#000000" font-family="monospace" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="32" x="441" y="195.856">NULL</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="4" x="473" y="195.856">.</text><line style="stroke: #A80036; stroke-width: 1.0;" x1="355" x2="920" y1="203.9219" y2="203.9219"/><line style="stroke: #A80036; stroke-width: 1.0;" x1="355" x2="920" y1="205.9219" y2="205.9219"/><line style="stroke: #A80036; stroke-width: 1.0;" x1="355" x2="566.5" y1="216.4883" y2="216.4883"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="0" x="570.5" y="220.4888"/><text fill="#000000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="45" x="570.5" y="220.4888">return</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="85" x="619.5" y="220.4888">: urt_status_t</text><line style="stroke: #A80036; stroke-width: 1.0;" x1="708.5" x2="920" y1="216.4883" y2="216.4883"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="49" x="361" y="236.1216">Returns</text><text fill="#000000" font-family="monospace" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="104" x="414" y="236.1216">URT_STATUS_OK</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="75" x="522" y="236.1216">on success.</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="49" x="361" y="251.2544">Returns</text><text fill="#000000" font-family="monospace" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="128" x="414" y="251.2544">URT_STATUS_ERROR</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="359" x="546" y="251.2544">if another service with the same identifier already exists.</text><ellipse cx="637.5" cy="289.3203" fill="#000000" filter="url(#f1snfj7r7itc1b)" rx="10" ry="10" style="stroke: none; stroke-width: 1.0;"/><path d="M10,309.3203 L10,485.7813 A0,0 0 0 0 10,485.7813 L552,485.7813 A0,0 0 0 0 552,485.7813 L552,401.5508 L572,397.5508 L552,393.5508 L552,319.3203 L542,309.3203 L10,309.3203 A0,0 0 0 0 10,309.3203 " fill="#FBFB77" filter="url(#f1snfj7r7itc1b)" style="stroke: #A80036; stroke-width: 1.0;"/><path d="M542,309.3203 L542,319.3203 L552,319.3203 L542,309.3203 " fill="#FBFB77" style="stroke: #A80036; stroke-width: 1.0;"/><text fill="#000000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="32" x="16" y="326.3872">next</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="11" x="52" y="326.3872">←</text><text fill="#000000" font-family="monospace" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="32" x="67" y="326.3872">NULL</text><text fill="#000000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="14" x="16" y="341.52">id</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="26" x="34" y="341.52">← id</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="81" x="16" y="356.6528">urtMutexInit(</text><text fill="#000000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="30" x="97" y="356.6528">lock</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="5" x="127" y="356.6528">)</text><text fill="#000000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="61" x="16" y="371.7856">callback</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="66" x="81" y="371.7856">← callback</text><line style="stroke: #A80036; stroke-width: 1.0; stroke-dasharray: 1.0,2.0;" x1="10" x2="20.5" y1="382.418" y2="382.418"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="513" x="24.5" y="386.4185">URT_CFG_RPC_QOS_JITTERCHECKS == true || URT_CFG_RPC_PROFILING == true</text><line style="stroke: #A80036; stroke-width: 1.0; stroke-dasharray: 1.0,2.0;" x1="541.5" x2="552" y1="382.418" y2="382.418"/><text fill="#000000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="90" x="16" y="402.0513">minDuration</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="52" x="110" y="402.0513">← 0xF..F</text><text fill="#000000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="94" x="16" y="417.1841">maxDuration</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="23" x="114" y="417.1841">← 0</text><line style="stroke: #A80036; stroke-width: 1.0; stroke-dasharray: 1.0,2.0;" x1="10" x2="167.5" y1="427.8164" y2="427.8164"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="219" x="171.5" y="431.8169">URT_CFG_RPC_PROFILING == true</text><line style="stroke: #A80036; stroke-width: 1.0; stroke-dasharray: 1.0,2.0;" x1="394.5" x2="552" y1="427.8164" y2="427.8164"/><text fill="#000000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="102" x="16" y="447.4497">sumDurations</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="23" x="122" y="447.4497">← 0</text><text fill="#000000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="67" x="16" y="462.5825">numCalls</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="23" x="87" y="462.5825">← 0</text><text fill="#000000" font-family="sans-serif" font-size="13" font-weight="bold" lengthAdjust="spacingAndGlyphs" textLength="99" x="16" y="477.7153">numTimeouts</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="23" x="119" y="477.7153">← 0</text><rect fill="#FEFECE" filter="url(#f1snfj7r7itc1b)" height="33.9688" rx="12.5" ry="12.5" style="stroke: #A80036; stroke-width: 1.5;" width="131" x="572" y="380.5664"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacingAndGlyphs" textLength="111" x="582" y="401.7051">initialize members</text><rect fill="#FEFECE" filter="url(#f1snfj7r7itc1b)" height="33.9688" rx="12.5" ry="12.5" style="stroke: #A80036; stroke-width: 1.5;" width="77" x="599" y="505.7813"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacingAndGlyphs" textLength="57" x="609" y="526.9199">lock core</text><rect fill="#FEFECE" filter="url(#f1snfj7r7itc1b)" height="33.9688" rx="12.5" ry="12.5" style="stroke: #A80036; stroke-width: 1.5;" width="140" x="567.5" y="559.75"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacingAndGlyphs" textLength="120" x="577.5" y="580.8887">access first service</text><rect fill="#FEFECE" filter="url(#f1snfj7r7itc1b)" height="33.9688" rx="12.5" ry="12.5" style="stroke: #A80036; stroke-width: 1.5;" width="168" x="553.5" y="671.0386"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacingAndGlyphs" textLength="148" x="563.5" y="692.1772">proceed to next service</text><polygon fill="#FEFECE" filter="url(#f1snfj7r7itc1b)" points="569.5,613.7188,705.5,613.7188,717.5,626.5234,705.5,639.3281,569.5,639.3281,557.5,626.5234,569.5,613.7188" style="stroke: #A80036; stroke-width: 1.5;"/><text fill="#000000" font-family="sans-serif" font-size="11" lengthAdjust="spacingAndGlyphs" textLength="20" x="641.5" y="649.5386">yes</text><text fill="#000000" font-family="sans-serif" font-size="11" lengthAdjust="spacingAndGlyphs" textLength="78" x="569.5" y="623.9292">Service is not</text><text fill="#000000" font-family="monospace" font-size="11" lengthAdjust="spacingAndGlyphs" textLength="28" x="651.5" y="623.9292">NULL</text><text fill="#000000" font-family="sans-serif" font-size="11" lengthAdjust="spacingAndGlyphs" textLength="136" x="569.5" y="636.7339">and service ID is lower?</text><text fill="#000000" font-family="sans-serif" font-size="11" lengthAdjust="spacingAndGlyphs" textLength="14" x="543.5" y="623.9292">no</text><polygon fill="#FEFECE" filter="url(#f1snfj7r7itc1b)" points="283,747.0073,423,747.0073,435,759.0073,423,771.0073,283,771.0073,271,759.0073,283,747.0073" style="stroke: #A80036; stroke-width: 1.5;"/><text fill="#000000" font-family="sans-serif" font-size="11" lengthAdjust="spacingAndGlyphs" textLength="20" x="357" y="781.2178">yes</text><text fill="#000000" font-family="sans-serif" font-size="11" lengthAdjust="spacingAndGlyphs" textLength="102" x="283" y="762.8154">Current service is</text><text fill="#000000" font-family="monospace" font-size="11" lengthAdjust="spacingAndGlyphs" textLength="28" x="389" y="762.8154">NULL</text><text fill="#000000" font-family="sans-serif" font-size="11" lengthAdjust="spacingAndGlyphs" textLength="6" x="417" y="762.8154">?</text><rect fill="#FEFECE" filter="url(#f1snfj7r7itc1b)" height="33.9688" rx="12.5" ry="12.5" style="stroke: #A80036; stroke-width: 1.5;" width="246" x="230" y="802.7178"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacingAndGlyphs" textLength="226" x="240" y="823.8564">append self to core's list of services</text><rect fill="#FEFECE" filter="url(#f1snfj7r7itc1b)" height="33.9688" rx="12.5" ry="12.5" style="stroke: #A80036; stroke-width: 1.5;" width="93" x="306.5" y="871.6865"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacingAndGlyphs" textLength="73" x="316.5" y="892.8252">unlock core</text><path d="M140,940.6553 L140,965.7881 A0,0 0 0 0 140,965.7881 L322,965.7881 A0,0 0 0 0 322,965.7881 L322,958.6553 L342,953.2217 L322,950.6553 L322,950.6553 L312,940.6553 L140,940.6553 A0,0 0 0 0 140,940.6553 " fill="#FBFB77" filter="url(#f1snfj7r7itc1b)" style="stroke: #A80036; stroke-width: 1.0;"/><path d="M312,940.6553 L312,950.6553 L322,950.6553 L312,940.6553 " fill="#FBFB77" style="stroke: #A80036; stroke-width: 1.0;"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="49" x="146" y="957.7222">Returns</text><text fill="#000000" font-family="monospace" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="104" x="199" y="957.7222">URT_STATUS_OK</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="4" x="303" y="957.7222">:</text><ellipse cx="353" cy="953.2217" fill="#FFFFFF" filter="url(#f1snfj7r7itc1b)" rx="11" ry="11" style="stroke: #000000; stroke-width: 1.0;"/><ellipse cx="353" cy="953.2217" fill="#000000" rx="6" ry="6" style="stroke: #7F7F7F; stroke-width: 1.0;"/><polygon fill="#FEFECE" filter="url(#f1snfj7r7itc1b)" points="624.5,747.0073,793.5,747.0073,805.5,759.0073,793.5,771.0073,624.5,771.0073,612.5,759.0073,624.5,747.0073" style="stroke: #A80036; stroke-width: 1.5;"/><text fill="#000000" font-family="sans-serif" font-size="11" lengthAdjust="spacingAndGlyphs" textLength="20" x="713" y="781.2178">yes</text><text fill="#000000" font-family="sans-serif" font-size="11" lengthAdjust="spacingAndGlyphs" textLength="169" x="624.5" y="762.8154">Current service ID is greater?</text><text fill="#000000" font-family="sans-serif" font-size="11" lengthAdjust="spacingAndGlyphs" textLength="14" x="805.5" y="756.4131">no</text><rect fill="#FEFECE" filter="url(#f1snfj7r7itc1b)" height="33.9688" rx="12.5" ry="12.5" style="stroke: #A80036; stroke-width: 1.5;" width="245" x="586.5" y="802.7178"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacingAndGlyphs" textLength="225" x="596.5" y="823.8564">insert self in front of current service</text><rect fill="#FEFECE" filter="url(#f1snfj7r7itc1b)" height="33.9688" rx="12.5" ry="12.5" style="stroke: #A80036; stroke-width: 1.5;" width="93" x="662.5" y="871.6865"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacingAndGlyphs" textLength="73" x="672.5" y="892.8252">unlock core</text><path d="M496,940.6553 L496,965.7881 A0,0 0 0 0 496,965.7881 L678,965.7881 A0,0 0 0 0 678,965.7881 L678,958.6553 L698,953.2217 L678,950.6553 L678,950.6553 L668,940.6553 L496,940.6553 A0,0 0 0 0 496,940.6553 " fill="#FBFB77" filter="url(#f1snfj7r7itc1b)" style="stroke: #A80036; stroke-width: 1.0;"/><path d="M668,940.6553 L668,950.6553 L678,950.6553 L668,940.6553 " fill="#FBFB77" style="stroke: #A80036; stroke-width: 1.0;"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="49" x="502" y="957.7222">Returns</text><text fill="#000000" font-family="monospace" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="104" x="555" y="957.7222">URT_STATUS_OK</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="4" x="659" y="957.7222">:</text><ellipse cx="709" cy="953.2217" fill="#FFFFFF" filter="url(#f1snfj7r7itc1b)" rx="11" ry="11" style="stroke: #000000; stroke-width: 1.0;"/><ellipse cx="709" cy="953.2217" fill="#000000" rx="6" ry="6" style="stroke: #7F7F7F; stroke-width: 1.0;"/><rect fill="#FEFECE" filter="url(#f1snfj7r7itc1b)" height="33.9688" rx="12.5" ry="12.5" style="stroke: #A80036; stroke-width: 1.5;" width="93" x="1042" y="833.7998"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacingAndGlyphs" textLength="73" x="1052" y="854.9385">unlock core</text><path d="M851.5,902.7686 L851.5,927.9014 A0,0 0 0 0 851.5,927.9014 L1057.5,927.9014 A0,0 0 0 0 1057.5,927.9014 L1057.5,920.7686 L1077.5,915.335 L1057.5,912.7686 L1057.5,912.7686 L1047.5,902.7686 L851.5,902.7686 A0,0 0 0 0 851.5,902.7686 " fill="#FBFB77" filter="url(#f1snfj7r7itc1b)" style="stroke: #A80036; stroke-width: 1.0;"/><path d="M1047.5,902.7686 L1047.5,912.7686 L1057.5,912.7686 L1047.5,902.7686 " fill="#FBFB77" style="stroke: #A80036; stroke-width: 1.0;"/><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="49" x="857.5" y="919.8354">Returns</text><text fill="#000000" font-family="monospace" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="128" x="910.5" y="919.8354">URT_STATUS_ERROR</text><text fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacingAndGlyphs" textLength="4" x="1038.5" y="919.8354">:</text><ellipse cx="1088.5" cy="915.335" fill="#FFFFFF" filter="url(#f1snfj7r7itc1b)" rx="11" ry="11" style="stroke: #000000; stroke-width: 1.0;"/><ellipse cx="1088.5" cy="915.335" fill="#000000" rx="6" ry="6" style="stroke: #7F7F7F; stroke-width: 1.0;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="637.5" x2="637.5" y1="259.3203" y2="279.3203"/><polygon fill="#A80036" points="633.5,269.3203,637.5,279.3203,641.5,269.3203,637.5,273.3203" style="stroke: #A80036; stroke-width: 1.0;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="637.5" x2="637.5" y1="299.3203" y2="380.5664"/><polygon fill="#A80036" points="633.5,370.5664,637.5,380.5664,641.5,370.5664,637.5,374.5664" style="stroke: #A80036; stroke-width: 1.0;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="637.5" x2="637.5" y1="414.5352" y2="505.7813"/><polygon fill="#A80036" points="633.5,495.7813,637.5,505.7813,641.5,495.7813,637.5,499.7813" style="stroke: #A80036; stroke-width: 1.0;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="637.5" x2="637.5" y1="539.75" y2="559.75"/><polygon fill="#A80036" points="633.5,549.75,637.5,559.75,641.5,549.75,637.5,553.75" style="stroke: #A80036; stroke-width: 1.0;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="637.5" x2="637.5" y1="639.3281" y2="671.0386"/><polygon fill="#A80036" points="633.5,661.0386,637.5,671.0386,641.5,661.0386,637.5,665.0386" style="stroke: #A80036; stroke-width: 1.0;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="637.5" x2="637.5" y1="705.0073" y2="715.0073"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="637.5" x2="733.5" y1="715.0073" y2="715.0073"/><polygon fill="#A80036" points="729.5,679.2183,733.5,669.2183,737.5,679.2183,733.5,675.2183" style="stroke: #A80036; stroke-width: 1.5;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="733.5" x2="733.5" y1="626.5234" y2="715.0073"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="733.5" x2="717.5" y1="626.5234" y2="626.5234"/><polygon fill="#A80036" points="727.5,622.5234,717.5,626.5234,727.5,630.5234,723.5,626.5234" style="stroke: #A80036; stroke-width: 1.0;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="557.5" x2="541.5" y1="626.5234" y2="626.5234"/><polygon fill="#A80036" points="537.5,665.2183,541.5,675.2183,545.5,665.2183,541.5,669.2183" style="stroke: #A80036; stroke-width: 1.5;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="541.5" x2="541.5" y1="626.5234" y2="727.0073"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="541.5" x2="637.5" y1="727.0073" y2="727.0073"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="637.5" x2="637.5" y1="727.0073" y2="732.0073"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="637.5" x2="637.5" y1="593.7188" y2="613.7188"/><polygon fill="#A80036" points="633.5,603.7188,637.5,613.7188,641.5,603.7188,637.5,607.7188" style="stroke: #A80036; stroke-width: 1.0;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="353" x2="353" y1="836.6865" y2="871.6865"/><polygon fill="#A80036" points="349,861.6865,353,871.6865,357,861.6865,353,865.6865" style="stroke: #A80036; stroke-width: 1.0;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="353" x2="353" y1="905.6553" y2="942.2217"/><polygon fill="#A80036" points="349,932.2217,353,942.2217,357,932.2217,353,936.2217" style="stroke: #A80036; stroke-width: 1.0;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="709" x2="709" y1="836.6865" y2="871.6865"/><polygon fill="#A80036" points="705,861.6865,709,871.6865,713,861.6865,709,865.6865" style="stroke: #A80036; stroke-width: 1.0;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="709" x2="709" y1="905.6553" y2="942.2217"/><polygon fill="#A80036" points="705,932.2217,709,942.2217,713,932.2217,709,936.2217" style="stroke: #A80036; stroke-width: 1.0;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="1088.5" x2="1088.5" y1="867.7686" y2="904.335"/><polygon fill="#A80036" points="1084.5,894.335,1088.5,904.335,1092.5,894.335,1088.5,898.335" style="stroke: #A80036; stroke-width: 1.0;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="353" x2="353" y1="771.0073" y2="802.7178"/><polygon fill="#A80036" points="349,792.7178,353,802.7178,357,792.7178,353,796.7178" style="stroke: #A80036; stroke-width: 1.0;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="709" x2="709" y1="771.0073" y2="802.7178"/><polygon fill="#A80036" points="705,792.7178,709,802.7178,713,792.7178,709,796.7178" style="stroke: #A80036; stroke-width: 1.0;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="435" x2="612.5" y1="759.0073" y2="759.0073"/><polygon fill="#A80036" points="602.5,755.0073,612.5,759.0073,602.5,763.0073,606.5,759.0073" style="stroke: #A80036; stroke-width: 1.0;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="637.5" x2="353" y1="732.0073" y2="732.0073"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="353" x2="353" y1="732.0073" y2="747.0073"/><polygon fill="#A80036" points="349,737.0073,353,747.0073,357,737.0073,353,741.0073" style="stroke: #A80036; stroke-width: 1.0;"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="805.5" x2="1088.5" y1="759.0073" y2="759.0073"/><line style="stroke: #A80036; stroke-width: 1.5;" x1="1088.5" x2="1088.5" y1="759.0073" y2="833.7998"/><polygon fill="#A80036" points="1084.5,823.7998,1088.5,833.7998,1092.5,823.7998,1088.5,827.7998" style="stroke: #A80036; stroke-width: 1.0;"/><!--MD5=[e97c440ea6d6ffb95ba2bae466cee68a]
2
@startuml
3

    
4
title **µRtWare**\nurtServiceInit()\n
5

    
6

    
7
note
8
  - - **service** : urt_service_t* - -
9
  The service to initialize.
10
  Must not be ""NULL"".
11
  - - **id** : urt_serviceid_t - -
12
  Unique, numeric identifier of the service.
13
  - - **callback** : urt_servicefunc_t* - -
14
  Callabck function to be executed by this service.
15
  Must not be ""NULL"".
16
  ====
17
  - - **return** : urt_status_t - -
18
  Returns ""URT_STATUS_OK"" on success.
19
  Returns ""URT_STATUS_ERROR"" if another service with the same identifier already exists.
20
endnote
21

    
22

    
23
start
24
:initialize members;
25
note
26
  **next** ← ""NULL""
27
  **id** ← id
28
  urtMutexInit(**lock**)
29
  **callback** ← callback
30
  .. URT_CFG_RPC_QOS_JITTERCHECKS == true || URT_CFG_RPC_PROFILING == true ..
31
  **minDuration** ← 0xF..F
32
  **maxDuration** ← 0
33
  .. URT_CFG_RPC_PROFILING == true ..
34
  **sumDurations** ← 0
35
  **numCalls** ← 0
36
  **numTimeouts** ← 0
37
endnote
38
:lock core;
39
:access first service;
40
while (Service is not ""NULL""\nand service ID is lower?) is (yes)
41
  :proceed to next service;
42
endwhile (no)
43
if (Current service is ""NULL""?) then (yes)
44
  :append self to core's list of services;
45
  :unlock core;
46
  stop
47
  note
48
    Returns ""URT_STATUS_OK"":
49
  endnote
50
elseif (Current service ID is greater?) then (yes)
51
  :insert self in front of current service;
52
  :unlock core;
53
  stop
54
  note
55
    Returns ""URT_STATUS_OK"":
56
  endnote
57
else (no)
58
  :unlock core;
59
  stop
60
  note
61
    Returns ""URT_STATUS_ERROR"":
62
  endnote
63
endif
64

    
65

    
66
@enduml
67

    
68
PlantUML version 1.2020.00(Sat Jan 11 13:30:53 CET 2020)
69
(GPL source distribution)
70
Java Runtime: OpenJDK Runtime Environment
71
JVM: OpenJDK 64-Bit Server VM
72
Java Version: 11.0.6+10-post-Ubuntu-1ubuntu118.04.1
73
Operating System: Linux
74
Default Encoding: UTF-8
75
Language: en
76
Country: US
77
--></g></svg>