Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
@throwsアプリケーションが複数の理由で同じ例外をスローする場合、複数の javadoc タグを使用できますか? 例えば:
@throws
@throws UserException if issue 1 happened @throws UserException if issue 2 happened @throws UserException if issue 3 happened
JavaDoc標準で禁止されていますか?
Java 6、7、および 8 で有効です。次のドキュメントを参照してください。
複数の @throws タグを、同じまたは異なる例外の特定のドキュメント コメントで使用できます。
(emph. mine)
これをテストしたところ、生成された JavaDoc には 3 つの @throws がすべて含まれています。