连接到Facebook的Java小程序? [英] Connecting Facebook to a Java applet?

查看:630
本文介绍了连接到Facebook的Java小程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们的软件工程类目前正在制定一项任务,我们是要创建一个Java小应用程序连接至Facebook,允许用户选择自己的好友列表中的朋友,然后检索朋友的生日,并返回的当天本周的朋友出生。

Our software engineering class is currently working on an assignment where we're to create a Java applet that connects to Facebook, allows the user to choose a friend from their friend list, then retrieves that friend's birthday and returns the day of the week that friend was born on.

现在,我已经完成了Java小程序部分,而且它目前允许用户输入任何一天,月,年。本周算法的一天完美的作品。不过,我还没有完成Facebook的部分还没有,因为我们班有不可以涵盖任何形式的Facebook开发的所有迄今为止,并分配在一个星期到期。

Now, I've completed the Java applet portion, and it currently allows a user to input any day, month, and year. The day of the week algorithm works perfectly. However, I haven't completed the Facebook portion yet since our class has not covered any sort of Facebook development at all thus far, and the assignment is due in one week.

不过,我发现所谓的RestFB的API,它似乎将是很容易的一周学习或因此离开之前,此分配所致。我想知道如果任何人有与Facebook连接到Java小程序的经验,如果是这样,怎么能做到呢?所有我需要做的是连接的用户,让他们的好友列表,并获得所选择的朋友的生日。没有人有任何想法如何可以做? (我知道一样多关于Facebook发展作为我的老师,但我愿意学习。)

Anyway, I found an API called "RestFB" which seems like it would be easy enough to learn in the week or so left before this assignment is due. I was wondering if anyone had experience with connecting Facebook to a Java applet, and if so, how can it be done? All I need to do is connect the user, get their friends list, and get the birthdate of the chosen friend. Does anyone have any idea how that could be done? (I know just as much about Facebook development as my instructor, but I'm willing to learn.)

推荐答案

我敢肯定,这是可以做到。然而,从一个小程序调用的API的Facebook只会工作,如果applet是受信任的......就算是小程序会尝试连接到服务不同的主机,该小程序从启动了一个在

I'm sure it can be done. However, calling Facebook APIs from an applet will only work if the applet is trusted ... 'cos the applet will be trying to connect to a service on a different host to the one that the applet was launched from.

另外,applets是不是从安全角度来看是个好主意......除非你认为甲骨文与Java-IN-A-浏览器安全记录是奇迹般地将改善与Java 7.0.13u及更高版本。 (即使他们这样做,有大多数用户不保持他们的Java插件了最新的问题。)

Also, applets are not a good idea from a security perspective ... unless you think that Oracle's record with Java-in-a-browser security is miraculously going to improve with Java 7.0.13u and later. (And even if they do, there is the problem that most users don't keep their Java plugins up-to-date.)

这篇关于连接到Facebook的Java小程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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