minFraud PHP API v1.0.0
  • Namespace
  • Class

Namespaces

  • GeoIp2
    • Database
    • Exception
    • Model
    • Record
    • Test
      • Database
      • Model
      • WebService
    • WebService
  • MaxMind
    • MinFraud
      • Model
  • PHP

Classes

  • GeoIp2\Database\Reader
  • GeoIp2\Model\AnonymousIp
  • GeoIp2\Model\City
  • GeoIp2\Model\ConnectionType
  • GeoIp2\Model\Country
  • GeoIp2\Model\Domain
  • GeoIp2\Model\Enterprise
  • GeoIp2\Model\Insights
  • GeoIp2\Model\Isp
  • GeoIp2\Record\AbstractPlaceRecord
  • GeoIp2\Record\AbstractRecord
  • GeoIp2\Record\City
  • GeoIp2\Record\Continent
  • GeoIp2\Record\Country
  • GeoIp2\Record\Location
  • GeoIp2\Record\MaxMind
  • GeoIp2\Record\Postal
  • GeoIp2\Record\RepresentedCountry
  • GeoIp2\Record\Subdivision
  • GeoIp2\Record\Traits
  • GeoIp2\Test\Database\ReaderTest
  • GeoIp2\Test\Model\CountryTest
  • GeoIp2\Test\Model\InsightsTest
  • GeoIp2\Test\Model\NameTest
  • GeoIp2\Test\WebService\ClientTest
  • GeoIp2\WebService\Client
  • MaxMind\MinFraud
  • MaxMind\MinFraud\Model\Address
  • MaxMind\MinFraud\Model\BillingAddress
  • MaxMind\MinFraud\Model\CreditCard
  • MaxMind\MinFraud\Model\Device
  • MaxMind\MinFraud\Model\Email
  • MaxMind\MinFraud\Model\Factors
  • MaxMind\MinFraud\Model\GeoIp2Country
  • MaxMind\MinFraud\Model\GeoIp2Location
  • MaxMind\MinFraud\Model\Insights
  • MaxMind\MinFraud\Model\IpAddress
  • MaxMind\MinFraud\Model\Issuer
  • MaxMind\MinFraud\Model\Score
  • MaxMind\MinFraud\Model\ScoreIpAddress
  • MaxMind\MinFraud\Model\ShippingAddress
  • MaxMind\MinFraud\Model\Subscores
  • MaxMind\MinFraud\Model\Warning

Interfaces

  • GeoIp2\ProviderInterface
  • JsonSerializable

Exceptions

  • BadFunctionCallException
  • BadMethodCallException
  • Exception
  • GeoIp2\Exception\AddressNotFoundException
  • GeoIp2\Exception\AuthenticationException
  • GeoIp2\Exception\GeoIp2Exception
  • GeoIp2\Exception\HttpException
  • GeoIp2\Exception\InvalidRequestException
  • GeoIp2\Exception\OutOfQueriesException
  • InvalidArgumentException
  • LogicException
 1 <?php
 2 
 3 namespace GeoIp2\Model;
 4 
 5 /**
 6  * Model class for the data returned by GeoIP2 Country web service and database.
 7  *
 8  * The only difference between the City and Insights model classes is which
 9  * fields in each record may be populated. See
10  * http://dev.maxmind.com/geoip/geoip2/web-services more details.
11  *
12  * @property-read \GeoIp2\Record\Continent $continent Continent data for the
13  * requested IP address.
14  *
15  * @property-read \GeoIp2\Record\Country $country Country data for the requested
16  * IP address. This object represents the country where MaxMind believes the
17  * end user is located.
18  *
19  * @property-read \GeoIp2\Record\MaxMind $maxmind Data related to your MaxMind
20  * account.
21  *
22  * @property-read \GeoIp2\Record\Country $registeredCountry Registered country
23  * data for the requested IP address. This record represents the country
24  * where the ISP has registered a given IP block and may differ from the
25  * user's country.
26  *
27  * @property-read \GeoIp2\Record\RepresentedCountry $representedCountry
28  * Represented country data for the requested IP address. The represented
29  * country is used for things like military bases. It is only present when
30  * the represented country differs from the country.
31  *
32  * @property-read \GeoIp2\Record\Traits $traits Data for the traits of the
33  * requested IP address.
34  */
35 class Country extends AbstractModel
36 {
37     protected $continent;
38     protected $country;
39     protected $locales;
40     protected $maxmind;
41     protected $registeredCountry;
42     protected $representedCountry;
43     protected $traits;
44 
45     /**
46      * @ignore
47      */
48     public function __construct($raw, $locales = array('en'))
49     {
50         parent::__construct($raw);
51 
52         $this->continent = new \GeoIp2\Record\Continent(
53             $this->get('continent'),
54             $locales
55         );
56         $this->country = new \GeoIp2\Record\Country(
57             $this->get('country'),
58             $locales
59         );
60         $this->maxmind = new \GeoIp2\Record\MaxMind($this->get('maxmind'));
61         $this->registeredCountry = new \GeoIp2\Record\Country(
62             $this->get('registered_country'),
63             $locales
64         );
65         $this->representedCountry = new \GeoIp2\Record\RepresentedCountry(
66             $this->get('represented_country'),
67             $locales
68         );
69         $this->traits = new \GeoIp2\Record\Traits($this->get('traits'));
70 
71         $this->locales = $locales;
72     }
73 }
74 
minFraud PHP API v1.0.0 API documentation generated by ApiGen