/** * Classifies the given $userAgent and specified $deviceID * @param string $userAgent * @param string $deviceID */ function filter($userAgent, $deviceID) { if ($this->canHandle($userAgent)) { $this->updateUserAgentsWithDeviceIDMap($this->normalizeUserAgent($userAgent), $deviceID); return; } if (isset($this->nextHandler)) { return $this->nextHandler->filter($userAgent, $deviceID); } }
function filter($userAgent, $deviceID) { if ($this->isMozilla4($userAgent)) { $this->mozilla4UserAgentsWithDeviceID[$this->normalizeUserAgent($userAgent)] = $deviceID; } if ($this->isMozilla5($userAgent)) { $this->mozilla5UserAgentsWithDeviceID[$this->normalizeUserAgent($userAgent)] = $deviceID; } parent::filter($userAgent, $deviceID); }