java.lang.Object
net.i2p.router.transport.GeoIPv6
Generate compressed geoipv6.dat.gz file, and lookup entries in it.
Public only for command line use, not a public API, not for external use.
Method Summary
All MethodsModifier and TypeMethodDescriptionstatic voidMerge and compress CSV files to I2P compressed formatstatic String[]readGeoIPFile(I2PAppContext context, Long[] search, Map<String, String> codeCache) Lookup search items in the geoip file.
Method Details
readGeoIPFile
public static String[] readGeoIPFile(I2PAppContext context, Long[] search, Map<String, String> codeCache) Lookup search items in the geoip file. See below for format.- Parameters:
context- the I2P app contextsearch- a sorted array of IPs to searchcodeCache- the country code cache- Returns:
- an array of country codes, same order as the search param, or a zero-length array on total failure. Individual array elements will be null for lookup failure of that item.
main
Merge and compress CSV files to I2P compressed formatGeoIPv6 infile1.csv[.gz] [infile2.csv[.gz]...] outfile.dat.gz
Used to create the file for distribution, do not comment out.
- Parameters:
args- command line arguments