• 大小: 28.93M
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2020-12-14
  • 语言: Java
  • 标签: 天气预报  天气  app  a  

资源简介

【Android studio开发】

【核心代码】

   public void updateBingPic() {
        String requestBingPic =
"http://guolin.tech/api/bing_pic";
        OkHttp.sendRequestOkHttpForGet(requestBingPic,
new Callback() {
           
@Override
           
public void onFailure(Call call, IOException e) {
                e.printStackTrace();
            }
           
@Override
           
public void onResponse(Call call, Response response) throws IOException {
                String bingPic = response.body().string();
                SharedPreferences.Editor editor = PreferenceManager.getDefaultSharedPreferences(WeatherActivity.
this).edit();
                editor.putString(
"bing_pic", bingPic);
                editor.apply();
            }
        });
    }

资源截图

代码片段和文件信息

/**
 * Automatically generated file. DO NOT MODIFY
 */
package com.dong.dongweather.test;

public final class BuildConfig {
  public static final boolean DEBUG = Boolean.parseBoolean(“true“);
  public static final String APPLICATION_ID = “com.dong.dongweather.test“;
  public static final String BUILD_TYPE = “debug“;
  public static final String FLAVOR = ““;
  public static final int VERSION_CODE = 1;
  public static final String VERSION_NAME = “1.0“;
}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2017-06-08 17:20  DongWeather22\
     目录           0  2017-06-08 17:19  DongWeather22\.git\
     文件          13  2017-04-15 17:13  DongWeather22\.git\COMMIT_EDITMSG
     文件          23  2017-04-15 17:02  DongWeather22\.git\HEAD
     文件         308  2017-04-15 17:02  DongWeather22\.git\config
     文件          73  2017-04-15 17:02  DongWeather22\.git\description
     目录           0  2017-06-08 17:19  DongWeather22\.git\hooks\
     文件         478  2017-04-15 17:02  DongWeather22\.git\hooks\applypatch-msg.sample
     文件         896  2017-04-15 17:02  DongWeather22\.git\hooks\commit-msg.sample
     文件         189  2017-04-15 17:02  DongWeather22\.git\hooks\post-update.sample
     文件         424  2017-04-15 17:02  DongWeather22\.git\hooks\pre-applypatch.sample
     文件        1642  2017-04-15 17:02  DongWeather22\.git\hooks\pre-commit.sample
     文件        1348  2017-04-15 17:02  DongWeather22\.git\hooks\pre-push.sample
     文件        4951  2017-04-15 17:02  DongWeather22\.git\hooks\pre-rebase.sample
     文件         544  2017-04-15 17:02  DongWeather22\.git\hooks\pre-receive.sample
     文件        1239  2017-04-15 17:02  DongWeather22\.git\hooks\prepare-commit-msg.sample
     文件        3610  2017-04-15 17:02  DongWeather22\.git\hooks\update.sample
     文件        8141  2017-04-15 17:42  DongWeather22\.git\index
     目录           0  2017-06-08 17:19  DongWeather22\.git\info\
     文件         240  2017-04-15 17:02  DongWeather22\.git\info\exclude
     目录           0  2017-06-08 17:19  DongWeather22\.git\logs\
     文件         329  2017-04-15 17:13  DongWeather22\.git\logs\HEAD
     目录           0  2017-06-08 17:19  DongWeather22\.git\logs\refs\
     目录           0  2017-06-08 17:19  DongWeather22\.git\logs\refs\heads\
     文件         329  2017-04-15 17:13  DongWeather22\.git\logs\refs\heads\master
     目录           0  2017-06-08 17:19  DongWeather22\.git\logs\refs\remotes\
     目录           0  2017-06-08 17:19  DongWeather22\.git\logs\refs\remotes\origin\
     文件         183  2017-04-15 17:02  DongWeather22\.git\logs\refs\remotes\origin\HEAD
     文件         140  2017-04-15 17:15  DongWeather22\.git\logs\refs\remotes\origin\master
     目录           0  2017-06-08 17:19  DongWeather22\.git\objects\
     目录           0  2017-06-08 17:19  DongWeather22\.git\objects\00\
............此处省略1926个文件信息

评论

共有 条评论