| 1 | |
| 2 | '''getProperty/10''' |
| 3 | |
| 4 | * !ParentPackage : in string |
| 5 | * !ParentType : in string |
| 6 | * !ParentImpl : in string |
| 7 | * Name : in string |
| 8 | * Package : in string |
| 9 | * Type : in string |
| 10 | * Impl : in string |
| 11 | * !InstId : in string |
| 12 | * Property : in string |
| 13 | * Value : out string |
| 14 | |
| 15 | '''notes:''' |
| 16 | |
| 17 | - refer to SAE-AS5506B - 11.3 - page 267 - figure 21: |
| 18 | [[Image(AADLPropertyValue.JPG)]] |
| 19 | - missing search of the default value in the property definition |
| 20 | |
| 21 | '''implementation:''' |
| 22 | |
| 23 | ( Package \= 'NIL' -> [[BR]] |
| 24 | !ActualPackage = Package;[[BR]] |
| 25 | !ActualPackage = !ParentPackage ),[[BR]] |
| 26 | |
| 27 | /* remove first element in id (root) */[[BR]] |
| 28 | |
| 29 | cutId(!InstId,X), getRoot(P,T,I), ([[BR]] |
| 30 | |
| 31 | /* step 1 */[[BR]] |
| 32 | |
| 33 | instanceProperty(P,T,I,Name,X,Property,Value); [[BR]] |
| 34 | |
| 35 | /* steps 2 or 3 */[[BR]] |
| 36 | |
| 37 | implementationProperty(!ActualPackage,Type,Impl,Property,Value); [[BR]] |
| 38 | |
| 39 | /* steps 4 or 5 */[[BR]] |
| 40 | |
| 41 | typeProperty(!ActualPackage,Type,Property,Value);[[BR]] |
| 42 | |
| 43 | /* step 6 */[[BR]] |
| 44 | |
| 45 | allowsInheritance(Property), [[BR]] |
| 46 | ( splitName(X,_,Y), Y \= !'', inheritedProperty(P,T,I,Name,Y,Property,Value) );[[BR]] |
| 47 | Value=!'' )[[BR]] |