Interface MinecraftDependency
- All Superinterfaces:
org.gradle.api.artifacts.Dependency,org.gradle.api.artifacts.ExternalDependency,org.gradle.api.artifacts.ExternalModuleDependency,org.gradle.api.attributes.HasAttributes,org.gradle.api.attributes.HasConfigurableAttributes<org.gradle.api.artifacts.ModuleDependency>,org.gradle.api.artifacts.ModuleDependency,org.gradle.api.artifacts.ModuleVersionSelector
public sealed interface MinecraftDependency
extends org.gradle.api.artifacts.ExternalModuleDependency
-
Field Summary
Fields inherited from interface org.gradle.api.artifacts.Dependency
ARCHIVES_CONFIGURATION, CLASSIFIER, DEFAULT_CONFIGURATION -
Method Summary
Modifier and TypeMethodDescriptionvoidaccessTransformer(Closure options) Configures the AccessTransformer options for this project.default voidaccessTransformer(org.gradle.api.Action<? super net.minecraftforge.accesstransformers.gradle.AccessTransformersContainer.Options> options) Configures the AccessTransformer options for this project.copy()default booleanvoidSets the mappings to use for the Minecraft Maven.default voidSets the mappings to use for the Minecraft Maven.voidsetAccessTransformer(File configFile) Sets the AccessTransformer configuration to use.voidsetAccessTransformer(Object configFile) Sets the AccessTransformer configuration to use.voidsetAccessTransformer(org.gradle.api.file.RegularFile configFile) Sets the AccessTransformer configuration to use.voidsetAccessTransformer(org.gradle.api.provider.Provider<?> configFile) Sets the AccessTransformer configuration to use.default MinecraftDependencysetChanging(boolean changing) Methods inherited from interface org.gradle.api.artifacts.Dependency
because, contentEquals, getGroup, getName, getReason, getVersionMethods inherited from interface org.gradle.api.artifacts.ExternalDependency
getVersionConstraint, isForce, versionMethods inherited from interface org.gradle.api.artifacts.ModuleDependency
addArtifact, artifact, artifact, attributes, capabilities, doNotEndorseStrictVersions, endorseStrictVersions, exclude, getArtifacts, getAttributes, getCapabilitySelectors, getExcludeRules, getRequestedCapabilities, getTargetConfiguration, isEndorsingStrictVersions, isTransitive, setTargetConfiguration, setTransitiveMethods inherited from interface org.gradle.api.artifacts.ModuleVersionSelector
getGroup, getModule, getName, getVersion, matchesStrictly
-
Method Details
-
getMappings
-
mappings
Sets the mappings to use for the Minecraft Maven.This method includes a generated named variant that can make declaration in your buildscript easier.
minecraft { mappings channel: 'official', version: '1.21.5' }- Parameters:
channel- The mappings channelversion- The mappings version- Throws:
IllegalArgumentException- If any parameter isnull- See Also:
- API Note:
- Mappings should only be declared once. A warning will be reported on re-declaration.
-
mappings
Sets the mappings to use for the Minecraft Maven.
This method is generated by Groovy in the implementing class, but has been included here for convenience and IDE support.
- Parameters:
namedArgs- The named arguments- Throws:
IllegalArgumentException- If any parameter isnull- See Also:
- API Note:
- Mappings should only be declared once. A warning will be reported on re-declaration.
-
setAccessTransformer
void setAccessTransformer(org.gradle.api.file.RegularFile configFile) Sets the AccessTransformer configuration to use.- Parameters:
configFile- The configuration file to use
-
setAccessTransformer
Sets the AccessTransformer configuration to use.- Parameters:
configFile- The configuration file to use
-
setAccessTransformer
Sets the AccessTransformer configuration to use.
The given object is resolved using
Project.file(Object).- Parameters:
configFile- The configuration file to use
-
setAccessTransformer
void setAccessTransformer(org.gradle.api.provider.Provider<?> configFile) Sets the AccessTransformer configuration to use.
If the given provider does not provide a file or regular file, the result will be resolved using
Project.file(Object), similarly tosetAccessTransformer(Object).- Parameters:
configFile- The configuration file to use
-
accessTransformer
default void accessTransformer(org.gradle.api.Action<? super net.minecraftforge.accesstransformers.gradle.AccessTransformersContainer.Options> options) Configures the AccessTransformer options for this project.- Parameters:
options- The options to apply
-
accessTransformer
void accessTransformer(@DelegatesTo(value=net.minecraftforge.accesstransformers.gradle.AccessTransformersContainer.Options.class,strategy=1) Closure options) Configures the AccessTransformer options for this project.- Parameters:
options- The options to apply
-
isChanging
default boolean isChanging()- Specified by:
isChangingin interfaceorg.gradle.api.artifacts.ExternalModuleDependency
-
setChanging
- Specified by:
setChangingin interfaceorg.gradle.api.artifacts.ExternalModuleDependency
-
copy
MinecraftDependency copy()- Specified by:
copyin interfaceorg.gradle.api.artifacts.Dependency- Specified by:
copyin interfaceorg.gradle.api.artifacts.ExternalDependency- Specified by:
copyin interfaceorg.gradle.api.artifacts.ExternalModuleDependency- Specified by:
copyin interfaceorg.gradle.api.artifacts.ModuleDependency
-