<commit_before><?php
/**
 * FlameCore UserAgent
 * Copyright (C) 2015 IceFlame.net
 *
 * Permission to use, copy, modify, and/or distribute this software for
 * any purpose with or without fee is hereby granted, provided that the
 * above copyright notice and this permission notice appear in all copies.
 *
 * @package  FlameCore\UserAgent
 * @version  1.0
 * @link     http://www.flamecore.org
 * @license  http://opensource.org/licenses/ISC ISC License
 */

namespace FlameCore\UserAgent;

/**
 * The UserAgent class
 *
 * @author   <NAME> <<EMAIL> at gmail dot com>
 * @author   <NAME> <<EMAIL>>
 */
class UserAgent
{
    /**
     * @var string
     */
    protected $string;

    /**
     * @var string
     */
    protected $browserName;

    /**
     * @var string
     */
    protected $browserVersion;

    /**
     * @var string
     */
    protected $browserEngine;

    /**
     * @var string
     */
    protected $operatingSystem;

    /**
     * @var string
     */
    protected $device;

    /**
     * Creates a UserAgent object.
     *
     * @param string $string The user agent string. Uses the current User Agent string by default.
     * @param \FlameCore\UserAgent\UserAgentStringParser $parser The parser used to parse the string
     */
    private function __construct($string = null, UserAgentStringParser $parser = null)
    {
        $this->configureFromUserAgentString($string, $parser);
    }

    /**
     * Creates a UserAgent object from the global $_SERVER string.
     *
     * @return UserAgent The user agent object.
     */
    public static function createFromGlobal()
    {
        return new self($_SERVER['HTTP_USER_AGENT']);
    }

    /**
     * Creates a UserAgent object.
     *
     * @param string $string The user agent string. Uses the current User Agent string by default.
     * @param \FlameCore\UserAgent\UserAgentStringParser $parser The parser used to parse the string
     * @return UserAgent The user agent object.
     */
    public static function create($string = null, UserAgentStringParser $parser = null)
    {
        return new self($string, $parser);
    }

    /**
     * Returns the string representation of the object.
     *
     * @return string
     */
    public function __toString()
    {
        return $this->getFullName();
    }
<commit_msg>Removes the  call so scrutinizer will stop complaining about it.<commit_after><?php
/**
 * FlameCore UserAgent
 * Copyright (C) 2015 IceFlame.net
 *
 * Permission to use, copy, modify, and/or distribute this software for
 * any purpose with or without fee is hereby granted, provided that the
 * above copyright notice and this permission notice appear in all copies.
 *
 * @package  FlameCore\UserAgent
 * @version  1.0
 * @link     http://www.flamecore.org
 * @license  http://opensource.org/licenses/ISC ISC License
 */

namespace FlameCore\UserAgent;

/**
 * The UserAgent class
 *
 * @author   <NAME> <thibault.duplessis at gmail dot com>
 * @author   <NAME> <<EMAIL>>
 */
class UserAgent
{
    /**
     * @var string
     */
    protected $string;

    /**
     * @var string
     */
    protected $browserName;

    /**
     * @var string
     */
    protected $browserVersion;

    /**
     * @var string
     */
    protected $browserEngine;

    /**
     * @var string
     */
    protected $operatingSystem;

    /**
     * @var string
     */
    protected $device;

    /**
     * Creates a UserAgent object.
     *
     * @param string $string The user agent string. Uses the current User Agent string by default.
     * @param \FlameCore\UserAgent\UserAgentStringParser $parser The parser used to parse the string
     */
    private function __construct($string = null, UserAgentStringParser $parser = null)
    {
        $this->configureFromUserAgentString($string, $parser);
    }

    /**
     * Creates a UserAgent object from the global $_SERVER string.
     *
     * @return UserAgent The user agent object.
     */
    public static function createFromGlobal()
    {
        return new self();
    }

    /**
     * Creates a UserAgent object.
     *
     * @param string $string The user agent string. Uses the current User Agent string by default.
     * @param \FlameCore\UserAgent\UserAgentStringParser $parser The parser used to parse the string
     * @return UserAgent The user agent object.
     */
    public static function create($string = null, UserAgentStringParser $parser = null)
    {
        return new self($string, $parser);
    }

    /**
     * Returns the string representation of the object.
     *
     * @return string
     */
    public function __toString()
    {
        return $this->getFullName();
    }

{'fraction_non_alphanumeric': 0.10365462705706348, 'fraction_numerical': 0.0025646505663603335, 'mean_word_length': 2.4085943190094685, 'pattern_counts': {'":': 0, '<': 16, '<?xml version=': 0, '>': 18, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6492833', 'n_tokens_mistral': 1333, 'n_tokens_neox': 1301, 'n_words': 433}