Load a class from a class path in a fresh class loader, detect the version it is implementing, and, if available, add it to the known implementations.
Load a class from a class path in a fresh class loader, detect the version it is implementing, and, if available, add it to the known implementations.
The class loader and the loaded class are discarded immediately afterwards.
Load a series of classes.
Load a series of classes.
Construct a environment in a fresh class loader, if the specified version is known.
Construct a environment in a fresh class loader, if the specified version is known.
Environments created through this method are unique and independent, because they reside in different class loaders.
Users may want to go call this method via Setup.makeEnvironment, which gives stronger guarantees about the success of this method.
Footnote
Advanced class loading trickery is needed to manage multiple environments
stemming from different setups.
libisabelle
itself is a more-or-less thin wrapper around the actual
Isabelle interface ("PIDE"), which relies on global state for environment
variables such as the home path. Once set, they cannot be changed.
However, on the JVM, global state is scoped to the class loader, i.e.
multiple "global states" may coexist in the same virtual machine. This is
exactly the trick used here.
Known versions.
A managed set of known implementations of
Environment
.An empty instance can be obtained via
Implementations.empty
.