Delete unused downloads page asset.
[chromium-blink-merge.git] / ppapi / c / dev / ppb_memory_dev.h
blobb25a9d108c702a218683046349c18ecc4d553921
1 /* Copyright (c) 2012 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 */
6 /* From dev/ppb_memory_dev.idl modified Fri Nov 18 15:58:00 2011. */
8 #ifndef PPAPI_C_DEV_PPB_MEMORY_DEV_H_
9 #define PPAPI_C_DEV_PPB_MEMORY_DEV_H_
11 #include "ppapi/c/pp_macros.h"
12 #include "ppapi/c/pp_stdint.h"
14 #define PPB_MEMORY_DEV_INTERFACE_0_1 "PPB_Memory(Dev);0.1"
15 #define PPB_MEMORY_DEV_INTERFACE PPB_MEMORY_DEV_INTERFACE_0_1
17 /**
18 * @file
19 * This file defines the <code>PPB_Memory interface</code> for functions
20 * related to memory management.
24 /**
25 * @addtogroup Interfaces
26 * @{
28 /**
29 * The PPB_Memory_Dev interface contains pointers to functions related to memory
30 * management.
33 struct PPB_Memory_Dev_0_1 {
34 /**
35 * MemAlloc is a pointer to a function that allocate memory.
37 * @param[in] num_bytes A number of bytes to allocate.
38 * @return A pointer to the memory if successful, NULL If the
39 * allocation fails.
41 void* (*MemAlloc)(uint32_t num_bytes);
42 /**
43 * MemFree is a pointer to a function that deallocates memory.
45 * @param[in] ptr A pointer to the memory to deallocate. It is safe to
46 * pass NULL to this function.
48 void (*MemFree)(void* ptr);
51 typedef struct PPB_Memory_Dev_0_1 PPB_Memory_Dev;
52 /**
53 * @}
56 #endif /* PPAPI_C_DEV_PPB_MEMORY_DEV_H_ */