-
Notifications
You must be signed in to change notification settings - Fork 310
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Base16 Support? #44
Comments
Can you point me in the right direction of the datasource and the flavour
of base16 they are using? If that is universally used and usefil, we could
add an overload of the method that takes a format spec and you could use
that one like so: `fromGeohashString(EncodedAs.BASE16)`
…On Thu, May 14, 2020, 17:29 Andrew Serff ***@***.***> wrote:
I have a datasource that uses geohashes encoded with Base16 and I'm trying
to figure out how to use your library with that data. I have tried to
decode using GeoHash.fromGeohashString() but it appears it's assuming the
GeoHash is Base32, so it's incorrect. Is there a way to use your library
with Base16 geohashes?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#44>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAAKAKG2KMOJU3ZPHNJ6FJTRRQE4ZANCNFSM4NAZKGWQ>
.
|
Unfortunately, the datasource isn't public. I can try to get you more information if you can expand on what you mean by |
If by |
yeah, the question is whether it also uses some special characters easy for
human reading as geohash base32 does.
…On Wed, May 20, 2020, 15:10 vinerich ***@***.***> wrote:
If by base16 u mean hex maybe this is something for you:
https://stackoverflow.com/questions/44654895/convert-hexadecimal-string-to-base32-in-java
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#44 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAAKAKDDUKLNTOY6F5CDWTTRSPJFFANCNFSM4NAZKGWQ>
.
|
The character set is:
Latitude Range is I actually tried the hex conversion to base32 and it didn't seem to work. I can try it again as it does seem like that should work. In any case, I think it would be good for this library to support more than just Base32. Base16 and base64 are out there, so it would be nice to have one library to use for any geohash you find. |
Could you supply a base16/hex encoded GeoHash and the corresponding Latitude and Longitude? As I see this it should be fairly trivial to implement but still somebody needs to have the time: https://stackoverflow.com/questions/49136896/geohash-16-how-to |
Sure, I choose a spot in Denver: I tried the Base16 (Hex) conversion to Base32 again and got: |
Yeah I forgot that geohash base32 differs in its alphabet from the RFC base32 so probably this is better suited in the library. Possible we should switch to the desired geohash precision instead of character precision then. |
I thought about it and it really shouldn't be the problem to integrate it. I would also volunteer to do it. Hopefully will be done somewhere next week. Last thing to note is that it would break some existing functionality again since atm the method-names are just |
@vinerich We can provide overloads of the methods that take an |
Yeah that's better. Thanks for the hint. |
I have a datasource that uses geohashes encoded with Base16 and I'm trying to figure out how to use your library with that data. I have tried to decode using
GeoHash.fromGeohashString()
but it appears it's assuming the GeoHash is Base32, so it's incorrect. Is there a way to use your library with Base16 geohashes?The text was updated successfully, but these errors were encountered: