GCMRegistrar vs GoogleCloudMessaging which to use? - google-cloud-messaging

Another one of my stupid questions probably.
I am confused on which to use GCMRegistrar or GoogleCloudMessaging, i know that GCMRegistrar is deprecated and i want to use GoogleCloudMessaging API but the problem is i can't find the jar files for it. so if you could help me by giving me jar file for the new GoogleCloudMessaging API it would help me a lot.
Thanks in advance!!!

That's because GCM before was a library, now it's part of the Google Play Services. So to use it you will need to follow this tutorial and download and include the Google Play services on your project using this page
You are welcome :)

Yes gcm.jar is deprecated. But I didn't find good explanation "why"! GCMRegistrar was good helper class. When you look at its sources you'll find that it's almost the same as example code of (now preferred) GoogleCloudMessaging API. So Google wants everyone to write (or copy) again and again the same code into all projects using GCM? Or shall every developer create his/her own helper class, a GCMRegistrar alike?
On the other hand when I use Google Play Services library, I use a library with a lot of ballast I don't need, I need just GCM, I'm not interested in other services.
Why don't they create a library for each service? GCM, Maps, Ads, Wallet, ... so every developer can include only what he needs.
Google's approach is far from optimization. I want to create as small and fast apps as possible. Google obviously doesn't. :-(

gcm.jar is deprecated.
Use GoogleCloudMessaging. comes with GooglePlayServices Library.
SDK Manager > Extras > Google Play Services.
then import google play services library PROJECT : Right Click > Properties >Android > Add...
and the project is in C:...\sdk\extras\google\google_play_services\libproject\google-play-services_lib
UNCHECK "Is Library"

Related

How to fetch POP3/SMTP email using Cordova

I'm new to mobile development and have been looking for a way to retrieve basic email information from simple POP3/SMTP email servers.
I've seen many posts on how to send email using numerous Cordova plugins, etc., but I'm simply trying to retrieve email information for various listing and analysis purposes.
Is this even possible?
Thanks for the help and suggestions on where to start.
Cordova does not have built-in functionality for POP3/SMTP access. As inside your codova app you are running in the javascript/webview sandbox, you don't have socket access, so you can't implement this kind of functionality there.
This leaves you no choice but to implement a Cordova Plugin. You are in Objective-C land now, but unfortunately there aren't any convenient classes in the standard framework for accessing POP3/SMTP. Your best bet is using a library like MailCore.
Details on how to implement a Cordova Plugin (as well as passing the relevant email data from and to your javascript layer) are outside the scope of a simple StackOverflow answer, but the process is (fortunately) well documented.

Open Contrail API, post request on project resource

I'm working on a cloud project and I have to use Contrail it provides a RESTful API to use, but it is documentation is too small. I would like to know how to perform rest requests, especially post requests on "project" resource.
Each Contrail config node provides supported API details(searchable) at http://:8082/documentation/index.html
You could also check here which is a bit old but should serve your project API needs.
Your question is old, but as there are no other answers I thought I would contribute one. Were you interested in an answer or just wanted to share the documentation you'd written? I agree with you that Contrail documentation is very scarce, and every attempt to contribute to it should be appreciated. I had to integrate with Contrail API a while ago, and found out that in some cases I had to call OpenStack APIs to get the job done (Contrail is built on top of OpenStack). Project and user management were some of them.
I wrote a documentation about Contrail api, For each resource I mention the allowed methods and which parameters to integrate on the request body and I test it until I get it to work finally I put an example. I haven't finished the documentation, I stopped working on Open Contrail. The documentation is my personal try maybe it would be useful and maybe it contains some mistakes, Thus, I would like to share it. You can find it here.

how to access UCWA API in android code?

I want to access UCWA API in android code. Is it possible?.
If possible, pls give me an idea and hello world program.
does UCWA API support for Video Chat and Screen Sharing?
Yes, UCWA is a REST based API, so there's no reason why you wouldn't be able to access it from an Android app. Your best bet is to look through the samples on http://ucwa.lync.com/
There are no known Java libraries available, so you have to do all of that on your own. Paul's link is a good place to start, however you might also find the MS pages on a C# implementation useful(1), they certainly are cleaner than the Javascript based samples at http://ucwa.lync.com/
As for supporting video chat and screen sharing, the answer for now seems to be no. UCWA may be able to initiate these on the users Lync client though.
(1) http://msdn.microsoft.com/en-us/library/office/dn551186%28v=office.15%29.aspx

Is there to read the data from google spreadsheet link in IOS?

i am currently work on an IOS project which is required to read data from Spreadsheet in google drive. I have done some research and i found Google APIs client library for Objective C. However, i still have problem of retrieving data from spreadsheet. i find only the sample code that can read the file in drive from the drive that user login. But what i actually want in this project is using Google Drive as the Database. In short i want to retrieve data from the url like this https://docs.google.com/spreadsheet/ccc?key=0AoYC7S60-ywcdHVZYzh4ZlZ1Y3J5R2ZGbnBqY09jdkE&usp=sharing.
So is there a solution for this kind of problem? and if there a good site that provide a good tutorial to this kindda problem?
Google apps script is probably a simpler option. You can set it up as a web app, and read/write to the spreadsheet via the webapp. The google-spreadsheet-api is hard to use as there is little good documentation.
Refer, Google's Sample Code it can help you. You can also use GData Objective C Client to use it.

Set instant messenger display message programmatically

Would a script that sets display messages for instant messengers be simple or complex? After some searching, there doesn't seem to be any information about this at all.
For the sake of an example, if I had a text file of quotations, would it be possible to have the google talk display message change to a different quotation hourly?
Depends on which client you're using. As far as I know, Google's client doesn't offer any interface for plugins, but the open source instant messenger Pidgin does. I think there already is a plugin for what you want to do, but you can write your own using the documentation and examples they give you.
The complexity of writing something like this is based on how much C or Perl you know, since you can program in either of those for Pidgin. Reading code from other people's plugins, you should be able to figure out the Pidgin API.
You can use Kik API to programmatically send rich content and files between mobile applications. It is available for iPhone and Android platforms and takes only about 5 lines of code to integrate into your app. There is more info at the API website: http://www.kik.com/dev
Disclaimer: I'm on of the developers behind Kik API :)