Bånder

GeoLocationService
in package

Table of Contents

Constants

CACHE_TTL  = 3600

Methods

getLocationData()  : array<string|int, mixed>
hasCountryChanged()  : bool
fetchLocationData()  : array<string|int, mixed>
isPrivateIp()  : bool

Constants

Methods

getLocationData()

public getLocationData(string $ipAddress) : array<string|int, mixed>
Parameters
$ipAddress : string
Return values
array<string|int, mixed>

hasCountryChanged()

public hasCountryChanged(string $oldCountryCode, string $newCountryCode) : bool
Parameters
$oldCountryCode : string
$newCountryCode : string
Return values
bool

fetchLocationData()

private fetchLocationData(string $ipAddress) : array<string|int, mixed>
Parameters
$ipAddress : string
Return values
array<string|int, mixed>

isPrivateIp()

private isPrivateIp(string $ip) : bool
Parameters
$ip : string
Return values
bool

        
On this page

Search results