From 21e5d68f745edea8f253bdcc9c5684f614b4e9b3 Mon Sep 17 00:00:00 2001 From: Kangping Dong Date: Thu, 28 Mar 2024 03:34:10 +0000 Subject: [PATCH] [Thread] use toHexString for toString() dumpHexString will create additional representations other than a HEX string, it's suitable for raw logging message but not in a Object#toString. Change-Id: I184eb10bafa2db1103a4ef5cf82250db52aec278 --- .../java/android/net/thread/ActiveOperationalDataset.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/thread/framework/java/android/net/thread/ActiveOperationalDataset.java b/thread/framework/java/android/net/thread/ActiveOperationalDataset.java index 4a7d3a79f9..22457f581d 100644 --- a/thread/framework/java/android/net/thread/ActiveOperationalDataset.java +++ b/thread/framework/java/android/net/thread/ActiveOperationalDataset.java @@ -18,7 +18,7 @@ package android.net.thread; import static com.android.internal.util.Preconditions.checkArgument; import static com.android.internal.util.Preconditions.checkState; -import static com.android.net.module.util.HexDump.dumpHexString; +import static com.android.net.module.util.HexDump.toHexString; import static java.nio.charset.StandardCharsets.UTF_8; import static java.util.Objects.requireNonNull; @@ -610,7 +610,7 @@ public final class ActiveOperationalDataset implements Parcelable { sb.append("{networkName=") .append(getNetworkName()) .append(", extendedPanId=") - .append(dumpHexString(getExtendedPanId())) + .append(toHexString(getExtendedPanId())) .append(", panId=") .append(getPanId()) .append(", channel=") @@ -1109,7 +1109,7 @@ public final class ActiveOperationalDataset implements Parcelable { sb.append("{rotation=") .append(mRotationTimeHours) .append(", flags=") - .append(dumpHexString(mFlags)) + .append(toHexString(mFlags)) .append("}"); return sb.toString(); }