typeParamT(#id, #parent, 'name', [#bound_1, ...])

Represents a type parameter of a class or a method.

Arguments

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

#parent: classT, methodT, constructorT
ID of the PEF which contains this type parameter

'name': atom
the name of the type parameter.

[#bound_1,…]: typeRefT, parameterizedTypeT
the list of bounds of this type parameter.

Sample Java Source

public class A <T extends Exception> {
  ...
}

Its PEF Representation

classT(#class, ..., 'A', ...)
typeParamT(#typeParam, #class, 'T', [#bound])
typeRefT(#bound, #typeParam, #class, #ref_to_exception)

AST Specification

ast_node_def('Java', typeParamT,[
     ast_arg(id,     mult(1,1,no ), id,   [typeParamT]),
     ast_arg(parent, mult(1,1,no ), id,   [classT, methodT, constructorT]),
     ast_arg(name,   mult(1,1,no ), attr, [atom]),
     ast_arg(bounds, mult(1,*,ord ),id,   [typeRefT, parameterizedTypeT])
]).
Last modified: 2014/10/02 19:47
*