<?xml version="1.0" encoding="utf-8" ?>

<rss version="2.0" 
   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
   xmlns:admin="http://webns.net/mvcb/"
   xmlns:dc="http://purl.org/dc/elements/1.1/"
   xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
   xmlns:wfw="http://wellformedweb.org/CommentAPI/"
   xmlns:content="http://purl.org/rss/1.0/modules/content/"
   >
<channel>
    <title>Manuel Pichler - php_depend</title>
    <link>http://www.manuel-pichler.de/</link>
    <description>Trust is good, (phpUnder)Control is better.</description>
    <dc:language>en</dc:language>
    <generator>Serendipity 1.3.1 - http://www.s9y.org/</generator>
    
    

<item>
    <title>PHP_Depend-0.9.11 released</title>
    <link>http://www.manuel-pichler.de/archives/82-PHP_Depend-0.9.11-released.html</link>
            <category>php</category>
            <category>php_depend</category>
            <category>phpugdo</category>
            <category>projects</category>
    
    <comments>http://www.manuel-pichler.de/archives/82-PHP_Depend-0.9.11-released.html#comments</comments>
    <wfw:comment>http://www.manuel-pichler.de/wfwcomment.php?cid=82</wfw:comment>

    <slash:comments>0</slash:comments>
    <wfw:commentRss>http://www.manuel-pichler.de/rss.php?version=2.0&amp;type=comments&amp;cid=82</wfw:commentRss>
    

    <author>nospam@example.com (Manuel Pichler)</author>
    <content:encoded>
    &lt;p&gt;
  I have just released version 0.9.11 of PHP_Depend. It contains a few bug fixes and improvements for PHP_Depend.
&lt;/p&gt;
&lt;ul&gt;
  &lt;li&gt;
    Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2291&amp;amp;entry_id=82&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/118&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/118&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#118&lt;/a&gt;: Calculation of the Number Of Overwritten Methods is wrong. Fixed in svn revision &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2292&amp;amp;entry_id=82&quot; title=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/1112&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/browse_code/revision/1112&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#1112&lt;/a&gt;.
  &lt;/li&gt;
  &lt;li&gt;
    Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2293&amp;amp;entry_id=82&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/119&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/119&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#119&lt;/a&gt;: Three test cases fail for all PHP versions prior to 5.3. Fixed in svn revision &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2294&amp;amp;entry_id=82&quot; title=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/1114&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/browse_code/revision/1114&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#1114&lt;/a&gt;.
  &lt;/li&gt;
  &lt;li&gt;
    Implemented &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2295&amp;amp;entry_id=82&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/121&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/121&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#121&lt;/a&gt;: Parse arguments of the ASTForeachStatement. Implemented in svn revision &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2296&amp;amp;entry_id=82&quot; title=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/1115&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/browse_code/revision/1115&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#1115&lt;/a&gt;.
  &lt;/li&gt;
  &lt;li&gt;
    Critical issue in PHP_Depend&#039;s temporary data cache fixed. This bug only occured when running several instances of PHP_Depend in parallel. In this setup the used cache key &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2297&amp;amp;entry_id=82&quot; title=&quot;http://php.net/spl_object_hash&quot;  onmouseover=&quot;window.status=&#039;http://php.net/spl_object_hash&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;spl_object_hash()&lt;/a&gt; has caused a corrupted cache, because different php process instances have written different data to the same cache file.
  &lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;p&gt;
  As always, you can get the latest PHP_Depend version from its PEAR channel: &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2298&amp;amp;entry_id=82&quot; title=&quot;http://pear.pdepend.org&quot;  onmouseover=&quot;window.status=&#039;http://pear.pdepend.org&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;pear.pdepend.org&lt;/a&gt;:
&lt;/p&gt;
&lt;pre&gt;
  mapi&amp;#64;arwen ~ $ pear channel-discover pear.pdepend.org
  mapi&amp;#64;arwen ~ $ pear install pdepend/PHP_Depend-beta
&lt;/pre&gt;
&lt;p&gt;
  Or you can fetch the sources from the subversion reposition:
&lt;/p&gt;
&lt;pre&gt;
  mapi&amp;#64;arwen ~ $ svn co http://svn.pdepend.org/branches/0.9.0/
&lt;/pre&gt;
&lt;p&gt;
  And additionally you can find a repository mirror on github:
&lt;/p&gt;
&lt;pre&gt;
  mapi&amp;#64;arwen ~ $ git clone git://github.com/manuelpichler/pdepend.git
&lt;/pre&gt; 
    </content:encoded>

    <pubDate>Tue, 02 Mar 2010 21:08:03 +0100</pubDate>
    <guid isPermaLink="false">http://www.manuel-pichler.de/archives/82-guid.html</guid>
    <category>bug fix</category>
<category>php_depend</category>
<category>release announcement</category>
<category>software metrics</category>
<category>static code analysis</category>

</item>
<item>
    <title>PHP_Depend-0.9.10 released</title>
    <link>http://www.manuel-pichler.de/archives/81-PHP_Depend-0.9.10-released.html</link>
            <category>php</category>
            <category>php_depend</category>
            <category>phpugdo</category>
            <category>planet-php</category>
            <category>projects</category>
    
    <comments>http://www.manuel-pichler.de/archives/81-PHP_Depend-0.9.10-released.html#comments</comments>
    <wfw:comment>http://www.manuel-pichler.de/wfwcomment.php?cid=81</wfw:comment>

    <slash:comments>0</slash:comments>
    <wfw:commentRss>http://www.manuel-pichler.de/rss.php?version=2.0&amp;type=comments&amp;cid=81</wfw:commentRss>
    

    <author>nospam@example.com (Manuel Pichler)</author>
    <content:encoded>
    &lt;p&gt;
I have just released the bug fix version 0.9.10 of PHP_Depend. This
release contains several bug fixes and improvements for PHP_Depend.
&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Implemented &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2272&amp;amp;entry_id=81&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/72&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/72&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#72&lt;/a&gt;__: Add NOAM, NOOM and NOCC metrics. Implemented in svn revision &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2273&amp;amp;entry_id=81&quot; title=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/1084&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/browse_code/revision/1084&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#1084&lt;/a&gt;.&lt;/li&gt;
  &lt;li&gt;Implemented &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2274&amp;amp;entry_id=81&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/74&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/74&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#74&lt;/a&gt;: Make CRAP-index available. Implemented in svn revision &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2275&amp;amp;entry_id=81&quot; title=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/1063&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/browse_code/revision/1063&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#1063&lt;/a&gt;.&lt;/li&gt;
  &lt;li&gt;Implemented &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2276&amp;amp;entry_id=81&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/105&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/105&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#105&lt;/a&gt;: Support for deep search implement. Implemented in svn revision &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2277&amp;amp;entry_id=81&quot; title=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/1078&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/browse_code/revision/1078&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#1078&lt;/a&gt;.&lt;/li&gt;
  &lt;li&gt;Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2278&amp;amp;entry_id=81&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/106&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/106&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#106&lt;/a&gt;: Filter algorithm is broken for namespaced internal classes. Fixed in svn revision &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2279&amp;amp;entry_id=81&quot; title=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/1039&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/browse_code/revision/1039&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#1039&lt;/a&gt;.&lt;/li&gt;
  &lt;li&gt;Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2280&amp;amp;entry_id=81&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/110&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/110&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#110&lt;/a&gt;: Duplicate &quot;coupling&quot; directory in test code. Fixed in svn revision &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2281&amp;amp;entry_id=81&quot; title=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/1032&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/browse_code/revision/1032&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#1032&lt;/a&gt;.&lt;/li&gt;
  &lt;li&gt;Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2282&amp;amp;entry_id=81&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/111&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/111&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#111&lt;/a&gt;: Dynamic Strings are treated as literal strings. Fixed in svn revision &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2283&amp;amp;entry_id=81&quot; title=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/1037&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/browse_code/revision/1037&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#1037&lt;/a&gt;. &lt;/li&gt;
  &lt;li&gt;Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2284&amp;amp;entry_id=81&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/114&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/114&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#114&lt;/a&gt;: Parsing error caused by complex string expressions fixed. Fixed in svn revision &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2285&amp;amp;entry_id=81&quot; title=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/1068&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/browse_code/revision/1068&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#1068&lt;/a&gt;.&lt;/li&gt;
  &lt;li&gt;Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2286&amp;amp;entry_id=81&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/115&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/115&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#115&lt;/a&gt;: Summary and PHPUnit Report lists unknown classes. Fixed in svn revision &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2287&amp;amp;entry_id=81&quot; title=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/1101&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/browse_code/revision/1101&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#1101&lt;/a&gt;.&lt;/li&gt;
  &lt;li&gt;Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2288&amp;amp;entry_id=81&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/116&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/116&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#116&lt;/a&gt;: Returns reference results in parsing error. Fixed in svn revision &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2289&amp;amp;entry_id=81&quot; title=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/1090&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/browse_code/revision/1090&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#1090&lt;/a&gt;.&lt;/li&gt;
  &lt;li&gt;Performance intensive calculation result cached.&lt;/li&gt;
  &lt;li&gt;Test code restructured and improved.&lt;/li&gt;
  &lt;li&gt;Concurrency issue for parallel running pdepend instances fixed.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;
As always, you can get the latest PHP_Depend version from its PEAR channel: &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2290&amp;amp;entry_id=81&quot; title=&quot;http://pear.pdepend.org&quot;  onmouseover=&quot;window.status=&#039;http://pear.pdepend.org&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;pear.pdepend.org&lt;/a&gt;:
&lt;/p&gt;
&lt;pre&gt;
  mapi@arwen ~ $ pear channel-discover pear.pdepend.org
  mapi@arwen ~ $ pear install pdepend/PHP_Depend-beta
&lt;/pre&gt;
&lt;p&gt;
Or you can fetch the sources from the subversion reposition:
&lt;/p&gt;
&lt;pre&gt;
  mapi@arwen ~ $ svn co http://svn.pdepend.org/branches/0.9.0/
&lt;/pre&gt;
&lt;p&gt;
And additionally you can find a repository mirror on github:
&lt;/p&gt;
&lt;pre&gt;
  mapi@arwen ~ $ git clone git://github.com/manuelpichler/pdepend.git
&lt;/pre&gt; 
    </content:encoded>

    <pubDate>Tue, 23 Feb 2010 20:36:01 +0100</pubDate>
    <guid isPermaLink="false">http://www.manuel-pichler.de/archives/81-guid.html</guid>
    <category>php</category>
<category>php5</category>
<category>php_depend</category>
<category>quality assurance</category>
<category>release announcement</category>
<category>software metrics</category>
<category>static code analysis</category>

</item>
<item>
    <title>PHP Mess Detector 0.2 released.</title>
    <link>http://www.manuel-pichler.de/archives/73-PHP-Mess-Detector-0.2-released..html</link>
            <category>php</category>
            <category>php_depend</category>
            <category>phpmd</category>
            <category>phpugdo</category>
            <category>planet-php</category>
            <category>projects</category>
    
    <comments>http://www.manuel-pichler.de/archives/73-PHP-Mess-Detector-0.2-released..html#comments</comments>
    <wfw:comment>http://www.manuel-pichler.de/wfwcomment.php?cid=73</wfw:comment>

    <slash:comments>2</slash:comments>
    <wfw:commentRss>http://www.manuel-pichler.de/rss.php?version=2.0&amp;type=comments&amp;cid=73</wfw:commentRss>
    

    <author>nospam@example.com (Manuel Pichler)</author>
    <content:encoded>
    &lt;p&gt;
  Today I have released version 0.2.0 of the &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2211&amp;amp;entry_id=73&quot; title=&quot;http://phpmd.org&quot;  onmouseover=&quot;window.status=&#039;http://phpmd.org&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;PHP Mess Detector&lt;/a&gt; or short &lt;em&gt;PHPMD&lt;/em&gt;. PHPMD is a simple, customizable and user friendly frontend application for &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2212&amp;amp;entry_id=73&quot; title=&quot;http://pdepend.org&quot;  onmouseover=&quot;window.status=&#039;http://pdepend.org&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;PHP_Depend&lt;/a&gt;. It takes the raw metrics measured by PHP_Depend, compares them with appropriate thresholds and generates a report that lists those software artifacts with potential problems. Such a report can be taken as a basis for human code audits or you can use it as input for an automated build/reporting tool.
&lt;/p&gt;

&lt;p&gt;
  Most concepts behind PHPMD are based on those of the well known Java Tool &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2213&amp;amp;entry_id=73&quot; title=&quot;http://pmd.sourceforge.net&quot;  onmouseover=&quot;window.status=&#039;http://pmd.sourceforge.net&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;PMD&lt;/a&gt;. It uses so called rule set files to organize different sets of rules. There are two purposes that are accomplished by these xml files. The first is to create custom sets of rules which fulfills the projects requirements. The second purpose is the configuration of each rule with thresholds, warning messages and other things. The format of these files is totally borrowed from PMD, so that the reuse existing rule sets in multi language environments should be easy. At the moment PHPMD has two build-in rule sets. One that detects software artifacts with high code size, and the second one detects unused code in your software.
&lt;/p&gt;

&lt;p&gt;
  Now lets start with a small &lt;em&gt;How to use it&lt;/em&gt;. PHPMD can be called from the command line by typing &lt;code&gt;phpmd&lt;/code&gt;, which prints a general help text.
&lt;/p&gt;

&lt;pre&gt;
mapi@arwen ~ $ phpmd 
Mandatory arguments:
1) A php source code filename or directory
2) A report format
3) A ruleset filename or a comma-separated string of ...

Optional arguments that may be put after the mandato...
--minimumpriority: rule priority threshold; rules with ...
--reportfile: send report output to a file; default to ...
--extensions: comma-separated string of valid source ...
--ignore: comma-separated string of patterns that are ...
&lt;/pre&gt;

&lt;p&gt;
  Now let&#039;s call PHPMD on its own source, with a simple text report on STDOUT and the &lt;code&gt;codesize&lt;/code&gt; ruleset:
&lt;/p&gt;

&lt;pre&gt;
mapi@arwen ~ $ phpmd ~/phpmd/source text codesize

/home/mapi/phpmd/source/PHP/PMD/RuleSetFactory.php:66 \
  This class has too many methods, consider refactoring it.
/home/mapi/phpmd/source/PHP/PMD/RuleSetFactory.php:267 \
  The method _parseSingleRuleNode() has a Cyclomatic \
  Complexity of 11.
/home/mapi/phpmd/source/PHP/PMD/RuleSetFactory.php:326 \
  The method _parseRuleReferenceNode() has a Cyclomatic \
  Complexity of 10.
&lt;/pre&gt;

&lt;p&gt;
  The &lt;code&gt;--reportfile&lt;/code&gt; option can be used, to redirect the report output into a file. So let us repeat the previous example that writes the report into a file, additionally uses the &lt;code&gt;unusedcode&lt;/code&gt; rule and changes the format from text to xml.
&lt;/p&gt;

&lt;pre&gt;
mapi@arwen ~ $ phpmd ~/phpmd/source xml codesize,unusedcode \
  --reportfile ~/pmd.xml
mapi@arwen ~ $ cat ~/pmd.xml 
&amp;lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; ?&amp;gt;
&amp;lt;pmd version=&quot;@package_version@&quot; timestamp=&quot;...&quot;&amp;gt;
  &amp;lt;file name=&quot;.../source/PHP/PMD/RuleSetFactory.php&quot;&amp;gt;
    &amp;lt;violation beginline=&quot;66&quot; endline=&quot;417&quot; rule=&quot;TooManyMet ...&amp;gt;
      This class has too many methods, consider refactoring it.
    &amp;lt;/violation&amp;gt;
    &amp;lt;violation beginline=&quot;267&quot; endline=&quot;315&quot; rule=&quot;Cyclomati ...&amp;gt;
      Method _parseSingleRule() has a Cyclomatic Complexity of 11.
    &amp;lt;/violation&amp;gt;
    &amp;lt;violation beginline=&quot;326&quot; endline=&quot;367&quot; rule=&quot;Cyclomati ...&amp;gt;
      Method _parseRuleReference() has a Cyclomatic Complexity of 10.
    &amp;lt;/violation&amp;gt;
  &amp;lt;/file&amp;gt;
&amp;lt;/pmd&amp;gt;
&lt;/pre&gt;

&lt;p&gt;
  This xml file is compatible with those files generated by &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2213&amp;amp;entry_id=73&quot; title=&quot;http://pmd.sourceforge.net&quot;  onmouseover=&quot;window.status=&#039;http://pmd.sourceforge.net&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;PMD&lt;/a&gt; and &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2219&amp;amp;entry_id=73&quot; title=&quot;http://phpunit.de&quot;  onmouseover=&quot;window.status=&#039;http://phpunit.de&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;PHPUnit&#039;s&lt;/a&gt; deprecated &lt;code&gt;--log-pmd&lt;/code&gt; option. So that it should be no problem to use this files in existing environments like &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2215&amp;amp;entry_id=73&quot; title=&quot;https://hudson.dev.java.net/&quot;  onmouseover=&quot;window.status=&#039;https://hudson.dev.java.net/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;Hudson&lt;/a&gt;, &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2216&amp;amp;entry_id=73&quot; title=&quot;http://cruisecontrol.sourceforge.net/&quot;  onmouseover=&quot;window.status=&#039;http://cruisecontrol.sourceforge.net/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;CruiseControl&lt;/a&gt; or &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2217&amp;amp;entry_id=73&quot; title=&quot;http://sonar.codehaus.org/&quot;  onmouseover=&quot;window.status=&#039;http://sonar.codehaus.org/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;Sonar&lt;/a&gt;.
&lt;/p&gt;

&lt;p&gt;
  Currently PHPMD supports the following three different report formats: Text, HTML and XML. And it has the build-in rule sets: &lt;code&gt;codesize&lt;/code&gt; and &lt;code&gt;unusedcode&lt;/code&gt;.
&lt;/p&gt;

&lt;p&gt;
  You can get the latest PHPMD version from its PEAR channel: &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2218&amp;amp;entry_id=73&quot; title=&quot;http://pear.phpmd.org&quot;  onmouseover=&quot;window.status=&#039;http://pear.phpmd.org&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;pear.phpmd.org&lt;/a&gt; 
&lt;/p&gt;

&lt;pre&gt;
mapi@arwen ~ $ pear channel-discover pear.pdepend.org
mapi@arwen ~ $ pear channel-discover pear.phpmd.org
mapi@arwen ~ $ pear install --alldeps phpmd/PHP_PMD-alpha
&lt;/pre&gt; 
    </content:encoded>

    <pubDate>Tue, 29 Dec 2009 23:40:00 +0100</pubDate>
    <guid isPermaLink="false">http://www.manuel-pichler.de/archives/73-guid.html</guid>
    <category>phpmd</category>
<category>php_depend</category>
<category>pmd</category>
<category>quality assurance</category>
<category>static code analysis</category>

</item>
<item>
    <title>PHP_Depend-0.9.9 released</title>
    <link>http://www.manuel-pichler.de/archives/71-PHP_Depend-0.9.9-released.html</link>
            <category>php</category>
            <category>php_depend</category>
            <category>phpugdo</category>
            <category>projects</category>
    
    <comments>http://www.manuel-pichler.de/archives/71-PHP_Depend-0.9.9-released.html#comments</comments>
    <wfw:comment>http://www.manuel-pichler.de/wfwcomment.php?cid=71</wfw:comment>

    <slash:comments>0</slash:comments>
    <wfw:commentRss>http://www.manuel-pichler.de/rss.php?version=2.0&amp;type=comments&amp;cid=71</wfw:commentRss>
    

    <author>nospam@example.com (Manuel Pichler)</author>
    <content:encoded>
    &lt;p&gt;
  I have just released the bug fix version 0.9.9 of PHP_Depend.
&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2207&amp;amp;entry_id=71&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/108&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/108&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#108&lt;/a&gt;: Parser doesn&#039;t set start/end line/column on variables, fixed in svn revision &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2208&amp;amp;entry_id=71&quot; title=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/1015&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/browse_code/revision/1015&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#1015&lt;/a&gt;.&lt;/li&gt;
  &lt;li&gt;Implemented &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2209&amp;amp;entry_id=71&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/104&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/104&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#104&lt;/a&gt;: Add isStatic() method on ASTMemberPrimaryPrefix node, implemented in svn revision &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2210&amp;amp;entry_id=71&quot; title=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/1013&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/browse_code/revision/1013&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#1013&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;br /&gt;
&lt;p&gt;
   You can get the latest PHP_Depend version from its PEAR channel: pear.pdepend.org 
&lt;/p&gt;

&lt;pre&gt;
mapi@arwen ~ $ pear channel-discover pear.pdepend.org
mapi@arwen ~ $ pear install pdepend/PHP_Depend-beta
&lt;/pre&gt; 
    </content:encoded>

    <pubDate>Sat, 26 Dec 2009 23:26:37 +0100</pubDate>
    <guid isPermaLink="false">http://www.manuel-pichler.de/archives/71-guid.html</guid>
    <category>bug fix</category>
<category>php_depend</category>
<category>release announcement</category>

</item>
<item>
    <title>PHP_Depend-0.9.8 released</title>
    <link>http://www.manuel-pichler.de/archives/70-PHP_Depend-0.9.8-released.html</link>
            <category>php</category>
            <category>php_depend</category>
            <category>phpugdo</category>
            <category>projects</category>
    
    <comments>http://www.manuel-pichler.de/archives/70-PHP_Depend-0.9.8-released.html#comments</comments>
    <wfw:comment>http://www.manuel-pichler.de/wfwcomment.php?cid=70</wfw:comment>

    <slash:comments>0</slash:comments>
    <wfw:commentRss>http://www.manuel-pichler.de/rss.php?version=2.0&amp;type=comments&amp;cid=70</wfw:commentRss>
    

    <author>nospam@example.com (Manuel Pichler)</author>
    <content:encoded>
    &lt;p&gt;
Today I released PHP_Depend 0.9.8, which contains many bug fixes and improvements. This release will be the base version for a new tool called &lt;a href=&quot;http://tracker.pdepend.org/php_mess_detector/browse_code&quot;&gt;PHPMD&lt;/a&gt;. PHPMD is a frontend that reports critical and suspect software artifacts in a project, based on the metrics measured with PHP_Depend. It aims to be a PHP equivalent to the well known java tool &lt;a href=&quot;http://pmd.sourceforge.net/&quot;&gt;PMD&lt;/a&gt;.
&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Closed &lt;a href=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/93&quot;&gt;#93&lt;/a&gt;: Implement an assignment expression, Implemented in svn revision &lt;a href=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/992&quot;&gt;#992&lt;/a&gt;.&lt;/li&gt;
  &lt;li&gt;Fixed &lt;a href=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/94&quot;&gt;#94&lt;/a&gt;: Parser throws exception for closures that return by reference, fixed in svn revision &lt;a href=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/962&quot;&gt;#962&lt;/a&gt;.&lt;/li&gt;
  &lt;li&gt;Fixed &lt;a href=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/98&quot;&gt;#98&lt;/a&gt;: Functions with an invalid signature result in an inconsistent object graph, fixed in svn revision &lt;a href=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/986&quot;&gt;#986&lt;/a&gt;.&lt;/li&gt;
  &lt;li&gt;Fixed &lt;a href=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/102&quot;&gt;#102&lt;/a&gt;: Namespace keyword in type-hint is broken, fixed in svn revision &lt;a href=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/1010&quot;&gt;#1010&lt;/a&gt;.&lt;/li&gt;
  &lt;li&gt;Fixed &lt;a href=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/103&quot;&gt;#103&lt;/a&gt;: The parser does not handle all strings as parameter default value correct, fixed in svn revision &lt;a href=&quot;http://tracker.pdepend.org/pdepend/browse_code/revision/1009&quot;&gt;#1009&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;br /&gt;
&lt;p&gt;
   You can get the latest PHP_Depend version from its PEAR channel: pear.pdepend.org 
&lt;/p&gt;

&lt;pre&gt;
mapi@arwen ~ $ pear channel-discover pear.pdepend.org
mapi@arwen ~ $ pear install pdepend/PHP_Depend-beta
&lt;/pre&gt;

 
    </content:encoded>

    <pubDate>Mon, 14 Dec 2009 17:21:00 +0100</pubDate>
    <guid isPermaLink="false">http://www.manuel-pichler.de/archives/70-guid.html</guid>
    <category>bug fix</category>
<category>phpmd</category>
<category>php_depend</category>
<category>pmd</category>
<category>release announcement</category>

</item>
<item>
    <title>PHP_Depend PEAR Channel switched to Pirum</title>
    <link>http://www.manuel-pichler.de/archives/67-PHP_Depend-PEAR-Channel-switched-to-Pirum.html</link>
            <category>php</category>
            <category>php_depend</category>
            <category>phpugdo</category>
            <category>planet-php</category>
    
    <comments>http://www.manuel-pichler.de/archives/67-PHP_Depend-PEAR-Channel-switched-to-Pirum.html#comments</comments>
    <wfw:comment>http://www.manuel-pichler.de/wfwcomment.php?cid=67</wfw:comment>

    <slash:comments>3</slash:comments>
    <wfw:commentRss>http://www.manuel-pichler.de/rss.php?version=2.0&amp;type=comments&amp;cid=67</wfw:commentRss>
    

    <author>nospam@example.com (Manuel Pichler)</author>
    <content:encoded>
    &lt;p&gt;
  Today &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2160&amp;amp;entry_id=67&quot; title=&quot;http://fabien.potencier.org/&quot;  onmouseover=&quot;window.status=&#039;http://fabien.potencier.org/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;Fabien Potencier&lt;/a&gt; &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2165&amp;amp;entry_id=67&quot; title=&quot;http://fabien.potencier.org/article/38/pirum-the-simple-pear-channel-server-manager&quot;  onmouseover=&quot;window.status=&#039;http://fabien.potencier.org/article/38/pirum-the-simple-pear-channel-server-manager&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;announced&lt;/a&gt; the first relase of the &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2161&amp;amp;entry_id=67&quot; title=&quot;http://pear.php.net&quot;  onmouseover=&quot;window.status=&#039;http://pear.php.net&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;PEAR&lt;/a&gt; Channel server &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2162&amp;amp;entry_id=67&quot; title=&quot;http://pirum-project.org/&quot;  onmouseover=&quot;window.status=&#039;http://pirum-project.org/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;Pirum&lt;/a&gt;. The great benefit of this Channel server is that it provides a simple shell script to publish new PEAR package releases, a feature that I missed in the previously used &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2163&amp;amp;entry_id=67&quot; title=&quot;http://pear.chiaraquartet.net/&quot;  onmouseover=&quot;window.status=&#039;http://pear.chiaraquartet.net/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;Chiara PEAR Server&lt;/a&gt;. Pirum will make it really easy to publish new package versions through a simple build script &lt;img src=&quot;http://www.manuel-pichler.de/templates/default/img/emoticons/smile.png&quot; alt=&quot;:-)&quot; style=&quot;display: inline; vertical-align: bottom;&quot; class=&quot;emoticon&quot; /&gt;
&lt;/p&gt;

&lt;p&gt;
  The setup was quick done, following the &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2162&amp;amp;entry_id=67&quot; title=&quot;http://pirum-project.org/&quot;  onmouseover=&quot;window.status=&#039;http://pirum-project.org/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;instructions&lt;/a&gt; on the pirum website, and importing the existing package files worked like a charm. The only problem I encountered was that both channel server implementations use a different directory structure. Pirum stores all the XML descriptors under a directory named &lt;i&gt;/rest&lt;/i&gt;, while my Chiara Server installation has used &lt;i&gt;/Chiara_PEAR_Server_REST&lt;/i&gt;, so that a first call to &lt;code&gt;pear upgrade&lt;/code&gt; resulted in the following error:
&lt;/p&gt;

&lt;pre&gt;
manu@arwen ~ $ pear upgrade
Error getting channel info from pear.pdepend.org: \
File http://pear.pdepend.org:80/Chiara_PEAR_Server_REST/p/packages.xml \
not valid (received: HTTP/1.1 404 Not Found)
&lt;/pre&gt;

&lt;p&gt;
  But a simple 301 redirect makes this software transition transparent for the &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2166&amp;amp;entry_id=67&quot; title=&quot;http://pdepend.org&quot;  onmouseover=&quot;window.status=&#039;http://pdepend.org&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;PHP_Depend&lt;/a&gt; users. So when you will also switch to Pirum you should keep this in mind and test your channel server with an existing/configured local pear installation.
&lt;/p&gt;

&lt;p&gt;
  Finally, thanks to Fabien for this nitty-gritty tool, which will speed up the deployment process of PEAR packages, at least for me.
&lt;/p&gt; 
    </content:encoded>

    <pubDate>Sat, 28 Nov 2009 14:00:23 +0100</pubDate>
    <guid isPermaLink="false">http://www.manuel-pichler.de/archives/67-guid.html</guid>
    <category>fabien potencier</category>
<category>php</category>
<category>php_depend</category>
<category>pirum</category>

</item>
<item>
    <title>PHP_Depend jumps on the D-BUS</title>
    <link>http://www.manuel-pichler.de/archives/66-PHP_Depend-jumps-on-the-D-BUS.html</link>
            <category>php</category>
            <category>php_depend</category>
            <category>phpugdo</category>
            <category>planet-php</category>
    
    <comments>http://www.manuel-pichler.de/archives/66-PHP_Depend-jumps-on-the-D-BUS.html#comments</comments>
    <wfw:comment>http://www.manuel-pichler.de/wfwcomment.php?cid=66</wfw:comment>

    <slash:comments>1</slash:comments>
    <wfw:commentRss>http://www.manuel-pichler.de/rss.php?version=2.0&amp;type=comments&amp;cid=66</wfw:commentRss>
    

    <author>nospam@example.com (Manuel Pichler)</author>
    <content:encoded>
    &lt;p&gt;
  Today I had the chance to visit &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2158&amp;amp;entry_id=66&quot; title=&quot;http://derickrethans.nl/&quot;  onmouseover=&quot;window.status=&#039;http://derickrethans.nl/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;Derick&#039;s&lt;/a&gt; IPC talk &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2154&amp;amp;entry_id=66&quot; title=&quot;http://it-republik.de/konferenzen/ext_scripts/v2/php/sessions-popup.php?module=ipc09&amp;amp;amp;id=11621&quot;  onmouseover=&quot;window.status=&#039;http://it-republik.de/konferenzen/ext_scripts/v2/php/sessions-popup.php?module=ipc09&amp;amp;amp;id=11621&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;PHP on the D-BUS&lt;/a&gt;. Beside the fact that it was an exciting talk, it inspired me to implement a small, but nice feature for &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2155&amp;amp;entry_id=66&quot; title=&quot;http://pdepend.org&quot;  onmouseover=&quot;window.status=&#039;http://pdepend.org&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;PHP_Depend&lt;/a&gt; using the &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2156&amp;amp;entry_id=66&quot; title=&quot;http://pecl.php.net/package/DBus&quot;  onmouseover=&quot;window.status=&#039;http://pecl.php.net/package/DBus&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;pecl/dbus&lt;/a&gt; extension.
&lt;/p&gt;

&lt;div class=&quot;serendipity_imageComment_center&quot; style=&quot;width: 400px&quot;&gt;&lt;div class=&quot;serendipity_imageComment_img&quot;&gt;&lt;!-- s9ymdb:59 --&gt;&lt;img class=&quot;serendipity_image_center&quot; width=&quot;400&quot; height=&quot;200&quot; src=&quot;http://www.manuel-pichler.de/uploads/php_depend/pdepend-jumps-on-the-dbus.png&quot; alt=&quot;&quot;  /&gt;&lt;/div&gt;&lt;div class=&quot;serendipity_imageComment_txt&quot;&gt;PHP_Depend jumps on the D-BUS&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;
  Sometimes the parsing and analysis process of PHP_Depend can consume a lot of time to finish, so I always put the shell aside and do something different. Normally I take a look at the shell every few minutes to check if the process has finished, but it also happens that I totally forget that I have started a PHP_Depend process on my system. So I need something that says to me, &lt;em&gt;&quot;Hey, mapi PHP_Depend has finished its job...&quot;&lt;/em&gt;, and here comes D-BUS in the game.
&lt;/p&gt;
&lt;p&gt;
  With D-BUS it is really simple to send a message to a desktop notification panel, as it is available for desktop environments like Gnome or KDE. To use D-BUS in your php applications you must checkout the source code of &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2156&amp;amp;entry_id=66&quot; title=&quot;http://pecl.php.net/package/DBus&quot;  onmouseover=&quot;window.status=&#039;http://pecl.php.net/package/DBus&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;pecl/dbus&lt;/a&gt; from the &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2159&amp;amp;entry_id=66&quot; title=&quot;http://svn.php.net/repository/pecl/dbus/trunk&quot;  onmouseover=&quot;window.status=&#039;http://svn.php.net/repository/pecl/dbus/trunk&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;svn repository&lt;/a&gt; and compile it for your php installation.
&lt;/p&gt;

&lt;pre&gt;
mapi@arwen ~ $ svn co http://svn.php.net/repository/pecl/dbus/trunk \
               pecl-dbus
mapi@arwen ~ $ cd pecl-dbus
mapi@arwen pecl-dbus $ phpize
mapi@arwen pecl-dbus $ ./configure
mapi@arwen pecl-dbus $ make
mapi@arwen pecl-dbus $ sudo make install
&lt;/pre&gt;

&lt;p&gt;
That&#039;s it. Now you should see the &lt;em&gt;--notify-me&lt;/em&gt; option when you open PHP_Depend&#039;s help screen.
&lt;/p&gt;

&lt;pre&gt;
mapi@arwen ~ $ ~/pdepend/pdepend.php --help
PHP_Depend @package_version@ by Manuel Pichler

// ... snipp ...

  --debug                   Prints debugging information.
  --help                    Print this help text.
  --version                 Print the current version.
  --notify-me               Show a notification after analysis.
  -d key[=value]            Sets a php.ini value.
&lt;/pre&gt;

&lt;p&gt;
  Now you can add this option to your normal PHP_Depend command and it will show a notification window with the number of analyzed files and the time the process took.
&lt;/p&gt;

&lt;pre&gt;
mapi@arwen ~ $ ~/pdepend/pdepend.php --summary-xml=/tmp/summary.xml \
                                       --notify-me \
                                       ~/pdepend/PHP
&lt;/pre&gt;

&lt;p&gt;
  For the moment this feature is only available through the &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2157&amp;amp;entry_id=66&quot; title=&quot;http://svn.pdepend.org/branches/0.9.0&quot;  onmouseover=&quot;window.status=&#039;http://svn.pdepend.org/branches/0.9.0&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;0.9.0 branch&lt;/a&gt; of PHP_Depend and not as a PEAR package.
&lt;/p&gt; 
    </content:encoded>

    <pubDate>Wed, 18 Nov 2009 18:47:00 +0100</pubDate>
    <guid isPermaLink="false">http://www.manuel-pichler.de/archives/66-guid.html</guid>
    <category>dbus</category>
<category>derick</category>
<category>fun</category>
<category>php_depend</category>

</item>
<item>
    <title>Softwaremetriken verstehen und nutzen</title>
    <link>http://www.manuel-pichler.de/archives/65-Softwaremetriken-verstehen-und-nutzen.html</link>
            <category>php</category>
            <category>php_depend</category>
            <category>phpugdo</category>
    
    <comments>http://www.manuel-pichler.de/archives/65-Softwaremetriken-verstehen-und-nutzen.html#comments</comments>
    <wfw:comment>http://www.manuel-pichler.de/wfwcomment.php?cid=65</wfw:comment>

    <slash:comments>0</slash:comments>
    <wfw:commentRss>http://www.manuel-pichler.de/rss.php?version=2.0&amp;type=comments&amp;cid=65</wfw:commentRss>
    

    <author>nospam@example.com (Manuel Pichler)</author>
    <content:encoded>
    &lt;p&gt;
  Today &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2148&amp;amp;entry_id=65&quot; title=&quot;http://kore-nordmann.de&quot;  onmouseover=&quot;window.status=&#039;http://kore-nordmann.de&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;Kore&lt;/a&gt; and I gave a talk on software metrics at the &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2149&amp;amp;entry_id=65&quot; title=&quot;http://it-republik.de/php/phpconference09/&quot;  onmouseover=&quot;window.status=&#039;http://it-republik.de/php/phpconference09/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;International PHP Conference 2009&lt;/a&gt; in Karlsruhe. You can download our german slides &lt;a href=&quot;http://www.manuel-pichler.de/stuff/slides/2009-11-17-ipc-softwaremetriken-verstehen-und-nutzen.pdf&quot;&gt;here&lt;/a&gt;.
&lt;/p&gt;
&lt;p&gt;
  It was a really nice talk and the feedback from the audience and on &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2151&amp;amp;entry_id=65&quot; title=&quot;http://twitter.com/search?q=ipc09#search?q=ipc09%20metrics&quot;  onmouseover=&quot;window.status=&#039;http://twitter.com/search?q=ipc09#search?q=ipc09%20metrics&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;twitter&lt;/a&gt; was really positive. So, if you liked the talk please comment on &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2152&amp;amp;entry_id=65&quot; title=&quot;http://joind.in/event/view/99&quot;  onmouseover=&quot;window.status=&#039;http://joind.in/event/view/99&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;joind.in&lt;/a&gt; later, when our slides are online.
&lt;/p&gt; 
    </content:encoded>

    <pubDate>Tue, 17 Nov 2009 14:19:00 +0100</pubDate>
    <guid isPermaLink="false">http://www.manuel-pichler.de/archives/65-guid.html</guid>
    <category>arbit</category>
<category>cyclomatic complexity</category>
<category>ipc</category>
<category>karlsruhe</category>
<category>kore</category>
<category>software metrics</category>
<category>talks</category>

</item>
<item>
    <title>My Slides from the PHP Unconference Hamburg 2009</title>
    <link>http://www.manuel-pichler.de/archives/64-My-Slides-from-the-PHP-Unconference-Hamburg-2009.html</link>
            <category>php</category>
            <category>php_depend</category>
            <category>phpugdo</category>
    
    <comments>http://www.manuel-pichler.de/archives/64-My-Slides-from-the-PHP-Unconference-Hamburg-2009.html#comments</comments>
    <wfw:comment>http://www.manuel-pichler.de/wfwcomment.php?cid=64</wfw:comment>

    <slash:comments>0</slash:comments>
    <wfw:commentRss>http://www.manuel-pichler.de/rss.php?version=2.0&amp;type=comments&amp;cid=64</wfw:commentRss>
    

    <author>nospam@example.com (Manuel Pichler)</author>
    <content:encoded>
    &lt;p&gt;
  Ok, it&#039;s day three after the famous &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2146&amp;amp;entry_id=64&quot; title=&quot;http://www.php-unconference.de/&quot;  onmouseover=&quot;window.status=&#039;http://www.php-unconference.de/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;PHP-Unconference-Hamburg&lt;/a&gt; and I still haven&#039;t found the time to write a review &lt;img src=&quot;http://www.manuel-pichler.de/templates/default/img/emoticons/sad.png&quot; alt=&quot;:-(&quot; style=&quot;display: inline; vertical-align: bottom;&quot; class=&quot;emoticon&quot; /&gt; So lets start with a big thank you to all the organizers of this great event.
&lt;/p&gt;
&lt;p&gt;
  So lets start with the &lt;a href=&quot;http://www.manuel-pichler.de/stuff/slides/2009-09-12-phpunconf-softwaremetriken-verstehen-und-nutzen.pdf&quot;&gt;slides (german)&lt;/a&gt; from my talk &lt;em&gt;Softwaremetriken verstehen und nutzen&lt;/em&gt;.
&lt;/p&gt; 
    </content:encoded>

    <pubDate>Wed, 16 Sep 2009 13:42:50 +0200</pubDate>
    <guid isPermaLink="false">http://www.manuel-pichler.de/archives/64-guid.html</guid>
    <category>hamburg</category>
<category>php</category>
<category>software metrics</category>
<category>talks</category>
<category>unconference</category>

</item>
<item>
    <title>PHP_Depend-0.9.7 Bugfix release</title>
    <link>http://www.manuel-pichler.de/archives/62-PHP_Depend-0.9.7-Bugfix-release.html</link>
            <category>php</category>
            <category>php_depend</category>
            <category>phpugdo</category>
            <category>projects</category>
    
    <comments>http://www.manuel-pichler.de/archives/62-PHP_Depend-0.9.7-Bugfix-release.html#comments</comments>
    <wfw:comment>http://www.manuel-pichler.de/wfwcomment.php?cid=62</wfw:comment>

    <slash:comments>0</slash:comments>
    <wfw:commentRss>http://www.manuel-pichler.de/rss.php?version=2.0&amp;type=comments&amp;cid=62</wfw:commentRss>
    

    <author>nospam@example.com (Manuel Pichler)</author>
    <content:encoded>
    &lt;p&gt;
  The NPath complexity calculation was  &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2145&amp;amp;entry_id=62&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/95&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot; title=&quot;#95: NPath complexity is broken in PHP_Depend 0.9.6&quot;&gt;broken&lt;/a&gt; in PHP_Depend 0.9.6. This bug was fixed in PHP_Depend 0.9.7.
&lt;/p&gt; 
    </content:encoded>

    <pubDate>Fri, 07 Aug 2009 23:24:08 +0200</pubDate>
    <guid isPermaLink="false">http://www.manuel-pichler.de/archives/62-guid.html</guid>
    <category>bug fix</category>
<category>npath complexity</category>
<category>php</category>
<category>php5</category>
<category>php_depend</category>

</item>
<item>
    <title>PHP_Depend-0.9.6 released</title>
    <link>http://www.manuel-pichler.de/archives/61-PHP_Depend-0.9.6-released.html</link>
            <category>php</category>
            <category>php_depend</category>
            <category>phpugdo</category>
            <category>planet-php</category>
            <category>projects</category>
    
    <comments>http://www.manuel-pichler.de/archives/61-PHP_Depend-0.9.6-released.html#comments</comments>
    <wfw:comment>http://www.manuel-pichler.de/wfwcomment.php?cid=61</wfw:comment>

    <slash:comments>1</slash:comments>
    <wfw:commentRss>http://www.manuel-pichler.de/rss.php?version=2.0&amp;type=comments&amp;cid=61</wfw:commentRss>
    

    <author>nospam@example.com (Manuel Pichler)</author>
    <content:encoded>
    &lt;p&gt;
Today I released PHP_Depend 0.9.6, which contains many bug fixes and improvements, but the main feature of this release is behind the scene, I have started to migrate PHP_Depend&#039;s internal system from plain &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2143&amp;amp;entry_id=61&quot;  onmouseover=&quot;window.status=&#039;http://svn.pdepend.org/branches/0.9.0/PHP/Depend/Token.php&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot; title=&quot;PHP_Depend_Token&quot;&gt;Token&lt;/a&gt; object to an &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2144&amp;amp;entry_id=61&quot;  onmouseover=&quot;window.status=&#039;http://svn.pdepend.org/branches/0.9.0/PHP/Depend/Code/ASTNode.php&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot; title=&quot;PHP_Depend_Code_ASTNode&quot;&gt;Abstract Syntax Tree&lt;/a&gt;.
&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Closed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2133&amp;amp;entry_id=61&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/57&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/57&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#57&lt;/a&gt;: Display caption for abbreviations in overview pyramid, implemented in svn revision #947.&lt;/li&gt;
  &lt;li&gt;Closed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2134&amp;amp;entry_id=61&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/80&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/80&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#80&lt;/a&gt;: Store default value for class properties.&lt;/li&gt;
  &lt;li&gt;Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2135&amp;amp;entry_id=61&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/81&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/81&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#81&lt;/a&gt;: PHP_Depend does not support comma separated property declarations, fixed in svn revision #916.&lt;/li&gt;
  &lt;li&gt;Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2136&amp;amp;entry_id=61&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/82&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/82&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#82&lt;/a&gt;: PHP_Depend does not support comma separated constant definitions, fixed in svn revision #931.&lt;/li&gt;
  &lt;li&gt;Closed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2137&amp;amp;entry_id=61&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/83&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/83&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#83&lt;/a&gt;: Make ClassOrInterfaceReference an ASTNode, implemented in svn revision #917.&lt;/li&gt;
  &lt;li&gt;Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2138&amp;amp;entry_id=61&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/87&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/87&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#87&lt;/a&gt;: The parent keyword is not accepted as parameter type hint, fixed in svn revision #925.&lt;/li&gt;
  &lt;li&gt;Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2139&amp;amp;entry_id=61&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/89&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/89&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#89&lt;/a&gt;: Coupling analyzer reports wrong results, fixed in svn revision #939&lt;/li&gt;
  &lt;li&gt;Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2140&amp;amp;entry_id=61&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/90&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/90&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#90&lt;/a&gt;: Coupling analyzer does not handle PHP 5.3 function chains, fixed in svn revision #943.&lt;/li&gt;
  &lt;li&gt;Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2141&amp;amp;entry_id=61&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/91&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/91&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#91&lt;/a&gt;: Parser throws an exception when __CLASS__ as default value of an array property, fixed in svn revision #944.&lt;/li&gt;
  &lt;li&gt;Closes &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2142&amp;amp;entry_id=61&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/92&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/92&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;#92&lt;/a&gt;: Use class constants as analyzer identifiers, implemented in svn revision #950.&lt;/li&gt;
&lt;/ul&gt;

&lt;br /&gt;
&lt;p&gt;
   You can get the latest PHP_Depend version from its PEAR channel: pear.pdepend.org 
&lt;/p&gt;

&lt;pre&gt;
mapi@arwen ~ $ pear channel-discover pear.pdepend.org
mapi@arwen ~ $ pear install pdepend/PHP_Depend-beta
&lt;/pre&gt;

 
    </content:encoded>

    <pubDate>Sun, 02 Aug 2009 21:32:00 +0200</pubDate>
    <guid isPermaLink="false">http://www.manuel-pichler.de/archives/61-guid.html</guid>
    <category>php5</category>
<category>php_depend</category>
<category>quality assurance</category>
<category>release announcement</category>

</item>
<item>
    <title>Why I love PHP</title>
    <link>http://www.manuel-pichler.de/archives/60-Why-I-love-PHP.html</link>
            <category>fun</category>
            <category>php</category>
            <category>php_depend</category>
            <category>phpugdo</category>
            <category>planet-php</category>
    
    <comments>http://www.manuel-pichler.de/archives/60-Why-I-love-PHP.html#comments</comments>
    <wfw:comment>http://www.manuel-pichler.de/wfwcomment.php?cid=60</wfw:comment>

    <slash:comments>16</slash:comments>
    <wfw:commentRss>http://www.manuel-pichler.de/rss.php?version=2.0&amp;type=comments&amp;cid=60</wfw:commentRss>
    

    <author>nospam@example.com (Manuel Pichler)</author>
    <content:encoded>
    &lt;p&gt;
  While working on &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2129&amp;amp;entry_id=60&quot;  onmouseover=&quot;window.status=&#039;http://pdepend.org/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot; title=&quot;PHP Depend - Software Metrics for PHP&quot;&gt;PHP_Depend&#039;s&lt;/a&gt; parser I realized one major reason &lt;em&gt;Why I love PHP&lt;/em&gt;, it&#039;s the flexibility of language. Even if you think you now know all ways to solve a problem, there is always one more way to solve it.
&lt;/p&gt;

&lt;div class=&quot;geshi&quot; style=&quot;text-align: left&quot;&gt;&lt;ol&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;class&lt;/span&gt; f &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; function bar&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt; echo __METHOD__, &lt;span style=&quot;color: #0000ff;&quot;&gt;&#039;()&#039;&lt;/span&gt;, PHP_EOL; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt; &lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; function __toString&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color: #0000ff;&quot;&gt;&#039;v&#039;&lt;/span&gt;; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt; &lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;class&lt;/span&gt; v &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt; function __toString&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color: #0000ff;&quot;&gt;&#039;c&#039;&lt;/span&gt;; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt; &lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;class&lt;/span&gt; m &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt; function __toString&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color: #0000ff;&quot;&gt;&#039;bar&#039;&lt;/span&gt;; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt; &lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;$c = &lt;span style=&quot;color: #0000ff;&quot;&gt;&#039;f&#039;&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;$$&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;span style=&quot;color: #0000ff;&quot;&gt;&#039;v&#039;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt; = &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;new&lt;/span&gt; $&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;string&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;new&lt;/span&gt; $&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;$v = &lt;span style=&quot;color: #0000ff;&quot;&gt;&#039;v&#039;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;$$$$$$v-&amp;gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;string&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;new&lt;/span&gt; m&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;

&lt;p&gt;
  But to be serious, don&#039;t be worried, if you don&#039;t get it.
&lt;/p&gt; 
    </content:encoded>

    <pubDate>Thu, 23 Jul 2009 19:22:09 +0200</pubDate>
    <guid isPermaLink="false">http://www.manuel-pichler.de/archives/60-guid.html</guid>
    <category>crazy</category>
<category>php</category>
<category>php5</category>
<category>phpugdo</category>
<category>php_depend</category>

</item>
<item>
    <title>The value of complexity metrics - Cyclomatic Complexity (1/2)</title>
    <link>http://www.manuel-pichler.de/archives/55-The-value-of-complexity-metrics-Cyclomatic-Complexity-12.html</link>
            <category>php</category>
            <category>php_depend</category>
            <category>phpugdo</category>
            <category>phpundercontrol</category>
            <category>planet-php</category>
            <category>projects</category>
    
    <comments>http://www.manuel-pichler.de/archives/55-The-value-of-complexity-metrics-Cyclomatic-Complexity-12.html#comments</comments>
    <wfw:comment>http://www.manuel-pichler.de/wfwcomment.php?cid=55</wfw:comment>

    <slash:comments>2</slash:comments>
    <wfw:commentRss>http://www.manuel-pichler.de/rss.php?version=2.0&amp;type=comments&amp;cid=55</wfw:commentRss>
    

    <author>nospam@example.com (Manuel Pichler)</author>
    <content:encoded>
    &lt;p&gt;
  Software metrics are currently on everyone&#039;s lips and a frequently discussed topic. There are many conference talks, blog posts and other presentations that talk about software metrics. But to me it seems as if this subject is a closed book for many developers, so I decided to write this little post about a special category of software metrics, the complexity metrics.
&lt;/p&gt;
&lt;p&gt;
  Complexity metrics are a theoretical approach to measure the subjective complexity of a &lt;em&gt;software fragment&lt;/em&gt;, where the words &lt;em&gt;software fragment&lt;/em&gt; stand for a paraphrase for functions, methods, classes and nearly every logical unit that can be found in a software system. The most prevalent procedure to calculate complexity values is static code analysis, where an application parses the raw source code of a project, counts different statements and expressions and packs up the determined results in simple classification numbers. And with this information you already know the main concepts behind most software metrics, classification numbers and counting. As you can see there is no magic behind the scene, the only thing required is a good background knowledge to interpret those values.
&lt;/p&gt;
&lt;p&gt;
The &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2124&amp;amp;entry_id=55&quot;  onmouseover=&quot;window.status=&#039;http://classes.cecs.ucf.edu/eel6883/berrios/notes/Paper%204%20(Complexity%20Measure).pdf&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot; title=&quot;Thomas J. McCabe: A Complexity Measure&quot;&gt;Cyclomatic Complexity Number&lt;/a&gt; or short CCN is the 
oldest complexity metrics. The first time this software 
metric was mentioned was 1976 by Thomas J. McCabe. This 
metric counts the available decision paths in a software 
fragment to determine its complexity. Each decision path 
starts with one of the conditional statements from the 
following list, so that it is fairly easy to detect them in
existing source code.
&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;?&lt;/li&gt;
  &lt;li&gt;case&lt;/li&gt;
  &lt;li&gt;elseif&lt;/li&gt;
  &lt;li&gt;for&lt;/li&gt;
  &lt;li&gt;foreach&lt;/li&gt;
  &lt;li&gt;if&lt;/li&gt;
  &lt;li&gt;while&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;
A look at this list of statements may result in the questions:
Is this list wrong, it doesn&#039;t list &lt;code&gt;else&lt;/code&gt; and &lt;code&gt;default&lt;/code&gt;?
But it is correct. The assumption is that both statements
will contain the defaut execution path of a program which 
also exists when there are no special cases to capture.
&lt;/p&gt;

&lt;p&gt;
Each decision path gets the value &lt;em&gt;1&lt;/em&gt; and the sum of all these
values represents the Cyclomatic Complexity of the analyzed
software fragment. Note that each function and method also 
counts with a value of &lt;em&gt;1&lt;/em&gt; With this knowlegde we can now 
calculate the complexity of the following example code:
&lt;/p&gt;

&lt;div class=&quot;geshi&quot; style=&quot;text-align: left&quot;&gt;&lt;ol&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;lt;?php&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;class&lt;/span&gt; CyclomaticComplexityNumber&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;public&lt;/span&gt; function exampe&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt; $x, $y &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #666666; font-style: italic;&quot;&gt;// (1)&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;if&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt; $x &amp;gt; &lt;span style=&quot;color: #cc66cc;&quot;&gt;23&lt;/span&gt; || $y &amp;lt; &lt;span style=&quot;color: #cc66cc;&quot;&gt;42&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #666666; font-style: italic;&quot;&gt;// (1)&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;for&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt; $i = $x; $i &amp;gt;= $x &amp;amp;&amp;amp;amp; $i &amp;lt;= $y; ++$i &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #666666; font-style: italic;&quot;&gt;// (1)&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;else&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;switch&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt; $x + $y &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;case&lt;/span&gt; &lt;span style=&quot;color: #cc66cc;&quot;&gt;1&lt;/span&gt;: &lt;span style=&quot;color: #666666; font-style: italic;&quot;&gt;// (1)&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;break&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;case&lt;/span&gt; &lt;span style=&quot;color: #cc66cc;&quot;&gt;2&lt;/span&gt;: &lt;span style=&quot;color: #666666; font-style: italic;&quot;&gt;// (1)&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;break&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;default&lt;/span&gt;:&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;break&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; file_exists&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span style=&quot;color: #0000ff;&quot;&gt;&#039;/tmp/log&#039;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; or touch&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span style=&quot;color: #0000ff;&quot;&gt;&#039;/tmp/log&#039;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;

&lt;p&gt;
Based on the previous definition the Cyclomatic Complexity
Number of the example code example is &lt;em&gt;5&lt;/em&gt;. But you may have
noticed that this approach does not capture all decision paths
that exist. We haven&#039;t catched those paths that came from the
by the boolean expression &lt;code&gt;||&lt;/code&gt; line 6 and &lt;code&gt;&amp;amp;&amp;amp;&lt;/code&gt; line 8, and
the logical &lt;code&gt;or&lt;/code&gt; expression in line 25. A variation of the
Cyclomatic Complexity Number that also captures those paths
is the so called CCN2. The CCN2 is the most widely used
variation of this software metrics. Tools like PHPUnit, PMD
and Checkstyle report it as Cyclomatic Complexity of an
analyzed software fragment.
&lt;/p&gt;

&lt;p&gt;
Now we get a complexity value of &lt;em&gt;8&lt;/em&gt; when we apply the CCN2
to the previous example, what is a growt of the software&#039;s
complexity of 60%.
&lt;/p&gt;

&lt;p&gt;
Due to the fact that Cyclomatic Complexity Number was
originally invented for procedural programming languages,
this definition for the Cyclomatic Complexity Number still
misses one element to measure the complexity of an object
oriented software system. With the concept of exceptions a
software gets additional decision paths for each &lt;code&gt;catch&lt;/code&gt;
statement used in the source code. While &lt;code&gt;try&lt;/code&gt; contains
the code for the regular execution code without special
cases, similar to &lt;code&gt;else&lt;/code&gt; and &lt;code&gt;default&lt;/code&gt; statements.
&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;?&lt;/li&gt;
  &lt;li&gt;&amp;amp;&amp;amp;&lt;/li&gt;
  &lt;li&gt;||&lt;/li&gt;
  &lt;li&gt;or&lt;/li&gt;
  &lt;li&gt;and&lt;/li&gt;
  &lt;li&gt;xor&lt;/li&gt;
  &lt;li&gt;case&lt;/li&gt;
  &lt;li&gt;catch&lt;/li&gt;
  &lt;li&gt;elseif&lt;/li&gt;
  &lt;li&gt;for&lt;/li&gt;
  &lt;li&gt;foreach&lt;/li&gt;
  &lt;li&gt;if&lt;/li&gt;
  &lt;li&gt;while&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;
Now that we know what the Cyclomatic Complexity Number is,
what can we do with the measured information? We can find
the complexity hotspots in a system, for example the top
ten artifacts with the highest complexity, but this is only
important during an initial analyses phase to get the big
picture of an application. For a continuous inspection this
information is not so important. A continuous analyses
requires thresholds that help to categories calculated
values. During the time four values have emerged as good
thresholds for the Cyclomatic Complexity Number of a
software system.
&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;A software fragment with a CCN value between &lt;em&gt;1-4&lt;/em&gt; has
  low complexity.&lt;/li&gt;
  &lt;li&gt;A complexity value between &lt;em&gt;5-7&lt;/em&gt; is moderate and still
  easy to understand.&lt;/li&gt;
  &lt;li&gt;Everything between &lt;em&gt;6-10&lt;/em&gt; has a high complexity, while
  everything greater &lt;em&gt;10&lt;/em&gt; is very complex and hard to
  understand.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;
You may ask, why should I care about the complexity of a
software system, where is the value of benefit in this
metric?
&lt;/p&gt;

&lt;p&gt;
Mostly the complex parts of an application contain business
critical logic. But this complexity has negative impacts on
the readability and understandability of source code. Those
parts will normally become a maintainence and bug fixing
nightmare, because no one knows all the constraints, side
effects and what&#039;s exactly going on in that part of the
software. This situation results in the well known saying
&lt;em&gt;&quot;Never touch a running system&quot;&lt;/em&gt; which in turn mostly ends
in copy&amp;amp;paste programming. The situation can even become
more critical when the original author leaves the
development team or the company.
&lt;/p&gt;

&lt;p&gt;
Finally a small example how to apply the new knowledge
about the Cyclomatic Complexity Number, thresholds and the
negative impacts of complex software to an existing
development process. The following source listing shows
a complex method taken from PHP_Depend&#039;s source. This method
has a Cyclomatic Complexity Number of &lt;em&gt;16&lt;/em&gt; and I must admit
that the original author needed some time to understand what
was going on in this method.
&lt;/p&gt;

&lt;div class=&quot;geshi&quot; style=&quot;text-align: left&quot;&gt;&lt;ol&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;lt;?php&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #666666; font-style: italic;&quot;&gt;// ...&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;private&lt;/span&gt; function _countCalls&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;AbstractCallable $callable&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; $callT&amp;#160; = array&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; TokenizerI::T_STRING,&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; TokenizerI::T_VARIABLE&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; $chainT = array&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; TokenizerI::T_DOUBLE_COLON,&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; TokenizerI::T_OBJECT_OPERATOR,&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; $called = array&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; $tokens = $callable-&amp;gt;getTokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; $count&amp;#160; = count&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;for&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$i = &lt;span style=&quot;color: #cc66cc;&quot;&gt;0&lt;/span&gt;; $i &amp;lt; $count; ++$i&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #666666; font-style: italic;&quot;&gt;// break on function body open&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;if&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$i&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;-&amp;gt;type === TokenizerI::T_CURLY_BRACE_OPEN&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;break&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;for&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;; $i &amp;lt; $count; ++$i&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #666666; font-style: italic;&quot;&gt;// Skip non parenthesis tokens&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;if&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$i&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;-&amp;gt;type !== TokenizerI::T_PARENTHESIS_OPEN&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;continue&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #666666; font-style: italic;&quot;&gt;// Skip first token&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;if&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;!isset&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$i - &lt;span style=&quot;color: #cc66cc;&quot;&gt;1&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; || !in_array&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$i - &lt;span style=&quot;color: #cc66cc;&quot;&gt;1&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;-&amp;gt;type, $callT&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;continue&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #666666; font-style: italic;&quot;&gt;// Count if no other token exists&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;if&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;!isset&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$i - &lt;span style=&quot;color: #cc66cc;&quot;&gt;2&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &amp;amp;&amp;amp;amp; !isset&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$called&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$i - &lt;span style=&quot;color: #cc66cc;&quot;&gt;1&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;-&amp;gt;image&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; $called&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$i - &lt;span style=&quot;color: #cc66cc;&quot;&gt;1&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;-&amp;gt;image&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt; = &lt;span style=&quot;color: #000066; font-weight: bold;&quot;&gt;true&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; ++$this-&amp;gt;_calls;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;continue&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;else&lt;/span&gt; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;if&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;in_array&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$i - &lt;span style=&quot;color: #cc66cc;&quot;&gt;2&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;-&amp;gt;type, $chainT&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; $identifier = $tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$i - &lt;span style=&quot;color: #cc66cc;&quot;&gt;2&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;-&amp;gt;image . $tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$i - &lt;span style=&quot;color: #cc66cc;&quot;&gt;1&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;-&amp;gt;image;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;for&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$j = $i - &lt;span style=&quot;color: #cc66cc;&quot;&gt;3&lt;/span&gt;; $j &amp;gt;= &lt;span style=&quot;color: #cc66cc;&quot;&gt;0&lt;/span&gt;; --$j&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;if&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;!in_array&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$j&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;-&amp;gt;type, $callT&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;amp;&amp;amp;amp; !in_array&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$j&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;-&amp;gt;type, $chainT&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;break&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; $identifier = $tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$j&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;-&amp;gt;image . $identifier;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;if&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;!isset&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$called&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$identifier&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; $called&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$identifier&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt; = &lt;span style=&quot;color: #000066; font-weight: bold;&quot;&gt;true&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; ++$this-&amp;gt;_calls;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;else&lt;/span&gt; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;if&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$i - &lt;span style=&quot;color: #cc66cc;&quot;&gt;2&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;-&amp;gt;type !== TokenizerI::T_NEW&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;amp;&amp;amp;amp; !isset&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$called&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$i - &lt;span style=&quot;color: #cc66cc;&quot;&gt;1&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;-&amp;gt;image&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; $called&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$i - &lt;span style=&quot;color: #cc66cc;&quot;&gt;1&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;-&amp;gt;image&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt; = &lt;span style=&quot;color: #000066; font-weight: bold;&quot;&gt;true&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; ++$this-&amp;gt;_calls;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;

&lt;p&gt;
The first thing to do is to make sure that the test suite
is good enough to ensure that the required refactorings
will not change the public behavior of the component or
class. When this is donw and we are sure our that api
breaks will be detected by the test suitewe can start to
extract logic into separate methods.
&lt;/p&gt;

&lt;p&gt;
The following example shows the result of the refactoring:
&lt;/p&gt;

&lt;div class=&quot;geshi&quot; style=&quot;text-align: left&quot;&gt;&lt;ol&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;lt;?php&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #666666; font-style: italic;&quot;&gt;// ...&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;private&lt;/span&gt; function _countCalls&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;AbstractCallable $callable&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; $called = array&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; $tokens = $callable-&amp;gt;getTokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; $count&amp;#160; = count&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;for&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$i = $this-&amp;gt;_findOpenCurlyBrace&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;; $i &amp;lt; $count; ++$i&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;if&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$this-&amp;gt;_isCallableOpenParenthesis&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$tokens, $i&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; === &lt;span style=&quot;color: #000066; font-weight: bold;&quot;&gt;false&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;continue&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;if&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$this-&amp;gt;_isMethodInvocation&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$tokens, $i&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; === &lt;span style=&quot;color: #000066; font-weight: bold;&quot;&gt;true&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; $image = $this-&amp;gt;_getInvocationChainImage&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$tokens, $i&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;else&lt;/span&gt; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;if&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$this-&amp;gt;_isFunctionInvocation&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$tokens, $i&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; === &lt;span style=&quot;color: #000066; font-weight: bold;&quot;&gt;true&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; $image = $tokens&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$i - &lt;span style=&quot;color: #cc66cc;&quot;&gt;1&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt;-&amp;gt;image;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;else&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; $image = &lt;span style=&quot;color: #000066; font-weight: bold;&quot;&gt;null&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #000000; font-weight: bold;&quot;&gt;if&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$image !== &lt;span style=&quot;color: #000066; font-weight: bold;&quot;&gt;null&lt;/span&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#123;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; &amp;#160; $called&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#91;&lt;/span&gt;$image&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#93;&lt;/span&gt; = $image;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; &lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160; &amp;#160; $this-&amp;gt;_calls += count&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#40;&lt;/span&gt;$called&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#41;&lt;/span&gt;;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #009900;&quot;&gt;&amp;#125;&lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;li style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; color: black; font-weight: normal; font-style: normal;&quot;&gt;&lt;div style=&quot;font-family: &#039;Courier New&#039;, Courier, monospace; font-weight: normal;&quot;&gt;&amp;#160;&lt;/div&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;

&lt;p&gt;
The subjective feeling of readability heavily depends on the
complexity of control structures, as we can see by a
comparison of the original and the refactored version of the
method example. The new version with its Cyclomatic Complexity
Number of &lt;em&gt;5&lt;/em&gt; is much easier to read and understand.
&lt;/p&gt;

&lt;p&gt;
This text is the first of two blog posts. The second article
will give a short introduction into the &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2125&amp;amp;entry_id=55&quot;  onmouseover=&quot;window.status=&#039;http://portal.acm.org/citation.cfm?id=42379&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot; title=&quot;NPATH: a measure of execution path complexity and its applications&quot;&gt;NPath Complexity&lt;/a&gt;
You liked this article and you are interested in this and
other quality assurence related topics? - Then you should
now order your copy of the Book &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url=aHR0cDovL3F1YWxpdHlhc3N1cmFuY2VpbnBocHByb2plY3RzLmNvbQ==&amp;amp;entry_id=55&quot;  onmouseover=&quot;window.status=&#039;http://qualityassuranceinphpprojects.com&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot; title=&quot;Quality Assurance in PHP Projects&quot;&gt;Quality Assurance in PHP 
Projects&lt;/a&gt;. The book talks about nearly all aspect of
quality assurence, with practical tips and expert knowledge
contributed by certain PHP professionals.
&lt;/p&gt;


 
    </content:encoded>

    <pubDate>Tue, 07 Jul 2009 21:20:00 +0200</pubDate>
    <guid isPermaLink="false">http://www.manuel-pichler.de/archives/55-guid.html</guid>
    <category>checkstyle</category>
<category>cyclomatic complexity</category>
<category>design quality</category>
<category>npath complexity</category>
<category>php_depend</category>
<category>quality assurance</category>
<category>software metrics</category>

</item>
<item>
    <title>PHP_Depend-0.9.5 released</title>
    <link>http://www.manuel-pichler.de/archives/53-PHP_Depend-0.9.5-released.html</link>
            <category>php</category>
            <category>php_depend</category>
            <category>phpugdo</category>
            <category>planet-php</category>
            <category>projects</category>
    
    <comments>http://www.manuel-pichler.de/archives/53-PHP_Depend-0.9.5-released.html#comments</comments>
    <wfw:comment>http://www.manuel-pichler.de/wfwcomment.php?cid=53</wfw:comment>

    <slash:comments>0</slash:comments>
    <wfw:commentRss>http://www.manuel-pichler.de/rss.php?version=2.0&amp;type=comments&amp;cid=53</wfw:commentRss>
    

    <author>nospam@example.com (Manuel Pichler)</author>
    <content:encoded>
    &lt;p&gt;
  Today I released PHP_Depend 0.9.5, which contains many bug fixes and improvements. The main features of this release are PHP 5.3 namespace support and a more robust parser that ignores most kinds of syntax errors,
&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;
    Closed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2104&amp;amp;entry_id=53&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/2&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/2&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;&lt;strong&gt;#2&lt;/strong&gt;&lt;/a&gt; Support PHP 5.3 namespace syntax, implemented since svn revision #789.
  &lt;/li&gt;
  &lt;li&gt;
    Closed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2105&amp;amp;entry_id=53&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/61&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/61&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;&lt;strong&gt;#61&lt;/strong&gt;&lt;/a&gt; Catch parser errors and continue processing, implemented in svn revision #880.
  &lt;/li&gt;
  &lt;li&gt;
    Closed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2106&amp;amp;entry_id=53&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/63&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/63&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;&lt;strong&gt;#63&lt;/strong&gt;&lt;/a&gt; Make ResultPrinter a configurable option, implemented in svn revision #668.
  &lt;/li&gt;
  &lt;li&gt;
    Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2107&amp;amp;entry_id=53&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/64&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/64&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;&lt;strong&gt;#64&lt;/strong&gt;&lt;/a&gt; The single cache directory causes permission denied on *NIX systems, fixed in svn revision #667.
  &lt;/li&gt;
  &lt;li&gt;
    Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2108&amp;amp;entry_id=53&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/65&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/65&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;&lt;strong&gt;#65&lt;/strong&gt;&lt;/a&gt; Endless loop for class and interface declarations without body, fixed in svn revision #672.
  &lt;/li&gt;
  &lt;li&gt;
    Closed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2109&amp;amp;entry_id=53&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/66&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/66&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;&lt;strong&gt;#66&lt;/strong&gt;&lt;/a&gt; Dependency wiring should be done at the end of the parsing process, implemented in svn revision #855.
  &lt;/li&gt;
  &lt;li&gt;
    Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2110&amp;amp;entry_id=53&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/69&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/69&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;&lt;strong&gt;#69&lt;/strong&gt;&lt;/a&gt; Parser does not handle PHP 5.3 class names in function and method bodies, fixed in svn revision #688.
  &lt;/li&gt;
  &lt;li&gt;
    Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2111&amp;amp;entry_id=53&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/70&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/70&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;&lt;strong&gt;#70&lt;/strong&gt;&lt;/a&gt; Parser throws an unexpected token exception for closure, fixed in svn revision #726.
  &lt;/li&gt;
  &lt;li&gt;
    Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2112&amp;amp;entry_id=53&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/71&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/71&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;&lt;strong&gt;#71&lt;/strong&gt;&lt;/a&gt; Parser throws an unexpected token exception for signed default values, fixed in svn revision #740.
  &lt;/li&gt;
  &lt;li&gt;
    Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2113&amp;amp;entry_id=53&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/73&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/73&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;&lt;strong&gt;#73&lt;/strong&gt;&lt;/a&gt; Inconsistent state when an interface and a class with the same name exists, fixed in svn revision #776.
  &lt;/li&gt;
  &lt;li&gt;
    Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2114&amp;amp;entry_id=53&quot; title=&quot;http://tracker.pdepend.org/pdepend/issue_tracker/issue/76&quot;  onmouseover=&quot;window.status=&#039;http://tracker.pdepend.org/pdepend/issue_tracker/issue/76&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;&lt;strong&gt;#76&lt;/strong&gt;&lt;/a&gt; Tokenizer keyword detection is broken, fixed in svn revision #871.
  &lt;/li&gt;
&lt;/ul&gt;

&lt;br /&gt;
&lt;p&gt;
  You can get the latest PHP_Depend version from its PEAR channel: &lt;em&gt;pear.pdepend.org&lt;/em&gt;
&lt;/p&gt;

&lt;pre&gt;
mapi@arwen ~ $ pear channel-discover pear.pdepend.org
mapi@arwen ~ $ pear install pdepend/PHP_Depend-beta
&lt;/pre&gt; 
    </content:encoded>

    <pubDate>Mon, 18 May 2009 22:21:14 +0200</pubDate>
    <guid isPermaLink="false">http://www.manuel-pichler.de/archives/53-guid.html</guid>
    <category>php5</category>
<category>php_depend</category>
<category>quality assurance</category>
<category>release announcement</category>

</item>
<item>
    <title>PHP_Depend-0.9.4 released</title>
    <link>http://www.manuel-pichler.de/archives/51-PHP_Depend-0.9.4-released.html</link>
            <category>php</category>
            <category>php_depend</category>
            <category>phpugdo</category>
            <category>planet-php</category>
            <category>projects</category>
    
    <comments>http://www.manuel-pichler.de/archives/51-PHP_Depend-0.9.4-released.html#comments</comments>
    <wfw:comment>http://www.manuel-pichler.de/wfwcomment.php?cid=51</wfw:comment>

    <slash:comments>1</slash:comments>
    <wfw:commentRss>http://www.manuel-pichler.de/rss.php?version=2.0&amp;type=comments&amp;cid=51</wfw:commentRss>
    

    <author>nospam@example.com (Manuel Pichler)</author>
    <content:encoded>
    &lt;p&gt;
  Today I released PHP_Depend 0.9.4, which contains many bug fixes and improvements.
&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;
    Fixed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2094&amp;amp;entry_id=51&quot; title=&quot;http://bugs.pdepend.org/index.php?do=details&amp;amp;amp;task_id=92&quot;  onmouseover=&quot;window.status=&#039;http://bugs.pdepend.org/index.php?do=details&amp;amp;amp;task_id=92&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;&lt;strong&gt;#92&lt;/strong&gt;&lt;/a&gt;: Handling of types within instanceof-operator fixed.
  &lt;/li&gt;
  &lt;li&gt;
    Closed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2095&amp;amp;entry_id=51&quot; title=&quot;http://bugs.pdepend.org/index.php?do=details&amp;amp;amp;task_id=90&quot;  onmouseover=&quot;window.status=&#039;http://bugs.pdepend.org/index.php?do=details&amp;amp;amp;task_id=90&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;&lt;strong&gt;#90&lt;/strong&gt;&lt;/a&gt;: Support for single file parsing/analyzing implemented.
  &lt;/li&gt;
  &lt;li&gt;
    Closed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2096&amp;amp;entry_id=51&quot; title=&quot;http://bugs.pdepend.org/index.php?do=details&amp;amp;amp;task_id=88&quot;  onmouseover=&quot;window.status=&#039;http://bugs.pdepend.org/index.php?do=details&amp;amp;amp;task_id=88&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;&lt;strong&gt;#88&lt;/strong&gt;&lt;/a&gt;: Tokens provide information about the start and end column.
  &lt;/li&gt;
  &lt;li&gt;
    Closed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2097&amp;amp;entry_id=51&quot; title=&quot;http://bugs.pdepend.org/index.php?do=details&amp;amp;amp;task_id=87&quot;  onmouseover=&quot;window.status=&#039;http://bugs.pdepend.org/index.php?do=details&amp;amp;amp;task_id=87&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;&lt;strong&gt;#87&lt;/strong&gt;&lt;/a&gt;: Support for type definitions within comments implemented.
  &lt;/li&gt;
  &lt;li&gt;
    Closed &lt;a href=&quot;http://www.manuel-pichler.de/exit.php?url_id=2098&amp;amp;entry_id=51&quot; title=&quot;http://bugs.pdepend.org/index.php?do=details&amp;amp;amp;task_id=40&quot;  onmouseover=&quot;window.status=&#039;http://bugs.pdepend.org/index.php?do=details&amp;amp;amp;task_id=40&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;&lt;strong&gt;#40&lt;/strong&gt;&lt;/a&gt;: Cli debug flag added. PHP_Depend will print additional debug information to STDERR when this cli switch is set.
  &lt;/li&gt;
  &lt;li&gt;
    The ProjectAwareI and NodeAwareI interfaces extend the AnalyzerI interface, which makes analyzer mocking easier.
  &lt;/li&gt;
  &lt;li&gt;
    Switch from PHP_Depend specific constants for public, protected, private methods &amp;amp; properties to modifiers compatible with PHP&#039;s reflection-extension.
  &lt;/li&gt;
  &lt;li&gt;
    Support for static modifier for properties&amp;amp;methods and final for methods added.
  &lt;/li&gt;
  &lt;li&gt;
    Support for class final modifier added.
  &lt;/li&gt;
  &lt;li&gt;
    Support for chained types like &quot;false|Iterator&quot; or &quot;array(false|Iterator)&quot; in doc comments added.
  &lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;p&gt;
  You can get the latest PHP_Depend version from its PEAR channel: &lt;em&gt;pear.pdepend.org&lt;/em&gt;
&lt;/p&gt;

&lt;pre&gt;
mapi@arwen ~ $ pear channel-discover pear.pdepend.org
mapi@arwen ~ $ pear install pdepend/PHP_Depend
&lt;/pre&gt;
 
    </content:encoded>

    <pubDate>Sat, 21 Feb 2009 21:15:00 +0100</pubDate>
    <guid isPermaLink="false">http://www.manuel-pichler.de/archives/51-guid.html</guid>
    <category>php5</category>
<category>php_depend</category>
<category>quality assurance</category>
<category>release announcement</category>

</item>

</channel>
</rss>