private static function checkOSX(Os $os, UserAgent $userAgent)
    {
        if (stripos($userAgent->getUserAgentString(), 'OS X') !== false) {
            $os->setName($os::OSX);
            if (preg_match('/OS X ([\d\._]*)/i', $userAgent->getUserAgentString(), $matches)) {
                if (isset($matches[1])) {
                    $os->setVersion(str_replace('_', '.', $matches[1]));
                }
            }

            return true;
        }

        return false;
    }
private static function checkOSX(Os $os, UserAgent $userAgent)
    {
        if (stripos($userAgent->getUserAgentString(), 'OS X') !== false) {
            $os->setName($os::OSX);
            if (preg_match('/OS X ([\d\._]*)/i', $userAgent->getUserAgentString(), $matches)) {
                if (isset($matches[1])) {
                    $os->setVersion(str_replace('_', '.', $matches[1]));
                }
            }

            return true;
        }

        return false;
    }
private static function checkOSX ( Os $ os , UserAgent $ userAgent ) { if ( stripos ( $ userAgent -> getUserAgentString ( ) , 'OS X' ) !== false ) { $ os -> setName ( $ os :: OSX ) ; if ( preg_match ( '/OS X ([\d\._]*)/i' , $ userAgent -> getUserAgentString ( ) , $ matches ) ) { if ( isset ( $ matches [ 1 ] ) ) { $ os -> setVersion ( str_replace ( '_' , '.' , $ matches [ 1 ] ) ) ; } } return true ; } return false ; }
Determine if the user's operating system is OS X.

@param Os $os
@param UserAgent $userAgent

@return bool
Determine if the user s operating system is OS X .