OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
59 | 59 |
60 class PLATFORM_EXPORT ContentDecryptionModuleSession : private blink::WebContent
DecryptionModuleSession::Client { | 60 class PLATFORM_EXPORT ContentDecryptionModuleSession : private blink::WebContent
DecryptionModuleSession::Client { |
61 WTF_MAKE_NONCOPYABLE(ContentDecryptionModuleSession); | 61 WTF_MAKE_NONCOPYABLE(ContentDecryptionModuleSession); |
62 public: | 62 public: |
63 static PassOwnPtr<ContentDecryptionModuleSession> create(ContentDecryptionMo
duleSessionClient*); | 63 static PassOwnPtr<ContentDecryptionModuleSession> create(ContentDecryptionMo
duleSessionClient*); |
64 | 64 |
65 ContentDecryptionModuleSession(blink::WebContentDecryptionModule*, ContentDe
cryptionModuleSessionClient*); | 65 ContentDecryptionModuleSession(blink::WebContentDecryptionModule*, ContentDe
cryptionModuleSessionClient*); |
66 ~ContentDecryptionModuleSession(); | 66 ~ContentDecryptionModuleSession(); |
67 | 67 |
68 String sessionId() const; | 68 String sessionId() const; |
69 void generateKeyRequest(const String& mimeType, const WTF::Uint8Array& initD
ata); | 69 void initialize(const String& mimeType, const WTF::Uint8Array& initData); |
70 void update(const WTF::Uint8Array& key); | 70 void update(const WTF::Uint8Array& key); |
71 void close(); | 71 void release(); |
72 | 72 |
73 private: | 73 private: |
74 // blink::WebContentDecryptionModuleSession::Client | 74 // blink::WebContentDecryptionModuleSession::Client |
75 virtual void keyAdded() OVERRIDE; | 75 virtual void keyAdded() OVERRIDE; |
76 virtual void keyError(MediaKeyErrorCode, unsigned long systemCode) OVERRIDE; | 76 virtual void keyError(MediaKeyErrorCode, unsigned long systemCode) OVERRIDE; |
77 virtual void keyMessage(const unsigned char* message, size_t messageLength,
const blink::WebURL& destinationURL) OVERRIDE; | 77 virtual void keyMessage(const unsigned char* message, size_t messageLength,
const blink::WebURL& destinationURL) OVERRIDE; |
78 | 78 |
79 OwnPtr<blink::WebContentDecryptionModuleSession> m_session; | 79 OwnPtr<blink::WebContentDecryptionModuleSession> m_session; |
80 | 80 |
81 ContentDecryptionModuleSessionClient* m_client; | 81 ContentDecryptionModuleSessionClient* m_client; |
82 }; | 82 }; |
83 | 83 |
84 } // namespace WebCore | 84 } // namespace WebCore |
85 | 85 |
86 #endif // ContentDecryptionModuleSession_h | 86 #endif // ContentDecryptionModuleSession_h |
OLD | NEW |