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:4.2:omit_parameterboundt [2018/05/09 01:59] (current)
Line 1: Line 1:
 +{{page>​prologast_bodypef_index&​fullpage&​nofooter}}
 +----
  
 +=== omit_parameterBoundT(#​id,​ #element) ===
 +This fact is used for preserving the original appearance of the source code after transformations. It declares, that no explicit bound for a type parameter or a wildcard in a parameterized type is given (therefore extends Object is used as an implicit bound).
 +
 +
 +<Code lang-java>​class A<T> {
 +...
 +List<?>​ l;
 +</​Code>​
 +
 +instead of 
 +
 +<Code lang-java>​class A<T extends Object> {
 +...
 +List<? extends Object> l;
 +</​Code>​
 +
 +== History ==
 +  * JTransformer 3.0: Added as noParameterBoundT
 +  * JTransformer 4.0: Renamed to preserve_noParameterBoundT
 +  * JTransformer 4.1: Renamed to omit_parameterBoundT
 +
 +=== Arguments ===
 +== ==
 +**#id:** id\\ 
 +ID of the [[typeparamt|typeParamT]] element or the parent of the [[parameterizedtypet|parameterizedTypeT]].
 +
 +**#​element:​** [[wildcardt|wildcardT]],​ null\\ ​
 +In case of a [[parameterizedtypet|parameterizedTypeT]] this is the ID of the corresponding [[wildcardt|wildcardT]],​ otherwise (in case of a [[typeparamt|typeParamT]]) it's null
 +
 +=== Sample Java Source ===
 +
 +==  ==
 +<Code lang-java>​class A<T> {
 +...
 +}
 +</​Code>​
 +
 +
 +=== Its PEF Representation ===
 +
 +==  ==
 +<Code lang-prolog>​
 +classT(Class,​ _, '​A',​ [TypeParam],​ _),
 +typeParamT(TypeParam,​ Class, '​T',​ [RefToObject]),​
 +omit_parameterBoundT(TypeParam,​ null).
 +</​Code>​
 +
 +=== AST Specification ===
 +== ==
 +<Code lang-prolog>​
 +ast_relation_type_spec( omit_parameterBoundT,​[
 +   ​ast_arg(id, ​     mult(1,1,no ), id,    [id]),
 +   ​ast_arg(element,​ mult(1,1,no ), id,    [wildcardT, nullType])
 +]).
 +</​Code>​
research/jtransformer/api/java/pefs/4.2/omit_parameterboundt.txt · Last modified: 2018/05/09 01:59 (external edit)

SEWiki, © 2019