xref: /plugin/statistics/vendor/matomo/device-detector/Yaml/Symfony.php (revision d5ef99ddb7dfb0cfae33e9257bd1d788f682c50f)
1*d5ef99ddSAndreas Gohr<?php
2*d5ef99ddSAndreas Gohr
3*d5ef99ddSAndreas Gohr/**
4*d5ef99ddSAndreas Gohr * Device Detector - The Universal Device Detection library for parsing User Agents
5*d5ef99ddSAndreas Gohr *
6*d5ef99ddSAndreas Gohr * @link https://matomo.org
7*d5ef99ddSAndreas Gohr *
8*d5ef99ddSAndreas Gohr * @license http://www.gnu.org/licenses/lgpl.html LGPL v3 or later
9*d5ef99ddSAndreas Gohr */
10*d5ef99ddSAndreas Gohr
11*d5ef99ddSAndreas Gohrdeclare(strict_types=1);
12*d5ef99ddSAndreas Gohr
13*d5ef99ddSAndreas Gohrnamespace DeviceDetector\Yaml;
14*d5ef99ddSAndreas Gohr
15*d5ef99ddSAndreas Gohruse Symfony\Component\Yaml\Yaml;
16*d5ef99ddSAndreas Gohr
17*d5ef99ddSAndreas Gohrclass Symfony implements ParserInterface
18*d5ef99ddSAndreas Gohr{
19*d5ef99ddSAndreas Gohr    /**
20*d5ef99ddSAndreas Gohr     * Parses the file with the given filename using Symfony Yaml parser and returns the converted content
21*d5ef99ddSAndreas Gohr     *
22*d5ef99ddSAndreas Gohr     * @param string $file
23*d5ef99ddSAndreas Gohr     *
24*d5ef99ddSAndreas Gohr     * @return mixed
25*d5ef99ddSAndreas Gohr     */
26*d5ef99ddSAndreas Gohr    public function parseFile(string $file)
27*d5ef99ddSAndreas Gohr    {
28*d5ef99ddSAndreas Gohr        return Yaml::parseFile($file);
29*d5ef99ddSAndreas Gohr    }
30*d5ef99ddSAndreas Gohr}
31