Package net.neoforged.fml.loading
Class LaunchContext
java.lang.Object
net.neoforged.fml.loading.LaunchContext
- All Implemented Interfaces:
ILaunchContext
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final IEnvironment
private static final org.slf4j.Logger
private final IModuleLayerManager
Fields inherited from interface net.neoforged.neoforgespi.ILaunchContext
LOGGER
-
Constructor Summary
ConstructorsConstructorDescriptionLaunchContext
(IEnvironment environment, IModuleLayerManager moduleLayerManager, List<String> modLists, List<String> mods, List<String> mavenRoots) -
Method Summary
Modifier and TypeMethodDescriptionboolean
addLocated
(Path path) Marks a path as being located and returns true if it was not previously located.The Modlauncher environment.boolean
Checks if a given path was already found by a previous locator, or may be already loaded.<T> Stream
<ServiceLoader.Provider<T>> loadServices
(Class<T> serviceClass) modLists()
mods()
private Path
unpackPath
(Path path) private static void
visitLayer
(IModuleLayerManager.Layer layer, Consumer<IModuleLayerManager.Layer> consumer)
-
Field Details
-
LOG
private static final org.slf4j.Logger LOG -
environment
-
moduleLayerManager
-
modLists
-
mods
-
mavenRoots
-
locatedPaths
-
-
Constructor Details
-
LaunchContext
LaunchContext(IEnvironment environment, IModuleLayerManager moduleLayerManager, List<String> modLists, List<String> mods, List<String> mavenRoots)
-
-
Method Details
-
unpackPath
-
loadServices
- Specified by:
loadServices
in interfaceILaunchContext
-
visitLayer
private static void visitLayer(IModuleLayerManager.Layer layer, Consumer<IModuleLayerManager.Layer> consumer) -
isLocated
Description copied from interface:ILaunchContext
Checks if a given path was already found by a previous locator, or may be already loaded.- Specified by:
isLocated
in interfaceILaunchContext
-
addLocated
Description copied from interface:ILaunchContext
Marks a path as being located and returns true if it was not previously located.- Specified by:
addLocated
in interfaceILaunchContext
-
environment
Description copied from interface:ILaunchContext
The Modlauncher environment.- Specified by:
environment
in interfaceILaunchContext
-
moduleLayerManager
-
modLists
- Specified by:
modLists
in interfaceILaunchContext
-
mods
- Specified by:
mods
in interfaceILaunchContext
-
mavenRoots
- Specified by:
mavenRoots
in interfaceILaunchContext
-