Global scoping
Xtext has a default mechanism for global scoping that allows you to refer to elements defined in a different file, possibly in a different project of the workspace; in particular, it uses the dependencies of the Eclipse projects. For Java projects, it uses the classpath of the projects. Of course, this mechanism relies on the global index.
Note
Global scoping is implied by the fact that the default scoping mechanism always relies on an outer scope that consists of the visible object descriptions in the index.
With the default configuration in the MWE2, this mechanism for global scoping works out of the box. You can experiment with a project with some SmallJava files. You will see that you can refer to the SmallJava classes defined in another file; content assist works accordingly.
Before proceeding to the use of global scoping, it is worthwhile to learn how to write JUnit tests that concern several input programs.
As hinted in the section The index, when running in a plain Java...