spunQ_HttpClientOsInformation Class Reference

Information about the operating system of an HTTP client. More...

Inheritance diagram for spunQ_HttpClientOsInformation:

spunQ_IHttpClientOsInformation

List of all members.

Public Member Functions

 __construct (spunQ_IHttpRequest $request)
 Constructor.
 getType ()
 Gets the OS type.
 getFlavor ()
 Gets the most specific OS_* constant possible.

Public Attributes

const OS_UNKNOWN = 0
 Unknown operating system.
const OS_WINDOWS = 100
 Microsoft Windows OS.
const OS_MAC = 200
 Macintosh OS.
const OS_UNIX = 300
 Unix OS.
const OS_WINDOWS_UNKNOWN = 100
 Unknown Microsot Windows Version.
const OS_WINDOWS_95 = 101
 Microsoft Windows 95.
const OS_WINDOWS_98 = 102
 Microsoft Windows 98.
const OS_WINDOWS_ME = 103
 Microsoft Windows ME.
const OS_WINDOWS_2000 = 104
 Microsoft Windows 2000.
const OS_WINDOWS_2003 = 105
 Microsoft Windows 2003.
const OS_WINDOWS_XP = 106
 Microsoft Windows XP.
const OS_WINDOWS_VISTA = 107
 Microsoft Windows VISTA.
const OS_WINDOWS_CE = 108
 Microsoft Windows CE.
const OS_WINDOWS_NT = 109
 Microsoft Windows NT.
const OS_WINDOWS_7 = 110
 Microsoft Windows 7.
const OS_MAC_UNKNOWN = 200
 Unknown Macintosh Version.
const OS_MAC_OS9 = 201
 Mac OS 9.
const OS_MAC_OSX = 202
 Mac OS X.
const OS_UNIX_UNKNOWN = 300
 Unknown Unix Distro.
const OS_UNIX_DEBIAN = 301
 Debian.
const OS_UNIX_SLACKWARE = 302
 Slackware.
const OS_UNIX_GENTOO = 303
 Gentoo.
const OS_UNIX_UBUNTU = 304
 Ubuntu.
const OS_UNIX_FEDORA = 305
 Fedora.
const OS_UNIX_BSD = 306
 BSD.

Protected Attributes

 $flavor = NULL
 The flavor of the OS.

Static Protected Attributes

static $mapping
 Mapping of strings to OS_* constants.


Detailed Description

Information about the operating system of an HTTP client.

Definition at line 6 of file HttpClientOsInformation.class.php.


Constructor & Destructor Documentation

spunQ_HttpClientOsInformation::__construct ( spunQ_IHttpRequest request  ) 

Constructor.

Parameters:
$request The Http client request to extract this information from.

Definition at line 60 of file HttpClientOsInformation.class.php.


Member Function Documentation

spunQ_HttpClientOsInformation::getFlavor (  ) 

Gets the most specific OS_* constant possible.

Returns:
integer Either of the OS_* constants.

Implements spunQ_IHttpClientOsInformation.

Definition at line 75 of file HttpClientOsInformation.class.php.

spunQ_HttpClientOsInformation::getType (  ) 

Gets the OS type.

Returns:
integer Either of the constants OS_WINDOWS, OS_MAC and OS_UNIX.

Implements spunQ_IHttpClientOsInformation.

Definition at line 68 of file HttpClientOsInformation.class.php.


Member Data Documentation

spunQ_HttpClientOsInformation::$flavor = NULL [protected]

The flavor of the OS.

Either of the OS_* constants.

Type:
integer

Definition at line 53 of file HttpClientOsInformation.class.php.

spunQ_HttpClientOsInformation::$mapping [static, protected]

Mapping of strings to OS_* constants.

The strings indicate a OS type and version if they appear inside the user-agent part of the request header.

Type:
array<integer>

Definition at line 14 of file HttpClientOsInformation.class.php.


The documentation for this class was generated from the following file:

Generated on Fri Jul 1 11:12:40 2011 for spunQ3 by  doxygen 1.5.9