xp-framework/rfc — Issue #25: Replace text.apidoc with new API
Author: thekid
Created: 2011-10-17 15:39:19+00:00
State: closed
Labels: framework, implemented

Scope of Change
====
The old API in text.apidoc will be deprecated and replaced by the API
from experiments/arena/apidoc.

Rationale
====
The old API doc is slow, hard to extend and does not offer sufficient
access to all program elements.

Functionality
====
Functionality is achieved by extending the abstract class "Doclet".

de.thekid.doclets.NameListDoclet class
----

```php
classes->hasNext()) {
$classdoc= &$root->classes->next();
echo '- ', $classdoc->qualifiedName();
if ($classdoc->superclass) {
echo ' extends ', $classdoc->superclass->qualifiedName();
}
echo "\n";
}
}
}
?>
```

doclet.php
----

```php
value('doclet'));

RootDoc::start($class->newInstance(), $p);
// }}}
?>
```

Usage
----

```
$ php doclet.php --doclet=de.thekid.doclets.NameListDoclet lang.Object lang.XPClass

```

Output
----

```
- lang.Object
- lang.XPClass extends lang.Object

```

Security considerations
====
n/a

Speed impact
====
The new API, though way more powerful, is actually quite a bit faster due to the
underlying parser.

Dependencies
====
n/a

Related documents
====
- Javadoc 5.0 Tool
http://java.sun.com/j2se/1.5.0/docs/guide/javadoc/