Quilt Loader 1
Loading...
Searching...
No Matches
org.quiltmc.loader.api.ModInternal Interface Reference

Indicates that the annotated package, class, method, constructor, or field is not considered to be part of a mods public api, and so quilt-loader should restrict access to only the mods specified in exceptions(). More...

Public Member Functions

String[] exceptions () default
 An array of mod ids, which are allowed to access the annotated element.
Class<?>[] classReplacements () default
 Indicates API classes which should be used instead of the annotated class.
String[] replacements () default
 Indicates replacements which should be used instead of the annotated element.

Detailed Description

Indicates that the annotated package, class, method, constructor, or field is not considered to be part of a mods public api, and so quilt-loader should restrict access to only the mods specified in exceptions().

If both a class and a method are annotated with this then the more specific annotation is read.

This is generally intended for library mods with a clearly defined api, and probably only those which use semantic versioning (or similar) to describe when their public API changes. Content mods which have an API too are generally discouraged from using this.

Care must be taken when mixins defined by the mod access elements annotated with this, as the target mod must also be included in the exceptions() array.

Member Function Documentation

◆ exceptions()

String[] org.quiltmc.loader.api.ModInternal.exceptions ( )
inline

An array of mod ids, which are allowed to access the annotated element.

This array is always treated as if it contains the owning mod id, so it doesn't need to be present.


The documentation for this interface was generated from the following file:
  • src/main/java/org/quiltmc/loader/api/ModInternal.java