Android的:如何设置两个移动devcies(Wi-Fi或网络)之间的连接 [英] Android: How to setup a connection between two mobile devcies (Wi-Fi or network)

查看:212
本文介绍了Android的:如何设置两个移动devcies(Wi-Fi或网络)之间的连接的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我开发我在哪里使用Facebook的SDK登录按钮获取好友列表游戏应用程序。我想发送邀请,挑战上的应用程序同龄人。因此,应用程序接收到来自别人,他们希望接受挑战的请求。

I am developing a game app where I am using Facebook SDK login button to retrieve the friend list. I want to send an invite to challenge their peers on the app. So the app receives a request from someone that they want to be challenged.

我不希望使用Facebook的使用通知的请求对话框。我希望我自己的应用程序接收通知,并通知传入挑战用户。

I do not want to use the request Dialog that uses facebook notifications. I want my own app to receive the notification and notify the user for incoming challenge.

我做了一些研究,我可以使用NSD可惜只允许你连接到人在同一网络上。我希望能够从远处连接到朋友。我听说你可以使用电子邮件,但我还没有发现任何文件。

I did some research and I could use the NSD but unfortunately it only allows you to connect to people on the same network. I want to be able to connect to friends from far away. I heard you can use emails but I have not found any documentation.

如果你可以点我到正确的方向我真的AP preciate它。

If you can point me to the right direction I really appreciate it.

推荐答案

好吧,我建议你正在努力实现的,使用Facebook的SDK来获取用户好友的数据是什么下面的方法,有将在一个id和名称响应。你可以使用这个Facebook的帐号给人们在系统中唯一的ID。当人们想要去挑战他们的朋友使用来自Facebook好友列表和查找其ID在你的系统,如果这些朋友已经注册/安装应用程序。如果是这样你发送通知给他们,如果没有可能是你建议他们向他们发送电子邮件或短信与URI来要求他们安装应用程序。尝试图形API资源管理器玩弄你可以从图形API获取数据。

ok i suggest the below approach for what you are trying to achieve, use facebook sdk to get the user friend data, there will be an id and name in the response. you can use this facebook id to give people a unique id in your system. when people are wanting to challenge their friends you use their id from facebook friendlist and lookup in your system if these friends have registered/ install your application. if so you send a notification to them if not may be you suggest them to send them a email or sms with a uri to ask them to install the application. Try the Graph API Explorer to play around with the data you can get from the Graph API.

这篇关于Android的:如何设置两个移动devcies(Wi-Fi或网络)之间的连接的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆