Click here to Skip to main content
15,886,518 members
Articles / Programming Languages / C++

A Simple and Easy to Use IOCP Server Framework

Rate me:
Please Sign up or sign in to vote.
3.43/5 (8 votes)
30 Jun 2008LGPL33 min read 44.2K   1.7K   35  
An introduction to SPServer Framework
/*
 * event_msgqueue.h
 *
 * Libevent threaded message passing primitives header
 *
 * Andrew Danforth <acd@weirdness.net>, October 2006
 *
 * Copyright (c) Andrew Danforth, 2006
 *
 */

#ifndef _EVENT_MSGQUEUE_H_
#define _EVENT_MSGQUEUE_H_

#include <event.h>

#ifdef __cplusplus
extern "C" {
#endif

struct event_msgqueue;

struct event_msgqueue *msgqueue_new(struct event_base *, unsigned int, void (*)(void *, void *), void *);
int msgqueue_push(struct event_msgqueue *, void *);
unsigned int msgqueue_length(struct event_msgqueue *);
void msgqueue_destroy(struct event_msgqueue*);

#ifdef __cplusplus
}
#endif

#endif

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The GNU Lesser General Public License (LGPLv3)


Written By
China China
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions