0

Redmine支持 REST API。它还提供了一个Java库,但它与android> 2.2兼容。我需要有关如何编写附加问题的提示,但与 android 兼容的版本应为 1.6。提前谢谢你,对不起我的英语不好。

4

2 回答 2

0

I had the same problem. My solution was to checkout a copy of the redmine-java-api and modify it. This is what I ended up having to do:

  1. Replace all references to JSONWriter with JSONStringer.
  2. Replace all slf4j logging with android logging
  3. Followed these answers to replace the encoding method https://stackoverflow.com/a/2533538, https://stackoverflow.com/a/8059544.
  4. Followed this answer to replace the PoolingClientConnectionManager https://stackoverflow.com/a/12045168
  5. Follow this answer to replace the NaiveSLLFactory https://stackoverflow.com/a/7636810

Alternatively, If you look at this issue, another person has solved the problem.

于 2013-05-27T20:38:50.830 回答
0

尝试添加库的源代码(如果有),并将 Android 版本设置为 1.6。然后所有不受支持的类都将可见。然后你必须实现这些类。

基于 2.2+ 的限制,我猜这个限制是这个库使用的 Http 客户端(即http://developer.android.com/reference/android/net/http/AndroidHttpClient.html)。

希望这可以帮助!

如果您有任何其他具体问题,请不要犹豫再次询问我们!

于 2012-06-16T10:21:31.853 回答