1: <?php
2:
3: namespace GeoIp2\Record;
4:
5: /**
6: * Contains data for the traits record associated with an IP address.
7: *
8: * This record is returned by all location services and databases.
9: *
10: * @property-read int|null $autonomousSystemNumber The
11: * {@link * http://en.wikipedia.org/wiki/Autonomous_system_(Internet) autonomous
12: * system number} associated with the IP address. This attribute is only
13: * available from the City and Insights web service and the GeoIP2
14: * Enterprise database.
15: * @property-read string|null $autonomousSystemOrganization The organization
16: * associated with the registered {@link * http://en.wikipedia.org/wiki/Autonomous_system_(Internet) autonomous
17: * system number} for the IP address. This attribute is only available from
18: * the City and Insights web service and the GeoIP2 Enterprise
19: * database.
20: * @property-read string|null $connectionType The connection type may take the
21: * following values: "Dialup", "Cable/DSL", "Corporate", "Cellular".
22: * Additional values may be added in the future. This attribute is only
23: * available in the GeoIP2 Enterprise database.
24: * @property-read string|null $domain The second level domain associated with the
25: * IP address. This will be something like "example.com" or "example.co.uk",
26: * not "foo.example.com". This attribute is only available from the
27: * City and Insights web service and the GeoIP2 Enterprise
28: * database.
29: * @property-read string $ipAddress The IP address that the data in the model
30: * is for. If you performed a "me" lookup against the web service, this
31: * will be the externally routable IP address for the system the code is
32: * running on. If the system is behind a NAT, this may differ from the IP
33: * address locally assigned to it. This attribute is returned by all end
34: * points.
35: * @property-read bool $isAnonymous This is true if the IP address belongs to
36: * any sort of anonymous network. This property is only available from GeoIP2
37: * Precision Insights.
38: * @property-read bool $isAnonymousProxy *Deprecated.* Please see our
39: * {@link * https://www.maxmind.com/en/geoip2-anonymous-ip-database GeoIP2
40: * Anonymous IP database} to determine whether the IP address is used by an
41: * anonymizing service.
42: * @property-read bool $isAnonymousVpn This is true if the IP address is
43: * registered to an anonymous VPN provider. If a VPN provider does not register
44: * subnets under names associated with them, we will likely only flag their IP
45: * ranges using the isHostingProvider property. This property is only available
46: * from GeoIP2 Precision Insights.
47: * @property-read bool $isHostingProvider This is true if the IP address belongs
48: * to a hosting or VPN provider (see description of isAnonymousVpn property).
49: * This property is only available from GeoIP2 Precision Insights.
50: * @property-read bool $isLegitimateProxy This attribute is true if MaxMind
51: * believes this IP address to be a legitimate proxy, such as an internal
52: * VPN used by a corporation. This attribute is only available in the GeoIP2
53: * Enterprise database.
54: * @property-read bool $isPublicProxy This is true if the IP address belongs to
55: * a public proxy. This property is only available from GeoIP2 Precision
56: * Insights.
57: * @property-read bool $isSatelliteProvider *Deprecated.* Due to the
58: * increased coverage by mobile carriers, very few satellite providers now
59: * serve multiple countries. As a result, the output does not provide
60: * sufficiently relevant data for us to maintain it.
61: * @property-read bool $isTorExitNode This is true if the IP address is a Tor
62: * exit node. This property is only available from GeoIP2 Precision Insights.
63: * @property-read string|null $isp The name of the ISP associated with the IP
64: * address. This attribute is only available from the City and Insights web
65: * services and the GeoIP2 Enterprise database.
66: * @property-read string|null $organization The name of the organization associated
67: * with the IP address. This attribute is only available from the City and
68: * Insights web services and the GeoIP2 Enterprise database.
69: * @property-read string|null $userType <p>The user type associated with the IP
70: * address. This can be one of the following values:</p>
71: * <ul>
72: * <li>business
73: * <li>cafe
74: * <li>cellular
75: * <li>college
76: * <li>content_delivery_network
77: * <li>dialup
78: * <li>government
79: * <li>hosting
80: * <li>library
81: * <li>military
82: * <li>residential
83: * <li>router
84: * <li>school
85: * <li>search_engine_spider
86: * <li>traveler
87: * </ul>
88: * <p>
89: * This attribute is only available from the Insights web service and the
90: * GeoIP2 Enterprise database.
91: * </p>
92: */
93: class Traits extends AbstractRecord
94: {
95: /**
96: * @ignore
97: */
98: protected $validAttributes = [
99: 'autonomousSystemNumber',
100: 'autonomousSystemOrganization',
101: 'connectionType',
102: 'domain',
103: 'ipAddress',
104: 'isAnonymous',
105: 'isAnonymousProxy',
106: 'isAnonymousVpn',
107: 'isHostingProvider',
108: 'isLegitimateProxy',
109: 'isp',
110: 'isPublicProxy',
111: 'isSatelliteProvider',
112: 'isTorExitNode',
113: 'organization',
114: 'userType',
115: ];
116: }
117: