我对 Twitter 的使用还不够熟悉它的术语或它的工作方式,所以请帮助我理解我手头的问题。
我收到了一些 Twitter 用户通过 RSS feed 发布的最后 20 个状态更新,该 feed XML 被解析并且状态显示在 ListView 中。这意味着我在字符串变量(ListView 的行)中拥有原始推文。当我单击 ListView 项目时,我会看到“转发推文”和“发布回复”选项。
据我了解,转发时我只需将我的 状态更新为:
RT @orig-poster <original tweet>
并且在发布回复时我只需更新我的状态 为:
@orig-poster <my tweet>
我浏览了 Jwitter 库(Twitter 类)的 JavaDocs,发现了一个 setStatus(String)
方法。我认为我不必使用 JTwitter 库中 Twitter 类的 retweet() 或 reply() 函数。
我的理解正确吗?如果我在这里错了或者遗漏了什么,请纠正我。
谢谢!
I have not used Twitter enough to become familiar with its terminology or the way it works, so please help me in understanding the problem I have at hand.
I am getting last 20 status updates posted by some Twitter user via RSS feed, the feed XML is parsed and the statuses are displayed in a ListView. Which means that I have the original tweet in a String variable(row of ListView). When I click a ListView item, I get the option of "Re-tweeting" and "post reply".
As, I understand it, when re-tweeting I will have to just update my status as:
RT @orig-poster <original tweet>
and when posting a reply I will have to just update my status as:
@orig-poster <my tweet>
I skimmed through the JavaDocs of the Jwitter library(Twitter class) and found a setStatus(String)
method. I dont think I will have to make use of retweet() or reply() functions of the Twitter class in JTwitter library.
Is my understanding correct? Please correct me if I am wrong here or missing anything.
Thanks!
发布评论
评论(4)
转推和回复比简单的语法差异要复杂一些:
回复有一个 in_reply_to_status_id 字段,指示提交的推文正在回复什么推文(由推文 ID 给出)(请参阅 http://apiwiki.twitter.com/Twitter-REST-API-Method:-statuses%C2% A0update)。
转发有两种形式:
Retweets and Replies are a bit more complex than simple syntax differences:
A reply has an in_reply_to_status_id field that indicates what Tweet (given by Tweet id) the submitted tweet is replying to (see http://apiwiki.twitter.com/Twitter-REST-API-Method:-statuses%C2%A0update).
A retweet has two forms:
您说得对,只需设置您的状态即可发送转发和回复。
如果可以的话,请使用 Twitter.reply() 进行回复,因为这可以向 Twitter 提供线程信息,其他客户端可以使用该信息进行对话显示。
如果您想要新式的转发,请使用 Twitter.retweet()。新风格与旧风格只是品味问题。新型转发将在 Twitter Web 客户端中显示为原始推文,并且可能会被其他客户端忽略,因为它们不包含在用户的标准时间线中。我个人更喜欢旧式,它更可靠并且允许您添加自己的评论。
You're quite right that you can send retweets and replies just by setting your status.
If you can, use Twitter.reply() for replies, as this provides threading information to Twitter, which other clients may use to give conversational displays.
If you want new-style retweets use Twitter.retweet(). New-style v old-style is a matter of taste. New-style retweets will display as the original tweeter in the Twitter web client, and may be ignored by other clients as they're not included in the standard timeline for a user. Personally I prefer old-style, which is more reliable and allows you to add your own comment.
正如其他人指出的那样,Twitter 上的数据呈现方式有所不同。您必须使用 retweet() 或reply(),以便充分利用 API。
As others pointed out there are difference how the data is presented on Twitter. You have to use retweet() or reply() so get the full out of the API.
术语是正确的(这就是 Twitter 用户转发/更新其状态的方式),但我不确定该库。
回复和转推可以链接回原始推文,因此我认为这就是 API 具有reply() 和 retweet() 方法的原因,这就是您应该使用这两个函数的原因。
编辑:通过“反向链接”,我的意思是,在 Twitter 上,如果一条推文被转发,它会告诉您最初是谁发布的。如果一条推文已被回复,您可以查看该条回复的推文。
The terminology is correct (that's how Twitter users retweet/update their statuses) but I'm not sure about the library.
Replies and retweets can be linked back to the original tweet, so I assume this is why the API has a reply() and retweet() methods and that's why you should use those two functions.
Edit: By "linking back", I mean that, on twitter, if a tweet has been retweeted, it tells you who originally tweeted it. If a tweet has been replied to, you can view the tweet of which it is a reply.