This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| android.provider.Settings。 | |
| 1. ACTION_ACCESSIBILITY_SETTINGS : // 跳转系统的辅助功能界面 | |
| Intent intent = new Intent(Settings.ACTION_ACCESSIBILITY_SETTINGS); | |
| startActivity(intent); | |
| 2. ACTION_ADD_ACCOUNT : // 显示添加帐户创建一个新的帐户屏幕。【测试跳转到微信登录界面】 | |
| Intent intent = new Intent(Settings.ACTION_ADD_ACCOUNT); | |
| startActivity(intent); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 国内一线互联网公司内部面试题库,从一个老码农转载的 | |
| 以下面试题来自于百度、小米、乐视、美团、58、猎豹、360、新浪、搜狐内部题库 | |
| 熟悉本文中列出的知识点会大大增加通过前两轮技术面试的几率。 | |
| 欢迎一线公司员工提交内部面试题库,欢迎star。 | |
| 一、java基础 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package solid.util; | |
| import android.graphics.PointF; | |
| import android.support.v4.util.Pair; | |
| import java.util.ArrayList; | |
| import java.util.Collections; | |
| import java.util.Comparator; | |
| /** |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| * Copyright (C) 2009 The Android Open Source Project | |
| * | |
| * Licensed under the Apache License, Version 2.0 (the "License"); | |
| * you may not use this file except in compliance with the License. | |
| * You may obtain a copy of the License at | |
| * | |
| * http://www.apache.org/licenses/LICENSE-2.0 | |
| * | |
| * Unless required by applicable law or agreed to in writing, software |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package solid.download; | |
| import android.content.Context; | |
| import android.net.ConnectivityManager; | |
| import android.net.NetworkInfo; | |
| import android.os.AsyncTask; | |
| import android.text.TextUtils; | |
| import android.util.Log; | |
| import com.squareup.okhttp.Call; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import android.content.Context; | |
| import android.graphics.Bitmap; | |
| import android.graphics.BitmapFactory; | |
| import android.graphics.drawable.BitmapDrawable; | |
| import android.graphics.drawable.Drawable; | |
| import android.graphics.drawable.TransitionDrawable; | |
| import android.support.annotation.DrawableRes; | |
| import android.support.annotation.NonNull; | |
| import android.support.annotation.Nullable; | |
| import android.view.animation.AlphaAnimation; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public interface Recall { | |
| void call(); | |
| } | |
| public void start(final Recall recall) { | |
| MyService.printDebugLog("Guarder for " + mPid); | |
| final ActivityManager activityManager = (ActivityManager) mContext | |
| .getSystemService(Context.ACTIVITY_SERVICE); | |
| new Thread(new Runnable() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.baidu.luxiaoyu; | |
| import java.io.EOFException; | |
| import java.io.IOException; | |
| import java.io.InputStream; | |
| /** | |
| * | |
| * Simple helper class that allows reading of integers. | |
| * |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * 把二进制byte数组生成 md5 32位 十六进制字符串,单个字节小于0xf,高位补0。 | |
| * | |
| * @param bytes | |
| * 输入 | |
| * @param upperCase | |
| * true:大写, false 小写字符串 | |
| * @return 把二进制byte数组生成 md5 32位 十六进制字符串,单个字节小于0xf,高位补0。 | |
| */ | |
| public static String toMd5(byte[] bytes, boolean upperCase) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| int a = 16; | |
| // “>>> 无符号右移,高位补0” | |
| System.out.println(a >>> 1); | |
| // “>> 右移,高位补符号位” | |
| System.out.println(a >> 1); |