/**
  * Setup prognosis strategy: Jack Daniels
  */
 protected function setupJackDanielsStrategy()
 {
     $Strategy = new Prognosis\Daniels();
     $Strategy->adjustVDOT(isset($_POST['endurance']));
     $Strategy->setVDOT((double) Helper::CommaToPoint($_POST['vdot']));
     $Strategy->setBasicEnduranceForAdjustment((int) $_POST['endurance-value']);
     $this->PrognosisStrategies['jack-daniels'] = $Strategy;
 }
Exemplo n.º 2
0
 /**
  * Prognosis time by shape in seconds
  * @return int
  */
 public function prognosisByShapeInSeconds()
 {
     $Prognosis = new Daniels();
     $Prognosis->adjustVDOT(false);
     $Prognosis->setVDOT($this->Shape);
     return $Prognosis->inSeconds($this->Activity->distance());
 }