2 * Copyright (c) 2011 The Chromium Authors. All rights reserved.
3 * Use of this source code is governed by a BSD-style license that can be
4 * found in the LICENSE file.
7 /* From test_cgen/interface.idl modified Wed Nov 21 14:22:50 2012. */
9 #ifndef PPAPI_C_TEST_CGEN_INTERFACE_H_
10 #define PPAPI_C_TEST_CGEN_INTERFACE_H_
12 #include "ppapi/c/pp_macros.h"
13 #include "ppapi/c/test_cgen/stdint.h"
15 #define IFACEFOO_INTERFACE_1_0 "ifaceFoo;1.0"
16 #define IFACEFOO_INTERFACE IFACEFOO_INTERFACE_1_0
18 #define IFACEBAR_INTERFACE_1_0 "ifaceBar;1.0"
19 #define IFACEBAR_INTERFACE IFACEBAR_INTERFACE_1_0
23 * This file will test that the IDL snippet matches the comment.
31 /* struct ist { void* X; }; */
40 * @addtogroup Interfaces
44 * struct ifaceFoo_1_0 {
45 * int8_t (*mem1)(int16_t x, int32_t y);
46 * int32_t (*mem2)(const struct ist* a);
47 * int32_t (*mem3)(struct ist* b);
48 * int32_t (*mem4)(const void** ptr);
49 * int32_t (*mem5)(void** ptr);
51 * typedef struct ifaceFoo_1_0 ifaceFoo;
54 int8_t (*mem1
)(int16_t x
, int32_t y
);
55 int32_t (*mem2
)(const struct ist
* a
);
56 int32_t (*mem3
)(struct ist
* b
);
57 int32_t (*mem4
)(const void** ptr
);
58 int32_t (*mem5
)(void** ptr
);
61 typedef struct ifaceFoo_1_0 ifaceFoo
;
64 int8_t (*testIface
)(const struct ifaceFoo_1_0
* foo
, int32_t y
);
65 struct ifaceFoo_1_0
* (*createIface
)(const char* name
);
68 typedef struct ifaceBar_1_0 ifaceBar
;
78 struct ifaceBar_1_0
* bar
;
84 #endif /* PPAPI_C_TEST_CGEN_INTERFACE_H_ */