We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ebeae18 commit 4aa7531Copy full SHA for 4aa7531
1 file changed
app/src/main/java/com/example/httpsender/MainActivity.java
@@ -177,7 +177,7 @@ public void sendPostJsonArray(View view) {
177
public void xmlConverter(View view) {
178
RxHttp.get("http://webservices.nextbus.com/service/publicXMLFeed?command=routeConfig&a=sf-muni")
179
.setXmlConverter()
180
- .asObject(NewsDataXml.class)
+ .asClass(NewsDataXml.class)
181
.as(RxLife.asOnMain(this)) //感知生命周期,并在主线程回调
182
.subscribe(dataXml -> {
183
mBinding.tvResult.setText(new Gson().toJson(dataXml));
0 commit comments