Interface AccessTransformersExtension
- All Superinterfaces:
AccessTransformersContainer
The extension interface for the AccessTransformers Gradle plugin.
Consumers must register at least one container using register(Attribute, Action) (or using register(Action) to
use the default attribute). This extension acts as a delegate to the last registered container, but consumers can
also use the return value of the registration to use multiple containers in a single project.
- API Note:
- This interface is effectively sealed and must not be extended.
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraftforge.accesstransformers.gradle.AccessTransformersContainer
AccessTransformersContainer.Options -
Field Summary
FieldsModifier and TypeFieldDescriptionThe default attribute used byregister(Action).static final StringThe name for this extension when added to projects. -
Method Summary
Modifier and TypeMethodDescriptiondefault AccessTransformersContainerRegisters a new container, with the given options, using the default attribute.default AccessTransformersContainerregister(Action<? super AccessTransformersContainer.Options> options) Registers a new container, with the given options, using the default attribute.Registers a new container using the given attribute and options.default AccessTransformersContainerregister(Attribute<Boolean> attribute, Action<? super AccessTransformersContainer.Options> options) Registers a new container using the given attribute and options.
-
Field Details
-
NAME
-
DEFAULT_ATTRIBUTE
The default attribute used by
register(Action).It is recommended that consumers use their own attributes if they plan on registering more than one container per build.
-
-
Method Details
-
register
default AccessTransformersContainer register(Action<? super AccessTransformersContainer.Options> options) Registers a new container, with the given options, using the default attribute.- Parameters:
options- The options to apply- Returns:
- The registered container
- See Also:
-
register
default AccessTransformersContainer register(@DelegatesTo(value=AccessTransformersContainer.Options.class,strategy=1) Closure options) Registers a new container, with the given options, using the default attribute.- Parameters:
options- The options to apply- Returns:
- The registered container
- See Also:
-
register
default AccessTransformersContainer register(Attribute<Boolean> attribute, Action<? super AccessTransformersContainer.Options> options) Registers a new container using the given attribute and options.- Parameters:
attribute- The boolean attribute to use for this containeroptions- The options to apply- Returns:
- The registered container
- See Also:
-
register
AccessTransformersContainer register(Attribute<Boolean> attribute, @DelegatesTo(value=AccessTransformersContainer.Options.class,strategy=1) Closure options) Registers a new container using the given attribute and options.- Parameters:
attribute- The boolean attribute to use for this containeroptions- The options to apply- Returns:
- The registered container
- See Also:
-