| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Name | Name | Last commit date | ||
|---|---|---|---|---|
###Ziptastic Object
####Introduction
####Documentation
#####Constructor Summary
| Constructor | Description |
|---|---|
| Ziptastic(String apiKey) | Creates an empty Ziptastic object with the Ziptastic API Key value. |
#####Method Summary
| Method | Description |
|---|---|
| GetFromLongLat(double longitude, double latitude, int radius) | Creates a url based on reverse geocoding, passes the url to the HTTPRequest method, and returns the results of a ReverseGeocoding API request. |
| GetFromZipcode(int zipcode) | Creates a url based on forward geocoding, passes the url to the HTTPRequest method, and returns the results of a ForwardGeocoding API request. |
####Usage Examples####
Forward Geocoding
Ziptastic zipObj = new Ziptastic(apiKey); String result = zipObj.GetFromZipcode(zipcode); System.out.println(result);
Reverse Geocoding
Ziptastic zipObj = new Ziptastic(apiKey); String result = zipObj.GetFromLongLat(longitude, latitude, radius); System.out.println(result);
####Sample Output####
Invalid Key Request
{
"message": "API Key Invalid."
}
Valid Key Request
[
{
"city": "Owosso",
"geohash": "dpshsfsytw8k",
"country": "US",
"county": "Shiawassee",
"state": "Michigan",
"state_short": "MI",
"postal_code": "48867",
"latitude": 42.9934,
"longitude": -84.1595,
"timezone": "America/Detroit"
}
]
####Maven Plugins####
####Future Work####
| Back | FazBrowse Home | New Git URL |