blob: 150d004ef96aa6298bfefefcd619b8d414499ee4 [file] [log] [blame]
MG Mud User88f12472016-06-24 23:31:02 +02001// MorgenGrauen MUDlib
2//
3// ringbuffer.h -- Header fuer /std/util/ringbuffer.c
4//
5// $Id: util.h 6404 2007-08-06 20:31:22Z Zesstra $
6
7#ifndef _RINGBUFFER_H
8#define _RINGBUFFER_H
9
10#define MODE_FIFO 1
11#define MODE_LIFO 2
12
13#endif // _RINGBUFFER_H
14
15#ifndef _RINGBUFFER_H_IMPLEMENTATION
16#ifdef NEED_PROTOTYPES
17
18#define _RINGBUFFER_H_IMPLEMENTATION
19
20protected struct std_ringbuffer CreateRingBuffer(int size, int newmode);
21protected void RingBufferPut(struct std_ringbuffer buffer, mixed val);
22protected mixed RingBufferGet(struct std_ringbuffer buffer);
23protected struct std_ringbuffer ResizeRingBuffer(struct std_ringbuffer buf,
24 int size);
25
26#endif // NEED_PROTOTYPES
27#endif // _RINGBUFFER_H_IMPLEMENTATION
28