VirtualBox

source: vbox/trunk/src/VBox/GuestHost/OpenGL/include/cr_hash.h@ 26084

最後變更 在這個檔案從26084是 15532,由 vboxsync 提交於 16 年 前

crOpenGL: export to OSE

  • 屬性 svn:eol-style 設為 native
  • 屬性 svn:keywords 設為 Id
檔案大小: 1.8 KB
 
1/* Copyright (c) 2001, Stanford University
2 * All rights reserved.
3 *
4 * See the file LICENSE.txt for information on redistributing this software.
5 */
6
7#ifndef CR_HASH_H
8#define CR_HASH_H
9
10#include "chromium.h"
11
12#include <iprt/cdefs.h>
13
14#ifdef __cplusplus
15extern "C" {
16#endif
17
18typedef struct CRHashTable CRHashTable;
19
20/* Callback function used for freeing/deleting table entries */
21typedef void (*CRHashtableCallback)(void *data);
22/* Callback function used for walking through table entries */
23typedef void (*CRHashtableWalkCallback)(unsigned long key, void *data1, void *data2);
24
25DECLEXPORT(CRHashTable *) crAllocHashtable( void );
26DECLEXPORT(void) crFreeHashtable( CRHashTable *hash, CRHashtableCallback deleteCallback );
27DECLEXPORT(void) crHashtableAdd( CRHashTable *h, unsigned long key, void *data );
28DECLEXPORT(GLuint) crHashtableAllocKeys( CRHashTable *h, GLsizei range );
29DECLEXPORT(void) crHashtableDelete( CRHashTable *h, unsigned long key, CRHashtableCallback deleteCallback );
30DECLEXPORT(void) crHashtableDeleteBlock( CRHashTable *h, unsigned long key, GLsizei range, CRHashtableCallback deleteFunc );
31DECLEXPORT(void *) crHashtableSearch( const CRHashTable *h, unsigned long key );
32DECLEXPORT(void) crHashtableReplace( CRHashTable *h, unsigned long key, void *data, CRHashtableCallback deleteFunc);
33DECLEXPORT(unsigned int) crHashtableNumElements( const CRHashTable *h) ;
34DECLEXPORT(GLboolean) crHashtableIsKeyUsed( const CRHashTable *h, GLuint id );
35DECLEXPORT(void) crHashtableWalk( CRHashTable *hash, CRHashtableWalkCallback walkFunc , void *data);
36/*Returns GL_TRUE if given hashtable hold the data, pKey is updated with key value for data in this case*/
37DECLEXPORT(GLboolean) crHashtableGetDataKey(CRHashTable *pHash, void *pData, unsigned long *pKey);
38
39#ifdef __cplusplus
40} /* extern "C" */
41#endif
42
43#endif /* CR_HASH_H */
注意: 瀏覽 TracBrowser 來幫助您使用儲存庫瀏覽器

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette