4. Mindennek az alapja
A legfontosabb, hogy a kód
„öndokumentált” legyen.
http://perro.si/spaghetti-code
5. Mindennek az alapja
/**
* A difficult, but
* frequently used function.
*
* @param a the first parameter
* @param q the second parameter
* @returns the result
*/
myClass.doIt = function(a, q) {
/* ... */ return result;
}
6. Mindennek az alapja
<?php
class TestResource extends Resource {
/**
* A GET kérés kezelése.
* @param Request kérés
* @return Response
*/
function post($request) {
//...
7. JsDoc toolkit
“JsDoc Toolkit is an application
for automatically generating
documentation
from commented
JavaScript source
code.”
(Michael Mathews)
9. JsDoc toolkit
“As of 27 June 2010 the JsDoc Toolkit
Version 2 project is no longer
accepting any new Feature Request
tickets. Any Feature Request tickets
submitted after that date will be
deleted without comment.”
Használják ma is: Google’s Closure
Linter, InteliJ IDEA, Eclipse, SproutCore…
10. docco
“Docco is a quick-and-
dirty, hundred-line-
long, literate-programming-
style documentation
generator.”
Azt mutatja, hogyan
működik, nem azt, hogy
11. NaturalDocs
“Natural Docs is an open-source
documentation generator for
multiple programming
languages.
You document your code in a
natural syntax that reads like
plain English.”
12. NaturalDocs
Function: Multiply
Multiplies two integers.
Parameters:
x - The first integer.
y - The second integer.
Returns:
The two integers multiplied together.
See Also:
<Divide>