工具类
文章平均质量分 73
浅若清兮
本人虚心好学,广交志同道合的小伙伴,期待与你一起创作更好的作品!!!
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
抽取基类 Fragment
public abstract class Fragments<T extends FragmentsPresenter> extends Fragment implements IFragments { public T fragments; @Nullable @Override public View onCreateView(@NonNull ...原创 2018-05-21 14:30:45 · 453 阅读 · 0 评论 -
封装Rxjava 与 Retrofit 工具类
public class RetrofitUtils { private static RetrofitUtils retrofitUtils; public static RetrofitApi retrofitApi; private RetrofitUtils() { } public RetrofitUtils getInstance(){ ...原创 2018-05-18 20:25:25 · 292 阅读 · 0 评论 -
(拦截器)Interceptor 配合Rxjava 与Retrofit (工具类)
class LoggingInterceptor implements Interceptor { @Override public Response intercept(Chain chain) throws IOException { Request request = chain.request(); Response response = ...原创 2018-05-18 20:27:47 · 613 阅读 · 0 评论 -
封装Fresco 工具类
public class FrescoUtils { public static void setControllerListener(final SimpleDraweeView simpleDraweeView, String imagePath, final int imageWidth) { final ViewGroup.LayoutParams layoutPara...原创 2018-05-15 15:27:16 · 590 阅读 · 0 评论 -
经常使用的依赖
常用的权限:<uses-permission android:name="android.permission.INTERNET" /> <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/> <uses-permission android:name="andr...原创 2018-05-01 19:17:18 · 403 阅读 · 0 评论 -
抽取BasePresenter
public class BasePresenter <P extends IBaseView> { private P miBaseView; public void attachView(P iBaseView){ this.miBaseView=iBaseView; } public void detachView()...原创 2018-07-06 20:27:09 · 516 阅读 · 0 评论 -
校验各种表达式
/* *判断有效用户名正则表达式 */ public static boolean validateUserName(String userName) { String validateStr = "^[\\w\\--_[0-9]\u4e00-\u9fa5\uFF21-\uFF3A\uFF41-\uFF5A]+$"; boolean rs = false; rs = ...原创 2018-08-11 12:02:06 · 774 阅读 · 0 评论 -
短信验证
//new倒计时对象,总共的时间,每隔多少秒更新一次时间 myCountDownTimer= new MyCountDownTimer(60000, 1000); send.setOnClickListener(new View.OnClickListener() { @SuppressLint("WrongConstant") @Override public voi...原创 2018-08-11 12:11:37 · 505 阅读 · 0 评论 -
详细介绍Logger日志
public class Logger { /** * log tag */ private String tagName = "MoGuLogger";// tag name //private static int logLevel = Log.ERROR; private static int logLevel = Log.DEBUG; pr...原创 2018-08-12 14:56:22 · 495 阅读 · 0 评论
分享