diff options
author | 2017-09-22 10:56:22 +0000 | |
---|---|---|
committer | 2017-09-22 10:56:22 +0000 | |
commit | 290d692e518f44fbc1fa9ef05a8f468d37510462 (patch) | |
tree | 36294dac425bf662a9db88ab796d790d842728b5 /tools/ahat/src/ObjectHandler.java | |
parent | 79bbbc1c9c40478ccf752214da9574dd22cd8b02 (diff) | |
parent | 26a982ad022a254ac57f84e996c31b4e271de028 (diff) |
Merge changes I9a71ea46,Ib14c294a,Id91c2be4,I3fa77e2e
* changes:
Remove last remaining guava dependencies.
Use a custom parser implementation instead of perflib.
Remove perflib-based native allocation registry identification.
ahat: Expand test coverage using static heap dumps.
Diffstat (limited to 'tools/ahat/src/ObjectHandler.java')
-rw-r--r-- | tools/ahat/src/ObjectHandler.java | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/tools/ahat/src/ObjectHandler.java b/tools/ahat/src/ObjectHandler.java index f4926aa83b..79f8b76c92 100644 --- a/tools/ahat/src/ObjectHandler.java +++ b/tools/ahat/src/ObjectHandler.java @@ -25,6 +25,7 @@ import com.android.ahat.heapdump.DiffFields; import com.android.ahat.heapdump.DiffedFieldValue; import com.android.ahat.heapdump.FieldValue; import com.android.ahat.heapdump.PathElement; +import com.android.ahat.heapdump.RootType; import com.android.ahat.heapdump.Site; import com.android.ahat.heapdump.Value; import java.io.IOException; @@ -74,13 +75,13 @@ class ObjectHandler implements AhatHandler { doc.description(DocString.text("Heap"), DocString.text(inst.getHeap().getName())); - Collection<String> rootTypes = inst.getRootTypes(); + Collection<RootType> rootTypes = inst.getRootTypes(); if (rootTypes != null) { DocString types = new DocString(); String comma = ""; - for (String type : rootTypes) { + for (RootType type : rootTypes) { types.append(comma); - types.append(type); + types.append(type.toString()); comma = ", "; } doc.description(DocString.text("Root Types"), types); @@ -175,21 +176,21 @@ class ObjectHandler implements AhatHandler { was.append(Summarizer.summarize(previous)); switch (field.status) { case ADDED: - doc.row(DocString.text(field.type), + doc.row(DocString.text(field.type.name), DocString.text(field.name), Summarizer.summarize(field.current), DocString.added("new")); break; case MATCHED: - doc.row(DocString.text(field.type), + doc.row(DocString.text(field.type.name), DocString.text(field.name), Summarizer.summarize(field.current), Objects.equals(field.current, previous) ? new DocString() : was); break; case DELETED: - doc.row(DocString.text(field.type), + doc.row(DocString.text(field.type.name), DocString.text(field.name), DocString.removed("del"), was); |