//说明:此处需引用httpclient、httpcore、commons-logging三个jar包
String line = null; try {
while ((line = reader.readLine()) != null) {
sb.append(line + "\n");
}
} catch (IOException e) {
e.printStackTrace();
} finally { try {
is.close();
} catch (IOException e) {
e.printStackTrace();
}
} return sb.toString();
}
可以做,接口代码是对接demo实例吧,还是要去巴卜公司网站下载,因为巴卜接口一直在做优化,最好对接最新发布的接口,会省很多事,当然老接口巴卜也有支持的,就是效率不如新的好。