当前位置: 代码迷 >> 综合 >> android studio weather app一个显示天气的应用
  详细解决方案

android studio weather app一个显示天气的应用

热度:4   发布时间:2024-01-14 12:23:58.0

这是根据youtube上的教学视频编写的天气app,教学视频有几处bug,自己调整了几处代码,视频地址:https://www.youtube.com/watch?v=CmUxsupaBdk&list=PLZsd_1glHoeRaq5zGzBHbRa_ktWH9NwcN&index=74

代码地址:https://github.com/jowang2016/weatherapp20160728

程序准备:

manifest:

<uses-permission android:name="android.permission.INTERNET"/>
build.gradle:
dependencies {compile fileTree(dir: 'libs', include: ['*.jar'])testCompile 'junit:junit:4.12'  compile 'com.android.support:appcompat-v7:24.1.0'  compile group: 'cz.msebera.android' , name: 'httpclient', version: '4.4.1.1' }
加入httpclient依赖是十分必要的,以便程序使用httpget等方法,这个在教学视频中没有提及。

  相关解决方案