Android/Java内存泄露检测框架 LeakCanary

码农软件 · 软件分类 · 程序调试工具 · 2019-11-30 14:12:09

软件介绍

LeakCanary 是 Android 和 Java 内存泄露检测框架。

开始使用

在 build.gradle 中加入引用,不同的编译使用不同的引用:

dependencies {
   debugCompile 'com.squareup.leakcanary:leakcanary-android:1.3'
   releaseCompile 'com.squareup.leakcanary:leakcanary-android-no-op:1.3'
 }

在 Application 中:

public class ExampleApplication extends Application {
@Override 
    public void onCreate() {
        super.onCreate(); 
        LeakCanary.install(this); 
    } 
}

这样,就万事俱备了! 在 debug build 中,如果检测到某个 activity 有内存泄露,LeakCanary 就是自动地显示一个通知。

中文文档:http://www.liaohuqiu.net/cn/posts/leak-canary-read-me/

Demo:https://github.com/liaohuqiu/leakcanary-demo

Why:http://www.liaohuqiu.net/cn/posts/leak-canary/

本文地址:https://www.codercto.com/soft/d/20125.html

Computational Geometry

Computational Geometry

Mark de Berg、Otfried Cheong、Marc van Kreveld、Mark Overmars / Springer / 2008-4-16 / USD 49.95

This well-accepted introduction to computational geometry is a textbook for high-level undergraduate and low-level graduate courses. The focus is on algorithms and hence the book is well suited for st......一起来看看 《Computational Geometry》 这本书的介绍吧!

HTML 压缩/解压工具
HTML 压缩/解压工具

在线压缩/解压 HTML 代码

CSS 压缩/解压工具
CSS 压缩/解压工具

在线压缩/解压 CSS 代码

HSV CMYK 转换工具
HSV CMYK 转换工具

HSV CMYK互换工具