1 // Copyright (c) 2013 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 LIBRARIES_NACL_IO_TEST_FAKE_VAR_INTERFACE_H_
6 #define LIBRARIES_NACL_IO_TEST_FAKE_VAR_INTERFACE_H_
11 #include <ppapi/c/pp_var.h>
13 #include "nacl_io/pepper_interface.h"
14 #include "sdk_util/macros.h"
16 class FakeVarInterface : public nacl_io::VarInterface {
21 virtual void AddRef(PP_Var var);
22 virtual void Release(PP_Var var);
23 virtual PP_Var VarFromUtf8(const char* data, uint32_t len);
24 virtual const char* VarToUtf8(PP_Var var, uint32_t* out_len);
29 struct FakeStringVar {
34 typedef std::map<Id, FakeStringVar> VarMap;
38 DISALLOW_COPY_AND_ASSIGN(FakeVarInterface);
41 #endif // LIBRARIES_NACL_IO_TEST_FAKE_VAR_INTERFACE_H_