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
3 // found in the LICENSE file.
5 #ifndef ContentDecryptionModuleResult_h
6 #define ContentDecryptionModuleResult_h
8 #include "platform/heap/Handle.h"
9 #include "public/platform/WebContentDecryptionModuleException.h"
10 #include "public/platform/WebContentDecryptionModuleResult.h"
14 class WebContentDecryptionModule
;
17 // Used to notify completion of a CDM operation.
18 class ContentDecryptionModuleResult
: public GarbageCollectedFinalized
<ContentDecryptionModuleResult
> {
20 virtual ~ContentDecryptionModuleResult() { }
22 virtual void complete() = 0;
23 virtual void completeWithContentDecryptionModule(WebContentDecryptionModule
*) = 0;
24 virtual void completeWithSession(WebContentDecryptionModuleResult::SessionStatus
) = 0;
25 virtual void completeWithError(WebContentDecryptionModuleException
, unsigned long systemCode
, const WebString
&) = 0;
27 WebContentDecryptionModuleResult
result()
29 return WebContentDecryptionModuleResult(this);
32 DEFINE_INLINE_VIRTUAL_TRACE() { }
37 #endif // ContentDecryptionModuleResult_h