Google Maps autocomplete Functionality from Apple Maps for Objective C? - ios

I need to implement autocomplete Functionality for a City-Name Search in Objective C.
Basically at the Moment I would use the Google Maps autocomplete Functionality from here: https://developers.google.com/places/documentation/autocomplete
But I don't like displaying the powered by google - logo.
That's the reason why I'm asking here, is there a way to implement autocomplete Functionality using Apple Maps API or similar ?
Thanks for any advice

Check this out - Yahoo YQL console.
There you can put queries like this - it gives you all places starting with San:
select * from geo.places where text="San%"
The resulting JSON / XML can act as data source to what you are trying to display for autocomplete results.
As I can see they allow up to some number of free queries for non-commercial use, and beyond that they charge. You may check it out here and here.

If you dont want to implement it yourself, you can use this service called 'Autocomplete as a Service' which is specifically written for these purposes. You can access it here - www.aaas.io. It does support large datasets and you can apply filters as well. You just add your data and use the API URL in your autocomplete data source.
Disclaimer: I am founder of it. I will be happy to provide this service to you.

Related

Getting street names in iOS

I need to offer users a way to type an address in an UITextField with an autocompletion functionality as user is introducing the text. I've been looking for the best way to implement this, but I'm still not sure: is it possible to get a list of street names for a certain city? Or should I being provided such information in another and custom way (service request, a file with that information...)?
My application is for iOS 7+
Thanks
You can do this by using Google Places autocomplete API.This api provide you addreess that you want in list.
For More info please refer this example that help you to how to use Google Places autocomplete with your application
https://maniacdev.com/2013/10/ios-completion-providing-search-with-autocompletion-and-map-marking-using-google-places
you can find sample code for the same on Github find Below link for this
https://github.com/chenyuan/SPGooglePlacesAutocomplete
Hope this may help you.

Simple way to get surrounding area name like Facebook?

Hi all,
In Facebook app, when adding a new post, the app show surrounding area name.
This way of sharing place is cool, since it's automatically, and users don't need to choose from a list of venue names like Instagram app.
What is a quick way to get the same result as Facebook app?
I've used similar things before through services like google maps api.
https://developers.google.com/maps/
You can pass them a lat and long and get various bits of info back.
I'm not sure if that is now a paid service though. It wasn't when I last used it but I think it changed.
There may be other similar services available.
A more specific page from Google maps api...
https://developers.google.com/maps/documentation/geocoding/#ReverseGeocoding
I found that iOS have a built-in api CLGeocoder, this is more convenient to use than Web API:
- (void)reverseGeocodeLocation:(CLLocation *)location completionHandler:(CLGeocodeCompletionHandler)completionHandler;
This return you CLPlacemark with places, and areas.
http://developer.apple.com/library/ios/#documentation/CoreLocation/Reference/CLPlacemark_class/Reference/Reference.html
Here's a detailed comparison of all the geolocation solutions - Foursquare, Facebook, Google etc etc - http://crschmidt.net/blog/archives/463/working-with-place-apis-aka-how-i-spent-my-spring-vacation/
But this is actually what you are looking for if you intend to use Facebook Graph APIs for "places" - https://developers.facebook.com/docs/tutorials/ios-sdk-tutorial/show-nearby-places/
Specifically step 3 (https://developers.facebook.com/docs/tutorials/ios-sdk-tutorial/show-nearby-places/#step3)
Now that you have the current location, use it with the
FBPlacePickerViewController object to show the place picker when the
user taps on the ''Where are you?'' menu option.

Google Places API Violation

I am using Google Places API to pull a list of resturants, and I am displaying them on map. However, since Apple has switched there map services over from Google in iOS 6.0, I am now in violation of Google's terms of use, which states that you must display Google data on a Google map.
"If your application displays Places API data on a map, that map must be provided by Google."
https://developers.google.com/places/policies#terms_of_use
I obviously need to change the map, because I am not going to release an application that is in violation. Any thoughts or suggestions on what to do? Should I go Google Maps with a web view? Does apple have some sort of Google Places API alternative?
Edit:
Using Google Maps through a web view is a hassle, i'd like to find an alternative to that, although it would technically work.
I decided to use Google Maps JavaScript API. Although, it is a little more difficult to deal with, mainly the JavaScript through Objective-C, it is a solution. The map is displayed through a web view, and I use JavaScript to interact with the map.
https://developers.google.com/maps/documentation/javascript/tutorial#api_key
I will wait to accept this answer, to see if anyone else has any thoughts. I just wanted to post this, in case it helps someone else.
Edit:
Google recently released a Maps SDK for iOS, this is the better solution now.
https://developers.google.com/maps/documentation/ios/
I would try to directly contact Google, explaining the situation, and ask them for written permission to use Apple's maps. This is more a legal question than programming. One would think that Google is aware that you can no longer display their maps using Apple's API and that, even regardless of the map, they would want you to use their places, as doing so generates advertising revenue for them.
Agree with #Owen here - you could get permission to leave your app unchanged until some possible future date when you might have to change it, or could you definitely go to the effort of changing it now and then possibly have to change it again in the future for some other reason.
If you could get a 100% guarantee that you could change it once and never have to change it again then I'd say do it now, but nothing's certain.

iOS: Google Calendar Example

Searching around the net for almost 1 day I still did not see any simple good example of an app that implements the Google Calendar API. Or even simple explanation on how to implement the API is still not available. Can someone help me please? I'm a newbie to iOS. I need to learn how to create an event using the Google Calendar API through my app in iOS. I need a sample simple code...
Here are some very useful links when trying to figure out the google calendar api. http://code.google.com/p/gdata-objectivec-client/wiki/GDataObjCIntroduction and mainly http://code.google.com/p/iphone-gcal/. I just downloaded the source code from the second link and worked from there. It was great!
The Google Calendar API, like most Google API's, provides a straightforward REST interface. Instead of focussing first on how to create calendar events, learn how to interact with a RESTful web service. Once you know how to do that, you only have to learn what calls to make to accomplish your goal, and that's already well documented.

Getting autocomplete googleMaps data into a Delphi combobox

I am doing a Delphi transport application interacting with GoogleMaps APi and i would like to propose all "near by" names coming from the autocomplete Google Maps API when i enter the starting adress of the direction.
All of this will be displayed in a TCombobox when would be changed on the OnChange propertie.
Is that possible ??? ever heard of it ???
Thanks a lot
Gwenael
There is a part of the Google Maps API called The Google Places Autocomplete API. You can send requests (in the examples part of the reference page there is also the example with bounds for your purpose) as you will type in your combo box (ideally after some short delay for typos corrections). As the result you can receive either JSON or XML format file. After you parse it, you will get the list of appropriate suggestions.
I'm not sure with the Google Maps API Key; if it's possible to use it in standalone application (and about the limitations) because I haven't implemented static part of the Google Maps yet.
My first thought (assuming an approach which is based on remote controlling the web interface) was: this can be solved using TWebBrowser and friends (IWebBrowser2, IHTMLElement etc.). See my answer on this question to get a feeling for this. You could use Embedded Web Browser from bsalsa for easy access to all the Internet Explorer functionality.
My second thought was: there might be a part in the official API for this. But this I don't know. If there is none then the above approach could be a (work-intensive) workaround.
Yes, it's possible.
I have written a free and open source component that implements the Google Place Autocomplete and Google Place Details API's:
https://carbonsoft.co.za/components/
or
https://github.com/RynoCoetzee/TRCGPlaceAutoCompleteCombo

Resources