File: gbucket.h

package info (click to toggle)
openmohaa 0.82.1%2Bdfsg-1
  • links: PTS, VCS
  • area: contrib
  • in suites: forky, sid
  • size: 34,192 kB
  • sloc: cpp: 315,720; ansic: 275,789; sh: 312; xml: 246; asm: 141; makefile: 7
file content (52 lines) | stat: -rw-r--r-- 1,336 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
/******
gbucket.h
GameSpy Stats/Tracking SDK 
  
Copyright 1999-2007 GameSpy Industries, Inc

devsupport@gamespy.com

******

Please see the GameSpy Stats and Tracking SDK for more info
You should not need to use the functions in this file, they
are used to manage the buckets by the gstats SDK.
Use the type-safe bucket functions in the gstats SDK instead.
******/ 


#ifndef _GBUCKET_H_
#define _GBUCKET_H_


#ifdef __cplusplus
extern "C" {
#endif

typedef struct bucketset_s *bucketset_t;
typedef enum {bt_int, bt_float, bt_string} BucketType;

bucketset_t NewBucketSet(void);
void FreeBucketSet(bucketset_t set);
char *DumpBucketSet(bucketset_t set);

void *BucketNew(bucketset_t set, char *name, BucketType type, void *initialvalue);
void *BucketSet(bucketset_t set, char *name,void *value);
void *BucketAdd(bucketset_t set, char *name, void *value);
void *BucketSub(bucketset_t set, char *name, void *value);
void *BucketMult(bucketset_t set, char *name, void *value);
void *BucketDiv(bucketset_t set, char *name, void *value);
void *BucketConcat(bucketset_t set, char *name, void *value);
void *BucketAvg(bucketset_t set, char *name, void *value);
void *BucketGet(bucketset_t set, char *name);

/* Helper functions */
void *bint(int i);
void *bfloat(double f);
#define bstring(a) ((void *)a)

#ifdef __cplusplus
}
#endif

#endif