Skip to content

qzteam/clj-ip2region

Repository files navigation

clj-ip2region

Build Status Coverage Status License Dependencies Status Clojars Project

ip2region 的 Clojure 封装。

  • 内置数据库文件
  • 仅保留线程安全的内存查询算法

Install

project.clj 中引入最新版本的依赖:

[clj-ip2region "x.y.z"]

Usage

(require '[clj-ip2region.ip2region :as ip2region])
; => nil
(ip2region/ip->region "119.29.29.29")
; => {:country "中国", :province "北京", :city "北京市", :isp "腾讯"}
(ip2region/ip->region "8.8.8.8")
; => {:country "美国", :province "0", :city "0", :isp "Level3"}

License

This program and the accompanying materials are made available under the terms of the Eclipse Public License 2.0 which is available at http://www.eclipse.org/legal/epl-2.0.

This Source Code may also be made available under the following Secondary Licenses when the conditions for such availability set forth in the Eclipse Public License, v. 2.0 are satisfied: GNU General Public License as published by the Free Software Foundation, either version 2 of the License, or (at your option) any later version, with the GNU Classpath Exception which is available at https://www.gnu.org/software/classpath/license.html.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published