当前位置:网站首页>【建议收藏】面试没亮点
【建议收藏】面试没亮点
2022-04-22 20:14:00 【InfoQ】
- 1、图片加载:Glide.with(this).load(imageUrl).override(800, 800).placeholder().error().animate().into()。
- 2、多样式媒体加载:asBitamp、asGif。
- 3、生命周期集成。
- 4、可以配置磁盘缓存策略ALL、NONE、SOURCE、RESULT。
3、这
Android开源项目《ali1024.coding.net/public/P7/Android/git》
个库的核心实现原理是什么?如果让你实现这个库的某些核心功能,你会考虑怎么去实现?
1、Glide&with:
- 1、初始化各式各样的配置信息(包括缓存,请求线程池,大小,图片格式等等)以及glide对象。
- 2、将glide请求和application/SupportFragment/Fragment的生命周期绑定在一块。
2、Glide&load:
3、Glide&into:
- 1、首先根据转码类transcodeClass类型返回不同的ImageViewTarget:BitmapImageViewTarget、DrawableImageViewTarget。
- 2、递归建立缩略图请求,没有缩略图请求,则直接进行正常请求。
- 3、如果没指定宽高,会根据ImageView的宽高计算出图片宽高,最终执行到onSizeReay()方法中的engine.load()方法。
- 4、engine是一个负责加载和管理缓存资源的类
常规三级缓存的流程:强引用->软引用->硬盘缓存
Glide的三层缓存机制
- 取的顺序是:弱引用、内存、磁盘。
- 存的顺序是:弱引用、内存、磁盘。
4、Glide源码机制的核心思想:
5、Glide中是如何计算一张图片的大小的?
助力一份Android热门三方库源码面试宝典
第一章:热修复


第二章:插件化


三:组件化框架设计
最后
版权声明
本文为[InfoQ]所创,转载请带上原文链接,感谢
https://xie.infoq.cn/article/8fe5701e1f1221730f85f6801
边栏推荐
- firewalld dbus接口使用指南
- 396. Rotation function (mathematical law + iterative method)
- Kingbasees service startup method of Jincang database
- DBUS client user guide
- 【Unity】可玩广告Luna Playable插件的踩坑记录
- 微服务高性能高可用架构设计
- Redis cluster 6.2.6
- Activity Result API 使用与源码分析
- [program source code] graduation project - film website
- C process runs the asynchronous echo of CMD command
猜你喜欢

解决金仓数据库KingbaseES对pg模式的单机数据库插入数据时,出现日志打印的问题

Internet News: Lenovo announced the new progress of ESG; Excellent sound and painting of Jimi h3s and z6x Pro were highly praised; Little red book responded to "layoffs of 20%"

<山东大学项目实训>辐射预计算渲染及后处理降噪系统研究(一)

Conditions for judging whether plastic deformation occurs: Von Mises yield criterion

Problems that must be avoided in the process of top survey technology sorting and transformation

ZTNA (Zero Trust Network Access)

Comparison and principle summary of golang local cache selection

判断是否发生塑性变形的条件:von Mises屈服准则
MySQL query data within a radius length of latitude and longitude

Linux下安装Mysql 8.0 + eclipse配置详细教程
随机推荐
The difference between null and "" in kingbases database
The new pytorch library by the author of "lottery hypothesis" is popular
How can the "vanguard" and "Internet Aegis" effectively deploy defense for cities?
C process runs the asynchronous echo of CMD command
envoy代理后获取客户端真实IP
396. 旋转函数(数学规律 + 迭代法)
如何提高PHP编程的效率?
启动kingbase单机服务时报错:invalid value for parmeter “bindcpulist”:”0-95”
Panyu maritime department has solidly promoted the 100 day action of safety education and training for water practitioners
Module 4 operation
What is the reason why the camera device with built-in 4G card of Haikang cannot register with easycvr platform?
Obtain the real IP address of the client after envoy proxy
微服务笔记合集
What is the reason why easycvr streaming media kernel cannot be started?
Linux下安装Mysql 8.0 + eclipse配置详细教程
【H5】微信端H5页面制作
What kind of headphones do you wear for sports? The best equipment for running and listening to music
Write a gateway service, understand more thoroughly!
Which brand of sports headphones is better and recommended for easy-to-use sports headphones
工作光靠努力是不够的!还有这个...