谷歌天气并json解析xml

时间:2014-11-30 09:22:37
【文件属性】:

文件名称:谷歌天气并json解析xml

文件大小:18KB

文件格式:RAR

更新时间:2014-11-30 09:22:37

android google weather json

package com.demo; import java.util.ArrayList; import java.util.List; import android.app.Activity; import android.content.Intent; import android.os.Bundle; import android.util.Log; import android.view.View; import android.widget.AdapterView; import android.widget.ArrayAdapter; import android.widget.ListView; import android.widget.AdapterView.OnItemClickListener; public class CityListActivity extends Activity implements OnItemClickListener{ private final static String TAG = "CityListActivity"; private ListView mListView; private List list = new ArrayList(); @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.citylist); String args = getIntent().getExtras().getString(JsonDemoActivity.COUNTRY_CODE); list = Utils.getCityInfos(args); setupViews(); } private void setupViews(){ mListView = (ListView) findViewById(R.id.cityList); ArrayList arrayList = new ArrayList(); int arraySize = list.size(); for(int i=0;i


【文件预览】:
JsonDemo
----.project(844B)
----proguard.cfg(1KB)
----src()
--------com()
----AndroidManifest.xml(762B)
----res()
--------drawable-ldpi()
--------drawable-hdpi()
--------drawable-mdpi()
--------layout()
--------values()
----.settings()
--------org.eclipse.core.resources.prefs(88B)
----assets()
----gen()
--------com()
----default.properties(362B)
----.classpath(280B)
教程说明见这里.txt

网友评论

  • 作为android应用的参考,看一下可以