OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef ContentDecryptionModuleResult_h | 5 #ifndef ContentDecryptionModuleResult_h |
6 #define ContentDecryptionModuleResult_h | 6 #define ContentDecryptionModuleResult_h |
7 | 7 |
8 #include "platform/heap/Handle.h" | 8 #include "platform/heap/Handle.h" |
9 #include "public/platform/WebContentDecryptionModuleException.h" | 9 #include "public/platform/WebContentDecryptionModuleException.h" |
10 #include "public/platform/WebContentDecryptionModuleResult.h" | 10 #include "public/platform/WebContentDecryptionModuleResult.h" |
11 | 11 |
12 namespace blink { | 12 namespace blink { |
| 13 |
13 class WebString; | 14 class WebString; |
14 } | |
15 | |
16 namespace blink { | |
17 | 15 |
18 // Used to notify completion of a CDM operation. | 16 // Used to notify completion of a CDM operation. |
19 class ContentDecryptionModuleResult : public GarbageCollectedFinalized<ContentDe
cryptionModuleResult> { | 17 class ContentDecryptionModuleResult : public GarbageCollectedFinalized<ContentDe
cryptionModuleResult> { |
20 public: | 18 public: |
21 virtual ~ContentDecryptionModuleResult() { } | 19 virtual ~ContentDecryptionModuleResult() { } |
22 | 20 |
23 virtual void complete() = 0; | 21 virtual void complete() = 0; |
24 virtual void completeWithSession(blink::WebContentDecryptionModuleResult::Se
ssionStatus) = 0; | 22 virtual void completeWithSession(WebContentDecryptionModuleResult::SessionSt
atus) = 0; |
25 virtual void completeWithError(blink::WebContentDecryptionModuleException, u
nsigned long systemCode, const blink::WebString&) = 0; | 23 virtual void completeWithError(WebContentDecryptionModuleException, unsigned
long systemCode, const WebString&) = 0; |
26 | 24 |
27 blink::WebContentDecryptionModuleResult result() | 25 WebContentDecryptionModuleResult result() |
28 { | 26 { |
29 return blink::WebContentDecryptionModuleResult(this); | 27 return WebContentDecryptionModuleResult(this); |
30 } | 28 } |
31 | 29 |
32 virtual void trace(Visitor*) { } | 30 virtual void trace(Visitor*) { } |
33 }; | 31 }; |
34 | 32 |
35 } // namespace blink | 33 } // namespace blink |
36 | 34 |
37 #endif // ContentDecryptionModuleResult_h | 35 #endif // ContentDecryptionModuleResult_h |
OLD | NEW |