Example #1
0
 /**
  * Calculates the Weight Method Per Class metric.
  *
  * @param PHP_Depend_Code_AbstractType $type The context type instance.
  *
  * @return integer[]
  * @since 1.0.6
  */
 private function calculateWmci(PHP_Depend_Code_AbstractType $type)
 {
     $ccn = array();
     foreach ($type->getMethods() as $method) {
         $ccn[$method->getName()] = $this->cyclomaticAnalyzer->getCcn2($method);
     }
     return $ccn;
 }