doc:scratchpad:pecldocs
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
doc:scratchpad:pecldocs [2008/12/04 00:48] – added link to howto philip | doc:scratchpad:pecldocs [2017/09/22 13:28] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 14: | Line 14: | ||
$ cd phpdoc/ | $ cd phpdoc/ | ||
$ php docgen.php --help | $ php docgen.php --help | ||
- | $ php docgen.php --output tmp --extension extname | + | $ php docgen.php --output tmp --extension extname |
</ | </ | ||
- | This will create a directory named ' | + | This will create a directory named ' |
* Read the Validating Changes section of the [[doc: | * Read the Validating Changes section of the [[doc: | ||
Line 24: | Line 24: | ||
If the user account lacks phpdoc karma, write the documentation list (phpdoc@lists.php.net) and put in the request. While doing this, show the created documentation and eventually karma will be granted. | If the user account lacks phpdoc karma, write the documentation list (phpdoc@lists.php.net) and put in the request. While doing this, show the created documentation and eventually karma will be granted. | ||
+ | ==== What the PECL extension requires ==== | ||
+ | Because docgen utilizes Reflection to create the skeletons, it's necessary for the extensions code to use arginfo structs to provide parameter information. | ||
+ | |||
+ | For example, the count() source code has this: | ||
+ | < | ||
+ | ZEND_BEGIN_ARG_INFO_EX(arginfo_count, | ||
+ | ZEND_ARG_INFO(0, | ||
+ | ZEND_ARG_INFO(0, | ||
+ | ZEND_END_ARG_INFO() | ||
+ | </ | ||
+ | |||
+ | Which provides Reflection the information, | ||
+ | |||
+ | < | ||
+ | $ php --rf count | ||
+ | |||
+ | Function [ < | ||
+ | |||
+ | - Parameters [2] { | ||
+ | | ||
+ | | ||
+ | } | ||
+ | } | ||
+ | </ | ||
==== Other Notes ==== | ==== Other Notes ==== | ||
* Docgen may be used to generate specific documentation too, like for individual classes and functions | * Docgen may be used to generate specific documentation too, like for individual classes and functions | ||
- | * Because the documentation generator utilizes Reflection to generate the skeletons, | + | * Write in third person voice (no " |
+ | * XML is single spaced | ||
+ | * Don't commit | ||
+ | * Skeletons generate several sections | ||
+ | * Don't commit auto-generated files from build time (like entities.*) | ||
+ | * Feel free to ask phpdoc@lists.php.net for code review, or #php.doc on Efnet | ||
+ | * When testing, be sure to add to manual.xml.in in phpdoc/ otherwise it won't be validated/ |
doc/scratchpad/pecldocs.1228351714.txt.gz · Last modified: 2017/09/22 13:28 (external edit)