/** * @param LigneInterface $ligne * @return VentilationLigne */ static function create(LigneInterface $ligne) { $ventilationLigne = new VentilationLigne(); $ventilationLigne->setMontant($ligne->getMontant()); $factory = new SectionFactory(); $ventilationLigne->setSection($factory->create($ligne)); return $ventilationLigne; }
/** * @param LigneInterface $ligne * @return Section */ public function create(LigneInterface $ligne) { return new Section(array('site' => self::getSousSectionCode('site', $ligne->getCodeForSiteAnalytique()), 'composante' => self::getSousSectionCode('composante', $ligne->getCodeForComposanteAnalytique()), 'modalite' => self::getSousSectionCode('modalite', $ligne->getCodeForModaliteAnalytique()), 'projet' => self::getSousSectionCode('projet', $ligne->getCodeForProjetAnalytique()))); }