com.github.antlrjavaparser.api
Class TypeParameter

java.lang.Object
  extended by com.github.antlrjavaparser.api.Node
      extended by com.github.antlrjavaparser.api.TypeParameter

public final class TypeParameter
extends Node

This class represents the declaration of a genetics argument.

The TypeParameter is constructed following the syntax:
TypeParameter ::= <IDENTIFIER> ( "extends" ClassOrInterfaceType ( "&" ClassOrInterfaceType )* )?

Author:
Julio Vilmar Gesser

Constructor Summary
TypeParameter()
           
TypeParameter(int beginLine, int beginColumn, int endLine, int endColumn, String name, List<ClassOrInterfaceType> typeBound)
           
TypeParameter(String name, List<ClassOrInterfaceType> typeBound)
           
 
Method Summary
<R,A> R
accept(GenericVisitor<R,A> v, A arg)
          Accept method for visitor support.
<A> void
accept(VoidVisitor<A> v, A arg)
          Accept method for visitor support.
 String getName()
          Return the name of the paramenter.
 List<ClassOrInterfaceType> getTypeBound()
          Return the list of ClassOrInterfaceType that this parameter extends.
 void setName(String name)
          Sets the name of this type parameter.
 void setTypeBound(List<ClassOrInterfaceType> typeBound)
          Sets the list o types.
 
Methods inherited from class com.github.antlrjavaparser.api.Node
equals, getBeginColumn, getBeginComments, getBeginLine, getData, getEndColumn, getEndComments, getEndLine, getInternalComments, hashCode, setBeginColumn, setBeginComments, setBeginLine, setData, setEndColumn, setEndComments, setEndLine, setInternalComments, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TypeParameter

public TypeParameter()

TypeParameter

public TypeParameter(String name,
                     List<ClassOrInterfaceType> typeBound)

TypeParameter

public TypeParameter(int beginLine,
                     int beginColumn,
                     int endLine,
                     int endColumn,
                     String name,
                     List<ClassOrInterfaceType> typeBound)
Method Detail

accept

public <R,A> R accept(GenericVisitor<R,A> v,
                      A arg)
Description copied from class: Node
Accept method for visitor support.

Specified by:
accept in class Node
Type Parameters:
R - the type the return value of the visitor
A - the type the argument passed for the visitor
Parameters:
v - the visitor implementation
arg - any value relevant for the visitor
Returns:
the result of the visit

accept

public <A> void accept(VoidVisitor<A> v,
                       A arg)
Description copied from class: Node
Accept method for visitor support.

Specified by:
accept in class Node
Type Parameters:
A - the type the argument passed for the visitor
Parameters:
v - the visitor implementation
arg - any value relevant for the visitor

getName

public String getName()
Return the name of the paramenter.

Returns:
the name of the paramenter

getTypeBound

public List<ClassOrInterfaceType> getTypeBound()
Return the list of ClassOrInterfaceType that this parameter extends. Return null null if there are no type.

Returns:
list of types that this paramente extends or null

setName

public void setName(String name)
Sets the name of this type parameter.

Parameters:
name - the name to set

setTypeBound

public void setTypeBound(List<ClassOrInterfaceType> typeBound)
Sets the list o types.

Parameters:
typeBound - the typeBound to set


Copyright © 2013. All Rights Reserved.