IDEA-209607 When completing equals/hashCode/toString, show elements that show corresponding generate dialogs

GitOrigin-RevId: 2b2609cec214567b8f1fc46f06f0b946b4ed9cab
This commit is contained in:
peter
2019-10-04 21:32:34 +00:00
committed by intellij-monorepo-bot
parent 3037e7f3f8
commit 1a8e3454e5
8 changed files with 85 additions and 10 deletions
@@ -0,0 +1,4 @@
class A {
int a;
equal<caret>
}
@@ -0,0 +1,18 @@
import java.util.Objects;
class A {
int a;
@Override
public boolean equals(Object o) {<caret>
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
A a1 = (A) o;
return a == a1.a;
}
@Override
public int hashCode() {
return Objects.hash(a);
}
}
@@ -0,0 +1,4 @@
class A {
int a;
toStri<caret>
}
@@ -0,0 +1,10 @@
class A {
int a;
@Override
public String <caret>toString() {
return "A{" +
"a=" + a +
'}';
}
}