java-docs

Writes and reviews Javadoc for Java types and members following standard conventions.

Updated Sep 10, 2026
One-click install
npx skills add https://github.com/serpro-workshop-fortaleza/sifap-modernization-paula --skill java-docs-serpro-workshop-fortaleza
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: java-docs
Source: https://github.com/serpro-workshop-fortaleza/sifap-modernization-paula/tree/main/.github/skills/java-docs
Command: npx skills add https://github.com/serpro-workshop-fortaleza/sifap-modernization-paula --skill java-docs-serpro-workshop-fortaleza

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Java codebases often ship with missing, inconsistent, or incorrect Javadoc, leaving public APIs without a clear contract for callers. This Skill applies Javadoc best practices so every public and protected member of a Java 21 + Spring Boot codebase has a correct, consistent documentation contract. ## Core Features & Use Cases - Javadoc authoring and review: Generates summary sentences, @param, @return, @throws, @since, and @see tags in the correct order for classes, methods, and generic type parameters. - Java 21 record documentation: Documents record components via @param on the type instead of adding accessor methods. - Inline tag conventions: Applies {@code}, {@link}, {@linkplain}, {@inheritDoc}, and <pre>{@code ...}</pre> blocks for multi-line examples. - Use Case: Before publishing a service module, ask the assistant to review a package and add missing @param/@return/@throws tags so mvn javadoc:javadoc builds without warnings. ## Quick Start Review the Javadoc in this Java service class and add missing @param, @return, and @throws tags following standard conventions.

Frequently Asked Questions about java-docs

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I write Javadoc for a Java method?

Start with a summary sentence in third-person verb form ending with a period, then add @param for each parameter, @return for non-void methods, and @throws for each documented exception. Keep tags in declaration order and describe the contract, not the implementation.

How to document Java 21 records with Javadoc?

Place the Javadoc on the record type itself and document each component with a @param tag. Do not add accessor methods just to attach Javadoc to them, since record components are documented at the type level.

Which Java members require Javadoc comments?

Public and protected members require Javadoc because they form the API contract. Package-private members need documentation only when intent is unclear, and private members only for genuinely complex logic.

What is the correct order of Javadoc block tags?

Order block tags as @param in declaration order, followed by @return, then @throws. A missing or out-of-order @param is the most common defect found in Javadoc reviews.

When should I use {@code} versus {@link} in Javadoc?

Use {@code} for identifiers, keywords, and literals like null or Optional.empty() in body text. Use {@link Type#member} to create cross-reference links to related types or members, and {@linkplain} for plain-text link rendering.

Why does mvn javadoc:javadoc fail with warnings?

Warnings typically come from missing @param or @return tags, malformed inline tags, or unescaped generics in examples. Wrap multi-line examples in <pre>{@code ...}</pre> so angle brackets render literally, then rebuild.