create method from usage: allow to reuse parent class type args (IDEA-64683)

This commit is contained in:
anna
2011-02-10 17:21:03 +01:00
parent 931286ad8d
commit 61f2714f06
3 changed files with 30 additions and 0 deletions

View File

@@ -0,0 +1,14 @@
// "Create Method 'foo'" "true"
class Test {
<R, D> R foo(T<R, D> t, D data) {
return t.foo(this, data);
}
}
class T<R, D> {
public R foo(Test test, D data) {
<selection>return null; //To change body of created methods use File | Settings | File Templates.</selection>
}
}

View File

@@ -0,0 +1,11 @@
// "Create Method 'foo'" "true"
class Test {
<R, D> R foo(T<R, D> t, D data) {
return t.f<caret>oo(this, data);
}
}
class T<R, D> {
}