[AWARE] Enhance debug logs

Add information to the debug message.

Bug: 31940045
Test: unit tests, integration (sl4a) tests
Change-Id: I076825164491a2025a8d04ebb5898a0e742af312
This commit is contained in:
Etan Cohen
2017-05-19 13:38:25 -07:00
parent d35ec686d7
commit 116d2cabb1
2 changed files with 22 additions and 13 deletions

View File

@@ -93,12 +93,17 @@ public final class PublishConfig implements Parcelable {
@Override
public String toString() {
return "PublishConfig [mServiceName='" + mServiceName + ", mServiceSpecificInfo='" + (
(mServiceSpecificInfo == null) ? "null" : HexEncoding.encode(mServiceSpecificInfo))
+ ", mMatchFilter=" + (new TlvBufferUtils.TlvIterable(0, 1,
mMatchFilter)).toString() + ", mPublishType=" + mPublishType
+ ", mTtlSec=" + mTtlSec + ", mEnableTerminateNotification="
+ mEnableTerminateNotification + "]";
return "PublishConfig [mServiceName='" + (mServiceName == null ? "<null>" : String.valueOf(
HexEncoding.encode(mServiceName))) + ", mServiceName.length=" + (
mServiceName == null ? 0 : mServiceName.length) + ", mServiceSpecificInfo='" + (
(mServiceSpecificInfo == null) ? "<null>" : String.valueOf(
HexEncoding.encode(mServiceSpecificInfo)))
+ ", mServiceSpecificInfo.length=" + (mServiceSpecificInfo == null ? 0
: mServiceSpecificInfo.length) + ", mMatchFilter="
+ (new TlvBufferUtils.TlvIterable(0, 1, mMatchFilter)).toString()
+ ", mMatchFilter.length=" + (mMatchFilter == null ? 0 : mMatchFilter.length)
+ ", mPublishType=" + mPublishType + ", mTtlSec=" + mTtlSec
+ ", mEnableTerminateNotification=" + mEnableTerminateNotification + "]";
}
@Override

View File

@@ -92,13 +92,17 @@ public final class SubscribeConfig implements Parcelable {
@Override
public String toString() {
return "SubscribeConfig [mServiceName='" + mServiceName + ", mServiceSpecificInfo='" + (
(mServiceSpecificInfo == null) ? "null" : HexEncoding.encode(mServiceSpecificInfo))
+ ", mMatchFilter=" + (new TlvBufferUtils.TlvIterable(0, 1,
mMatchFilter)).toString() + ", mSubscribeType=" + mSubscribeType
+ ", mTtlSec=" + mTtlSec
+ ", mEnableTerminateNotification=" + mEnableTerminateNotification
+ "]";
return "SubscribeConfig [mServiceName='" + (mServiceName == null ? "<null>"
: String.valueOf(HexEncoding.encode(mServiceName))) + ", mServiceName.length=" + (
mServiceName == null ? 0 : mServiceName.length) + ", mServiceSpecificInfo='" + (
(mServiceSpecificInfo == null) ? "<null>" : String.valueOf(
HexEncoding.encode(mServiceSpecificInfo)))
+ ", mServiceSpecificInfo.length=" + (mServiceSpecificInfo == null ? 0
: mServiceSpecificInfo.length) + ", mMatchFilter="
+ (new TlvBufferUtils.TlvIterable(0, 1, mMatchFilter)).toString()
+ ", mMatchFilter.length=" + (mMatchFilter == null ? 0 : mMatchFilter.length)
+ ", mSubscribeType=" + mSubscribeType + ", mTtlSec=" + mTtlSec
+ ", mEnableTerminateNotification=" + mEnableTerminateNotification + "]";
}
@Override