Log rtcstats as JSON
authoreric.carlson@apple.com <eric.carlson@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 8 May 2018 21:22:30 +0000 (21:22 +0000)
committereric.carlson@apple.com <eric.carlson@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 8 May 2018 21:22:30 +0000 (21:22 +0000)
commite55f469aa5c4a790bb823dc1e7031e1cc2fc9b3d
tree42b2f0dba96b5c0fb47f2890722348a47e349800
parent7a7e9532f184c6fe825d721c8a9a033b071ccc78
Log rtcstats as JSON
https://bugs.webkit.org/show_bug.cgi?id=185437
<rdar://problem/40065332>

Reviewed by Youenn Fablet.

* Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp:
(WebCore::RTCStatsLogger::RTCStatsLogger): Create a wrapper class so we don't have to add a
toJSONString method to libwebrtc.
(WebCore::RTCStatsLogger::toJSONString const): Log stats as JSON.
(WebCore::LibWebRTCMediaEndpoint::OnStatsDelivered): Don't use the LOGIDENTIFIER macro because
it doesn't work well inside of a lambda.
(WTF::LogArgument<WebCore::RTCStatsLogger>::toString): Move into .cpp file because it is only
used here.
* Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.h:
(WTF::LogArgument<webrtc::RTCStats>::toString): Deleted. Move to .cpp file.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@231512 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp
Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.h