SDA SE Wiki

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

User Tools

Site Tools



modifierT(#id, #parent, 'modifier')

Arguments

#id: id
The unique ID assigned to this fact.

#parent: ( importT, classT, fieldT, methodT, constructorT, classInitializerT, annotationMemberT, localT, paramT )
ID form parent PEF.

modifier: atomic
one of the atoms:

  • 'public'
  • 'private'
  • 'package'
  • 'protected'
  • 'static'
  • 'strictfp'
  • 'synchronized'
  • 'transient'
  • 'native'
  • 'volatile'
  • 'abstract'
  • 'final'

Sample Java Source

final int i = 3;                       //modifier "final" for a fieldT
...
public void myFunction(double i){      //modifier "public" for a methodT     
	...
}

Its PEF Representation

fieldT(#fieldID, #parent ,...,'i',...),
modifierT(#modifierID1, #fieldID, 'final'),
...
methodT(#methodID, ..., 'myFunction', ...),
modifierT(#modifierID2, #methodID, 'public').

AST Specification

ast_node_type_spec(modifierT,[
     ast_arg(id,     mult(1,1,no ), id,   [modifierT]),
     ast_arg(parent, mult(1,1,no ), id,   [importT,classT,fieldT,methodT, constructorT, classInitializerT, annotationMemberT, localT, paramT]),
     ast_arg(modifier,mult(1,1,no ),attr, [atomic]) 
]).
research/jtransformer/api/java/pefs/4.0/modifiert.txt · Last modified: 2018/05/09 01:59 (external edit)

SEWiki, © 2019