SDA SE Wiki

Software Engineering for Smart Data Analytics & Smart Data Analytics for Software Engineering

User Tools

Site Tools


Differences

This shows you the differences between two versions of the page.

Link to this comparison view

research:jtransformer:api:java:pefs:2.9:classinitializert [2018/05/09 01:59]
research:jtransformer:api:java:pefs:2.9:classinitializert [2018/05/09 01:59] (current)
Line 1: Line 1:
 +{{page>​prologast_bodypef_index&​fullpage&​nofooter}}
 +----
  
 +=== classInitializerT(#​id,​ #​classT,#​body) ​ ===
 +
 +Represents the initializer declaration.
 +
 +=== Arguments ===
 +== ==
 +**#id:** id\\ 
 +the unique ID assigned to this fact.
 +
 +**#class:** [[classt|classT]]\\ ​
 +ID of the parent/​declaring class.
 +
 +**#body:** [[blockt|blockT]]\\ ​
 +ID of the block.
 +
 +=== Sample Java Source ===
 +== ==
 +<Code lang-java>​
 +class MyClass ​ {   
 +       ​static { ... }
 +...                                              ​
 +}
 +</​Code>​
 +
 +
 +=== Its PEF Representation ===
 +==  ==
 +<Code lang-prolog>​
 +class(#​class,​ #​compilationUnit,​ '​MyClass',​ [..., #init]).
 +classInitializerT(#​init,​ #class, #body).
 +modifierT(#​init,​ static).
 +</​Code>​
 +
 +=== AST Specification ===
 +== ==
 +<​Code>​
 +ast_node_def('​Java',​classInitializerT,​[
 +    ast_arg(id, ​     mult(1,1,no ), id,  [classInitializerT]),​
 +    ast_arg(parent, ​ mult(1,1,no ), id,  [classT]), ​
 +    ast_arg(body, ​   mult(0,​1,​no), ​ id,  [blockT])
 +]).
 +</​Code>​
research/jtransformer/api/java/pefs/2.9/classinitializert.txt · Last modified: 2018/05/09 01:59 (external edit)

SEWiki, © 2019