Class JavaParserSymbolDeclaration

  • All Implemented Interfaces:
    com.github.javaparser.resolution.declarations.ResolvedDeclaration, com.github.javaparser.resolution.declarations.ResolvedValueDeclaration

    public class JavaParserSymbolDeclaration
    extends Object
    implements com.github.javaparser.resolution.declarations.ResolvedValueDeclaration
    This should not be used to represent fields of parameters. Eventually this should be renamed in JavaParserVariableDeclaration.
    Author:
    Federico Tomassetti
    • Method Detail

      • field

        public static JavaParserFieldDeclaration field​(com.github.javaparser.ast.body.VariableDeclarator wrappedNode,
                                                       com.github.javaparser.symbolsolver.model.resolution.TypeSolver typeSolver)
      • parameter

        public static JavaParserParameterDeclaration parameter​(com.github.javaparser.ast.body.Parameter parameter,
                                                               com.github.javaparser.symbolsolver.model.resolution.TypeSolver typeSolver)
      • localVar

        public static JavaParserSymbolDeclaration localVar​(com.github.javaparser.ast.body.VariableDeclarator variableDeclarator,
                                                           com.github.javaparser.symbolsolver.model.resolution.TypeSolver typeSolver)
      • getParamPos

        public static int getParamPos​(com.github.javaparser.ast.body.Parameter parameter)
      • getParamPos

        public static int getParamPos​(com.github.javaparser.ast.Node node)
      • getName

        public String getName()
        Specified by:
        getName in interface com.github.javaparser.resolution.declarations.ResolvedDeclaration
      • isField

        public boolean isField()
        Specified by:
        isField in interface com.github.javaparser.resolution.declarations.ResolvedDeclaration
      • isParameter

        public boolean isParameter()
        Specified by:
        isParameter in interface com.github.javaparser.resolution.declarations.ResolvedDeclaration
      • isType

        public boolean isType()
        Specified by:
        isType in interface com.github.javaparser.resolution.declarations.ResolvedDeclaration
      • getType

        public com.github.javaparser.resolution.types.ResolvedType getType()
        Specified by:
        getType in interface com.github.javaparser.resolution.declarations.ResolvedValueDeclaration
      • asType

        public com.github.javaparser.resolution.declarations.ResolvedTypeDeclaration asType()
        Specified by:
        asType in interface com.github.javaparser.resolution.declarations.ResolvedDeclaration
      • getWrappedNode

        public com.github.javaparser.ast.Node getWrappedNode()
        Returns the JavaParser node associated with this JavaParserSymbolDeclaration.
        Returns:
        A visitable JavaParser node wrapped by this object.