27 lines
490 B
PHP
27 lines
490 B
PHP
<?php
|
|
|
|
namespace Questionnaire\Model;
|
|
|
|
use Questionnaire\Application;
|
|
use Symfony\Component\Yaml\Yaml;
|
|
|
|
abstract class QuestionnairePeer
|
|
{
|
|
/**
|
|
* @var string
|
|
*/
|
|
protected static $yaml;
|
|
|
|
protected static function getYaml()
|
|
{
|
|
if (null !== self::$yaml) {
|
|
return self::$yaml;
|
|
}
|
|
|
|
$file = Application::getInstance()['config.locator']
|
|
->locate('questionnaire.yml');
|
|
|
|
return self::$yaml = Yaml::parse($file);
|
|
}
|
|
}
|