chsh / geohex4j Goto Github PK
View Code? Open in Web Editor NEWGeoHex implementation for Java
GeoHex implementation for Java
I tried to upload geohex4j library on the issue https://issues.sonatype.org/browse/OSSRH-17037.
Then operator said.
Do you or your organization own the domain geohex.net? If not, please read:
http://central.sonatype.org/pages/choosing-your-coordinates.html
You may also choose a groupId that reflects your project hosting, in this case, something like com.github.chsh
I thought public domain "geohex.net" is owned by @sa2da.
So what should we do..?
I think the best thing is asking him to allow to use the group id..
Fix for Math.round problem.
geohex4j seems to have a same issue as tkawachi/c-geohexv3#3 .
Test code is below:
package net.geohex;
import net.geohex.GeoHex;
public class Main {
public static void main(String[] args) {
GeoHex.Zone z1 = GeoHex.getZoneByCode("DO0");
GeoHex.Zone z2 = GeoHex.getZoneByLocation(z1.lat, z1.lon, z1.level);
System.out.println("" + z1.x + ", " + z1.y);
System.out.println("" + z2.x + ", " + z2.y);
}
}
The output is:
-10, -37
-37, -10
See the link above for same test code with javascript.
Official project announced the license was changed to MIT.
A StringIndexOutOfBoundsException
is raised for a few zone codes that are processed by GeoHex.decode()
. The following code reproduces this issue:
String code = GeoHex.encode(-82.6, -58.7, 0); // resulting code is 'Bc'
Zone zone = GeoHex.decode(code);
This problem appears only for zones around the north and south pole (in different levels of precision).
Update logics to latest version.
I would like to use the library from gradle, but currently it's not seems to be uploaded to any public repository....
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.