/**
  * Init ppa
  * @param type $configGlobale
  * @param Translator $translator
  */
 public function __construct($configGlobale, Translator $translator, $rootDir)
 {
     // traduction
     $this->translator = $translator;
     // web ppa path
     $this->dirRoot = $rootDir . '/web/ppa';
     // report path
     $this->reportPath = $this->dirRoot . '/reports';
     // parameters
     $this->parameters = $configGlobale;
     // l'objet analyse
     $this->oAnalyze = new Analyze();
     $this->oAnalyze->setLang($translator->getLocale())->setNbNamespace($this->extractFromLoc('namespaces'))->setNbClasses($this->extractFromLoc('classes'))->setNbMethod($this->extractFromLoc('methods'))->setLoc((int) $this->extractFromLoc('loc'));
     // Exploits analysis
     $this->count();
     $this->setSecurityInfo();
     $this->setQualityInfo();
     $this->setAnalysisTimeInfo();
     $this->exploitTestReport();
     $this->calculateScore();
 }
Beispiel #2
0
 public function __construct(\Symfony\Component\Translation\DataCollectorTranslator $translator)
 {
     $this->_locale = $translator->getLocale();
     $this->_trad1 = $translator->trans('windsurfdb.matos.form.marque.type_choice.board');
     $this->_trad2 = $translator->trans('windsurfdb.matos.form.marque.type_choice.voile');
 }
Beispiel #3
0
 public function __construct(\Symfony\Component\Translation\DataCollectorTranslator $translator, $localeDefault)
 {
     $this->_locale = $translator->getLocale();
     var_dump($this->_locale);
 }