You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: headless-services/spring-boot-language-server/src/main/java/org/springframework/ide/vscode/boot/java/beans/BeanCompletionProposal.java
Copy file name to clipboardExpand all lines: headless-services/spring-boot-language-server/src/main/java/org/springframework/ide/vscode/boot/java/jdt/refactoring/ArrayTypeName.java
Copy file name to clipboardExpand all lines: headless-services/spring-boot-language-server/src/main/java/org/springframework/ide/vscode/boot/java/jdt/refactoring/ClassName.java
Copy file name to clipboardExpand all lines: headless-services/spring-boot-language-server/src/main/java/org/springframework/ide/vscode/boot/java/jdt/refactoring/InjectBeanConstructorRefactoring.java
+60-40Lines changed: 60 additions & 40 deletions
Original file line number
Diff line number
Diff line change
@@ -14,7 +14,6 @@
14
14
importjava.util.List;
15
15
importjava.util.Map;
16
16
17
-
importorg.eclipse.jdt.core.JavaCore;
18
17
importorg.eclipse.jdt.core.dom.AST;
19
18
importorg.eclipse.jdt.core.dom.ASTNode;
20
19
importorg.eclipse.jdt.core.dom.Assignment;
@@ -67,52 +66,74 @@ public class InjectBeanConstructorRefactoring {
67
66
68
67
privatefinalCompilationUnitcu;
69
68
privatefinalStringsource;
70
-
privatefinalStringfullyQualifiedBeanType;
69
+
privatefinalJavaTypebeanType;
71
70
privatefinalStringfieldName;
72
71
privatefinalStringtargetClassFqName;
73
72
privatefinalbooleanaddFieldAssignment;
74
73
privatefinalMap<String, String> formatterOptions;
75
74
76
75
/**
77
-
* Create a new bean constructor injection refactoring.
76
+
* Create a new bean constructor injection refactoring from a pre-parsed {@link JavaType}.
77
+
* <p>
78
+
* Use this constructor when the caller already has a parsed {@link JavaType} instance
79
+
* to avoid redundant parsing.
78
80
*
79
-
* @param cu the already-parsed {@link CompilationUnit}. The caller provides
80
-
* it — in the completion flow it comes from the CU cache; in tests
81
-
* it can be a simple {@code ASTParser}-created CU.
82
-
* @param source the full Java source text of the compilation unit. Required because
83
-
* the DOM {@link CompilationUnit} does not retain the original source
84
-
* text, and {@link ASTRewrite#rewriteAST(org.eclipse.jface.text.IDocument, Map)}
85
-
* needs it to compute correct text edits.
86
-
* @param fullyQualifiedBeanType the fully qualified type name of the bean to inject
Copy file name to clipboardExpand all lines: headless-services/spring-boot-language-server/src/main/java/org/springframework/ide/vscode/boot/java/jdt/refactoring/JavaType.java
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -36,7 +36,7 @@
36
36
*
37
37
* @author Alex Boyko
38
38
*/
39
-
interfaceJavaType {
39
+
publicinterfaceJavaType {
40
40
41
41
/**
42
42
* Returns a human-readable display name for this type using short (simple) names.
Copy file name to clipboardExpand all lines: headless-services/spring-boot-language-server/src/main/java/org/springframework/ide/vscode/boot/java/jdt/refactoring/ParameterizedClassName.java
+14Lines changed: 14 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -13,6 +13,7 @@
13
13
importjava.util.ArrayList;
14
14
importjava.util.Collections;
15
15
importjava.util.List;
16
+
importjava.util.Objects;
16
17
importjava.util.stream.Collectors;
17
18
18
19
importorg.eclipse.jdt.core.dom.AST;
@@ -115,4 +116,17 @@ public String toString() {
115
116
returngetFullyQualifiedName();
116
117
}
117
118
119
+
@Override
120
+
publicbooleanequals(Objecto) {
121
+
if (this == o) returntrue;
122
+
if (o == null || getClass() != o.getClass()) returnfalse;
Copy file name to clipboardExpand all lines: headless-services/spring-boot-language-server/src/main/java/org/springframework/ide/vscode/boot/java/jdt/refactoring/WildcardName.java
0 commit comments