tutorial:mixin_glossary
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| tutorial:mixin_glossary [2025/09/29 09:04] – Creation of sections, along with many different definitions for injector and general terms. gauntrecluse | tutorial:mixin_glossary [2025/11/29 03:49] (current) – gauntrecluse | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | :!: //this page is a draft being written by GauntRecluse! Feedback is appreciated but the page is currently not ready to be read by users of the Wiki!// | + | :!: //this page is a draft! Feedback is appreciated but the page is currently not ready to be read by users of the Wiki!// |
| ====== Mixin Glossary (DRAFT) ====== | ====== Mixin Glossary (DRAFT) ====== | ||
| Line 5: | Line 5: | ||
| ===== Preamble ===== | ===== Preamble ===== | ||
| - | This page aims to address terms, acronyms, abbreviations, | + | This page aims to address terms, acronyms, abbreviations, |
| It is advised to read the [[[[tutorial: | It is advised to read the [[[[tutorial: | ||
| ==== Contributing ==== | ==== Contributing ==== | ||
| - | Seeing as this page is likely to change a lot with time as terms, both official and common usage ones, may vary over time and need many amendments as both Mixin and associated libraries | + | Seeing as this page is likely to change a lot with time as terms, both official and common usage ones, may vary over time and need many amendments as both Mixin and associated libraries evolve and get used in different contexts; it feels wise to add a section on best practices for contributing to this page in the long run. |
| - | If you wish to contribute it is appreciated to use references to external sources | + | If you wish to contribute it is appreciated to use references to external sources |
| Due to the amount of potential areas that could be edited, it would also be appreciated to always specify which definitions you're adding or editing in your edit summary messages. If necessary, split your edit into different smaller edits to be able to more clearly indicate which definitions were modified. | Due to the amount of potential areas that could be edited, it would also be appreciated to always specify which definitions you're adding or editing in your edit summary messages. If necessary, split your edit into different smaller edits to be able to more clearly indicate which definitions were modified. | ||
| Line 20: | Line 20: | ||
| TODO notes should always describe what should be added there and should ideally be in //italics// | TODO notes should always describe what should be added there and should ideally be in //italics// | ||
| + | |||
| + | Example definition: | ||
| + | |||
| + | == Words! == | ||
| + | - First def | ||
| + | - Sub-def | ||
| + | * Note on First def | ||
| + | - Second def | ||
| + | * Note on Second def | ||
| + | |||
| + | === Referencing other definitions === | ||
| + | |||
| + | You can reference another definition on the page by referencing the definition' | ||
| + | [[# | ||
| + | [[#asm|The ASM definition]] - '' | ||
| + | |||
| ---- | ---- | ||
| - | //TODO: Probably add subsections depending on the terms?// | + | :!: //This is under heavy construction and probably contains inaccuracies, |
| - | FIXME //This is under heavy construction and probably contains inaccuracies, | + | |
| ===== Definitions ===== | ===== Definitions ===== | ||
| - | ==== General/Misc. Terms ==== | + | ==== General |
| - | == Mixin, | + | == Lambda Function, Lambda Method == |
| + | - Unnamed method that can be defined within a method body(see [[# | ||
| + | * For a more thorough technical definition, see [[https:// | ||
| + | |||
| + | |||
| + | == Anonymous Class == | ||
| + | - A nameless inner class declared and instantiated a single time. Anonymous classes may be declared within a method' | ||
| + | |||
| + | |||
| + | == Enclosing Method == | ||
| + | - The method containing the relevant subject, such as an [[# | ||
| + | |||
| + | == Encapsulating Class, Outer Class == | ||
| + | - The class containing the relevant subject, often an inner class such as an [[# | ||
| + | |||
| + | == Mixin, | ||
| - When used as a single term in the form of a proper noun, references the Mixin Subsystem as a whole. Mixin is a subsystem with the primary purpose of allowing a developer to describe modifications to be made at runtime using code. See [[tutorial: | - When used as a single term in the form of a proper noun, references the Mixin Subsystem as a whole. Mixin is a subsystem with the primary purpose of allowing a developer to describe modifications to be made at runtime using code. See [[tutorial: | ||
| - | - "a Mixin" or "a Mixin Class" | + | - "a Mixin" or "a Mixin Class" |
| + | |||
| + | |||
| + | == Target Class == | ||
| + | - A class with contents being targeted by the relevant Mixin Class' | ||
| + | |||
| + | |||
| + | == Target Method == | ||
| + | - A method within a [[# | ||
| + | |||
| + | |||
| + | == Merging, to merge == | ||
| + | - In the context of Mixin, merging most of members and new interface implementations from the Mixin class into the target class' | ||
| + | |||
| + | |||
| + | == Shadowing == | ||
| + | - Reference to usages of '' | ||
| + | |||
| + | == Double-Casting == | ||
| + | - For Mixins, references the practice of casting a '' | ||
| + | |||
| + | |||
| + | == Accessor == | ||
| + | - Reference to an [[tutorial: | ||
| + | - Reference to the '' | ||
| + | |||
| + | == Invoker == | ||
| + | - Reference to the '' | ||
| == MixinExtras == | == MixinExtras == | ||
| - | - A companion library for the Mixin subsystem | + | - A companion library for the Mixin subsystem. MixinExtras focuses on giving more versatile, precise and compatible injectors and general Mixin usage utility. MixinExtras is bundled with Fabric since Loader version 0.15; MixinExtras 0.5.0 has been bundled with Fabric since Loader version 0.17.0; See [[https:// |
| Line 42: | Line 100: | ||
| - | == Bytecode | + | == MCDev == |
| + | - References the IntelliJ Minecraft Development Plugin. It is very frequently used for Mixin development due to the added convenience, | ||
| + | |||
| + | |||
| + | == ASM == | ||
| + | - Java framework used by Mixin and other tools to modify and manipulate JVM bytecode at runtime. | ||
| + | - In general programming contexts, may refer to Assembly. | ||
| + | |||
| + | |||
| + | ---- | ||
| + | |||
| + | ==== Bytecode | ||
| + | |||
| + | == As opposed to Source code == | ||
| - Bytecode is a set of less readable, computer-oriented instructions, | - Bytecode is a set of less readable, computer-oriented instructions, | ||
| ---- | ---- | ||
| - | ==== Injectors | + | == Signatures |
| + | - A class signature encodes type information about a class or interface declaration. It describes any type parameters of the class or interface, and lists its direct superclass and direct superinterfaces, | ||
| + | - A method signature encodes the name, modifiers and type information about a method declaration. It describes any type parameters of the method, the types of any formal parameters, the return type, and the types of any exceptions declared in the method' | ||
| + | - A field signature encodes the name and the type of a field, formal parameter, local variable, or record component declaration. | ||
| + | |||
| + | == Field Descriptor | ||
| + | - A field descriptor represents the type of a field, parameter, local variable, or value. | ||
| + | * See the below table for possible field descriptors. | ||
| + | |||
| + | ^ FieldType term ^ Type ^ | ||
| + | | B | byte | | ||
| + | | C | char | | ||
| + | | D | double | | ||
| + | | F | float | | ||
| + | | I | int | | ||
| + | | J | long | | ||
| + | | L ClassName ; | Named class or interface type | | ||
| + | | S | short | | ||
| + | | Z | boolean | | ||
| + | | [ ComponentType | Array of given component type | | ||
| + | |||
| + | == Method Descriptor == | ||
| + | - A method descriptor contains zero or more parameter descriptors, | ||
| + | - For example the descriptor of < | ||
| - | == Relevant external articles for this section | + | == Synthetic members/ |
| - | Technical article on callback injectors, Mixin Wiki: [[https:// | + | - In Java, synthetic members and constructs refers to constructs added by the Java compiler into the compiled bytecode that do not have a source code equivalent. For instance, an anonymous class is given synthetic '' |
| - | MixinExtras Wiki: [[https:// | + | * Synthetic members may be targeted by Mixin, such as with '' |
| ---- | ---- | ||
| + | |||
| + | ==== Injectors ==== | ||
| == Injector == | == Injector == | ||
| - | - Most commonly, references a " | + | - Also known as " |
| + | * Typically only refers to injectors that can chain and do not remove | ||
| == Handler method / Handler == | == Handler method / Handler == | ||
| - | - In the context of Mixins, a decorated | + | - In Mixins, a method |
| == Callback == | == Callback == | ||
| - | - A series of injected instructions | + | - A series of injected instructions |
| + | |||
| + | |||
| + | == CallbackInfo == | ||
| + | - An argument passed to an injector allowing to interact with the callback instructions. Notably, it may be " | ||
| + | * If the target method returns a value, the injector will instead be passed a '' | ||
| + | * See the JavaDocs for the [[https:// | ||
| == Injection Point == | == Injection Point == | ||
| - | - An injection point is the primary value used by Mixin to determine where to insert the callback instructions for a given injector. Injection points are most often defined | + | - An injection point is the primary value used by Mixin to determine where to insert the callback instructions for a given injector. Injection points are typically passed |
| - The injection point " | - The injection point " | ||
| - | - In some cases of common speech, injection point may refer to the specific point an injector' | + | - In some cases, injection point may refer to the specific point an injector' |
| + | |||
| + | |||
| + | == WrapOp, @WrapOperation == | ||
| + | - Injector from MixinExtras, | ||
| + | * See [[https:// | ||
| + | |||
| + | |||
| + | == MEV, @ModifyExpressionValue == | ||
| + | - Injector from MixinExtras, | ||
| + | * See [[https:// | ||
| + | |||
| + | |||
| + | == MRV, @ModifyReturnValue == | ||
| + | - Injector from Mixinextras, | ||
| + | * See [[https:// | ||
| + | |||
| + | |||
| + | == Inject == | ||
| + | - (Verb) To use a Mixin injector to add to or modify existing operations. | ||
| + | - Reference to the '' | ||
| + | |||
| + | |||
| + | == Local == | ||
| + | - (General programming) Value confined to the relevant scope. | ||
| + | - When working with Mixins, the relevant scope will be the target method and its locals. | ||
| + | - Reference to the '' | ||
| + | * See the [[https:// | ||
| + | |||
| + | == Capturing Locals == | ||
| + | - The process of using [[# | ||
| + | |||
| + | |||
| + | == Cancel, Cancellable == | ||
| + | - (Verb) In the context of injectors, means to cancel the remaining operations of the target method. | ||
| + | - (Annotation) Reference to the '' | ||
| + | * See the [[https:// | ||
| + | |||
| + | |||
| + | == Share, Sharing == | ||
| + | - '' | ||
| + | * See the [[https:// | ||
| ---- | ---- | ||
| + | |||
| + | ==== Targeting Tools ==== | ||
| + | Outside of [[# | ||
| + | |||
| + | |||
| + | == Brittle == | ||
| + | - A " | ||
| + | |||
| + | |||
| + | == Slice, Slicing == | ||
| + | - Reference to the '' | ||
| + | |||
| + | |||
| + | == Expressions == | ||
| + | - Added in MixinExtras '' | ||
| + | - To "use an expression" | ||
| + | * See [[https:// | ||
| + | |||
| + | == MixinExtras Flowchart == | ||
| + | - An IDE feature added by the [# | ||
| + | |||
| + | == @Definition == | ||
| + | - In the context of [[# | ||
| + | |||
| + | == Wildcard == | ||
| + | - In the context of Expressions, | ||
| + | |||
| + | |||
| + | == Ordinal == | ||
| + | - A discriminator which, between all valid targets once other filters and discriminators are applied, uses a zero-indexed value to select one of the remaining targets for the injector to target. | ||
| + | * Ordinals are generally a more [[# | ||
tutorial/mixin_glossary.1759136661.txt.gz · Last modified: 2025/09/29 09:04 by gauntrecluse