模塊化的Android異步網絡請求:RoboSpice

jopen 11年前發布 | 33K 次閱讀 Android Android開發 移動開發

RoboSpice是一個模塊化的Android庫能夠讓編寫異步網絡請求變得非常簡單。它專門用于網絡請求,通過使用Spring Android或者Google Http Client等擴展模塊可支持REST請求。

模塊化的Android異步網絡請求:RoboSpice

RoboSpice的主要特性:

  • supports Android starting from SDK version 8 (Froyo / 2.2.x)
  • executes network requests asynchronously (in a background AndroidService)
  • supports REST out of the box (using Spring Android or Google Http Client).
  • is strongly typed ! You query webservices using POJOs and you get POJOs as request results.
  • enforces no constraints neither on POJOs used for requests nor on Activity classes you use in your projects
  • caches results in Json with both Jackson or Jackson2 or Gson, or Xml, or flat text files, or binary files, even using ORM Lite (still in beta)
  • notifies your activities (or any other context) of the result of the network request with respect to their lifecycles.
  • no memory leaks at all, like Android Loaders, unlike Android AsyncTasks
  • notifies your activities on their UI Thread
  • uses a simple but robust exception handling model
  • supports multi-threading of request executions
  • supports aggregation of different web services
  • is a full featured replacement for long running AsyncTasks even they are not related to networking.
  • is open source ;)
  • and tested (more than 160 tests)

項目主頁:http://www.baiduhome.net/lib/view/home/1371547440578

     本文由用戶 jopen 自行上傳分享,僅供網友學習交流。所有權歸原作者,若您的權利被侵害,請聯系管理員。
     轉載本站原創文章,請注明出處,并保留原始鏈接、圖片水印。
     本站是一個以用戶分享為主的開源技術平臺,歡迎各類分享!