Issue:
With the current version, if I use one of my own class (Foo), and I start to write:
new Foo().ac
If a ‘Foo.java’ tab is open in Eclipse, Copilot will come up with a relevant ending (maybe new Foo().accept())
If no ‘Foo.java’ tab is open, Copilot will use its imagination (e.g., new Foo().activate() even if Foo has no activate() method).
This is very disturbing, even if this is the standard Copilot behavior.
Solution 1 (light)
Copilot4Eclipse has a preference where a list of packages is declared. The source of these packages is available (jar or .java files).
Whenever a non-* import declared in the current java file starts with a package from this list, Copilot4Eclipse acts as if the file is opened in another tab.
Solution 2 (maybe too heavy for Copilot)
Copilot4Eclipse has a preference where a list of packages is declared. The source of these packages is available (jar or .java files).
Copilot4Eclipse acts as if all sources from these packages are always opened in tabs.
Solution 2 would allow much better predictions than Solution 1, but would maybe put a lot of burden on Copilot.
I reckon I made this issue very java-centric, but this issue is applicable for all languages.