如何将Twitter应用程序集成到我的iPhone中?

问题描述:


可能重复:

如何从iPhone连接到Twitter?


可以有人用简单的示例来说明如何将Twitter应用程序集成到我的iPhone应用程序中吗?

can anybody please explain how to integrate the twitter app in my iphone app with simple example?

您拥有twitter iOS SDK,可以从此处下载。而且那里的文档足以帮助您入门。

You have twitter iOS SDK, which can be downloaded from here. And the documentation there is good enough to get you started.

从iOS 6开始,您可以使用Apple自己的 SocialFramework 即可发布推文。从Apple的文档

From iOS 6 onwards, you can use Apple's own SocialFramework to post tweets. From Apple's documentation


社交框架(Social.framework)提供了一个简单的接口
,用于访问用户的社交媒体帐户。这个框架
取代了iOS 5中引入的Twitter框架,并为其他社交帐户(包括Facebook和新浪的微博
服务)增加了
的支持。应用程序可以使用此框架发布状态更新,并将
的图片发布到用户的帐户中。该框架与Accounts框架
一起为用户提供单一登录模型,并确保
对用户帐户的访问获得批准。

The Social framework (Social.framework) provides a simple interface for accessing the user’s social media accounts. This framework supplants the Twitter framework that was introduced in iOS 5 and adds support for other social accounts, including Facebook and Sina’s Weibo service. Apps can use this framework to post status updates and images to a user’s account. This framework works with the Accounts framework to provide a single sign-on model for the user and to ensure that access to the user’s account is approved.