3 Adnotacje JavaDoc
Wybrane TAG'i Adnotacji w Java.
Tag & Parametr |
Opis |
Zastoowanie |
Od |
@author John Smith |
Opisuje autora. |
Class, Interface, Enum |
|
{@docRoot} |
Reprezentuje relatywną ścieżkę do katalogu głównego generowanego dokumentu z dowolnej wygenerowanej strony |
Class, Interface, Enum, Field, Method |
|
@version version |
Dostarcza wersję oprogramowania. Maksymalnie jedną na klasę / interfejs |
Class, Interface, Enum |
|
@since since-text |
Opisuje, kiedy (wersja) wprowadzono funkcjonalność |
Class, Interface, Enum, Field, Method |
|
@see reference |
Dostarcza odnośnik do innego elementu dokumentacji |
Class, Interface, Enum, Field, Method |
|
@param name description |
Opisuje parametr metody. |
Method |
|
@return description |
Opisuje zwracaną wartość. |
Method |
|
@exception classname description @throws classname description |
Opisuje wyjątek możliwy do rzucenia przez metodę. |
Method |
|
@deprecated description |
Wskazuje, że metoda jest przestarzała. |
Class, Interface, Enum, Field, Method |
|
{@inheritDoc} |
Kopiuje opis z nadpisywanej metody. |
Overriding Method |
1.4.0 |
{@link reference} |
Linkuje do innego symbolu. |
Class, Interface, Enum, Field, Method |
|
{@linkplain reference} |
Identical to {@link}, except the link's label is displayed in plain text than code font. |
Class, Interface, Enum, Field, Method |
|
{@value #STATIC_FIELD} |
Return the value of a static field. |
Static Field |
1.4.0 |
{@code literal} |
Formats literal text in the code font. It is equivalent to <code>{@literal}</code>. |
Class, Interface, Enum, Field, Method |
1.5.0 |
{@literal literal} |
Denotes literal text. The enclosed text is interpreted as not containing HTML markup or nested javadoc tags. |
Class, Interface, Enum, Field, Method |
1.5.0 |
{@serial literal} |
Used in the doc comment for a default serializable field. |
Field |
|
{@serialData literal} |
Documents the data written by the writeObject( ) or writeExternal( ) methods. |
Field, Method |
|
{@serialField literal} |
Documents an ObjectStreamField component. |
Field |
|