|
mUPnP for C
|
#include <mupnp/http/http.h>#include <mupnp/net/socket.h>#include <mupnp/util/list.h>#include <mupnp/util/log.h>#include <mupnp/util/mutex.h>#include <mupnp/util/time.h>Data Structures | |
| struct | _mUpnpHttpPersistentConnection |
Macros | |
| #define | MUPNP_HTTP_PERSISTENT_CACHE_SIZE 5 |
| #define | MUPNP_HTTP_PERSISTENT_TIMEOUT_PERIOD 60 |
Typedefs | |
| typedef struct _mUpnpHttpPersistentConnection | mUpnpHttpPersistentConnection |
| typedef struct _mUpnpHttpPersistentConnection | mUpnpHttpPersistentConnectionList |
Functions | |
| bool | mupnp_http_persistentconnection_init (void) |
| mUpnpHttpPersistentConnection * | mupnp_http_persistentconnection_new (void) |
| void | mupnp_http_persistentconnection_delete (mUpnpHttpPersistentConnection *node) |
| void * | mupnp_http_persistentconnection_get (char *host, int port) |
| bool | mupnp_http_persistentconnection_put (char *host, int port, void *data) |
| void | mupnp_http_persistentconnection_clear (void) |
| void | mupnp_http_persistentconnection_lock (void) |
| void | mupnp_http_persistentconnection_unlock (void) |
Variables | |
| static mUpnpHttpPersistentConnectionList * | cache = NULL |
| static mUpnpMutex * | persistentConnectionMutex = NULL |
| #define MUPNP_HTTP_PERSISTENT_CACHE_SIZE 5 |
| #define MUPNP_HTTP_PERSISTENT_TIMEOUT_PERIOD 60 |
| typedef struct _mUpnpHttpPersistentConnection mUpnpHttpPersistentConnection |
| typedef struct _mUpnpHttpPersistentConnection mUpnpHttpPersistentConnectionList |
| void mupnp_http_persistentconnection_clear | ( | void | ) |
Clear persistent connection cache and free all memory
| void mupnp_http_persistentconnection_delete | ( | mUpnpHttpPersistentConnection * | node | ) |
| void * mupnp_http_persistentconnection_get | ( | char * | host, |
| int | port ) |
Get persistent connection from cache
| bool mupnp_http_persistentconnection_init | ( | void | ) |
Initialize persistent connection cache. Can be called many times
| void mupnp_http_persistentconnection_lock | ( | void | ) |
Lock persistent connection cache. Required for getting, putting and using persistent connection from cache
| mUpnpHttpPersistentConnection * mupnp_http_persistentconnection_new | ( | void | ) |
| bool mupnp_http_persistentconnection_put | ( | char * | host, |
| int | port, | ||
| void * | data ) |
Put connection to persistent connection cache
| void mupnp_http_persistentconnection_unlock | ( | void | ) |
Unlock persistent connection cache.
|
static |
|
static |