in our development team we have both Eclipse & Intellij IDEA users, with my team working mainly in Groovy.
We junior developers on this specific team, while working on an IDE with full access to all the relevant classes we need, still copy-paste the scripts into our web-ui, which internally runs them based on the specific rules and settings.
Since the script runner, afaik, injects certain variables into the environment, they are available for use in the scripts but are unavailable for the IDE to autocomplete. In Intellij, we declare them as Dynamic Properties for each script on the IDE level, so that the IntelliSense treats these as objects of the type they are, but I am not able to find an equivalent functionality in Eclipse, nor much information about anyone with a similar situation.
For example, in the following script:
def location = locationService.findLocationById(123)
Where locationService
is an object of a type which implements ILocationService
. When ran on the server, location
is correctly identified as of type Location
, but the IDE cannot infer it, of course.
In Intellij, I can add a Dynamic Property for locationService
, identifying it as of type 'ILocationService'.
Is that even possible on Eclipe?
Thanks!