Re: phpDoc @static tag usage and traduction/implementation

From: Date: Sun, 09 Dec 2007 18:07:52 +0000
Subject: Re: phpDoc @static tag usage and traduction/implementation
References: 1  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-48733@lists.php.net to get a copy of this message
On Dec 9, 2007 11:23 AM, Laurent Laville <pear@laurent-laville.org> wrote: > Hi all, > > Due to a bug opened [1] for phpDocumentor, I'd like point of view of all > phpdoc community users before to reply to feedback asked by Chuck Burgess > (hope you understand Chuck). :) no problem at all... I'm clueless about these tags in DocBook, so my question is really "teach me teach me" :P I just noticed that your bug shows usage of "notstatic" and "shouldstatic", whereas the XML converter in PhpDocumentor only shows occurrences of "notstatic" and "canstatic". So, the first question in my mind is "does * shouldstatic* instead be *canstatic*", or vice versa... > > > While I've tried to generate XML DocBook for PEAR Info manual pages I > found that a method with @static phpdoc tag [2] was well not rendered. > > > /** > * Sets PEAR HTTP Proxy Server Address > * > * @param string $proxy PEAR HTTP Proxy Server Address > * > * @static > * @return bool > * @access public > * @since 1.0.6 > */ > function setProxy($proxy) > { > $res = define('PEAR_INFO_PROXY', $proxy); > return $res; > } > > With phpDocumentor 1.4.0, we got actually: > > <refsect1 id="package.pear.pear-info.pear-info.setproxy.note"> > &title.note; > &note.notstatic; > </refsect1> > > While I expected to have : > > <refsect1 id="package.pear.pear-info.pear-info.setproxy.note"> > &title.note; > &note.shouldstatic; > </refsect1> > > Entities are declared into "language-snippets.ent" file > > <!ENTITY note.notstatic '<simpara>This function can not be called > statically.</simpara>'> > > > My question, related to question of Chuck : > > What is the difference between, and in what condition shouldstatic must > replace canstatic ? : > > <!ENTITY note.canstatic '<simpara>This function can be called > statically.</simpara>'> > > <!ENTITY note.shouldstatic '<simpara>This function should be called > statically.</simpara>'> > So, are you saying that DocBook has *both* the *shouldstatic* tag as well as *canstatic*? If that's the case, then I think I need to *add* handling for the *shouldstatic* tag into the XML converter. > > > My function can of course be call statically and not ; What is the > recommandation : > 1. mandatory => shouldstatic > 2. as we want => canstatic > 3. other > > Thanks in advance for answers ! > > Laurent > > [1] http://pear.php.net/bugs/bug.php?id=11540 > [2] > > > http://pear.php.net/manual/en/package.pear.pear-info.pear-info.setproxy.php > > -- > PEAR Development Mailing List (http://pear.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > -- CRB Let me introduce you to my very own DMCA-protected encryption key: BC 1B 64 4A 8D DE 49 E8 C3 7D CC EE 1A AD EE F5 (compliments of Freedom-to-Tinker http://www.freedom-to-tinker.com/?p=1155)

« previous php.pear.dev (#48733) next »