Uses of Class
com.github.javaparser.ast.type.Type
Packages that use Type
Package
Description
-
Uses of Type in com.github.javaparser
Fields in com.github.javaparser with type parameters of type TypeMethods in com.github.javaparser that return TypeModifier and TypeMethodDescriptionstatic TypeParses a Java type name and returns aTypethat represents it.Methods in com.github.javaparser that return types with arguments of type Type -
Uses of Type in com.github.javaparser.ast.body
Methods in com.github.javaparser.ast.body that return TypeModifier and TypeMethodDescriptionAnnotationMemberDeclaration.getType()MethodDeclaration.getType()Parameter.getType()ReceiverParameter.getType()VariableDeclarator.getType()Methods in com.github.javaparser.ast.body that return types with arguments of type TypeMethods in com.github.javaparser.ast.body with parameters of type TypeModifier and TypeMethodDescriptionAnnotationDeclaration.addField(Type type, String name, Modifier.Keyword... modifiers)Constructors in com.github.javaparser.ast.body with parameters of type TypeModifierConstructorDescriptionAnnotationMemberDeclaration(NodeList<Modifier> modifiers, NodeList<AnnotationExpr> annotations, Type type, SimpleName name, Expression defaultValue)AnnotationMemberDeclaration(NodeList<Modifier> modifiers, Type type, String name, Expression defaultValue)AnnotationMemberDeclaration(TokenRange tokenRange, NodeList<Modifier> modifiers, NodeList<AnnotationExpr> annotations, Type type, SimpleName name, Expression defaultValue)This constructor is used by the parser and is considered private.FieldDeclaration(NodeList<Modifier> modifiers, Type type, String name)Creates aFieldDeclaration.MethodDeclaration(NodeList<Modifier> modifiers, NodeList<AnnotationExpr> annotations, NodeList<TypeParameter> typeParameters, Type type, SimpleName name, NodeList<Parameter> parameters, NodeList<ReferenceType> thrownExceptions, BlockStmt body)MethodDeclaration(NodeList<Modifier> modifiers, NodeList<AnnotationExpr> annotations, NodeList<TypeParameter> typeParameters, Type type, SimpleName name, NodeList<Parameter> parameters, NodeList<ReferenceType> thrownExceptions, BlockStmt body, ReceiverParameter receiverParameter)MethodDeclaration(NodeList<Modifier> modifiers, Type type, String name)MethodDeclaration(NodeList<Modifier> modifiers, String name, Type type, NodeList<Parameter> parameters)MethodDeclaration(TokenRange tokenRange, NodeList<Modifier> modifiers, NodeList<AnnotationExpr> annotations, NodeList<TypeParameter> typeParameters, Type type, SimpleName name, NodeList<Parameter> parameters, NodeList<ReferenceType> thrownExceptions, BlockStmt body, ReceiverParameter receiverParameter)This constructor is used by the parser and is considered private.Parameter(NodeList<Modifier> modifiers, NodeList<AnnotationExpr> annotations, Type type, boolean isVarArgs, NodeList<AnnotationExpr> varArgsAnnotations, SimpleName name)Parameter(NodeList<Modifier> modifiers, Type type, SimpleName name)Parameter(Type type, SimpleName name)Creates a newParameter.Parameter(TokenRange tokenRange, NodeList<Modifier> modifiers, NodeList<AnnotationExpr> annotations, Type type, boolean isVarArgs, NodeList<AnnotationExpr> varArgsAnnotations, SimpleName name)This constructor is used by the parser and is considered private.ReceiverParameter(NodeList<AnnotationExpr> annotations, Type type, Name name)ReceiverParameter(Type type, Name name)ReceiverParameter(Type type, String name)Creates a newReceiverParameter.ReceiverParameter(TokenRange tokenRange, NodeList<AnnotationExpr> annotations, Type type, Name name)This constructor is used by the parser and is considered private.VariableDeclarator(Type type, SimpleName name)VariableDeclarator(Type type, SimpleName name, Expression initializer)Defines the declaration of a variable.VariableDeclarator(Type type, String variableName)VariableDeclarator(Type type, String variableName, Expression initializer)VariableDeclarator(TokenRange tokenRange, Type type, SimpleName name, Expression initializer)This constructor is used by the parser and is considered private. -
Uses of Type in com.github.javaparser.ast.expr
Methods in com.github.javaparser.ast.expr that return TypeModifier and TypeMethodDescriptionArrayCreationExpr.createdType()Takes the element type and wraps it in an ArrayType for every array creation level.ArrayCreationExpr.getElementType()CastExpr.getType()ClassExpr.getType()TypeExpr.getType()Methods in com.github.javaparser.ast.expr that return types with arguments of type TypeModifier and TypeMethodDescriptionFieldAccessExpr.getTypeArguments()MethodCallExpr.getTypeArguments()MethodReferenceExpr.getTypeArguments()ObjectCreationExpr.getTypeArguments()Methods in com.github.javaparser.ast.expr with parameters of type TypeMethod parameters in com.github.javaparser.ast.expr with type arguments of type TypeModifier and TypeMethodDescriptionFieldAccessExpr.setTypeArguments(NodeList<Type> typeArguments)Sets the type argumentsMethodCallExpr.setTypeArguments(NodeList<Type> typeArguments)Sets the typeArgumentsMethodReferenceExpr.setTypeArguments(NodeList<Type> typeArguments)Sets the typeArgumentsObjectCreationExpr.setTypeArguments(NodeList<Type> typeArguments)Sets the typeArgumentsConstructors in com.github.javaparser.ast.expr with parameters of type TypeModifierConstructorDescriptionArrayCreationExpr(Type elementType)ArrayCreationExpr(Type elementType, NodeList<ArrayCreationLevel> levels, ArrayInitializerExpr initializer)ArrayCreationExpr(TokenRange tokenRange, Type elementType, NodeList<ArrayCreationLevel> levels, ArrayInitializerExpr initializer)This constructor is used by the parser and is considered private.CastExpr(Type type, Expression expression)CastExpr(TokenRange tokenRange, Type type, Expression expression)This constructor is used by the parser and is considered private.ClassExpr(TokenRange tokenRange, Type type)This constructor is used by the parser and is considered private.TypeExpr(TokenRange tokenRange, Type type)This constructor is used by the parser and is considered private.VariableDeclarationExpr(Type type, String variableName)VariableDeclarationExpr(Type type, String variableName, Modifier... modifiers)Constructor parameters in com.github.javaparser.ast.expr with type arguments of type TypeModifierConstructorDescriptionFieldAccessExpr(Expression scope, NodeList<Type> typeArguments, SimpleName name)FieldAccessExpr(TokenRange tokenRange, Expression scope, NodeList<Type> typeArguments, SimpleName name)This constructor is used by the parser and is considered private.MethodCallExpr(Expression scope, NodeList<Type> typeArguments, SimpleName name, NodeList<Expression> arguments)MethodCallExpr(Expression scope, NodeList<Type> typeArguments, String name, NodeList<Expression> arguments)MethodCallExpr(TokenRange tokenRange, Expression scope, NodeList<Type> typeArguments, SimpleName name, NodeList<Expression> arguments)This constructor is used by the parser and is considered private.MethodReferenceExpr(Expression scope, NodeList<Type> typeArguments, String identifier)MethodReferenceExpr(TokenRange tokenRange, Expression scope, NodeList<Type> typeArguments, String identifier)This constructor is used by the parser and is considered private.ObjectCreationExpr(Expression scope, ClassOrInterfaceType type, NodeList<Type> typeArguments, NodeList<Expression> arguments, NodeList<BodyDeclaration<?>> anonymousClassBody)ObjectCreationExpr(TokenRange tokenRange, Expression scope, ClassOrInterfaceType type, NodeList<Type> typeArguments, NodeList<Expression> arguments, NodeList<BodyDeclaration<?>> anonymousClassBody)This constructor is used by the parser and is considered private. -
Uses of Type in com.github.javaparser.ast.nodeTypes
Classes in com.github.javaparser.ast.nodeTypes with type parameters of type TypeModifier and TypeInterfaceDescriptioninterfaceNodeWithType<N extends Node,T extends Type>A node with a type.Methods in com.github.javaparser.ast.nodeTypes that return TypeModifier and TypeMethodDescriptiondefault TypeNodeWithVariables.getCommonType()Returns the type that is shared between all variables.default TypeNodeWithVariables.getElementType()Returns the element type.Methods in com.github.javaparser.ast.nodeTypes that return types with arguments of type TypeModifier and TypeMethodDescriptionNodeWithVariables.calculateMaximumCommonType(List<Type> types)NodeWithVariables.getMaximumCommonType()Returns the type that maximum shared type between all variables.NodeWithTypeArguments.getTypeArguments()Methods in com.github.javaparser.ast.nodeTypes with parameters of type TypeModifier and TypeMethodDescriptiondefault ParameterNodeWithParameters.addAndGetParameter(Type type, String name)default FieldDeclarationNodeWithMembers.addField(Type type, String name, Modifier.Keyword... modifiers)Add a field to this.default FieldDeclarationNodeWithMembers.addFieldWithInitializer(Type type, String name, Expression initializer, Modifier.Keyword... modifiers)Add a field to this.default NNodeWithParameters.addParameter(Type type, String name)default FieldDeclarationNodeWithMembers.addPrivateField(Type type, String name)Add a private field to this.default FieldDeclarationNodeWithMembers.addProtectedField(Type type, String name)Add a protected field to this.default FieldDeclarationNodeWithMembers.addPublicField(Type type, String name)Add a public field to this.default NNodeWithVariables.setAllTypes(Type newType)Sets the type of all variables.default NNodeWithTypeArguments.setTypeArguments(Type... typeArguments)Method parameters in com.github.javaparser.ast.nodeTypes with type arguments of type TypeModifier and TypeMethodDescriptionNodeWithVariables.calculateMaximumCommonType(List<Type> types)NodeWithTypeArguments.setTypeArguments(NodeList<Type> typeArguments)Allows you to set the generic arguments -
Uses of Type in com.github.javaparser.ast.stmt
Methods in com.github.javaparser.ast.stmt that return types with arguments of type TypeMethod parameters in com.github.javaparser.ast.stmt with type arguments of type TypeModifier and TypeMethodDescriptionExplicitConstructorInvocationStmt.setTypeArguments(NodeList<Type> typeArguments)Sets the typeArgumentsConstructor parameters in com.github.javaparser.ast.stmt with type arguments of type TypeModifierConstructorDescriptionExplicitConstructorInvocationStmt(NodeList<Type> typeArguments, boolean isThis, Expression expression, NodeList<Expression> arguments)ExplicitConstructorInvocationStmt(TokenRange tokenRange, NodeList<Type> typeArguments, boolean isThis, Expression expression, NodeList<Expression> arguments)This constructor is used by the parser and is considered private. -
Uses of Type in com.github.javaparser.ast.type
Subclasses of Type in com.github.javaparser.ast.typeModifier and TypeClassDescriptionclassTo indicate that a type is an array, it gets wrapped in an ArrayType for every array level it has.classA class or an interface type.classRepresents a set of types.classA primitive type.classBase class for reference types.classA type parameter.classThe union typeclassAn unknown parameter type object.classA type called "var" waiting for Java to infer it.classThe return type of aMethodDeclarationwhen it returns void.classA wildcard type argument.Methods in com.github.javaparser.ast.type that return TypeModifier and TypeMethodDescriptionType.clone()ArrayType.getComponentType()ArrayType.getElementType()Finds the element type, meaning: the type without ArrayTypes around it.Type.getElementType()Finds the element type, meaning: the type without ArrayTypes around it.Type.setAnnotations(NodeList<AnnotationExpr> annotations)static TypeArrayType.wrapInArrayTypes(Type type, List<ArrayType.ArrayBracketPair>... arrayBracketPairLists)Takes lists of arrayBracketPairs, assumes the lists are ordered outer to inner and the pairs are ordered left to right.Methods in com.github.javaparser.ast.type that return types with arguments of type TypeModifier and TypeMethodDescriptionClassOrInterfaceType.getTypeArguments()static Pair<Type,List<ArrayType.ArrayBracketPair>>ArrayType.unwrapArrayTypes(Type type)Takes a type that may be an ArrayType.Methods in com.github.javaparser.ast.type with parameters of type TypeModifier and TypeMethodDescriptionArrayType.setComponentType(Type componentType)static Pair<Type,List<ArrayType.ArrayBracketPair>>ArrayType.unwrapArrayTypes(Type type)Takes a type that may be an ArrayType.static TypeArrayType.wrapInArrayTypes(Type type, List<ArrayType.ArrayBracketPair>... arrayBracketPairLists)Takes lists of arrayBracketPairs, assumes the lists are ordered outer to inner and the pairs are ordered left to right.Method parameters in com.github.javaparser.ast.type with type arguments of type TypeModifier and TypeMethodDescriptionClassOrInterfaceType.setTypeArguments(NodeList<Type> typeArguments)Sets the typeArgumentsConstructors in com.github.javaparser.ast.type with parameters of type TypeModifierConstructorDescriptionArrayType(Type type, AnnotationExpr... annotations)ArrayType(Type componentType, ArrayType.Origin origin, NodeList<AnnotationExpr> annotations)ArrayType(TokenRange tokenRange, Type componentType, ArrayType.Origin origin, NodeList<AnnotationExpr> annotations)This constructor is used by the parser and is considered private.Constructor parameters in com.github.javaparser.ast.type with type arguments of type TypeModifierConstructorDescriptionClassOrInterfaceType(ClassOrInterfaceType scope, SimpleName name, NodeList<Type> typeArguments)ClassOrInterfaceType(ClassOrInterfaceType scope, SimpleName name, NodeList<Type> typeArguments, NodeList<AnnotationExpr> annotations)ClassOrInterfaceType(TokenRange tokenRange, ClassOrInterfaceType scope, SimpleName name, NodeList<Type> typeArguments, NodeList<AnnotationExpr> annotations)This constructor is used by the parser and is considered private. -
Uses of Type in com.github.javaparser.resolution
Methods in com.github.javaparser.resolution with parameters of type TypeModifier and TypeMethodDescription<T> TSymbolResolver.toResolvedType(Type javaparserType, Class<T> resultClass)For types it would find the corresponding resolved types.