Package asteroid.nodes
Class ClassNodeBuilder
- java.lang.Object
-
- asteroid.nodes.ClassNodeBuilder
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ClassNodebuild()Returns the instance of typeClassNodeconfigured by this builderstatic ClassNodeBuilderclazz(Class<?> clazz)Creates a new instance ofClassNodeBuilderby using theClasstype.static ClassNodeBuilderclazz(String qualifiedName)static ClassNodeBuilderclazzWithGenerics(Class<?> clazz, GenericsType... genericsTypes)Creates a new instance ofClassNodeBuilderby using the fully qualified name of aClassClassNodeBuildergenericsPlaceHolder(Boolean usePlaceholder)Informs the builder whether to use a generic placeholder in the resultingClassNodeor not.ClassNodeBuildergenericsTypes(GenericsType... genericsTypes)Sets generic types for the resultingClassNodeClassNodeBuilderusingGenerics(Boolean useGenerics)Informs the builder whether to use generics in the resultingClassNodeor not.
-
-
-
Method Detail
-
clazz
public static ClassNodeBuilder clazz(Class<?> clazz)
Creates a new instance ofClassNodeBuilderby using theClasstype.
AST
Resultclazz(String) .build()String.class- Parameters:
clazz-- Returns:
- an instance of
ClassNodeBuilder - Since:
- 0.1.0
-
clazz
public static ClassNodeBuilder clazz(String qualifiedName)
Creates a new instance ofClassNodeBuilderby using the fully qualified name of aClass
AST
Resultclazz('java.lang.String') .build()String.class- Parameters:
qualifiedName- aStringwithe the complete name of the class- Returns:
- current instance of
ClassNodeBuilder - Since:
- 0.1.0
-
clazzWithGenerics
public static ClassNodeBuilder clazzWithGenerics(Class<?> clazz, GenericsType... genericsTypes)
Creates a new instance ofClassNodeBuilderby using the fully qualified name of aClass- Parameters:
clazz- The type of the class nodegenericsTypes- the generic types the class node will have- Returns:
- current instance of
ClassNodeBuilder - Since:
- 0.1.0
-
usingGenerics
public ClassNodeBuilder usingGenerics(Boolean useGenerics)
Informs the builder whether to use generics in the resultingClassNodeor not.- Parameters:
useGenerics- true if it should use generics- Returns:
- current instance of
ClassNodeBuilder - Since:
- 0.1.0
-
genericsPlaceHolder
public ClassNodeBuilder genericsPlaceHolder(Boolean usePlaceholder)
Informs the builder whether to use a generic placeholder in the resultingClassNodeor not.- Parameters:
usePlaceholder- true if the builder should use it- Returns:
- current instance of
ClassNodeBuilder - Since:
- 0.1.0
-
genericsTypes
public ClassNodeBuilder genericsTypes(GenericsType... genericsTypes)
Sets generic types for the resultingClassNode- Parameters:
genericsTypes-- Returns:
- current instance of
ClassNodeBuilder - Since:
- 0.1.0
-
-