[aadl-modeling]: Best way to parse an AADL model to extract property values?

Champagne, Roger roger.champagne at etsmtl.net
Fri Apr 7 18:10:05 EDT 2017


Hi all,

Not sure which is the best list to post this question, sorry for
cross-posting.

We are trying to capture properties in an AADL model, and were hoping to
extract these properties by parsing the XML instance model to transform
them to HTML tables (we are working on avionics ICDs, and our users LOVE
tables).

There is a lot of indirection in the instance model, which does not contain
the actual property values, but a path to a file and indexed elements in
that file. For instance, here is a property set:

================================================
property set ARINC429_mod is
    -- enumeration of message types to bind to ports
MessageType: list of enumeration (
ils_frequency,
ils_glide_slope_deviation,
ils_localizer_deviation,
runway_heading)
applies to (port, data);
end ARINC429_mod;
================================================

Here is the usage of some of those properties in the AADL model:

================================================
package ILS
public
with ARINC429_mod;

system ils
features
a429_in_1: in data port;
end ils;

system implementation ils.impl_basic
properties
ARINC429_mod::MessageType => (ils_frequency, unway_heading) applies to
a429_in_1;
end ils.impl_basic;
end ILS;
================================================

Here is what the instance model holds as information for the feature
instance (port):

================================================
<?xml version="1.0" encoding="ASCII"?>
<instance:SystemInstance xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:aadl2="
http://aadl.info/AADL/2.0" xmlns:instance="
http://aadl.info/AADL/2.0/instance" name="ils_impl_basic_Instance"
category="system">
  <featureInstance name="a429_in_1">
    <ownedPropertyAssociation
xsi:type="instance:PropertyAssociationInstance">
      <property
href="../packages/ARINC429_mod.aadl#ARINC429_mod.MessageType"/>
      <ownedValue>
        <ownedValue xsi:type="aadl2:ListValue">
          <ownedListElement xsi:type="aadl2:NamedValue">
            <namedValue xsi:type="aadl2:EnumerationLiteral"
href="../packages/ARINC429_mod.aadl#/0/@ownedProperty.0/@ownedPropertyType/@ownedElementType/@ownedLiteral.0"/>
================================================

The last line above is the important one. A bit far from the actual values
in the model.

There are most probably valid reasons why things are so. Our question is:
what is the best way to parse either the AADL source or the instance model
to recover the actual property values, say in an HTML report?

If anyone has advice to share, we would be garteful. A great week-end to
all!

Sincerely,

Roger

--------------------------------------------------------------
Roger Champagne, P.Eng., Ph. D.
Professeur agrégé, Département de génie logiciel et des TI
Associate Professor, Department of Software and IT Engineering

École de technologie supérieure
1100, rue Notre-Dame Ouest, Montréal, Québec, H3C 1K3, Canada
Bureau / Office : A-4499
Téléphone / Phone : +1 514 396 8825 -- Télécopieur / Fax : +1 514 396 8405
Web: http://etsmtl.ca/Professeurs/rchampagne
-------------- next part --------------
HTML attachment scrubbed and removed


More information about the aadl-modeling mailing list