mirror of
https://github.com/androidx/media.git
synced 2025-04-30 06:46:50 +08:00
Add toString to TrackGroup(Array)
These classes are often logged in error messages or tests. The current output is just the hash code which makes it hard to debug. PiperOrigin-RevId: 736799086
This commit is contained in:
parent
d37f05238a
commit
54c64b41c4
@ -161,6 +161,11 @@ public final class TrackGroup {
|
||||
return id.equals(other.id) && Arrays.equals(formats, other.formats);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return id + ": " + Arrays.toString(formats);
|
||||
}
|
||||
|
||||
private static final String FIELD_FORMATS = Util.intToStringMaxRadix(0);
|
||||
private static final String FIELD_ID = Util.intToStringMaxRadix(1);
|
||||
|
||||
|
@ -115,6 +115,11 @@ public final class TrackGroupArray {
|
||||
return length == other.length && trackGroups.equals(other.trackGroups);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return trackGroups.toString();
|
||||
}
|
||||
|
||||
private static final String FIELD_TRACK_GROUPS = Util.intToStringMaxRadix(0);
|
||||
|
||||
public Bundle toBundle() {
|
||||
|
Loading…
x
Reference in New Issue
Block a user