作者热门文章
- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
在 Twitter 兼容的 API 中,什么是 setAPIRootURL 值?
twitter=new Twitter("username","password");
twitter.setAPIRootUrl("http://yamba.marakana.com/api");
最佳答案
这只是指向您的 Twitter 兼容服务的 API 端点。
然后实际查询会“低于”,如 http://yamba.marakana.com/api/timeline/home.json ETC。这个 Marakana 是一个基于 status.net 的类似 Twitter 的公共(public)服务。其他的是identi.ca(api端点是http://identi.ca/api/)等等。
正如 Daniel 所写,Twitter 是默认设置。 setAPIRootUrl 的 javadoc 说:
/**
* Set this to access sites other than Twitter that support the Twitter API.
* E.g. WordPress or Identi.ca. Note that not all methods may work! Also,
* search uses a separate url and is not affected by this method (it will
* continue to point to Twitter).
*
* @param url
* Format: "http://domain-name", e.g. "http://twitter.com" by
* default.
*/
public void setAPIRootUrl(String url) {
所以基本上连接到 Twitter 你不需要关心那个方法。
关于android - JTwitter for android 中的 setAPIRootUrl 是什么?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5736158/
在 Twitter 兼容的 API 中,什么是 setAPIRootURL 值? twitter=new Twitter("username","password"); twitter.setAP
我是一名优秀的程序员,十分优秀!