Chromium Code Reviews| Index: Source/core/html/MediaProvider.h |
| diff --git a/Source/platform/mediastream/RTCStatsRequest.h b/Source/core/html/MediaProvider.h |
| similarity index 70% |
| copy from Source/platform/mediastream/RTCStatsRequest.h |
| copy to Source/core/html/MediaProvider.h |
| index c397f90ab7ec90a65a7a5312bdd250e527eea561..aa566ba36496b5e79c69911ca1c263aae793b003 100644 |
| --- a/Source/platform/mediastream/RTCStatsRequest.h |
| +++ b/Source/core/html/MediaProvider.h |
| @@ -1,5 +1,5 @@ |
| /* |
| - * Copyright (C) 2012 Google Inc. All rights reserved. |
| + * Copyright (C) 2014 Google Inc. All rights reserved. |
| * |
| * Redistribution and use in source and binary forms, with or without |
| * modification, are permitted provided that the following conditions |
| @@ -28,34 +28,36 @@ |
| * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| */ |
| -#ifndef RTCStatsRequest_h |
| -#define RTCStatsRequest_h |
| +#ifndef MediaProvider_h |
| +#define MediaProvider_h |
| #include "platform/heap/Handle.h" |
| -#include "wtf/PassRefPtr.h" |
| -#include "wtf/text/WTFString.h" |
| +#include "wtf/Assertions.h" |
| namespace blink { |
| -class MediaStreamComponent; |
| -class MediaStreamDescriptor; |
| -class RTCStatsResponseBase; |
| +class EventTarget; |
| +class MediaProvider; |
| +class ScriptValue; |
| -class RTCStatsRequest : public GarbageCollectedFinalized<RTCStatsRequest> { |
| +class MediaProviderConverter { |
| public: |
| - virtual ~RTCStatsRequest() { } |
| - |
| - virtual RTCStatsResponseBase* createResponse() = 0; |
| - virtual bool hasSelector() = 0; |
| - virtual MediaStreamComponent* component() = 0; |
| - virtual void requestSucceeded(RTCStatsResponseBase*) = 0; |
| + MediaProviderConverter(); |
| + virtual MediaProvider* getMediaProvider(const ScriptValue&) = 0; |
|
perkj_chrome
2014/09/11 17:31:45
Is there some type of function pointers in blink I
philipj_slow
2014/09/11 19:07:53
I haven't looked at any of the code yet, but it so
|
| + static MediaProvider* convert(const ScriptValue&); |
| +protected: |
| + virtual ~MediaProviderConverter() { } |
| +}; |
| - virtual void trace(Visitor*) { } |
| +class MediaProvider : public WillBeGarbageCollectedMixin { |
| +public: |
| + MediaProvider(RawPtr<MediaProviderConverter>); |
| + virtual ~MediaProvider() { }; |
| -protected: |
| - RTCStatsRequest() { } |
| + virtual EventTarget* eventTarget() = 0; |
| + virtual const String& getObjectUrl() = 0; |
| }; |
| } // namespace blink |
| -#endif // RTCStatsRequest_h |
| +#endif |