-
Notifications
You must be signed in to change notification settings - Fork 0
/
dbdata.ip2x.go
360 lines (313 loc) · 22.9 KB
/
dbdata.ip2x.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
// Code generated by codegen; DO NOT EDIT.
package ip2x
import "strconv"
//go:generate go run dbdata.go
// IP2Location™ IP Address Geolocation Database provides a solution to deduce
// the geolocation of a device connected to the Internet and to determine the
// approximate geographic location of an IP address along with some other useful
// information like country, region or state, city, latitude and longitude,
// ZIP/Postal code, time zone, Internet Service Provider (ISP) or company name,
// domain name, net speed, area code, weather station code, weather station
// name, mobile country code (MCC), mobile network code (MNC) and carrier brand,
// elevation, usage type, address type and advertising category.
// Up to DB26.
const IP2Location DBProduct = 1
// IP2Proxy™ Proxy Detection Database contains IP addresses which are used as VPN
// anonymizer, open proxies, web proxies and Tor exits, data center, web hosting
// (DCH) range, search engine robots (SES) and residential proxies (RES).
// Up to PX11.
const IP2Proxy DBProduct = 2
// IP address types as defined in Internet Protocol version 4 (IPv4) and
// Internet Protocol version 6 (IPv6).
// - (A) Anycast - One to the closest
// - (U) Unicast - One to one
// - (M) Multicast - One to multiple
// - (B) Broadcast - One to all
//
// In DB25-26.
const AddressType DBField = 1
// A varying length number assigned to geographic areas for call between cities.
//
// See https://www.ip2location.com/area-code-coverage.
//
// In DB15-16, DB18, DB20-22, DB24-26.
const AreaCode DBField = 2
// Autonomous system number (ASN).
//
// In DB26, PX7-11.
const AS DBField = 3
// Autonomous system (AS) name.
//
// In DB26, PX7-11.
const ASN DBField = 4
// The domain category is based on IAB Tech Lab Content Taxonomy.
//
// These categories are comprised of Tier-1 and Tier-2 (if available) level
// categories widely used in services like advertising, Internet security and
// filtering appliances.
//
// See https://www.ip2location.com/free/iab-categories.
//
// In DB25-26.
const Category DBField = 5
// City name.
//
// In DB3-26, PX3-11.
const City DBField = 6
// Two-character country code based on ISO 3166.
//
// In DB1-26, PX1-11.
const CountryCode DBField = 7
// Country name based on ISO 3166.
//
// In DB1-26, PX1-11.
const CountryName DBField = 8
// Internet domain name associated with IP address range.
//
// In DB7-8, DB10, DB12, DB14, DB16, DB18-20, DB22-26, PX5-11.
const Domain DBField = 9
// District or county name.
//
// In DB26.
const District DBField = 10
// Average height of city above sea level in meters (m).
//
// In DB21-22, DB24-26.
const Elevation DBField = 11
// The IDD prefix to call the city from another country.
//
// In DB15-16, DB18, DB20-22, DB24-26.
const IDDCode DBField = 12
// Internet Service Provider or company's name.
//
// In DB2, DB4, DB6-8, DB10, DB12, DB14, DB16, DB18-20, DB22-26, PX4-11.
const ISP DBField = 13
// Proxy last seen in days.
//
// In PX8-11.
const LastSeen DBField = 14
// City latitude. Defaults to capital city latitude if city is unknown.
//
// In DB5-6, DB8-26.
const Latitude DBField = 15
// City longitude. Defaults to capital city longitude if city is unknown.
//
// In DB5-6, DB8-26.
const Longitude DBField = 16
// Mobile Country Codes (MCC) as defined in ITU E.212 for use in identifying
// mobile stations in wireless telephone networks, particularly GSM and UMTS
// networks.
//
// In DB19-20, DB22-26.
const MCC DBField = 17
// Mobile Network Code (MNC) is used in combination with a Mobile Country Code
// (MCC) to uniquely identify a mobile phone operator or carrier.
//
// In DB19-20, DB22-26.
const MNC DBField = 18
// Commercial brand associated with the mobile carrier.
//
// See https://www.ip2location.com/mobile-carrier-coverage.
//
// In DB19-20, DB22-26.
const MobileBrand DBField = 19
// Internet Connection Type
// - (DIAL) dial up
// - (DSL) broadband/cable/fiber/mobile
// - (COMP) company/T1
//
// In DB13-14, DB16-18, DB20, DB22, DB24-26.
const NetSpeed DBField = 20
// Name of VPN provider if available.
//
// In PX11.
const Provider DBField = 21
// Type of proxy.
// - (VPN) Anonymizing VPN services. These services offer users a publicly
// accessible VPN for the purpose of hiding their IP address. Anonymity:
// High.
// - (TOR) Tor Exit Nodes. The Tor Project is an open network used by those
// who wish to maintain anonymity. Anonymity: High.
// - (DCH) Hosting Provider, Data Center or Content Delivery Network. Since
// hosting providers and data centers can serve to provide anonymity, the
// Anonymous IP database flags IP addresses associated with them. Anonymity:
// Low.
// - (PUB) Public Proxies. These are services which make connection requests
// on a user's behalf. Proxy server software can be configured by the
// administrator to listen on some specified port. These differ from VPNs in
// that the proxies usually have limited functions compare to VPNs.
// Anonymity: High.
// - (WEB) Web Proxies. These are web services which make web requests on a
// user's behalf. These differ from VPNs or Public Proxies in that they are
// simple web-based proxies rather than operating at the IP address and
// other ports level. Anonymity: High.
// - (SES) Search Engine Robots. These are services which perform crawling or
// scraping to a website, such as, the search engine spider or bots engine.
// Anonymity: Low.
// - (RES) Residential proxies. These services offer users proxy connections
// through residential ISP with or without consents of peers to share their
// idle resources. Only available with PX10 & PX11. Anonymity: Medium.
//
// In PX2-11.
const ProxyType DBField = 22
// Region or state name.
//
// In DB3-26, PX3-11.
const Region DBField = 23
// Security threat reported.
// - (SPAM) Email and forum spammers
// - (SCANNER) Network security scanners
// - (BOTNET) Malware infected devices
//
// In PX9-11.
const Threat DBField = 24
// UTC time zone (with DST supported).
//
// In DB11-18, DB20-22, DB24-26.
const Timezone DBField = 25
// Usage type classification of ISP or company.
// - (COM) Commercial
// - (ORG) Organization
// - (GOV) Government
// - (MIL) Military
// - (EDU) University/College/School
// - (LIB) Library
// - (CDN) Content Delivery Network
// - (ISP) Fixed Line ISP
// - (MOB) Mobile ISP
// - (DCH) Data Center/Web Hosting/Transit
// - (SES) Search Engine Spider
// - (RSV) Reserved
//
// In DB23-26, PX6-11.
const UsageType DBField = 26
// The special code to identify the nearest weather observation station.
//
// In DB17-18, DB20, DB22, DB24-26.
const WeatherStationCode DBField = 27
// The name of the nearest weather observation station.
//
// In DB17-18, DB20, DB22, DB24-26.
const WeatherStationName DBField = 28
// ZIP code or Postal code.
//
// See https://www.ip2location.com/zip-code-coverage.
//
// In DB9-12, DB14-16, DB18, DB20-22, DB24-26.
const Zipcode DBField = 29
var _dbs = dbs{
IP2Location: {
1: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, dbField_extra: {2, uint8(IP2Location), 1}},
2: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, ISP: {3, 0, dbtype_str}, dbField_extra: {3, uint8(IP2Location), 2}},
3: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, dbField_extra: {4, uint8(IP2Location), 3}},
4: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, ISP: {5, 0, dbtype_str}, dbField_extra: {5, uint8(IP2Location), 4}},
5: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, dbField_extra: {6, uint8(IP2Location), 5}},
6: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, ISP: {7, 0, dbtype_str}, dbField_extra: {7, uint8(IP2Location), 6}},
7: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, ISP: {5, 0, dbtype_str}, Domain: {6, 0, dbtype_str}, dbField_extra: {6, uint8(IP2Location), 7}},
8: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, ISP: {7, 0, dbtype_str}, Domain: {8, 0, dbtype_str}, dbField_extra: {8, uint8(IP2Location), 8}},
9: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, Zipcode: {7, 0, dbtype_str}, dbField_extra: {7, uint8(IP2Location), 9}},
10: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, Zipcode: {7, 0, dbtype_str}, ISP: {8, 0, dbtype_str}, Domain: {9, 0, dbtype_str}, dbField_extra: {9, uint8(IP2Location), 10}},
11: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, Zipcode: {7, 0, dbtype_str}, Timezone: {8, 0, dbtype_str}, dbField_extra: {8, uint8(IP2Location), 11}},
12: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, Zipcode: {7, 0, dbtype_str}, Timezone: {8, 0, dbtype_str}, ISP: {9, 0, dbtype_str}, Domain: {10, 0, dbtype_str}, dbField_extra: {10, uint8(IP2Location), 12}},
13: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, Timezone: {7, 0, dbtype_str}, NetSpeed: {8, 0, dbtype_str}, dbField_extra: {8, uint8(IP2Location), 13}},
14: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, Zipcode: {7, 0, dbtype_str}, Timezone: {8, 0, dbtype_str}, ISP: {9, 0, dbtype_str}, Domain: {10, 0, dbtype_str}, NetSpeed: {11, 0, dbtype_str}, dbField_extra: {11, uint8(IP2Location), 14}},
15: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, Zipcode: {7, 0, dbtype_str}, Timezone: {8, 0, dbtype_str}, IDDCode: {9, 0, dbtype_str}, AreaCode: {10, 0, dbtype_str}, dbField_extra: {10, uint8(IP2Location), 15}},
16: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, Zipcode: {7, 0, dbtype_str}, Timezone: {8, 0, dbtype_str}, ISP: {9, 0, dbtype_str}, Domain: {10, 0, dbtype_str}, NetSpeed: {11, 0, dbtype_str}, IDDCode: {12, 0, dbtype_str}, AreaCode: {13, 0, dbtype_str}, dbField_extra: {13, uint8(IP2Location), 16}},
17: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, Timezone: {7, 0, dbtype_str}, NetSpeed: {8, 0, dbtype_str}, WeatherStationCode: {9, 0, dbtype_str}, WeatherStationName: {10, 0, dbtype_str}, dbField_extra: {10, uint8(IP2Location), 17}},
18: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, Zipcode: {7, 0, dbtype_str}, Timezone: {8, 0, dbtype_str}, ISP: {9, 0, dbtype_str}, Domain: {10, 0, dbtype_str}, NetSpeed: {11, 0, dbtype_str}, IDDCode: {12, 0, dbtype_str}, AreaCode: {13, 0, dbtype_str}, WeatherStationCode: {14, 0, dbtype_str}, WeatherStationName: {15, 0, dbtype_str}, dbField_extra: {15, uint8(IP2Location), 18}},
19: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, ISP: {7, 0, dbtype_str}, Domain: {8, 0, dbtype_str}, MCC: {9, 0, dbtype_str}, MNC: {10, 0, dbtype_str}, MobileBrand: {11, 0, dbtype_str}, dbField_extra: {11, uint8(IP2Location), 19}},
20: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, Zipcode: {7, 0, dbtype_str}, Timezone: {8, 0, dbtype_str}, ISP: {9, 0, dbtype_str}, Domain: {10, 0, dbtype_str}, NetSpeed: {11, 0, dbtype_str}, IDDCode: {12, 0, dbtype_str}, AreaCode: {13, 0, dbtype_str}, WeatherStationCode: {14, 0, dbtype_str}, WeatherStationName: {15, 0, dbtype_str}, MCC: {16, 0, dbtype_str}, MNC: {17, 0, dbtype_str}, MobileBrand: {18, 0, dbtype_str}, dbField_extra: {18, uint8(IP2Location), 20}},
21: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, Zipcode: {7, 0, dbtype_str}, Timezone: {8, 0, dbtype_str}, IDDCode: {9, 0, dbtype_str}, AreaCode: {10, 0, dbtype_str}, Elevation: {11, 0, dbtype_str}, dbField_extra: {11, uint8(IP2Location), 21}},
22: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, Zipcode: {7, 0, dbtype_str}, Timezone: {8, 0, dbtype_str}, ISP: {9, 0, dbtype_str}, Domain: {10, 0, dbtype_str}, NetSpeed: {11, 0, dbtype_str}, IDDCode: {12, 0, dbtype_str}, AreaCode: {13, 0, dbtype_str}, WeatherStationCode: {14, 0, dbtype_str}, WeatherStationName: {15, 0, dbtype_str}, MCC: {16, 0, dbtype_str}, MNC: {17, 0, dbtype_str}, MobileBrand: {18, 0, dbtype_str}, Elevation: {19, 0, dbtype_str}, dbField_extra: {19, uint8(IP2Location), 22}},
23: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, ISP: {7, 0, dbtype_str}, Domain: {8, 0, dbtype_str}, MCC: {9, 0, dbtype_str}, MNC: {10, 0, dbtype_str}, MobileBrand: {11, 0, dbtype_str}, UsageType: {12, 0, dbtype_str}, dbField_extra: {12, uint8(IP2Location), 23}},
24: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, Zipcode: {7, 0, dbtype_str}, Timezone: {8, 0, dbtype_str}, ISP: {9, 0, dbtype_str}, Domain: {10, 0, dbtype_str}, NetSpeed: {11, 0, dbtype_str}, IDDCode: {12, 0, dbtype_str}, AreaCode: {13, 0, dbtype_str}, WeatherStationCode: {14, 0, dbtype_str}, WeatherStationName: {15, 0, dbtype_str}, MCC: {16, 0, dbtype_str}, MNC: {17, 0, dbtype_str}, MobileBrand: {18, 0, dbtype_str}, Elevation: {19, 0, dbtype_str}, UsageType: {20, 0, dbtype_str}, dbField_extra: {20, uint8(IP2Location), 24}},
25: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, Zipcode: {7, 0, dbtype_str}, Timezone: {8, 0, dbtype_str}, ISP: {9, 0, dbtype_str}, Domain: {10, 0, dbtype_str}, NetSpeed: {11, 0, dbtype_str}, IDDCode: {12, 0, dbtype_str}, AreaCode: {13, 0, dbtype_str}, WeatherStationCode: {14, 0, dbtype_str}, WeatherStationName: {15, 0, dbtype_str}, MCC: {16, 0, dbtype_str}, MNC: {17, 0, dbtype_str}, MobileBrand: {18, 0, dbtype_str}, Elevation: {19, 0, dbtype_str}, UsageType: {20, 0, dbtype_str}, AddressType: {21, 0, dbtype_str}, Category: {22, 0, dbtype_str}, dbField_extra: {22, uint8(IP2Location), 25}},
26: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, Region: {3, 0, dbtype_str}, City: {4, 0, dbtype_str}, Latitude: {5, 255, dbtype_f32}, Longitude: {6, 255, dbtype_f32}, Zipcode: {7, 0, dbtype_str}, Timezone: {8, 0, dbtype_str}, ISP: {9, 0, dbtype_str}, Domain: {10, 0, dbtype_str}, NetSpeed: {11, 0, dbtype_str}, IDDCode: {12, 0, dbtype_str}, AreaCode: {13, 0, dbtype_str}, WeatherStationCode: {14, 0, dbtype_str}, WeatherStationName: {15, 0, dbtype_str}, MCC: {16, 0, dbtype_str}, MNC: {17, 0, dbtype_str}, MobileBrand: {18, 0, dbtype_str}, Elevation: {19, 0, dbtype_str}, UsageType: {20, 0, dbtype_str}, AddressType: {21, 0, dbtype_str}, Category: {22, 0, dbtype_str}, District: {23, 0, dbtype_str}, ASN: {24, 0, dbtype_str}, AS: {25, 0, dbtype_str}, dbField_extra: {25, uint8(IP2Location), 26}},
},
IP2Proxy: {
1: {CountryCode: {2, 0, dbtype_str}, CountryName: {2, 3, dbtype_str}, dbField_extra: {2, uint8(IP2Proxy), 1}},
2: {CountryCode: {3, 0, dbtype_str}, CountryName: {3, 3, dbtype_str}, ProxyType: {2, 0, dbtype_str}, dbField_extra: {3, uint8(IP2Proxy), 2}},
3: {CountryCode: {3, 0, dbtype_str}, CountryName: {3, 3, dbtype_str}, ProxyType: {2, 0, dbtype_str}, Region: {4, 0, dbtype_str}, City: {5, 0, dbtype_str}, dbField_extra: {5, uint8(IP2Proxy), 3}},
4: {CountryCode: {3, 0, dbtype_str}, CountryName: {3, 3, dbtype_str}, ProxyType: {2, 0, dbtype_str}, Region: {4, 0, dbtype_str}, City: {5, 0, dbtype_str}, ISP: {6, 0, dbtype_str}, dbField_extra: {6, uint8(IP2Proxy), 4}},
5: {CountryCode: {3, 0, dbtype_str}, CountryName: {3, 3, dbtype_str}, ProxyType: {2, 0, dbtype_str}, Region: {4, 0, dbtype_str}, City: {5, 0, dbtype_str}, ISP: {6, 0, dbtype_str}, Domain: {7, 0, dbtype_str}, dbField_extra: {7, uint8(IP2Proxy), 5}},
6: {CountryCode: {3, 0, dbtype_str}, CountryName: {3, 3, dbtype_str}, ProxyType: {2, 0, dbtype_str}, Region: {4, 0, dbtype_str}, City: {5, 0, dbtype_str}, ISP: {6, 0, dbtype_str}, Domain: {7, 0, dbtype_str}, UsageType: {8, 0, dbtype_str}, dbField_extra: {8, uint8(IP2Proxy), 6}},
7: {CountryCode: {3, 0, dbtype_str}, CountryName: {3, 3, dbtype_str}, ProxyType: {2, 0, dbtype_str}, Region: {4, 0, dbtype_str}, City: {5, 0, dbtype_str}, ISP: {6, 0, dbtype_str}, Domain: {7, 0, dbtype_str}, UsageType: {8, 0, dbtype_str}, ASN: {9, 0, dbtype_str}, AS: {10, 0, dbtype_str}, dbField_extra: {10, uint8(IP2Proxy), 7}},
8: {CountryCode: {3, 0, dbtype_str}, CountryName: {3, 3, dbtype_str}, ProxyType: {2, 0, dbtype_str}, Region: {4, 0, dbtype_str}, City: {5, 0, dbtype_str}, ISP: {6, 0, dbtype_str}, Domain: {7, 0, dbtype_str}, UsageType: {8, 0, dbtype_str}, ASN: {9, 0, dbtype_str}, AS: {10, 0, dbtype_str}, LastSeen: {11, 0, dbtype_str}, dbField_extra: {11, uint8(IP2Proxy), 8}},
9: {CountryCode: {3, 0, dbtype_str}, CountryName: {3, 3, dbtype_str}, ProxyType: {2, 0, dbtype_str}, Region: {4, 0, dbtype_str}, City: {5, 0, dbtype_str}, ISP: {6, 0, dbtype_str}, Domain: {7, 0, dbtype_str}, UsageType: {8, 0, dbtype_str}, ASN: {9, 0, dbtype_str}, AS: {10, 0, dbtype_str}, LastSeen: {11, 0, dbtype_str}, Threat: {12, 0, dbtype_str}, dbField_extra: {12, uint8(IP2Proxy), 9}},
10: {CountryCode: {3, 0, dbtype_str}, CountryName: {3, 3, dbtype_str}, ProxyType: {2, 0, dbtype_str}, Region: {4, 0, dbtype_str}, City: {5, 0, dbtype_str}, ISP: {6, 0, dbtype_str}, Domain: {7, 0, dbtype_str}, UsageType: {8, 0, dbtype_str}, ASN: {9, 0, dbtype_str}, AS: {10, 0, dbtype_str}, LastSeen: {11, 0, dbtype_str}, Threat: {12, 0, dbtype_str}, dbField_extra: {12, uint8(IP2Proxy), 10}},
11: {CountryCode: {3, 0, dbtype_str}, CountryName: {3, 3, dbtype_str}, ProxyType: {2, 0, dbtype_str}, Region: {4, 0, dbtype_str}, City: {5, 0, dbtype_str}, ISP: {6, 0, dbtype_str}, Domain: {7, 0, dbtype_str}, UsageType: {8, 0, dbtype_str}, ASN: {9, 0, dbtype_str}, AS: {10, 0, dbtype_str}, LastSeen: {11, 0, dbtype_str}, Threat: {12, 0, dbtype_str}, Provider: {13, 0, dbtype_str}, dbField_extra: {13, uint8(IP2Proxy), 11}},
},
}
const (
dbProductMax = DBProduct(2)
dbTypeMax = DBType(26)
dbFieldMax = DBField(29)
dbField_extra = dbFieldMax + 1
)
type dbI struct {
col uint8
ptr uint8
typ uint8
}
type dbS [dbFieldMax + 2]dbI
type dbs [dbProductMax + 1][dbTypeMax + 1]dbS
func dbinfo(p DBProduct, t DBType) (r *dbS) {
if p <= dbProductMax && t <= dbTypeMax {
r = &_dbs[p][t]
}
return
}
func (i *dbS) Field(f DBField) (r dbI) {
if i != nil && f <= dbFieldMax {
r = i[f]
}
return
}
func (i *dbS) Info() (c uint8, p DBProduct, t DBType) {
if i != nil {
x := i[dbField_extra]
c, p, t = x.col, DBProduct(x.ptr), DBType(x.typ)
}
return
}
func (c dbI) IsValid() bool { return c.col != 0 }
func (c dbI) Column() uint8 { return c.col }
func (c dbI) IsPointer() bool { return ^c.ptr == 0 }
func (c dbI) PtrOffset() uint8 { return c.ptr }
func (c dbI) Type() uint8 { return c.typ }
func (p DBProduct) GoString() string {
if o := int64(p)*2 - 2; o >= 0 && o < 3 {
return _stringer_vzc2jgus[_stringer_DBProduct_GoString[o]:_stringer_DBProduct_GoString[o+1]]
}
return "DBProduct(" + strconv.FormatUint(uint64(p), 10) + ")"
}
func (p DBProduct) product() string {
if o := int64(p)*2 - 2; o >= 0 && o < 3 {
return _stringer_vzc2jgus[_stringer_DBProduct_product[o]:_stringer_DBProduct_product[o+1]]
}
return ""
}
func (p DBProduct) prefix() string {
if o := int64(p)*2 - 2; o >= 0 && o < 3 {
return _stringer_vzc2jgus[_stringer_DBProduct_prefix[o]:_stringer_DBProduct_prefix[o+1]]
}
return ""
}
func (f DBField) GoString() string {
if o := int64(f)*2 - 2; o >= 0 && o < 57 {
return _stringer_vzc2jgus[_stringer_DBField_GoString[o]:_stringer_DBField_GoString[o+1]]
}
return "DBField(" + strconv.FormatUint(uint64(f), 10) + ")"
}
func (f DBField) column() string {
if o := int64(f)*2 - 2; o >= 0 && o < 57 {
return _stringer_vzc2jgus[_stringer_DBField_column[o]:_stringer_DBField_column[o+1]]
}
return ""
}
const _stringer_vzc2jgus = "IP2LocationIP2ProxyDBPXAddressTypeAreaCodeASNCategoryCityCountryCodeCountryNameDomainDistrictElevationIDDCodeISPLastSeenLatitudeLongitudeMCCMNCMobileBrandNetSpeedProviderProxyTypeRegionThreatTimezoneUsageTypeWeatherStationCodeWeatherStationNameZipcodeaddress_typearea_codeasncategorycitycountry_codecountry_namedomaindistrictelevationidd_codeisplast_seenlatitudelongitudemccmncmobile_brandnet_speedproviderproxy_typeregionthreattime_zoneusage_typeweather_station_codeweather_station_namezip_code" // ratio 495 / 518 = 0.9
var _stringer_DBProduct_GoString = [...]int{0, 11, 11, 19}
var _stringer_DBProduct_product = [...]int{0, 11, 11, 19}
var _stringer_DBProduct_prefix = [...]int{19, 21, 21, 23}
var _stringer_DBField_GoString = [...]int{23, 34, 34, 42, 42, 44, 42, 45, 45, 53, 53, 57, 57, 68, 68, 79, 79, 85, 85, 93, 93, 102, 102, 109, 109, 112, 112, 120, 120, 128, 128, 137, 137, 140, 140, 143, 143, 154, 154, 162, 162, 170, 170, 179, 179, 185, 185, 191, 191, 199, 199, 208, 208, 226, 226, 244, 244, 251}
var _stringer_DBField_column = [...]int{251, 263, 263, 272, 272, 274, 272, 275, 275, 283, 283, 287, 287, 299, 299, 311, 311, 317, 317, 325, 325, 334, 334, 342, 342, 345, 345, 354, 354, 362, 362, 371, 371, 374, 374, 377, 377, 389, 389, 398, 398, 406, 406, 416, 416, 422, 422, 428, 428, 437, 437, 447, 447, 467, 467, 487, 487, 495}