Automatic module resolution

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Automatic module resolution

Nicolai Parlog
 Hi!

In a year-old comment on StackOverflow[1] Mark Reinhold wrote:

> If one automatic module depends upon another automatic module
> (i.e., both are on the module path but only the first is required
> by an explicit module) then you can cause the second automatic
> module to be loaded via the `--add-modules` option.

Experiments show that is became unnecessary and once one automatic
module gets loaded, so do all others. I couldn't find any references to
this in a cursory search of the SotMS and this mailing list - can aynone
link to a discussion on this?

 so long ... Nicolai


[1]
https://stackoverflow.com/q/38269630/2525313?noredirect=1#comment64036158_38274483



--

PGP Key:
    http://keys.gnupg.net/pks/lookup?op=vindex&search=0xCA3BAD2E9CCCD509

Web:
    http://codefx.org
        a blog about software development
    https://www.sitepoint.com/java
        high-quality Java/JVM content
    http://do-foss.de
        Free and Open Source Software for the City of Dortmund

Twitter:
    https://twitter.com/nipafx
Reply | Threaded
Open this post in threaded view
|

Re: Automatic module resolution

Alan Bateman


On 30/08/2017 11:33, Nicolai Parlog wrote:
> :
> Experiments show that is became unnecessary and once one automatic
> module gets loaded, so do all others. I couldn't find any references to
> this in a cursory search of the SotMS and this mailing list - can aynone
> link to a discussion on this?
>
Yes, this changed in the last year to make automatic modules easier to
use.  In the resolution spec [1], look for "If at least one automatic
module is enumerated ..." and it has the details.

-Alan

[1]
http://download.java.net/java/jdk9/docs/api/java/lang/module/package-summary.html#resolution