{"id":18834302,"url":"https://github.com/crafttweaker/crafttweaker-annotation-processors","last_synced_at":"2026-01-26T09:30:18.254Z","repository":{"id":93098704,"uuid":"475138263","full_name":"CraftTweaker/CraftTweaker-Annotation-Processors","owner":"CraftTweaker","description":null,"archived":false,"fork":false,"pushed_at":"2025-02-01T23:59:06.000Z","size":392,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-02-02T00:26:37.433Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/CraftTweaker.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-03-28T18:53:56.000Z","updated_at":"2025-02-01T23:59:11.000Z","dependencies_parsed_at":null,"dependency_job_id":"f3f35dc6-d659-4ff7-85f0-2ecdee1dbb87","html_url":"https://github.com/CraftTweaker/CraftTweaker-Annotation-Processors","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CraftTweaker%2FCraftTweaker-Annotation-Processors","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CraftTweaker%2FCraftTweaker-Annotation-Processors/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CraftTweaker%2FCraftTweaker-Annotation-Processors/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CraftTweaker%2FCraftTweaker-Annotation-Processors/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CraftTweaker","download_url":"https://codeload.github.com/CraftTweaker/CraftTweaker-Annotation-Processors/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239768923,"owners_count":19693764,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-08T02:11:50.576Z","updated_at":"2026-01-26T09:30:18.211Z","avatar_url":"https://github.com/CraftTweaker.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CraftTweaker-Annotation-Processors\n\nJava Annotation Processors used to validate and generate documentation for the CraftTweaker project.\n\n## Introduction\n\nCraftTweaker-Annotation-Processors is a Java Annotation Processor that validates and generates documentation for CraftTweaker related projects.\n\n## Using the Annotation Processor\n\nBuilds are published to the [BlameJared maven](https://maven.blamejared.com), to use them in your build, first add the BlameJared maven to your `repositories` block in your build.gradle file like so:\n\n```groovy\nrepositories {\n    maven { \n        url = 'https://maven.blamejared.com'\n        name = 'BlameJared Maven'\n    }\n}\n```\n\nThen add the Annotation Processor in your `dependencies` block like so:\n\n```groovy\ndependencies {\n    annotationProcessor('com.blamejared.crafttweaker:Crafttweaker_Annotation_Processors:[VERSION]')\n}\n```\n\nThe latest version is current: [![Maven](https://img.shields.io/maven-metadata/v?color=C71A36\u0026label=Latest%20version\u0026logo=Latest%20version\u0026metadataUrl=https%3A%2F%2Fmaven.blamejared.com%2Fcom%2Fblamejared%2Fcrafttweaker%2FCrafttweaker_Annotation_Processors%2Fmaven-metadata.xml\u0026style=flat-square)](https://maven.blamejared.com/com/blamejared/crafttweaker/Crafttweaker_Annotation_Processors/)\n\nYou can then configure the annotation processor like so:\n```groovy\ncompileJava {\n    options.compilerArgs \u003c\u003c \"-Acrafttweaker.processor.document.output_directory=${file('docsOut')}\"\n}\n```\n\nIf you are using a multiloader project such as the [MultiLoader-Template](https://github.com/jaredlll08/MultiLoader-Template), then it \nis advised to add the Annotation Processor to all sources and use the following options, which will handle merging the generated files.\n```groovy\ntasks {\n    compileJava {\n        options.compilerArgs \u003c\u003c \"-Acrafttweaker.processor.document.output_directory=${project.rootProject.file('docsOut')}\"\n        options.compilerArgs \u003c\u003c \"-Acrafttweaker.processor.document.multi_source=true\"\n    }\n}\n```\n\n## Validation\n\nOnce you have the Annotation Processor in your project, it will automatically validate your ZenScript related classes and methods, ensuring it meets the runtime requirements of the annotation, such as:\n- @BracketResolver methods has a string parameter and a non-void return type\n- Exposed member names do not conflict with ZenScript keywords (such as `get` or `set`)\n- @Optional parameters appear at the end of the parameters\n\n## Automatic Documentation\n\nThe Annotation Processor will look for all classes with the `@Document` annotation and generate a file containing all the exposed members in the class, using their JavaDoc for extra comments.\n\nThe Annotation Processor also lets you provide examples for parameters using a new javadoc tag, `@docParam \u003cparam_name\u003e \u003cexample\u003e`, which can also go on the class itself using `this` as the `param_name`, like so: `@docParam this myObject`\n\nHere is an example of what a documented class may look like:\n```java\nimport com.blamejared.crafttweaker_annotations.annotations.Document;\nimport org.openzen.zencode.java.ZenCodeType;\n\nimport java.util.function.Predicate;\n\n/**\n * @docParam this myTestObject\n */\n@Document(\"vanilla/api/util/Test\")\npublic class Test {\n    \n    /**\n     * Does a thing with the provided parameters\n     * @param first the first parameter\n     * @param second the second parameter\n     * @param third the third parameter\n     *\n     * @docParam first 1\n     * @docParam second \"hello world\"\n     * @docParam third (str) =\u003e str.length == 0\n     */\n    @ZenCodeType.Method\n    public static void doThing(int first, String second, Predicate\u003cString\u003e third) {}\n    \n}\n```\n\nMost JavaDoc tags such as `@return`, `@see`, and `@deprecated` are supported and will be retained in the generated files.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcrafttweaker%2Fcrafttweaker-annotation-processors","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcrafttweaker%2Fcrafttweaker-annotation-processors","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcrafttweaker%2Fcrafttweaker-annotation-processors/lists"}