OLD | NEW |
(Empty) | |
| 1 // Copyright 2017 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. |
| 4 |
| 5 #ifndef MojoSharedBuffer_h |
| 6 #define MojoSharedBuffer_h |
| 7 |
| 8 #include "bindings/core/v8/ScriptWrappable.h" |
| 9 |
| 10 namespace blink { |
| 11 |
| 12 class DOMArrayBuffer; |
| 13 |
| 14 class MojoSharedBuffer final |
| 15 : public GarbageCollectedFinalized<MojoSharedBuffer>, |
| 16 public ScriptWrappable { |
| 17 DEFINE_WRAPPERTYPEINFO(); |
| 18 |
| 19 public: |
| 20 MojoSharedBuffer(void* data, unsigned numBytes); |
| 21 |
| 22 DOMArrayBuffer* buffer() { return m_buffer.get(); } |
| 23 void unmap(); |
| 24 |
| 25 DECLARE_TRACE(); |
| 26 |
| 27 private: |
| 28 Member<DOMArrayBuffer> m_buffer; |
| 29 }; |
| 30 |
| 31 } // namespace blink |
| 32 |
| 33 #endif // MojoSharedBuffer_h |
OLD | NEW |