Skip to content

Latest commit

Β 

History

History
58 lines (51 loc) Β· 2 KB

[20200918]_javadoc.md

File metadata and controls

58 lines (51 loc) Β· 2 KB

javadoc

  • java μ†ŒμŠ€ μ½”λ“œμ—μ„œ html ν˜•μ‹μ˜ λ¬Έμ„œλ₯Ό μƒμ„±ν•˜κΈ° μœ„ν•œ document generator

ν˜•μ‹

  • /** */
/**
 * 여기에 주석을 μž‘μ„±
 */

νƒœκ·Έ

Order of Tags

Include tags in the following order:

Tags Description
@author classes and interfaces only, required
@version classes and interfaces only, required. See footnote 1
@param methods and constructors only
@return methods only
@exception @throws is a synonym added in Javadoc 1.2
@see
@since
@serial or @serialField or @serialData
@deprecated see How and When To Deprecate APIs

Example

/**
 * javadoc 예제λ₯Ό μœ„ν•œ 클래슀
 * @author yjo
 * @version 1.0
 */
public class Practice {

    /**
     * 두 수λ₯Ό 더함
     * @param a λŒ€μƒ 숫자
     * @param b 더할 숫자
     * @return 두 수의 ν•©
     */
    public int sum(int a, int b) { 
        return a + b; 
    }
}

생성

  • μ•„λž˜ λͺ…λ Ήμ–΄ 이용
javadoc -d doc Practice.java
  • ν•΄λ‹Ή 디렉터리에 doc/Practice.html 생성됨 Practice.html 1 Practice.html 2