- * groovyscript.wiki.{@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName() VirtualizedRegistry#getName()}.note{index of note in array}
+ * groovyscript.wiki.{@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName()
+ * VirtualizedRegistry#getName()}.note{index of note in array}
*
*
* @return localization key for the admonition description
@@ -36,7 +36,8 @@
/**
* The type of Admonition.
* The Admonition type controls the symbol, color, and default title.
- * The title may be overridden by enabling {@link #hasTitle()}, after which the value of {@link #title()} will control the title.
+ * The title may be overridden by enabling {@link #hasTitle()}, after which the value of {@link #title()} will control the
+ * title.
*
* @return the type of Admonition, controlling symbol, color, and default title, defaults to {@link Type#NOTE}
* @see Type
@@ -47,12 +48,14 @@
* If {@link #hasTitle()} is enabled, overrides the title set by the type in {@link #type()}. When it is an empty string
* the title will be cleared and the title bar will be removed from the Admonition.
*
- * @return title of the Admonition, with an empty string clears the default title set by the time, defaults to clearing the title
+ * @return title of the Admonition, with an empty string clears the default title set by the time, defaults to clearing the
+ * title
*/
String title() default "";
/**
- * Controls if the title set by {@link #title()} is applied and overrides the default title set by the type in {@link #type()}.
+ * Controls if the title set by {@link #title()} is applied and overrides the default title set by the type in
+ * {@link #type()}.
*
* @return enables the custom {@link #title()}, defaults to {@code false}
*/
@@ -68,11 +71,13 @@ enum Format {
*/
STANDARD,
/**
- * A box which can be toggled between only rendering the title and the full text. Defaults to the collapsed form (only the title visible).
+ * A box which can be toggled between only rendering the title and the full text. Defaults to the collapsed form (only the
+ * title visible).
*/
COLLAPSED,
/**
- * A box which can be toggled between only rendering the title and the full text. Defaults to the expanded form (both title and text visible).
+ * A box which can be toggled between only rendering the title and the full text. Defaults to the expanded form (both
+ * title and text visible).
*/
EXPANDED
}
@@ -86,6 +91,7 @@ enum Format {
* name | - *symbol | - *key | - *
---|---|---|
GT | - *> | - *groovyscript.wiki.greater_than | - *
GTE | - *>= | - *groovyscript.wiki.greater_than_or_equal_to | - *
EQ | - *== | - *groovyscript.wiki.equal_to | - *
LTE | - *<= | - *groovyscript.wiki.less_than_or_equal_to | - *
LT | - *< | - *groovyscript.wiki.less_than | - *
NOT | - *!= | - *groovyscript.wiki.not | - *
name | + *symbol | + *key | + *
GT | + *> | + *groovyscript.wiki.greater_than | + *
GTE | + *>= | + *groovyscript.wiki.greater_than_or_equal_to | + *
EQ | + *== | + *groovyscript.wiki.equal_to | + *
LTE | + *<= | + *groovyscript.wiki.less_than_or_equal_to | + *
LT | + *< | + *groovyscript.wiki.less_than | + *
NOT | + *!= | + *groovyscript.wiki.not | + *
* /*()*{@literal /}
*
- * and then the actual text of the comment should be in an {@link #annotations()}. Multiple comments can be inserted, and replace the comment as expected.
+ * and then the actual text of the comment should be in an {@link #annotations()}. Multiple comments can be inserted, and
+ * replace the comment as expected.
*
* @return a string that will generate valid code when processed
*/
String value() default "";
/**
- * As imports must be added to the top of the file, any imports must be split out and explicitly noted for the example(s) to function.
- * Some imports are imported to all files by default via {@link com.cleanroommc.groovyscript.sandbox.GroovyScriptSandbox#getImportCustomizer() GroovyScriptSandbox#getImportCustomizer()}.
+ * As imports must be added to the top of the file, any imports must be split out and explicitly noted for the example(s) to
+ * function.
+ * Some imports are imported to all files by default via
+ * {@link com.cleanroommc.groovyscript.sandbox.GroovyScriptSandbox#getImportCustomizer()
+ * GroovyScriptSandbox#getImportCustomizer()}.
* /*()*{@literal /}
, or /*()!*{@literal /}
, with the {@code !} controlling if the surrounding comment is rendered, with
+ * /*()*{@literal /}
, or /*()!*{@literal /}
, with the {@code !} controlling if the surrounding
+ * comment is rendered, with
* {@code !} being present causing the surrounding comment characters to be removed./*()!*{@literal /}
should be used./*()*{@literal /}
or /*()!*{@literal /}
to create annotations for the wiki
+ * @return an array of strings which will replace /*()*{@literal /}
or /*()!*{@literal /}
to create
+ * annotations for the wiki
*/
String[] annotations() default {};
/**
* Some examples may conflict with each other, or it may be otherwise beneficial for the code to the commented by default,
* yet still remain in the examples file.
- * A common example of this is {@code removeAll()} methods, which may remove entries required for other examples, causing errors when
+ * A common example of this is {@code removeAll()} methods, which may remove entries required for other examples, causing
+ * errors when
* the full file is run.
*
* @return if the code in the examples should be commented, defaults to {@code false}
@@ -87,7 +96,8 @@
/**
* Priority of the method, relative to other methods in the same class.
- * Priorities sort entries such that lowest is first, then commented examples are last, then number of examples, then the natural order of the first example.
+ * Priorities sort entries such that lowest is first, then commented examples are last, then number of examples, then the
+ * natural order of the first example.
*
* @return the example priority (relative to other examples for the same method or Recipe Builder)
*/
diff --git a/src/main/java/com/cleanroommc/groovyscript/api/documentation/annotations/MethodDescription.java b/src/main/java/com/cleanroommc/groovyscript/api/documentation/annotations/MethodDescription.java
index b8f105091..0ee3cc73a 100644
--- a/src/main/java/com/cleanroommc/groovyscript/api/documentation/annotations/MethodDescription.java
+++ b/src/main/java/com/cleanroommc/groovyscript/api/documentation/annotations/MethodDescription.java
@@ -9,23 +9,26 @@
/**
* Documentation information for generic methods of a registry.
- * groovyscript.wiki.{@link com.cleanroommc.groovyscript.compat.mods.GroovyContainer#getModId() GroovyContainer#getModId()}.{@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName() VirtualizedRegistry#getName()}.{@link Method#getName()}
- *
- *
+ * groovyscript.wiki.{@link com.cleanroommc.groovyscript.compat.mods.GroovyContainer#getModId()
+ * GroovyContainer#getModId()}.{@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName()
+ * VirtualizedRegistry#getName()}.{@link Method#getName()}
+ *
+ * {@link net.minecraft.client.resources.I18n#format(String, Object...) I18n.format(description())}
* groovyscript.wiki.{@link com.cleanroommc.groovyscript.compat.mods.GroovyContainer#getModId() GroovyContainer#getModId()}.{@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName() VirtualizedRegistry#getName()}.{@link Method#getName()}
.
+ * groovyscript.wiki.{@link com.cleanroommc.groovyscript.compat.mods.GroovyContainer#getModId()
+ * GroovyContainer#getModId()}.{@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName()
+ * VirtualizedRegistry#getName()}.{@link Method#getName()}
.
* Then, if that does not have a lang key defined, it will attempt to use a global lang key based on the method name
* groovyscript.wiki.{@link Method#getName()}
* if that also does not have a lang key defined, will log a missing key in the {@code groovy.log} file.
@@ -53,10 +58,12 @@
Example[] example() default {};
/**
- * Determines if the method is used to add an entry to the registry, remove an entry from the registry, or simply get information about the registry.
+ * Determines if the method is used to add an entry to the registry, remove an entry from the registry, or simply get
+ * information about the registry.
* Defaults to {@code Type.REMOVAL}
*
- * @return if the method adds entries, removes entries, or is purely a query of information. Defaults to removes entries ({@link Type#REMOVAL})
+ * @return if the method adds entries, removes entries, or is purely a query of information. Defaults to removes entries
+ * ({@link Type#REMOVAL})
* @see Type
*/
Type type() default Type.REMOVAL;
@@ -76,19 +83,22 @@
enum Type {
/**
- * Instructs that the method neither adds nor removes entries from the registry, and only checks information about the registry.
+ * Instructs that the method neither adds nor removes entries from the registry, and only checks information about the
+ * registry.
* Often used in removing entries matching complex requirements that are not otherwise supported.
*/
QUERY,
/**
- * Instructs that the method adds entries to the registry, indicating it should be placed in the ADDITION category on the wiki and
+ * Instructs that the method adds entries to the registry, indicating it should be placed in the ADDITION category on the
+ * wiki and
* below {@linkplain #REMOVAL}-type methods in examples files.
*/
ADDITION,
/**
- * Instructs that the method removes entries to the registry, indicating it should be placed in the REMOVAL category on the wiki and
+ * Instructs that the method removes entries to the registry, indicating it should be placed in the REMOVAL category on
+ * the wiki and
* above {@linkplain #ADDITION}-type methods in examples files.
*/
REMOVAL,
diff --git a/src/main/java/com/cleanroommc/groovyscript/api/documentation/annotations/Property.java b/src/main/java/com/cleanroommc/groovyscript/api/documentation/annotations/Property.java
index a345ecb09..75afc4c3a 100644
--- a/src/main/java/com/cleanroommc/groovyscript/api/documentation/annotations/Property.java
+++ b/src/main/java/com/cleanroommc/groovyscript/api/documentation/annotations/Property.java
@@ -6,54 +6,66 @@
/**
* Functions in one of three ways depending on what the annotation is attached to:
* * Elements: *
- * groovyscript.wiki.{@link com.cleanroommc.groovyscript.compat.mods.GroovyContainer#getModId() GroovyContainer#getModId()}.{@link Field#getName()}.value
- *
- * and states what the property does.
- *
+ * groovyscript.wiki.{@link com.cleanroommc.groovyscript.compat.mods.GroovyContainer#getModId()
+ * GroovyContainer#getModId()}.{@link Field#getName()}.value
+ *
+ * and states what the property does.
+ *
- * groovyscript.wiki.{@link com.cleanroommc.groovyscript.compat.mods.GroovyContainer#getModId() GroovyContainer#getModId()}.{@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName() VirtualizedRegistry#getName()}.{@link Field#getName()}.value
+ * groovyscript.wiki.{@link com.cleanroommc.groovyscript.compat.mods.GroovyContainer#getModId()
+ * GroovyContainer#getModId()}.{@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName()
+ * VirtualizedRegistry#getName()}.{@link Field#getName()}.value
*
*
* @return localization key for what the target field will accomplish
@@ -61,18 +73,22 @@
String value() default "";
/**
- * If this {@link Property} annotation is attached to a field, this element is set to the name of the field they are attached to.
- * When annotated on a field already, this should not be set or be set to the field name. Any other string will generate a warning.
+ * If this {@link Property} annotation is attached to a field, this element is set to the name of the field they are attached
+ * to.
+ * When annotated on a field already, this should not be set or be set to the field name. Any other string will generate a
+ * warning.
*
* @return the target property, if not annotated to a field.
*/
String property() default "";
/**
- * The default value of the property. Only needs to be declared if the default value is different from the default value created by a new object of that type.
+ * The default value of the property. Only needs to be declared if the default value is different from the default value
+ * created by a new object of that type.
* For instance, "0" is the default value for {@code int}s, and so does not have to be declared.
*
- * @return what the default value is, defaults to {@code false}, {@code 0}, {@code 0.0f}, {@code "null"}, etc depending on the property class.
+ * @return what the default value is, defaults to {@code false}, {@code 0}, {@code 0.0f}, {@code "null"}, etc depending on the
+ * property class.
* @see com.cleanroommc.groovyscript.documentation.Builder#defaultValueConverter
*/
@SuppressWarnings("JavadocReference")
@@ -84,32 +100,32 @@
* validation | - *code | - *
---|---|
x == 1 |
- * valid = @Comp("1") |
- *
x != 1 |
- * valid = @Comp(value = "1", type = Comp.Type.NOT) |
- *
x != null |
- * valid = @Comp(value = "null", type = Comp.Type.NOT) |
- *
x > 0 |
- * valid = @Comp(value = "0", type = Comp.Type.GT) |
- *
x >= 0 && x <= 5 |
- * valid = {{@literal @}Comp(value = "0", type = Comp.Type.GTE), @Comp(value = "5", type = Comp.Type.LTE)} |
- *
validation | + *code | + *
x == 1 |
+ * valid = @Comp("1") |
+ *
x != 1 |
+ * valid = @Comp(value = "1", type = Comp.Type.NOT) |
+ *
x != null |
+ * valid = @Comp(value = "null", type = Comp.Type.NOT) |
+ *
x > 0 |
+ * valid = @Comp(value = "0", type = Comp.Type.GT) |
+ *
x >= 0 && x <= 5 |
+ * valid = {{@literal @}Comp(value = "0", type = Comp.Type.GTE), @Comp(value = "5", type =
+ * Comp.Type.LTE)} |
+ *
- * groovyscript.wiki.{@link com.cleanroommc.groovyscript.compat.mods.GroovyContainer#getModId() GroovyContainer#getModId()}.{@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName() VirtualizedRegistry#getName()}.{@link Field#getName()}
- *
- *
+ * groovyscript.wiki.{@link com.cleanroommc.groovyscript.compat.mods.GroovyContainer#getModId()
+ * GroovyContainer#getModId()}.{@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName()
+ * VirtualizedRegistry#getName()}.{@link Field#getName()}
+ *
+ * groovyscript.wiki.{@link com.cleanroommc.groovyscript.compat.mods.GroovyContainer#getModId() GroovyContainer#getModId()}.{@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName() VirtualizedRegistry#getName()}.title
- * groovyscript.wiki.{@link com.cleanroommc.groovyscript.compat.mods.GroovyContainer#getModId() GroovyContainer#getModId()}.{@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName() VirtualizedRegistry#getName()}.description
- * groovyscript.wiki.{@link com.cleanroommc.groovyscript.compat.mods.GroovyContainer#getModId()
+ * GroovyContainer#getModId()}.{@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName()
+ * VirtualizedRegistry#getName()}.title
+ * groovyscript.wiki.{@link com.cleanroommc.groovyscript.compat.mods.GroovyContainer#getModId()
+ * GroovyContainer#getModId()}.{@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName()
+ * VirtualizedRegistry#getName()}.description
+ *
- * groovyscript.wiki.{@link com.cleanroommc.groovyscript.compat.mods.GroovyContainer#getModId() GroovyContainer#getModId()}.{@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName() VirtualizedRegistry#getName()}.title
+ * groovyscript.wiki.{@link com.cleanroommc.groovyscript.compat.mods.GroovyContainer#getModId()
+ * GroovyContainer#getModId()}.{@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName()
+ * VirtualizedRegistry#getName()}.title
*
*
* @return localization key for the compat name
@@ -47,7 +57,9 @@
/**
* The localization key for the description of the compat, will default to generating
*
- * groovyscript.wiki.{@link com.cleanroommc.groovyscript.compat.mods.GroovyContainer#getModId() GroovyContainer#getModId()}.{@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName() VirtualizedRegistry#getName()}.description
+ * groovyscript.wiki.{@link com.cleanroommc.groovyscript.compat.mods.GroovyContainer#getModId()
+ * GroovyContainer#getModId()}.{@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName()
+ * VirtualizedRegistry#getName()}.description
*
*
* @return localization key for the compat description
@@ -55,13 +67,17 @@
String description() default "";
/**
- * Controls what the parser is to transform the java class file into a link so the source code may be accessed from the documentation.
- * Addons should create their own instance of the {@link com.cleanroommc.groovyscript.documentation.linkgenerator.ILinkGenerator ILinkGenerator} class,
+ * Controls what the parser is to transform the java class file into a link so the source code may be accessed from the
+ * documentation.
+ * Addons should create their own instance of the
+ * {@link com.cleanroommc.groovyscript.documentation.linkgenerator.ILinkGenerator ILinkGenerator} class,
* preferably with the name of the generator being set to the modid.
- * If it is not set or a corresponding LinkGenerator does not exist, the {@link com.cleanroommc.groovyscript.documentation.linkgenerator.ILinkGenerator ILinkGenerator}
- * converts to a link towards CleanroomMC's Groovyscript repo set to view the repo at a specific version tag.
+ * If it is not set or a corresponding LinkGenerator does not exist, the
+ * {@link com.cleanroommc.groovyscript.documentation.linkgenerator.ILinkGenerator ILinkGenerator}
+ * converts to a link towards CleanroomMC's Groovyscript repo set to view the repo at a specific version tag.
*
- * @return a string corresponding to a {@link com.cleanroommc.groovyscript.documentation.linkgenerator.ILinkGenerator ILinkGenerator}, which controls how the source code link is generated.
+ * @return a string corresponding to a {@link com.cleanroommc.groovyscript.documentation.linkgenerator.ILinkGenerator
+ * ILinkGenerator}, which controls how the source code link is generated.
* @see com.cleanroommc.groovyscript.documentation.linkgenerator.ILinkGenerator ILinkGenerator
*/
String linkGenerator() default "";
@@ -105,7 +121,8 @@
/**
* Priority of the registry, relative to other registries of the same mod.
- * Priorities sort entries such that lowest is first, then by the natural order of {@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName() VirtualizedRegistry#getName()}
+ * Priorities sort entries such that lowest is first, then by the natural order of
+ * {@link com.cleanroommc.groovyscript.registry.VirtualizedRegistry#getName() VirtualizedRegistry#getName()}
*
* @return the registry priority
*/
@@ -113,11 +130,14 @@
/**
* How reloadable the compat is: