Exemple #1
0
 /**
  * @param \Runalyze\Data\Laps\Lap $Lap
  * @return string
  */
 protected function additionalTableCellsFor(\Runalyze\Data\Laps\Lap $Lap)
 {
     $Code = '';
     $View = new Dataview(new Activity\Entity($Lap->additionalValues()));
     foreach ($this->AdditionalKeys as $key) {
         switch ($key) {
             case Activity\Entity::CADENCE:
                 $Code .= '<td>' . $View->cadence()->asString() . '</td>';
                 break;
             case Activity\Entity::GROUNDCONTACT:
                 $Code .= '<td>' . $View->groundcontact() . '</td>';
                 break;
             case Activity\Entity::GROUNDCONTACT_BALANCE:
                 $Code .= '<td>' . $View->groundcontactBalance() . '</td>';
                 break;
             case Activity\Entity::VERTICAL_OSCILLATION:
                 $Code .= '<td>' . $View->verticalOscillation() . '</td>';
                 break;
             case Activity\Entity::VERTICAL_RATIO:
                 $Code .= '<td>' . $View->verticalRatio() . '</td>';
                 break;
             case Activity\Entity::STRIDE_LENGTH:
                 $Code .= '<td>' . $View->strideLength()->string() . '</td>';
                 break;
             case Activity\Entity::VDOT:
                 $Code .= '<td>' . $View->vdot()->value() . '</td>';
                 break;
             case Activity\Entity::POWER:
                 $Code .= '<td>' . $View->power() . '</td>';
                 break;
             default:
                 $Code .= '<td></td>';
         }
     }
     return $Code;
 }