Javadoc
Called when a module is being considered for loading.
(This would be before
#installed,
#restored,
or
#updated are called.) If something is critically
wrong with the module (missing ad-hoc dependency, missing
license key, etc.) then IllegalStateException
may be thrown to prevent it from being loaded (preferably
with a
Exceptions#attachLocalizedMessage). The default implementation
does nothing. The module cannot assume much about when this
method will be called; specifically it cannot rely on layers
or manifest sections to be ready, nor for the module's classloader
to exist in the system class loader (so if loading bundles, icons,
and so on, specifically pass in the class loader of the install
class rather than relying on the default modules class loader).