Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 13 lines (12 sloc) 0.415 kb
800a935 Initial revision
Thomas J Mather authored
1 //an example of how to lookup the isp or org of a ip address
2 using System;
3 using System.IO;
4 class Appa0{
5 public static void Main(String[] args){
6 //open the database
8fa9816 added memory caching option to examples
Thomas J Mather authored
7 LookupService ls = new LookupService("/usr/local/share/GeoIP/GeoIPOrg.dat", LookupService.GEOIP_STANDARD);
800a935 Initial revision
Thomas J Mather authored
8 //get org of the ip address
9 String orgorisp = ls.getOrg("24.24.24.24");
10 Console.Write(" org: " + orgorisp + "\n");
11 }
12 }
Something went wrong with that request. Please try again.