13.08.2013 Views

institut f¨ur informatik - PST Thesis Management Interface - LMU

institut f¨ur informatik - PST Thesis Management Interface - LMU

institut f¨ur informatik - PST Thesis Management Interface - LMU

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

3.2. Artop<br />

Figure 3.8.: Version-specific generation of AUTOSAR API code from the respective AU-<br />

TOSAR metamodels.<br />

This situation requires the tool developer to implement the same tool functionality separately<br />

for each AUTOSAR version. Consider an example where Artop should offer a function on a<br />

QueuedReceiverComSpec model element 2 from figure 3.7 that requires reading the value of<br />

its Queue Length property. The code will look like illustrated in listing 3.1:<br />

( element autosar21 . swcomponent . communication .<br />

QueuedReceiverComSpec ) {<br />

queuedReceiver_21 = ( autosar21 . swcomponent . communication .<br />

QueuedReceiverComSpec ) element ;<br />

qrValue = queuedReceiver_21 . getQueueLength ();<br />

...<br />

} ( element autosar3x . swcomponent .<br />

communication . QueuedReceiverComSpec ) {<br />

queuedReceiver_3x = ( autosar3x . swcomponent . communication .<br />

QueuedReceiverComSpec ) element ;<br />

qrValue = queuedReceiver_3x . getQueueLength ();<br />

...<br />

} ( element autosar40 . swcomponent .<br />

communication . QueuedReceiverComSpec ) {<br />

2 The semantics of this element is irrelevant here, but can be found in the appropriate AUTOSAR template.<br />

33

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!