diff --git a/annotated.html b/annotated.html new file mode 100644 index 0000000..6622f03 --- /dev/null +++ b/annotated.html @@ -0,0 +1,95 @@ + + + + + + + +libevent: Data Structures + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+
Data Structures
+
+
+
Here are the data structures with brief descriptions:
+ + + + + + + + + + + + + + +
 CbuffereventAn opaque type for handling buffered IO
 CevbufferAn evbuffer is an opaque data type for efficiently buffering data to be sent or received on the network
 Cevbuffer_cb_infoStructure passed to an evbuffer_cb_func evbuffer callback
 Cevbuffer_iovecDescribes a single extent of memory inside an evbuffer
 Cevbuffer_ptrPointer to a position within an evbuffer
 CeventStructure to represent a single event
 Cevent_baseStructure to hold information and state for a Libevent dispatch loop
 Cevent_configConfiguration for an event_base
 Cevhttp_ext_methodStructure that is passed to (and modified by) the extended method callback function
 Cevthread_condition_callbacksThis structure describes the interface a threading library uses for condition variables
 Cevthread_lock_callbacksThis structure describes the interface a threading library uses for locking
 Cevutil_addrinfoA definition of struct addrinfo for systems that lack it
 Cevutil_monotonic_timerStructure to hold information about a monotonic timer
+
+
+ + + + diff --git a/bc_s.png b/bc_s.png new file mode 100644 index 0000000..224b29a Binary files /dev/null and b/bc_s.png differ diff --git a/bdwn.png b/bdwn.png new file mode 100644 index 0000000..940a0b9 Binary files /dev/null and b/bdwn.png differ diff --git a/buffer_8h.html b/buffer_8h.html new file mode 100644 index 0000000..a47db0d --- /dev/null +++ b/buffer_8h.html @@ -0,0 +1,2729 @@ + + + + + + + +libevent: event2/buffer.h File Reference + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+Data Structures | +Macros | +Typedefs | +Enumerations | +Functions
+
+
buffer.h File Reference
+
+
+ +

Functions for buffering data for network sending or receiving. +More...

+
#include <event2/visibility.h>
+#include <event2/event-config.h>
+#include <stdarg.h>
+#include <event2/util.h>
+
+

Go to the source code of this file.

+ + + + + + + + + + + + + + +

+Data Structures

struct  evbuffer
 An evbuffer is an opaque data type for efficiently buffering data to be sent or received on the network. More...
 
struct  evbuffer_cb_info
 Structure passed to an evbuffer_cb_func evbuffer callback. More...
 
struct  evbuffer_iovec
 Describes a single extent of memory inside an evbuffer. More...
 
struct  evbuffer_ptr
 Pointer to a position within an evbuffer. More...
 
+ + + + + + + + + + + + + + + + + + + +

+Macros

+#define EVBUF_FS_CLOSE_ON_FREE   0x01
 Flag for creating evbuffer_file_segment: If this flag is set, then when the evbuffer_file_segment is freed and no longer in use by any evbuffer, the underlying fd is closed.
 
#define EVBUF_FS_DISABLE_LOCKING   0x08
 Flag for creating evbuffer_file_segment: Do not allocate a lock for this segment. More...
 
+#define EVBUF_FS_DISABLE_MMAP   0x02
 Flag for creating evbuffer_file_segment: Disable memory-map based implementations.
 
#define EVBUF_FS_DISABLE_SENDFILE   0x04
 Flag for creating evbuffer_file_segment: Disable direct fd-to-fd implementations (sendfile). More...
 
#define EVBUFFER_CB_ENABLED   1
 If this flag is not set, then a callback is temporarily disabled, and should not be invoked. More...
 
#define EVBUFFER_FLAG_DRAINS_TO_FD   1
 If this flag is set, then we will not use evbuffer_peek(), evbuffer_remove(), evbuffer_remove_buffer(), and so on to read bytes from this buffer: we'll only take bytes out of this buffer by writing them to the network (as with evbuffer_write_atmost), by removing them without observing them (as with evbuffer_drain), or by copying them all out at once (as with evbuffer_add_buffer). More...
 
+ + + + + + + + + + +

+Typedefs

typedef void(* evbuffer_cb_func) (struct evbuffer *buffer, const struct evbuffer_cb_info *info, void *arg)
 Type definition for a callback that is invoked whenever data is added or removed from an evbuffer. More...
 
+typedef void(* evbuffer_file_segment_cleanup_cb) (struct evbuffer_file_segment const *seg, int flags, void *arg)
 A cleanup function for a evbuffer_file_segment added to an evbuffer for reference.
 
typedef void(* evbuffer_ref_cleanup_cb) (const void *data, size_t datalen, void *extra)
 A cleanup function for a piece of memory added to an evbuffer by reference. More...
 
+ + + + + + + +

+Enumerations

enum  evbuffer_eol_style {
+  EVBUFFER_EOL_ANY, +EVBUFFER_EOL_CRLF, +EVBUFFER_EOL_CRLF_STRICT, +EVBUFFER_EOL_LF, +
+  EVBUFFER_EOL_NUL +
+ }
 Used to tell evbuffer_readln what kind of line-ending to look for. More...
 
enum  evbuffer_ptr_how { EVBUFFER_PTR_SET, +EVBUFFER_PTR_ADD + }
 Defines how to adjust an evbuffer_ptr by evbuffer_ptr_set() More...
 
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+Functions

EVENT2_EXPORT_SYMBOL int evbuffer_add (struct evbuffer *buf, const void *data, size_t datlen)
 Append data to the end of an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_add_buffer (struct evbuffer *outbuf, struct evbuffer *inbuf)
 Move all data from one evbuffer into another evbuffer. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_add_buffer_reference (struct evbuffer *outbuf, struct evbuffer *inbuf)
 Copy data from one evbuffer into another evbuffer. More...
 
EVENT2_EXPORT_SYMBOL struct evbuffer_cb_entry * evbuffer_add_cb (struct evbuffer *buffer, evbuffer_cb_func cb, void *cbarg)
 Add a new callback to an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_add_file (struct evbuffer *outbuf, int fd, ev_off_t offset, ev_off_t length)
 Copy data from a file into the evbuffer for writing to a socket. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_add_file_segment (struct evbuffer *buf, struct evbuffer_file_segment *seg, ev_off_t offset, ev_off_t length)
 Insert some or all of an evbuffer_file_segment at the end of an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL size_t evbuffer_add_iovec (struct evbuffer *buffer, struct evbuffer_iovec *vec, int n_vec)
 Append data from 1 or more iovec's to an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_add_printf (struct evbuffer *buf, const char *fmt,...)
 Append a formatted string to the end of an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_add_reference (struct evbuffer *outbuf, const void *data, size_t datlen, evbuffer_ref_cleanup_cb cleanupfn, void *cleanupfn_arg)
 Reference memory into an evbuffer without copying. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_add_reference_with_offset (struct evbuffer *outbuf, const void *data, size_t offset, size_t datlen, evbuffer_ref_cleanup_cb cleanupfn, void *cleanupfn_arg)
 Reference memory into an evbuffer without copying. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_add_vprintf (struct evbuffer *buf, const char *fmt, va_list ap)
 Append a va_list formatted string to the end of an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_cb_clear_flags (struct evbuffer *buffer, struct evbuffer_cb_entry *cb, ev_uint32_t flags)
 Change the flags that are set for a callback on a buffer by removing some. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_cb_set_flags (struct evbuffer *buffer, struct evbuffer_cb_entry *cb, ev_uint32_t flags)
 Change the flags that are set for a callback on a buffer by adding more. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_clear_flags (struct evbuffer *buf, ev_uint64_t flags)
 Change the flags that are set for an evbuffer by removing some. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_commit_space (struct evbuffer *buf, struct evbuffer_iovec *vec, int n_vecs)
 Commits previously reserved space. More...
 
EVENT2_EXPORT_SYMBOL ev_ssize_t evbuffer_copyout (struct evbuffer *buf, void *data_out, size_t datlen)
 Read data from an evbuffer, and leave the buffer unchanged. More...
 
EVENT2_EXPORT_SYMBOL ev_ssize_t evbuffer_copyout_from (struct evbuffer *buf, const struct evbuffer_ptr *pos, void *data_out, size_t datlen)
 Read data from the middle of an evbuffer, and leave the buffer unchanged. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_defer_callbacks (struct evbuffer *buffer, struct event_base *base)
 Force all the callbacks on an evbuffer to be run, not immediately after the evbuffer is altered, but instead from inside the event loop. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_drain (struct evbuffer *buf, size_t len)
 Remove a specified number of bytes data from the beginning of an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_enable_locking (struct evbuffer *buf, void *lock)
 Enable locking on an evbuffer so that it can safely be used by multiple threads at the same time. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_expand (struct evbuffer *buf, size_t datlen)
 Expands the available space in an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL void evbuffer_file_segment_add_cleanup_cb (struct evbuffer_file_segment *seg, evbuffer_file_segment_cleanup_cb cb, void *arg)
 Add cleanup callback and argument for the callback to an evbuffer_file_segment. More...
 
EVENT2_EXPORT_SYMBOL void evbuffer_file_segment_free (struct evbuffer_file_segment *seg)
 Free an evbuffer_file_segment. More...
 
EVENT2_EXPORT_SYMBOL struct evbuffer_file_segment * evbuffer_file_segment_new (int fd, ev_off_t offset, ev_off_t length, unsigned flags)
 Create and return a new evbuffer_file_segment for reading data from a file and sending it out via an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL void evbuffer_free (struct evbuffer *buf)
 Deallocate storage for an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_freeze (struct evbuffer *buf, int at_front)
 Prevent calls that modify an evbuffer from succeeding. More...
 
EVENT2_EXPORT_SYMBOL size_t evbuffer_get_contiguous_space (const struct evbuffer *buf)
 Returns the number of contiguous available bytes in the first buffer chain. More...
 
EVENT2_EXPORT_SYMBOL size_t evbuffer_get_length (const struct evbuffer *buf)
 Returns the total number of bytes stored in the evbuffer. More...
 
EVENT2_EXPORT_SYMBOL size_t evbuffer_get_max_read (struct evbuffer *buf)
 Get maximum read buffer size. More...
 
EVENT2_EXPORT_SYMBOL void evbuffer_lock (struct evbuffer *buf)
 Acquire the lock on an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL struct evbufferevbuffer_new (void)
 Allocate storage for a new evbuffer. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_peek (struct evbuffer *buffer, ev_ssize_t len, struct evbuffer_ptr *start_at, struct evbuffer_iovec *vec_out, int n_vec)
 Function to peek at data inside an evbuffer without removing it or copying it out. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_prepend (struct evbuffer *buf, const void *data, size_t size)
 Prepends data to the beginning of the evbuffer. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_prepend_buffer (struct evbuffer *dst, struct evbuffer *src)
 Prepends all data from the src evbuffer to the beginning of the dst evbuffer. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_ptr_set (struct evbuffer *buffer, struct evbuffer_ptr *ptr, size_t position, enum evbuffer_ptr_how how)
 Sets the search pointer in the buffer to position. More...
 
EVENT2_EXPORT_SYMBOL unsigned char * evbuffer_pullup (struct evbuffer *buf, ev_ssize_t size)
 Makes the data at the beginning of an evbuffer contiguous. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_read (struct evbuffer *buffer, evutil_socket_t fd, int howmuch)
 Read from a file descriptor and store the result in an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL char * evbuffer_readln (struct evbuffer *buffer, size_t *n_read_out, enum evbuffer_eol_style eol_style)
 Read a single line from an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_remove (struct evbuffer *buf, void *data, size_t datlen)
 Read data from an evbuffer and drain the bytes read. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_remove_buffer (struct evbuffer *src, struct evbuffer *dst, size_t datlen)
 Read data from an evbuffer into another evbuffer, draining the bytes from the source buffer. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_remove_cb (struct evbuffer *buffer, evbuffer_cb_func cb, void *cbarg)
 Remove a callback from an evbuffer, given the function and argument used to add it. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_remove_cb_entry (struct evbuffer *buffer, struct evbuffer_cb_entry *ent)
 Remove a callback from an evbuffer, given a handle returned from evbuffer_add_cb. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_reserve_space (struct evbuffer *buf, ev_ssize_t size, struct evbuffer_iovec *vec, int n_vec)
 Reserves space in the last chain or chains of an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL struct evbuffer_ptr evbuffer_search (struct evbuffer *buffer, const char *what, size_t len, const struct evbuffer_ptr *start)
 Search for a string within an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL struct evbuffer_ptr evbuffer_search_eol (struct evbuffer *buffer, struct evbuffer_ptr *start, size_t *eol_len_out, enum evbuffer_eol_style eol_style)
 Search for an end-of-line string within an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL struct evbuffer_ptr evbuffer_search_range (struct evbuffer *buffer, const char *what, size_t len, const struct evbuffer_ptr *start, const struct evbuffer_ptr *end)
 Search for a string within part of an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_set_flags (struct evbuffer *buf, ev_uint64_t flags)
 Change the flags that are set for an evbuffer by adding more. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_set_max_read (struct evbuffer *buf, size_t max)
 Set maximum read buffer size. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_unfreeze (struct evbuffer *buf, int at_front)
 Re-enable calls that modify an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL void evbuffer_unlock (struct evbuffer *buf)
 Release the lock on an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_write (struct evbuffer *buffer, evutil_socket_t fd)
 Write the contents of an evbuffer to a file descriptor. More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_write_atmost (struct evbuffer *buffer, evutil_socket_t fd, ev_ssize_t howmuch)
 Write some of the contents of an evbuffer to a file descriptor. More...
 
+

Detailed Description

+

Functions for buffering data for network sending or receiving.

+

An evbuffer can be used for preparing data before sending it to the network or conversely for reading data from the network. Evbuffers try to avoid memory copies as much as possible. As a result, evbuffers can be used to pass data around without actually incurring the overhead of copying the data.

+

A new evbuffer can be allocated with evbuffer_new(), and can be freed with evbuffer_free(). Most users will be using evbuffers via the bufferevent interface. To access a bufferevent's evbuffers, use bufferevent_get_input() and bufferevent_get_output().

+

There are several guidelines for using evbuffers.

+ +

In Libevent 2.0 and later, evbuffers are represented using a linked list of memory chunks, with pointers to the first and last chunk in the chain.

+

As the contents of an evbuffer can be stored in multiple different memory blocks, it cannot be accessed directly. Instead, evbuffer_pullup() can be used to force a specified number of bytes to be contiguous. This will cause memory reallocation and memory copies if the data is split across multiple blocks. It is more efficient, however, to use evbuffer_peek() if you don't require that the memory to be contiguous.

+

Macro Definition Documentation

+ +

◆ EVBUF_FS_DISABLE_LOCKING

+ +
+
+ + + + +
#define EVBUF_FS_DISABLE_LOCKING   0x08
+
+ +

Flag for creating evbuffer_file_segment: Do not allocate a lock for this segment.

+

If this option is set, then neither the segment nor any evbuffer it is added to may ever be accessed from more than one thread at a time.

+ +
+
+ +

◆ EVBUF_FS_DISABLE_SENDFILE

+ +
+
+ + + + +
#define EVBUF_FS_DISABLE_SENDFILE   0x04
+
+ +

Flag for creating evbuffer_file_segment: Disable direct fd-to-fd implementations (sendfile).

+

You might want to use this option if data needs to be taken from the evbuffer by any means other than writing it to the network: the sendfile backend is fast, but it only works for sending files directly to the network.

+ +
+
+ +

◆ EVBUFFER_CB_ENABLED

+ +
+
+ + + + +
#define EVBUFFER_CB_ENABLED   1
+
+ +

If this flag is not set, then a callback is temporarily disabled, and should not be invoked.

+
See also
evbuffer_cb_set_flags(), evbuffer_cb_clear_flags()
+ +
+
+ +

◆ EVBUFFER_FLAG_DRAINS_TO_FD

+ +
+
+ + + + +
#define EVBUFFER_FLAG_DRAINS_TO_FD   1
+
+ +

If this flag is set, then we will not use evbuffer_peek(), evbuffer_remove(), evbuffer_remove_buffer(), and so on to read bytes from this buffer: we'll only take bytes out of this buffer by writing them to the network (as with evbuffer_write_atmost), by removing them without observing them (as with evbuffer_drain), or by copying them all out at once (as with evbuffer_add_buffer).

+

Using this option allows the implementation to use sendfile-based operations for evbuffer_add_file(); see that function for more information.

+

This flag is on by default for bufferevents that can take advantage of it; you should never actually need to set it on a bufferevent's output buffer.

+ +
+
+

Typedef Documentation

+ +

◆ evbuffer_cb_func

+ +
+
+ + + + +
typedef void(* evbuffer_cb_func) (struct evbuffer *buffer, const struct evbuffer_cb_info *info, void *arg)
+
+ +

Type definition for a callback that is invoked whenever data is added or removed from an evbuffer.

+

An evbuffer may have one or more callbacks set at a time. The order in which they are executed is undefined.

+

A callback function may add more callbacks, or remove itself from the list of callbacks, or add or remove data from the buffer. It may not remove another callback from the list.

+

If a callback adds or removes data from the buffer or from another buffer, this can cause a recursive invocation of your callback or other callbacks. If you ask for an infinite loop, you might just get one: watch out!

+
Parameters
+ + + + +
bufferthe buffer whose size has changed
infoa structure describing how the buffer changed.
arga pointer to user data
+
+
+ +
+
+ +

◆ evbuffer_ref_cleanup_cb

+ +
+
+ + + + +
typedef void(* evbuffer_ref_cleanup_cb) (const void *data, size_t datalen, void *extra)
+
+ +

A cleanup function for a piece of memory added to an evbuffer by reference.

+
Parameters
+ + + +
databuffer
datalen- total buffer len (including @offset if any,
+
+
+
See also
evbuffer_add_reference_with_offset())
+
+evbuffer_add_reference()
+
+evbuffer_add_reference_with_offset()
+ +
+
+

Enumeration Type Documentation

+ +

◆ evbuffer_eol_style

+ +
+
+ + + + +
enum evbuffer_eol_style
+
+ +

Used to tell evbuffer_readln what kind of line-ending to look for.

+ + + + + + +
Enumerator
EVBUFFER_EOL_ANY 

Any sequence of CR and LF characters is acceptable as an EOL.

+

Note that this style can produce ambiguous results: the sequence "CRLF" will be treated as a single EOL if it is all in the buffer at once, but if you first read a CR from the network and later read an LF from the network, it will be treated as two EOLs.

+
EVBUFFER_EOL_CRLF 

An EOL is an LF, optionally preceded by a CR.

+

This style is most useful for implementing text-based internet protocols.

+
EVBUFFER_EOL_CRLF_STRICT 

An EOL is a CR followed by an LF.

+
EVBUFFER_EOL_LF 

An EOL is a LF.

+
EVBUFFER_EOL_NUL 

An EOL is a NUL character (that is, a single byte with value 0)

+
+ +
+
+ +

◆ evbuffer_ptr_how

+ +
+
+ + + + +
enum evbuffer_ptr_how
+
+ +

Defines how to adjust an evbuffer_ptr by evbuffer_ptr_set()

+
See also
evbuffer_ptr_set()
+ + + +
Enumerator
EVBUFFER_PTR_SET 

Sets the pointer to the position; can be called on with an uninitialized evbuffer_ptr.

+
EVBUFFER_PTR_ADD 

Advances the pointer by adding to the current position.

+
+ +
+
+

Function Documentation

+ +

◆ evbuffer_add()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_add (struct evbufferbuf,
const void * data,
size_t datlen 
)
+
+ +

Append data to the end of an evbuffer.

+
Parameters
+ + + + +
bufthe evbuffer to be appended to
datapointer to the beginning of the data buffer
datlenthe number of bytes to be copied from the data buffer
+
+
+
Returns
0 on success, -1 on failure.
+ +
+
+ +

◆ evbuffer_add_buffer()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_add_buffer (struct evbufferoutbuf,
struct evbufferinbuf 
)
+
+ +

Move all data from one evbuffer into another evbuffer.

+

This is a destructive add. The data from one buffer moves into the other buffer. However, no unnecessary memory copies occur.

+
Parameters
+ + + +
outbufthe output buffer
inbufthe input buffer
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
evbuffer_remove_buffer()
+ +
+
+ +

◆ evbuffer_add_buffer_reference()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_add_buffer_reference (struct evbufferoutbuf,
struct evbufferinbuf 
)
+
+ +

Copy data from one evbuffer into another evbuffer.

+

This is a non-destructive add. The data from one buffer is copied into the other buffer. However, no unnecessary memory copies occur.

+

Note that buffers already containing buffer references can't be added to other buffers.

+
Parameters
+ + + +
outbufthe output buffer
inbufthe input buffer
+
+
+
Returns
0 if successful, or -1 if an error occurred
+ +
+
+ +

◆ evbuffer_add_cb()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evbuffer_cb_entry* evbuffer_add_cb (struct evbufferbuffer,
evbuffer_cb_func cb,
void * cbarg 
)
+
+ +

Add a new callback to an evbuffer.

+

Subsequent calls to evbuffer_add_cb() add new callbacks. To remove this callback, call evbuffer_remove_cb or evbuffer_remove_cb_entry.

+
Parameters
+ + + + +
bufferthe evbuffer to be monitored
cbthe callback function to invoke when the evbuffer is modified, or NULL to remove all callbacks.
cbargan argument to be provided to the callback function
+
+
+
Returns
a handle to the callback on success, or NULL on failure.
+ +
+
+ +

◆ evbuffer_add_file()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_add_file (struct evbufferoutbuf,
int fd,
ev_off_t offset,
ev_off_t length 
)
+
+ +

Copy data from a file into the evbuffer for writing to a socket.

+

This function avoids unnecessary data copies between userland and kernel. If sendfile is available and the EVBUFFER_FLAG_DRAINS_TO_FD flag is set, it uses those functions. Otherwise, it tries to use mmap (or CreateFileMapping on Windows).

+

The function owns the resulting file descriptor and will close (even in case of error) it when finished transferring data.

+

The results of using evbuffer_remove() or evbuffer_pullup() on evbuffers whose data was added using this function are undefined.

+

For more fine-grained control, use evbuffer_add_file_segment.

+
Parameters
+ + + + + +
outbufthe output buffer
fdthe file descriptor
offsetthe offset from which to read data
lengthhow much data to read, or -1 to read as much as possible. (-1 requires that 'fd' support fstat.)
+
+
+
Returns
0 if successful, or -1 if an error occurred
+ +
+
+ +

◆ evbuffer_add_file_segment()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_add_file_segment (struct evbufferbuf,
struct evbuffer_file_segment * seg,
ev_off_t offset,
ev_off_t length 
)
+
+ +

Insert some or all of an evbuffer_file_segment at the end of an evbuffer.

+

Note that the offset and length parameters of this function have a different meaning from those provided to evbuffer_file_segment_new: When you create the segment, the offset is the offset within the file, and the length is the length of the segment, whereas when you add a segment to an evbuffer, the offset is within the segment and the length is the length of the _part of the segment you want to use.

+

In other words, if you have a 10 KiB file, and you create an evbuffer_file_segment for it with offset 20 and length 1000, it will refer to bytes 20..1019 inclusive. If you then pass this segment to evbuffer_add_file_segment and specify an offset of 20 and a length of 50, you will be adding bytes 40..99 inclusive.

+
Parameters
+ + + + + +
bufthe evbuffer to append to
segthe segment to add
offsetthe offset within the segment to start from
lengththe amount of data to add, or -1 to add it all.
+
+
+
Returns
0 on success, -1 on failure.
+ +
+
+ +

◆ evbuffer_add_iovec()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL size_t evbuffer_add_iovec (struct evbufferbuffer,
struct evbuffer_iovecvec,
int n_vec 
)
+
+ +

Append data from 1 or more iovec's to an evbuffer.

+

Calculates the number of bytes needed for an iovec structure and guarantees all data will fit into a single chain. Can be used in lieu of functionality which calls evbuffer_add() constantly before being used to increase performance.

+
Parameters
+ + + + +
bufferthe destination buffer
vecthe source iovec
n_vecthe number of iovec structures.
+
+
+
Returns
the number of bytes successfully written to the output buffer.
+ +
+
+ +

◆ evbuffer_add_printf()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_add_printf (struct evbufferbuf,
const char * fmt,
 ... 
)
+
+ +

Append a formatted string to the end of an evbuffer.

+

The string is formated as printf.

+
Parameters
+ + + + +
bufthe evbuffer that will be appended to
fmta format string
...arguments that will be passed to printf(3)
+
+
+
Returns
The number of bytes added if successful, or -1 if an error occurred.
+
See also
evutil_printf(), evbuffer_add_vprintf()
+ +
+
+ +

◆ evbuffer_add_reference()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_add_reference (struct evbufferoutbuf,
const void * data,
size_t datlen,
evbuffer_ref_cleanup_cb cleanupfn,
void * cleanupfn_arg 
)
+
+ +

Reference memory into an evbuffer without copying.

+

The memory needs to remain valid until all the added data has been read. This function keeps just a reference to the memory without actually incurring the overhead of a copy.

+
Parameters
+ + + + + + +
outbufthe output buffer
datathe memory to reference
datlenhow memory to reference
cleanupfncallback to be invoked when the memory is no longer referenced by this evbuffer.
cleanupfn_argoptional argument to the cleanup callback
+
+
+
Returns
0 if successful, or -1 if an error occurred
+ +
+
+ +

◆ evbuffer_add_reference_with_offset()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_add_reference_with_offset (struct evbufferoutbuf,
const void * data,
size_t offset,
size_t datlen,
evbuffer_ref_cleanup_cb cleanupfn,
void * cleanupfn_arg 
)
+
+ +

Reference memory into an evbuffer without copying.

+

The memory needs to remain valid until all the added data has been read. This function keeps just a reference to the memory without actually incurring the overhead of a copy.

+
Parameters
+ + + + + + + +
outbufthe output buffer
datathe memory to reference
offsetoffset inside @data
datlenhow memory to reference (excluding @offset)
cleanupfncallback to be invoked when the memory is no longer referenced by this evbuffer.
cleanupfn_argoptional argument to the cleanup callback
+
+
+
Returns
0 if successful, or -1 if an error occurred
+ +
+
+ +

◆ evbuffer_add_vprintf()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_add_vprintf (struct evbufferbuf,
const char * fmt,
va_list ap 
)
+
+ +

Append a va_list formatted string to the end of an evbuffer.

+
Parameters
+ + + + +
bufthe evbuffer that will be appended to
fmta format string
apa varargs va_list argument array that will be passed to vprintf(3)
+
+
+
Returns
The number of bytes added if successful, or -1 if an error occurred.
+ +
+
+ +

◆ evbuffer_cb_clear_flags()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_cb_clear_flags (struct evbufferbuffer,
struct evbuffer_cb_entry * cb,
ev_uint32_t flags 
)
+
+ +

Change the flags that are set for a callback on a buffer by removing some.

+
Parameters
+ + + + +
bufferthe evbuffer that the callback is watching.
cbthe callback whose status we want to change.
flagsEVBUFFER_CB_ENABLED to disable the callback.
+
+
+
Returns
0 on success, -1 on failure.
+ +
+
+ +

◆ evbuffer_cb_set_flags()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_cb_set_flags (struct evbufferbuffer,
struct evbuffer_cb_entry * cb,
ev_uint32_t flags 
)
+
+ +

Change the flags that are set for a callback on a buffer by adding more.

+
Parameters
+ + + + +
bufferthe evbuffer that the callback is watching.
cbthe callback whose status we want to change.
flagsEVBUFFER_CB_ENABLED to re-enable the callback.
+
+
+
Returns
0 on success, -1 on failure.
+ +
+
+ +

◆ evbuffer_clear_flags()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_clear_flags (struct evbufferbuf,
ev_uint64_t flags 
)
+
+ +

Change the flags that are set for an evbuffer by removing some.

+
Parameters
+ + + +
bufthe evbuffer that the callback is watching.
flagsOne or more EVBUFFER_FLAG_* options
+
+
+
Returns
0 on success, -1 on failure.
+ +
+
+ +

◆ evbuffer_commit_space()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_commit_space (struct evbufferbuf,
struct evbuffer_iovecvec,
int n_vecs 
)
+
+ +

Commits previously reserved space.

+

Commits some of the space previously reserved with evbuffer_reserve_space(). It then becomes available for reading.

+

This function may return an error if the pointer in the extents do not match those returned from evbuffer_reserve_space, or if data has been added to the buffer since the space was reserved.

+

If you want to commit less data than you got reserved space for, modify the iov_len pointer of the appropriate extent to a smaller value. Note that you may have received more space than you requested if it was available!

+
Parameters
+ + + + +
bufthe evbuffer in which to reserve space.
vecone or two extents returned by evbuffer_reserve_space.
n_vecsthe number of extents.
+
+
+
Returns
0 on success, -1 on error
+
See also
evbuffer_reserve_space()
+ +
+
+ +

◆ evbuffer_copyout()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL ev_ssize_t evbuffer_copyout (struct evbufferbuf,
void * data_out,
size_t datlen 
)
+
+ +

Read data from an evbuffer, and leave the buffer unchanged.

+

If more bytes are requested than are available in the evbuffer, we only extract as many bytes as were available.

+
Parameters
+ + + + +
bufthe evbuffer to be read from
data_outthe destination buffer to store the result
datlenthe maximum size of the destination buffer
+
+
+
Returns
the number of bytes read, or -1 if we can't drain the buffer.
+ +
+
+ +

◆ evbuffer_copyout_from()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL ev_ssize_t evbuffer_copyout_from (struct evbufferbuf,
const struct evbuffer_ptrpos,
void * data_out,
size_t datlen 
)
+
+ +

Read data from the middle of an evbuffer, and leave the buffer unchanged.

+

If more bytes are requested than are available in the evbuffer, we only extract as many bytes as were available.

+
Parameters
+ + + + + +
bufthe evbuffer to be read from
posthe position to start reading from
data_outthe destination buffer to store the result
datlenthe maximum size of the destination buffer
+
+
+
Returns
the number of bytes read, or -1 if we can't drain the buffer.
+ +
+
+ +

◆ evbuffer_defer_callbacks()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_defer_callbacks (struct evbufferbuffer,
struct event_basebase 
)
+
+ +

Force all the callbacks on an evbuffer to be run, not immediately after the evbuffer is altered, but instead from inside the event loop.

+

This can be used to serialize all the callbacks to a single thread of execution.

+ +
+
+ +

◆ evbuffer_drain()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_drain (struct evbufferbuf,
size_t len 
)
+
+ +

Remove a specified number of bytes data from the beginning of an evbuffer.

+
Parameters
+ + + +
bufthe evbuffer to be drained
lenthe number of bytes to drain from the beginning of the buffer
+
+
+
Returns
0 on success, -1 on failure.
+ +
+
+ +

◆ evbuffer_enable_locking()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_enable_locking (struct evbufferbuf,
void * lock 
)
+
+ +

Enable locking on an evbuffer so that it can safely be used by multiple threads at the same time.

+

NOTE: when locking is enabled, the lock will be held when callbacks are invoked. This could result in deadlock if you aren't careful. Plan accordingly!

+
Parameters
+ + + +
bufAn evbuffer to make lockable.
lockA lock object, or NULL if we should allocate our own.
+
+
+
Returns
0 on success, -1 on failure.
+ +
+
+ +

◆ evbuffer_expand()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_expand (struct evbufferbuf,
size_t datlen 
)
+
+ +

Expands the available space in an evbuffer.

+

Expands the available space in the evbuffer to at least datlen, so that appending datlen additional bytes will not require any new allocations.

+
Parameters
+ + + +
bufthe evbuffer to be expanded
datlenthe new minimum length requirement
+
+
+
Returns
0 if successful, or -1 if an error occurred
+ +
+
+ +

◆ evbuffer_file_segment_add_cleanup_cb()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evbuffer_file_segment_add_cleanup_cb (struct evbuffer_file_segment * seg,
evbuffer_file_segment_cleanup_cb cb,
void * arg 
)
+
+ +

Add cleanup callback and argument for the callback to an evbuffer_file_segment.

+

The cleanup callback will be invoked when no more references to the evbuffer_file_segment exist.

+ +
+
+ +

◆ evbuffer_file_segment_free()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void evbuffer_file_segment_free (struct evbuffer_file_segment * seg)
+
+ +

Free an evbuffer_file_segment.

+

It is safe to call this function even if the segment has been added to one or more evbuffers. The evbuffer_file_segment will not be freed until no more references to it exist.

+ +
+
+ +

◆ evbuffer_file_segment_new()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evbuffer_file_segment* evbuffer_file_segment_new (int fd,
ev_off_t offset,
ev_off_t length,
unsigned flags 
)
+
+ +

Create and return a new evbuffer_file_segment for reading data from a file and sending it out via an evbuffer.

+

This function avoids unnecessary data copies between userland and kernel. Where available, it uses sendfile.

+

The file descriptor must not be closed so long as any evbuffer is using this segment.

+

The results of using evbuffer_remove() or evbuffer_pullup() or any other function that reads bytes from an evbuffer on any evbuffer containing the newly returned segment are undefined, unless you pass the EVBUF_FS_DISABLE_SENDFILE flag to this function.

+
Parameters
+ + + + + +
fdan open file to read from.
offsetan index within the file at which to start reading
lengthhow much data to read, or -1 to read as much as possible. (-1 requires that 'fd' support fstat.)
flagsany number of the EVBUF_FS_* flags
+
+
+
Returns
a new evbuffer_file_segment, or NULL on failure.
+ +
+
+ +

◆ evbuffer_free()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void evbuffer_free (struct evbufferbuf)
+
+ +

Deallocate storage for an evbuffer.

+
Parameters
+ + +
bufpointer to the evbuffer to be freed
+
+
+ +
+
+ +

◆ evbuffer_freeze()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_freeze (struct evbufferbuf,
int at_front 
)
+
+ +

Prevent calls that modify an evbuffer from succeeding.

+

A buffer may frozen at the front, at the back, or at both the front and the back.

+

If the front of a buffer is frozen, operations that drain data from the front of the buffer, or that prepend data to the buffer, will fail until it is unfrozen. If the back a buffer is frozen, operations that append data from the buffer will fail until it is unfrozen.

+
Parameters
+ + + +
bufThe buffer to freeze
at_frontIf true, we freeze the front of the buffer. If false, we freeze the back.
+
+
+
Returns
0 on success, -1 on failure.
+ +
+
+ +

◆ evbuffer_get_contiguous_space()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL size_t evbuffer_get_contiguous_space (const struct evbufferbuf)
+
+ +

Returns the number of contiguous available bytes in the first buffer chain.

+

This is useful when processing data that might be split into multiple chains, or that might all be in the first chain. Calls to evbuffer_pullup() that cause reallocation and copying of data can thus be avoided.

+
Parameters
+ + +
bufpointer to the evbuffer
+
+
+
Returns
0 if no data is available, otherwise the number of available bytes in the first buffer chain.
+ +
+
+ +

◆ evbuffer_get_length()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL size_t evbuffer_get_length (const struct evbufferbuf)
+
+ +

Returns the total number of bytes stored in the evbuffer.

+
Parameters
+ + +
bufpointer to the evbuffer
+
+
+
Returns
the number of bytes stored in the evbuffer
+ +
+
+ +

◆ evbuffer_get_max_read()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL size_t evbuffer_get_max_read (struct evbufferbuf)
+
+ +

Get maximum read buffer size.

+
Parameters
+ + +
bufpointer to the evbuffer
+
+
+
Returns
current maximum buffer read
+ +
+
+ +

◆ evbuffer_lock()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void evbuffer_lock (struct evbufferbuf)
+
+ +

Acquire the lock on an evbuffer.

+

Has no effect if locking was not enabled with evbuffer_enable_locking.

+ +
+
+ +

◆ evbuffer_new()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evbuffer* evbuffer_new (void )
+
+ +

Allocate storage for a new evbuffer.

+
Returns
a pointer to a newly allocated evbuffer struct, or NULL if an error occurred
+ +
+
+ +

◆ evbuffer_peek()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_peek (struct evbufferbuffer,
ev_ssize_t len,
struct evbuffer_ptrstart_at,
struct evbuffer_iovecvec_out,
int n_vec 
)
+
+ +

Function to peek at data inside an evbuffer without removing it or copying it out.

+

Pointers to the data are returned by filling the 'vec_out' array with pointers to one or more extents of data inside the buffer.

+

The total data in the extents that you get back may be more than you requested (if there is more data last extent than you asked for), or less (if you do not provide enough evbuffer_iovecs, or if the buffer does not have as much data as you asked to see).

+
Parameters
+ + + + + + +
bufferthe evbuffer to peek into,
lenthe number of bytes to try to peek. If len is negative, we will try to fill as much of vec_out as we can. If len is negative and vec_out is not provided, we return the number of evbuffer_iovecs that would be needed to get all the data in the buffer.
start_atan evbuffer_ptr indicating the point at which we should start looking for data. NULL means, "At the start of the + buffer."
vec_outan array of evbuffer_iovec
n_vecthe length of vec_out. If 0, we only count how many extents would be necessary to point to the requested amount of data.
+
+
+
Returns
The number of extents needed. This may be less than n_vec if we didn't need all the evbuffer_iovecs we were given, or more than n_vec if we would need more to return all the data that was requested.
+ +
+
+ +

◆ evbuffer_prepend()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_prepend (struct evbufferbuf,
const void * data,
size_t size 
)
+
+ +

Prepends data to the beginning of the evbuffer.

+
Parameters
+ + + + +
bufthe evbuffer to which to prepend data
dataa pointer to the memory to prepend
sizethe number of bytes to prepend
+
+
+
Returns
0 if successful, or -1 otherwise
+ +
+
+ +

◆ evbuffer_prepend_buffer()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_prepend_buffer (struct evbufferdst,
struct evbuffersrc 
)
+
+ +

Prepends all data from the src evbuffer to the beginning of the dst evbuffer.

+
Parameters
+ + + +
dstthe evbuffer to which to prepend data
srcthe evbuffer to prepend; it will be emptied as a result
+
+
+
Returns
0 if successful, or -1 otherwise
+ +
+
+ +

◆ evbuffer_ptr_set()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_ptr_set (struct evbufferbuffer,
struct evbuffer_ptrptr,
size_t position,
enum evbuffer_ptr_how how 
)
+
+ +

Sets the search pointer in the buffer to position.

+

There are two ways to use this function: you can call evbuffer_ptr_set(buf, &pos, N, EVBUFFER_PTR_SET) to move 'pos' to a position 'N' bytes after the start of the buffer, or evbuffer_ptr_set(buf, &pos, N, EVBUFFER_PTR_ADD) to move 'pos' forward by 'N' bytes.

+

If evbuffer_ptr is not initialized, this function can only be called with EVBUFFER_PTR_SET.

+

An evbuffer_ptr can represent any position from the start of the buffer to a position immediately after the end of the buffer.

+
Parameters
+ + + + + +
bufferthe evbuffer to be search
ptra pointer to a struct evbuffer_ptr
positionthe position at which to start the next search
howdetermines how the pointer should be manipulated.
+
+
+
Returns
0 on success or -1 otherwise
+ +
+
+ +

◆ evbuffer_pullup()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL unsigned char* evbuffer_pullup (struct evbufferbuf,
ev_ssize_t size 
)
+
+ +

Makes the data at the beginning of an evbuffer contiguous.

+
Parameters
+ + + +
bufthe evbuffer to make contiguous
sizethe number of bytes to make contiguous, or -1 to make the entire buffer contiguous.
+
+
+
Returns
a pointer to the contiguous memory array, or NULL if param size requested more data than is present in the buffer.
+ +
+
+ +

◆ evbuffer_read()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_read (struct evbufferbuffer,
evutil_socket_t fd,
int howmuch 
)
+
+ +

Read from a file descriptor and store the result in an evbuffer.

+
Parameters
+ + + + +
bufferthe evbuffer to store the result
fdthe file descriptor to read from
howmuchthe number of bytes to be read. If the given number is negative or out of maximum bytes per one read, as many bytes as we can will be read.
+
+
+
Returns
the number of bytes read, or -1 if an error occurred
+
See also
evbuffer_write()
+ +
+
+ +

◆ evbuffer_readln()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL char* evbuffer_readln (struct evbufferbuffer,
size_t * n_read_out,
enum evbuffer_eol_style eol_style 
)
+
+ +

Read a single line from an evbuffer.

+

Reads a line terminated by an EOL as determined by the evbuffer_eol_style argument. Returns a newly allocated nul-terminated string; the caller must free the returned value. The EOL is not included in the returned string.

+
Parameters
+ + + + +
bufferthe evbuffer to read from
n_read_outif non-NULL, points to a size_t that is set to the number of characters in the returned string. This is useful for strings that can contain NUL characters.
eol_stylethe style of line-ending to use.
+
+
+
Returns
pointer to a single line, or NULL if an error occurred
+ +
+
+ +

◆ evbuffer_remove()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_remove (struct evbufferbuf,
void * data,
size_t datlen 
)
+
+ +

Read data from an evbuffer and drain the bytes read.

+

If more bytes are requested than are available in the evbuffer, we only extract as many bytes as were available.

+
Parameters
+ + + + +
bufthe evbuffer to be read from
datathe destination buffer to store the result
datlenthe maximum size of the destination buffer
+
+
+
Returns
the number of bytes read, or -1 if we can't drain the buffer.
+ +
+
+ +

◆ evbuffer_remove_buffer()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_remove_buffer (struct evbuffersrc,
struct evbufferdst,
size_t datlen 
)
+
+ +

Read data from an evbuffer into another evbuffer, draining the bytes from the source buffer.

+

This function avoids copy operations to the extent possible.

+

If more bytes are requested than are available in src, the src buffer is drained completely.

+
Parameters
+ + + + +
srcthe evbuffer to be read from
dstthe destination evbuffer to store the result into
datlenthe maximum numbers of bytes to transfer
+
+
+
Returns
the number of bytes read
+ +
+
+ +

◆ evbuffer_remove_cb()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_remove_cb (struct evbufferbuffer,
evbuffer_cb_func cb,
void * cbarg 
)
+
+ +

Remove a callback from an evbuffer, given the function and argument used to add it.

+
Returns
0 if a callback was removed, or -1 if no matching callback was found.
+ +
+
+ +

◆ evbuffer_remove_cb_entry()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_remove_cb_entry (struct evbufferbuffer,
struct evbuffer_cb_entry * ent 
)
+
+ +

Remove a callback from an evbuffer, given a handle returned from evbuffer_add_cb.

+

Calling this function invalidates the handle.

+
Returns
0 if a callback was removed, or -1 if no matching callback was found.
+ +
+
+ +

◆ evbuffer_reserve_space()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_reserve_space (struct evbufferbuf,
ev_ssize_t size,
struct evbuffer_iovecvec,
int n_vec 
)
+
+ +

Reserves space in the last chain or chains of an evbuffer.

+

Makes space available in the last chain or chains of an evbuffer that can be arbitrarily written to by a user. The space does not become available for reading until it has been committed with evbuffer_commit_space().

+

The space is made available as one or more extents, represented by an initial pointer and a length. You can force the memory to be available as only one extent. Allowing more extents, however, makes the function more efficient.

+

Multiple subsequent calls to this function will make the same space available until evbuffer_commit_space() has been called.

+

It is an error to do anything that moves around the buffer's internal memory structures before committing the space.

+

NOTE: The code currently does not ever use more than two extents. This may change in future versions.

+
Parameters
+ + + + + +
bufthe evbuffer in which to reserve space.
sizehow much space to make available, at minimum. The total length of the extents may be greater than the requested length.
vecan array of one or more evbuffer_iovec structures to hold pointers to the reserved extents of memory.
n_vecThe length of the vec array. Must be at least 1; 2 is more efficient.
+
+
+
Returns
the number of provided extents, or -1 on error.
+
See also
evbuffer_commit_space()
+ +
+
+ +

◆ evbuffer_search()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evbuffer_ptr evbuffer_search (struct evbufferbuffer,
const char * what,
size_t len,
const struct evbuffer_ptrstart 
)
+
+ +

Search for a string within an evbuffer.

+
Parameters
+ + + + + +
bufferthe evbuffer to be searched
whatthe string to be searched for
lenthe length of the search string
startNULL or a pointer to a valid struct evbuffer_ptr.
+
+
+
Returns
a struct evbuffer_ptr whose 'pos' field has the offset of the first occurrence of the string in the buffer after 'start'. The 'pos' field of the result is -1 if the string was not found.
+ +
+
+ +

◆ evbuffer_search_eol()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evbuffer_ptr evbuffer_search_eol (struct evbufferbuffer,
struct evbuffer_ptrstart,
size_t * eol_len_out,
enum evbuffer_eol_style eol_style 
)
+
+ +

Search for an end-of-line string within an evbuffer.

+
Parameters
+ + + + + +
bufferthe evbuffer to be searched
startNULL or a pointer to a valid struct evbuffer_ptr to start searching at.
eol_len_outIf non-NULL, the pointed-to value will be set to the length of the end-of-line string.
eol_styleThe kind of EOL to look for; see evbuffer_readln() for more information
+
+
+
Returns
a struct evbuffer_ptr whose 'pos' field has the offset of the first occurrence EOL in the buffer after 'start'. The 'pos' field of the result is -1 if the string was not found.
+ +
+
+ +

◆ evbuffer_search_range()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evbuffer_ptr evbuffer_search_range (struct evbufferbuffer,
const char * what,
size_t len,
const struct evbuffer_ptrstart,
const struct evbuffer_ptrend 
)
+
+ +

Search for a string within part of an evbuffer.

+
Parameters
+ + + + + + +
bufferthe evbuffer to be searched
whatthe string to be searched for
lenthe length of the search string
startNULL or a pointer to a valid struct evbuffer_ptr that indicates where we should start searching.
endNULL or a pointer to a valid struct evbuffer_ptr that indicates where we should stop searching.
+
+
+
Returns
a struct evbuffer_ptr whose 'pos' field has the offset of the first occurrence of the string in the buffer after 'start'. The 'pos' field of the result is -1 if the string was not found.
+ +
+
+ +

◆ evbuffer_set_flags()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_set_flags (struct evbufferbuf,
ev_uint64_t flags 
)
+
+ +

Change the flags that are set for an evbuffer by adding more.

+
Parameters
+ + + +
bufthe evbuffer that the callback is watching.
flagsOne or more EVBUFFER_FLAG_* options
+
+
+
Returns
0 on success, -1 on failure.
+ +
+
+ +

◆ evbuffer_set_max_read()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_set_max_read (struct evbufferbuf,
size_t max 
)
+
+ +

Set maximum read buffer size.

+

Default is 4096 and it works fine most of time, so before increasing the default check carefully, since this has some negative effects (like memory fragmentation and unfair resource distribution, i.e. some events will make less progress than others).

+
Parameters
+ + + +
bufpointer to the evbuffer
maxbuffer size
+
+
+
Returns
0 on success, -1 on failure (if max > INT_MAX).
+ +
+
+ +

◆ evbuffer_unfreeze()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_unfreeze (struct evbufferbuf,
int at_front 
)
+
+ +

Re-enable calls that modify an evbuffer.

+
Parameters
+ + + +
bufThe buffer to un-freeze
at_frontIf true, we unfreeze the front of the buffer. If false, we unfreeze the back.
+
+
+
Returns
0 on success, -1 on failure.
+ +
+
+ +

◆ evbuffer_unlock()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void evbuffer_unlock (struct evbufferbuf)
+
+ +

Release the lock on an evbuffer.

+

Has no effect if locking was not enabled with evbuffer_enable_locking.

+ +
+
+ +

◆ evbuffer_write()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_write (struct evbufferbuffer,
evutil_socket_t fd 
)
+
+ +

Write the contents of an evbuffer to a file descriptor.

+

The evbuffer will be drained after the bytes have been successfully written.

+
Parameters
+ + + +
bufferthe evbuffer to be written and drained
fdthe file descriptor to be written to
+
+
+
Returns
the number of bytes written, or -1 if an error occurred
+
See also
evbuffer_read()
+ +
+
+ +

◆ evbuffer_write_atmost()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_write_atmost (struct evbufferbuffer,
evutil_socket_t fd,
ev_ssize_t howmuch 
)
+
+ +

Write some of the contents of an evbuffer to a file descriptor.

+

The evbuffer will be drained after the bytes have been successfully written.

+
Parameters
+ + + + +
bufferthe evbuffer to be written and drained
fdthe file descriptor to be written to
howmuchthe largest allowable number of bytes to write, or -1 to write as many bytes as we can.
+
+
+
Returns
the number of bytes written, or -1 if an error occurred
+
See also
evbuffer_read()
+ +
+
+
+ + + + diff --git a/buffer_8h_source.html b/buffer_8h_source.html new file mode 100644 index 0000000..95762f8 --- /dev/null +++ b/buffer_8h_source.html @@ -0,0 +1,477 @@ + + + + + + + +libevent: event2/buffer.h Source File + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
buffer.h
+
+
+Go to the documentation of this file.
1 /*
+
2  * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson
+
3  *
+
4  * Redistribution and use in source and binary forms, with or without
+
5  * modification, are permitted provided that the following conditions
+
6  * are met:
+
7  * 1. Redistributions of source code must retain the above copyright
+
8  * notice, this list of conditions and the following disclaimer.
+
9  * 2. Redistributions in binary form must reproduce the above copyright
+
10  * notice, this list of conditions and the following disclaimer in the
+
11  * documentation and/or other materials provided with the distribution.
+
12  * 3. The name of the author may not be used to endorse or promote products
+
13  * derived from this software without specific prior written permission.
+
14  *
+
15  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+
16  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+
17  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+
18  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+
19  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+
20  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+
21  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+
22  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+
23  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+
24  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
25  */
+
26 #ifndef EVENT2_BUFFER_H_INCLUDED_
+
27 #define EVENT2_BUFFER_H_INCLUDED_
+
28 
+
75 #include <event2/visibility.h>
+
76 
+
77 #ifdef __cplusplus
+
78 extern "C" {
+
79 #endif
+
80 
+
81 #include <event2/event-config.h>
+
82 #include <stdarg.h>
+
83 #ifdef EVENT__HAVE_SYS_TYPES_H
+
84 #include <sys/types.h>
+
85 #endif
+
86 #ifdef EVENT__HAVE_SYS_UIO_H
+
87 #include <sys/uio.h>
+
88 #endif
+
89 #include <event2/util.h>
+
90 
+
97 struct evbuffer
+
98 #ifdef EVENT_IN_DOXYGEN_
+
99 {}
+
100 #endif
+
101 ;
+
102 
+
116 struct evbuffer_ptr {
+
117  ev_ssize_t pos;
+
118 
+
119  /* Do not alter or rely on the values of fields: they are for internal
+
120  * use */
+
121  struct {
+
122  void *chain;
+
123  size_t pos_in_chain;
+
124  } internal_;
+
125 };
+
126 
+
132 #ifdef EVENT__HAVE_SYS_UIO_H
+
133 #define evbuffer_iovec iovec
+
134 /* Internal use -- defined only if we are using the native struct iovec */
+
135 #define EVBUFFER_IOVEC_IS_NATIVE_
+
136 #else
+ +
139  void *iov_base;
+
141  size_t iov_len;
+
142 };
+
143 #endif
+
144 
+
151 EVENT2_EXPORT_SYMBOL
+
152 struct evbuffer *evbuffer_new(void);
+
158 EVENT2_EXPORT_SYMBOL
+
159 void evbuffer_free(struct evbuffer *buf);
+
160 
+
161 
+
174 EVENT2_EXPORT_SYMBOL
+
175 int evbuffer_set_max_read(struct evbuffer *buf, size_t max);
+
182 EVENT2_EXPORT_SYMBOL
+
183 size_t evbuffer_get_max_read(struct evbuffer *buf);
+
184 
+
197 EVENT2_EXPORT_SYMBOL
+
198 int evbuffer_enable_locking(struct evbuffer *buf, void *lock);
+
199 
+
204 EVENT2_EXPORT_SYMBOL
+
205 void evbuffer_lock(struct evbuffer *buf);
+
206 
+
211 EVENT2_EXPORT_SYMBOL
+
212 void evbuffer_unlock(struct evbuffer *buf);
+
213 
+
214 
+
230 #define EVBUFFER_FLAG_DRAINS_TO_FD 1
+
231 
+
238 EVENT2_EXPORT_SYMBOL
+
239 int evbuffer_set_flags(struct evbuffer *buf, ev_uint64_t flags);
+
246 EVENT2_EXPORT_SYMBOL
+
247 int evbuffer_clear_flags(struct evbuffer *buf, ev_uint64_t flags);
+
248 
+
255 EVENT2_EXPORT_SYMBOL
+
256 size_t evbuffer_get_length(const struct evbuffer *buf);
+
257 
+
270 EVENT2_EXPORT_SYMBOL
+
271 size_t evbuffer_get_contiguous_space(const struct evbuffer *buf);
+
272 
+
283 EVENT2_EXPORT_SYMBOL
+
284 int evbuffer_expand(struct evbuffer *buf, size_t datlen);
+
285 
+
319 EVENT2_EXPORT_SYMBOL
+
320 int
+
321 evbuffer_reserve_space(struct evbuffer *buf, ev_ssize_t size,
+
322  struct evbuffer_iovec *vec, int n_vec);
+
323 
+
345 EVENT2_EXPORT_SYMBOL
+
346 int evbuffer_commit_space(struct evbuffer *buf,
+
347  struct evbuffer_iovec *vec, int n_vecs);
+
348 
+
357 EVENT2_EXPORT_SYMBOL
+
358 int evbuffer_add(struct evbuffer *buf, const void *data, size_t datlen);
+
359 
+
360 
+
372 EVENT2_EXPORT_SYMBOL
+
373 int evbuffer_remove(struct evbuffer *buf, void *data, size_t datlen);
+
374 
+
386 EVENT2_EXPORT_SYMBOL
+
387 ev_ssize_t evbuffer_copyout(struct evbuffer *buf, void *data_out, size_t datlen);
+
388 
+
401 EVENT2_EXPORT_SYMBOL
+
402 ev_ssize_t evbuffer_copyout_from(struct evbuffer *buf, const struct evbuffer_ptr *pos, void *data_out, size_t datlen);
+
403 
+
417 EVENT2_EXPORT_SYMBOL
+
418 int evbuffer_remove_buffer(struct evbuffer *src, struct evbuffer *dst,
+
419  size_t datlen);
+
420 
+ + + + + + +
443 };
+
444 
+
459 EVENT2_EXPORT_SYMBOL
+
460 char *evbuffer_readln(struct evbuffer *buffer, size_t *n_read_out,
+
461  enum evbuffer_eol_style eol_style);
+
462 
+
475 EVENT2_EXPORT_SYMBOL
+
476 int evbuffer_add_buffer(struct evbuffer *outbuf, struct evbuffer *inbuf);
+
477 
+
491 EVENT2_EXPORT_SYMBOL
+
492 int evbuffer_add_buffer_reference(struct evbuffer *outbuf,
+
493  struct evbuffer *inbuf);
+
494 
+
505 typedef void (*evbuffer_ref_cleanup_cb)(const void *data,
+
506  size_t datalen, void *extra);
+
507 
+
523 EVENT2_EXPORT_SYMBOL
+
524 int evbuffer_add_reference(struct evbuffer *outbuf,
+
525  const void *data, size_t datlen,
+
526  evbuffer_ref_cleanup_cb cleanupfn, void *cleanupfn_arg);
+
527 
+
528 
+
545 EVENT2_EXPORT_SYMBOL
+
546 int evbuffer_add_reference_with_offset(struct evbuffer *outbuf, const void *data,
+
547  size_t offset, size_t datlen, evbuffer_ref_cleanup_cb cleanupfn,
+
548  void *cleanupfn_arg);
+
549 
+
574 EVENT2_EXPORT_SYMBOL
+
575 int evbuffer_add_file(struct evbuffer *outbuf, int fd, ev_off_t offset,
+
576  ev_off_t length);
+
577 
+
585 struct evbuffer_file_segment;
+
586 
+
592 #define EVBUF_FS_CLOSE_ON_FREE 0x01
+
593 
+
597 #define EVBUF_FS_DISABLE_MMAP 0x02
+
598 
+
607 #define EVBUF_FS_DISABLE_SENDFILE 0x04
+
608 
+
614 #define EVBUF_FS_DISABLE_LOCKING 0x08
+
615 
+ +
621  struct evbuffer_file_segment const* seg, int flags, void* arg);
+
622 
+
645 EVENT2_EXPORT_SYMBOL
+
646 struct evbuffer_file_segment *evbuffer_file_segment_new(
+
647  int fd, ev_off_t offset, ev_off_t length, unsigned flags);
+
648 
+
656 EVENT2_EXPORT_SYMBOL
+
657 void evbuffer_file_segment_free(struct evbuffer_file_segment *seg);
+
658 
+
666 EVENT2_EXPORT_SYMBOL
+
667 void evbuffer_file_segment_add_cleanup_cb(struct evbuffer_file_segment *seg,
+
668  evbuffer_file_segment_cleanup_cb cb, void* arg);
+
669 
+
692 EVENT2_EXPORT_SYMBOL
+
693 int evbuffer_add_file_segment(struct evbuffer *buf,
+
694  struct evbuffer_file_segment *seg, ev_off_t offset, ev_off_t length);
+
695 
+
708 EVENT2_EXPORT_SYMBOL
+
709 int evbuffer_add_printf(struct evbuffer *buf, const char *fmt, ...)
+
710 #ifdef __GNUC__
+
711  __attribute__((format(printf, 2, 3)))
+
712 #endif
+
713 ;
+
714 
+
723 EVENT2_EXPORT_SYMBOL
+
724 int evbuffer_add_vprintf(struct evbuffer *buf, const char *fmt, va_list ap)
+
725 #ifdef __GNUC__
+
726  __attribute__((format(printf, 2, 0)))
+
727 #endif
+
728 ;
+
729 
+
730 
+
738 EVENT2_EXPORT_SYMBOL
+
739 int evbuffer_drain(struct evbuffer *buf, size_t len);
+
740 
+
741 
+
752 EVENT2_EXPORT_SYMBOL
+
753 int evbuffer_write(struct evbuffer *buffer, evutil_socket_t fd);
+
754 
+
767 EVENT2_EXPORT_SYMBOL
+
768 int evbuffer_write_atmost(struct evbuffer *buffer, evutil_socket_t fd,
+
769  ev_ssize_t howmuch);
+
770 
+
781 EVENT2_EXPORT_SYMBOL
+
782 int evbuffer_read(struct evbuffer *buffer, evutil_socket_t fd, int howmuch);
+
783 
+
795 EVENT2_EXPORT_SYMBOL
+
796 struct evbuffer_ptr evbuffer_search(struct evbuffer *buffer, const char *what, size_t len, const struct evbuffer_ptr *start);
+
797 
+
812 EVENT2_EXPORT_SYMBOL
+
813 struct evbuffer_ptr evbuffer_search_range(struct evbuffer *buffer, const char *what, size_t len, const struct evbuffer_ptr *start, const struct evbuffer_ptr *end);
+
814 
+ + + +
825 };
+
826 
+
848 EVENT2_EXPORT_SYMBOL
+
849 int
+
850 evbuffer_ptr_set(struct evbuffer *buffer, struct evbuffer_ptr *ptr,
+
851  size_t position, enum evbuffer_ptr_how how);
+
852 
+
867 EVENT2_EXPORT_SYMBOL
+
868 struct evbuffer_ptr evbuffer_search_eol(struct evbuffer *buffer,
+
869  struct evbuffer_ptr *start, size_t *eol_len_out,
+
870  enum evbuffer_eol_style eol_style);
+
871 
+
900 EVENT2_EXPORT_SYMBOL
+
901 int evbuffer_peek(struct evbuffer *buffer, ev_ssize_t len,
+
902  struct evbuffer_ptr *start_at,
+
903  struct evbuffer_iovec *vec_out, int n_vec);
+
904 
+
905 
+ +
913  size_t orig_size;
+
915  size_t n_added;
+
917  size_t n_deleted;
+
918 };
+
919 
+
939 typedef void (*evbuffer_cb_func)(struct evbuffer *buffer, const struct evbuffer_cb_info *info, void *arg);
+
940 
+
941 struct evbuffer_cb_entry;
+
953 EVENT2_EXPORT_SYMBOL
+
954 struct evbuffer_cb_entry *evbuffer_add_cb(struct evbuffer *buffer, evbuffer_cb_func cb, void *cbarg);
+
955 
+
964 EVENT2_EXPORT_SYMBOL
+
965 int evbuffer_remove_cb_entry(struct evbuffer *buffer,
+
966  struct evbuffer_cb_entry *ent);
+
967 
+
974 EVENT2_EXPORT_SYMBOL
+
975 int evbuffer_remove_cb(struct evbuffer *buffer, evbuffer_cb_func cb, void *cbarg);
+
976 
+
982 #define EVBUFFER_CB_ENABLED 1
+
983 
+
991 EVENT2_EXPORT_SYMBOL
+
992 int evbuffer_cb_set_flags(struct evbuffer *buffer,
+
993  struct evbuffer_cb_entry *cb, ev_uint32_t flags);
+
994 
+
1002 EVENT2_EXPORT_SYMBOL
+
1003 int evbuffer_cb_clear_flags(struct evbuffer *buffer,
+
1004  struct evbuffer_cb_entry *cb, ev_uint32_t flags);
+
1005 
+
1006 #if 0
+
1007 
+
1016 EVENT2_EXPORT_SYMBOL
+
1017 void evbuffer_cb_suspend(struct evbuffer *buffer, struct evbuffer_cb_entry *cb);
+
1026 EVENT2_EXPORT_SYMBOL
+
1027 void evbuffer_cb_unsuspend(struct evbuffer *buffer, struct evbuffer_cb_entry *cb);
+
1028 #endif
+
1029 
+
1040 EVENT2_EXPORT_SYMBOL
+
1041 unsigned char *evbuffer_pullup(struct evbuffer *buf, ev_ssize_t size);
+
1042 
+
1052 EVENT2_EXPORT_SYMBOL
+
1053 int evbuffer_prepend(struct evbuffer *buf, const void *data, size_t size);
+
1054 
+
1063 EVENT2_EXPORT_SYMBOL
+
1064 int evbuffer_prepend_buffer(struct evbuffer *dst, struct evbuffer* src);
+
1065 
+
1080 EVENT2_EXPORT_SYMBOL
+
1081 int evbuffer_freeze(struct evbuffer *buf, int at_front);
+
1090 EVENT2_EXPORT_SYMBOL
+
1091 int evbuffer_unfreeze(struct evbuffer *buf, int at_front);
+
1092 
+
1093 struct event_base;
+
1101 EVENT2_EXPORT_SYMBOL
+
1102 int evbuffer_defer_callbacks(struct evbuffer *buffer, struct event_base *base);
+
1103 
+
1117 EVENT2_EXPORT_SYMBOL
+
1118 size_t evbuffer_add_iovec(struct evbuffer * buffer, struct evbuffer_iovec * vec, int n_vec);
+
1119 
+
1120 #ifdef __cplusplus
+
1121 }
+
1122 #endif
+
1123 
+
1124 #endif /* EVENT2_BUFFER_H_INCLUDED_ */
+
+
evbuffer_enable_locking
EVENT2_EXPORT_SYMBOL int evbuffer_enable_locking(struct evbuffer *buf, void *lock)
Enable locking on an evbuffer so that it can safely be used by multiple threads at the same time.
+
evbuffer_get_length
EVENT2_EXPORT_SYMBOL size_t evbuffer_get_length(const struct evbuffer *buf)
Returns the total number of bytes stored in the evbuffer.
+
EVBUFFER_PTR_ADD
@ EVBUFFER_PTR_ADD
Advances the pointer by adding to the current position.
Definition: buffer.h:824
+
evbuffer_remove
EVENT2_EXPORT_SYMBOL int evbuffer_remove(struct evbuffer *buf, void *data, size_t datlen)
Read data from an evbuffer and drain the bytes read.
+
evbuffer_add_file
EVENT2_EXPORT_SYMBOL int evbuffer_add_file(struct evbuffer *outbuf, int fd, ev_off_t offset, ev_off_t length)
Copy data from a file into the evbuffer for writing to a socket.
+
evbuffer_add_reference_with_offset
EVENT2_EXPORT_SYMBOL int evbuffer_add_reference_with_offset(struct evbuffer *outbuf, const void *data, size_t offset, size_t datlen, evbuffer_ref_cleanup_cb cleanupfn, void *cleanupfn_arg)
Reference memory into an evbuffer without copying.
+
evbuffer_get_contiguous_space
EVENT2_EXPORT_SYMBOL size_t evbuffer_get_contiguous_space(const struct evbuffer *buf)
Returns the number of contiguous available bytes in the first buffer chain.
+
evbuffer_cb_info
Structure passed to an evbuffer_cb_func evbuffer callback.
Definition: buffer.h:910
+
evbuffer_add
EVENT2_EXPORT_SYMBOL int evbuffer_add(struct evbuffer *buf, const void *data, size_t datlen)
Append data to the end of an evbuffer.
+
EVBUFFER_EOL_CRLF
@ EVBUFFER_EOL_CRLF
An EOL is an LF, optionally preceded by a CR.
Definition: buffer.h:436
+
evbuffer_iovec::iov_base
void * iov_base
The start of the extent of memory.
Definition: buffer.h:139
+
evbuffer_add_iovec
EVENT2_EXPORT_SYMBOL size_t evbuffer_add_iovec(struct evbuffer *buffer, struct evbuffer_iovec *vec, int n_vec)
Append data from 1 or more iovec's to an evbuffer.
+
evbuffer_unfreeze
EVENT2_EXPORT_SYMBOL int evbuffer_unfreeze(struct evbuffer *buf, int at_front)
Re-enable calls that modify an evbuffer.
+
evbuffer_set_flags
EVENT2_EXPORT_SYMBOL int evbuffer_set_flags(struct evbuffer *buf, ev_uint64_t flags)
Change the flags that are set for an evbuffer by adding more.
+
evbuffer_peek
EVENT2_EXPORT_SYMBOL int evbuffer_peek(struct evbuffer *buffer, ev_ssize_t len, struct evbuffer_ptr *start_at, struct evbuffer_iovec *vec_out, int n_vec)
Function to peek at data inside an evbuffer without removing it or copying it out.
+
evbuffer_set_max_read
EVENT2_EXPORT_SYMBOL int evbuffer_set_max_read(struct evbuffer *buf, size_t max)
Set maximum read buffer size.
+
evbuffer_eol_style
evbuffer_eol_style
Used to tell evbuffer_readln what kind of line-ending to look for.
Definition: buffer.h:423
+
EVBUFFER_EOL_NUL
@ EVBUFFER_EOL_NUL
An EOL is a NUL character (that is, a single byte with value 0)
Definition: buffer.h:442
+
event_base
Structure to hold information and state for a Libevent dispatch loop.
Definition: event.h:219
+
evbuffer_lock
EVENT2_EXPORT_SYMBOL void evbuffer_lock(struct evbuffer *buf)
Acquire the lock on an evbuffer.
+
evbuffer_add_vprintf
EVENT2_EXPORT_SYMBOL int evbuffer_add_vprintf(struct evbuffer *buf, const char *fmt, va_list ap)
Append a va_list formatted string to the end of an evbuffer.
+
evbuffer_pullup
EVENT2_EXPORT_SYMBOL unsigned char * evbuffer_pullup(struct evbuffer *buf, ev_ssize_t size)
Makes the data at the beginning of an evbuffer contiguous.
+
EVBUFFER_EOL_CRLF_STRICT
@ EVBUFFER_EOL_CRLF_STRICT
An EOL is a CR followed by an LF.
Definition: buffer.h:438
+
evbuffer_search
EVENT2_EXPORT_SYMBOL struct evbuffer_ptr evbuffer_search(struct evbuffer *buffer, const char *what, size_t len, const struct evbuffer_ptr *start)
Search for a string within an evbuffer.
+
evbuffer_defer_callbacks
EVENT2_EXPORT_SYMBOL int evbuffer_defer_callbacks(struct evbuffer *buffer, struct event_base *base)
Force all the callbacks on an evbuffer to be run, not immediately after the evbuffer is altered,...
+
evbuffer_prepend
EVENT2_EXPORT_SYMBOL int evbuffer_prepend(struct evbuffer *buf, const void *data, size_t size)
Prepends data to the beginning of the evbuffer.
+
evbuffer_read
EVENT2_EXPORT_SYMBOL int evbuffer_read(struct evbuffer *buffer, evutil_socket_t fd, int howmuch)
Read from a file descriptor and store the result in an evbuffer.
+
evbuffer_write_atmost
EVENT2_EXPORT_SYMBOL int evbuffer_write_atmost(struct evbuffer *buffer, evutil_socket_t fd, ev_ssize_t howmuch)
Write some of the contents of an evbuffer to a file descriptor.
+
evbuffer_ref_cleanup_cb
void(* evbuffer_ref_cleanup_cb)(const void *data, size_t datalen, void *extra)
A cleanup function for a piece of memory added to an evbuffer by reference.
Definition: buffer.h:505
+
evbuffer_copyout_from
EVENT2_EXPORT_SYMBOL ev_ssize_t evbuffer_copyout_from(struct evbuffer *buf, const struct evbuffer_ptr *pos, void *data_out, size_t datlen)
Read data from the middle of an evbuffer, and leave the buffer unchanged.
+
evbuffer_iovec
Describes a single extent of memory inside an evbuffer.
Definition: buffer.h:137
+
evbuffer_drain
EVENT2_EXPORT_SYMBOL int evbuffer_drain(struct evbuffer *buf, size_t len)
Remove a specified number of bytes data from the beginning of an evbuffer.
+
evbuffer_ptr
Pointer to a position within an evbuffer.
Definition: buffer.h:116
+
evbuffer_prepend_buffer
EVENT2_EXPORT_SYMBOL int evbuffer_prepend_buffer(struct evbuffer *dst, struct evbuffer *src)
Prepends all data from the src evbuffer to the beginning of the dst evbuffer.
+
evbuffer_remove_cb_entry
EVENT2_EXPORT_SYMBOL int evbuffer_remove_cb_entry(struct evbuffer *buffer, struct evbuffer_cb_entry *ent)
Remove a callback from an evbuffer, given a handle returned from evbuffer_add_cb.
+
evbuffer_ptr_set
EVENT2_EXPORT_SYMBOL int evbuffer_ptr_set(struct evbuffer *buffer, struct evbuffer_ptr *ptr, size_t position, enum evbuffer_ptr_how how)
Sets the search pointer in the buffer to position.
+
evbuffer
An evbuffer is an opaque data type for efficiently buffering data to be sent or received on the netwo...
Definition: buffer.h:97
+
evbuffer_cb_func
void(* evbuffer_cb_func)(struct evbuffer *buffer, const struct evbuffer_cb_info *info, void *arg)
Type definition for a callback that is invoked whenever data is added or removed from an evbuffer.
Definition: buffer.h:939
+
evbuffer_freeze
EVENT2_EXPORT_SYMBOL int evbuffer_freeze(struct evbuffer *buf, int at_front)
Prevent calls that modify an evbuffer from succeeding.
+
evbuffer_search_eol
EVENT2_EXPORT_SYMBOL struct evbuffer_ptr evbuffer_search_eol(struct evbuffer *buffer, struct evbuffer_ptr *start, size_t *eol_len_out, enum evbuffer_eol_style eol_style)
Search for an end-of-line string within an evbuffer.
+
evbuffer_add_cb
EVENT2_EXPORT_SYMBOL struct evbuffer_cb_entry * evbuffer_add_cb(struct evbuffer *buffer, evbuffer_cb_func cb, void *cbarg)
Add a new callback to an evbuffer.
+
evbuffer_file_segment_new
EVENT2_EXPORT_SYMBOL struct evbuffer_file_segment * evbuffer_file_segment_new(int fd, ev_off_t offset, ev_off_t length, unsigned flags)
Create and return a new evbuffer_file_segment for reading data from a file and sending it out via an ...
+
evbuffer_readln
EVENT2_EXPORT_SYMBOL char * evbuffer_readln(struct evbuffer *buffer, size_t *n_read_out, enum evbuffer_eol_style eol_style)
Read a single line from an evbuffer.
+
evbuffer_unlock
EVENT2_EXPORT_SYMBOL void evbuffer_unlock(struct evbuffer *buf)
Release the lock on an evbuffer.
+
evbuffer_cb_set_flags
EVENT2_EXPORT_SYMBOL int evbuffer_cb_set_flags(struct evbuffer *buffer, struct evbuffer_cb_entry *cb, ev_uint32_t flags)
Change the flags that are set for a callback on a buffer by adding more.
+
evbuffer_cb_info::n_deleted
size_t n_deleted
The number of bytes removed since callbacks were last invoked.
Definition: buffer.h:917
+
evbuffer_clear_flags
EVENT2_EXPORT_SYMBOL int evbuffer_clear_flags(struct evbuffer *buf, ev_uint64_t flags)
Change the flags that are set for an evbuffer by removing some.
+
evbuffer_ptr_how
evbuffer_ptr_how
Defines how to adjust an evbuffer_ptr by evbuffer_ptr_set()
Definition: buffer.h:819
+
evbuffer_cb_info::n_added
size_t n_added
The number of bytes added since callbacks were last invoked.
Definition: buffer.h:915
+
evbuffer_add_reference
EVENT2_EXPORT_SYMBOL int evbuffer_add_reference(struct evbuffer *outbuf, const void *data, size_t datlen, evbuffer_ref_cleanup_cb cleanupfn, void *cleanupfn_arg)
Reference memory into an evbuffer without copying.
+
evbuffer_add_buffer
EVENT2_EXPORT_SYMBOL int evbuffer_add_buffer(struct evbuffer *outbuf, struct evbuffer *inbuf)
Move all data from one evbuffer into another evbuffer.
+
evbuffer_add_file_segment
EVENT2_EXPORT_SYMBOL int evbuffer_add_file_segment(struct evbuffer *buf, struct evbuffer_file_segment *seg, ev_off_t offset, ev_off_t length)
Insert some or all of an evbuffer_file_segment at the end of an evbuffer.
+
evbuffer_add_printf
EVENT2_EXPORT_SYMBOL int evbuffer_add_printf(struct evbuffer *buf, const char *fmt,...)
Append a formatted string to the end of an evbuffer.
+
EVBUFFER_EOL_LF
@ EVBUFFER_EOL_LF
An EOL is a LF.
Definition: buffer.h:440
+
evbuffer_commit_space
EVENT2_EXPORT_SYMBOL int evbuffer_commit_space(struct evbuffer *buf, struct evbuffer_iovec *vec, int n_vecs)
Commits previously reserved space.
+
evbuffer_write
EVENT2_EXPORT_SYMBOL int evbuffer_write(struct evbuffer *buffer, evutil_socket_t fd)
Write the contents of an evbuffer to a file descriptor.
+
evbuffer_remove_buffer
EVENT2_EXPORT_SYMBOL int evbuffer_remove_buffer(struct evbuffer *src, struct evbuffer *dst, size_t datlen)
Read data from an evbuffer into another evbuffer, draining the bytes from the source buffer.
+
evbuffer_search_range
EVENT2_EXPORT_SYMBOL struct evbuffer_ptr evbuffer_search_range(struct evbuffer *buffer, const char *what, size_t len, const struct evbuffer_ptr *start, const struct evbuffer_ptr *end)
Search for a string within part of an evbuffer.
+
evbuffer_free
EVENT2_EXPORT_SYMBOL void evbuffer_free(struct evbuffer *buf)
Deallocate storage for an evbuffer.
+
evbuffer_file_segment_cleanup_cb
void(* evbuffer_file_segment_cleanup_cb)(struct evbuffer_file_segment const *seg, int flags, void *arg)
A cleanup function for a evbuffer_file_segment added to an evbuffer for reference.
Definition: buffer.h:620
+
EVBUFFER_EOL_ANY
@ EVBUFFER_EOL_ANY
Any sequence of CR and LF characters is acceptable as an EOL.
Definition: buffer.h:433
+
evbuffer_cb_info::orig_size
size_t orig_size
The number of bytes in this evbuffer when callbacks were last invoked.
Definition: buffer.h:913
+
evbuffer_reserve_space
EVENT2_EXPORT_SYMBOL int evbuffer_reserve_space(struct evbuffer *buf, ev_ssize_t size, struct evbuffer_iovec *vec, int n_vec)
Reserves space in the last chain or chains of an evbuffer.
+
EVBUFFER_PTR_SET
@ EVBUFFER_PTR_SET
Sets the pointer to the position; can be called on with an uninitialized evbuffer_ptr.
Definition: buffer.h:822
+
evbuffer_iovec::iov_len
size_t iov_len
The length of the extent of memory.
Definition: buffer.h:141
+
evbuffer_add_buffer_reference
EVENT2_EXPORT_SYMBOL int evbuffer_add_buffer_reference(struct evbuffer *outbuf, struct evbuffer *inbuf)
Copy data from one evbuffer into another evbuffer.
+
evbuffer_remove_cb
EVENT2_EXPORT_SYMBOL int evbuffer_remove_cb(struct evbuffer *buffer, evbuffer_cb_func cb, void *cbarg)
Remove a callback from an evbuffer, given the function and argument used to add it.
+
evbuffer_new
EVENT2_EXPORT_SYMBOL struct evbuffer * evbuffer_new(void)
Allocate storage for a new evbuffer.
+
evbuffer_get_max_read
EVENT2_EXPORT_SYMBOL size_t evbuffer_get_max_read(struct evbuffer *buf)
Get maximum read buffer size.
+
evbuffer_file_segment_free
EVENT2_EXPORT_SYMBOL void evbuffer_file_segment_free(struct evbuffer_file_segment *seg)
Free an evbuffer_file_segment.
+
util.h
Common convenience functions for cross-platform portability and related socket manipulations.
+
evbuffer_copyout
EVENT2_EXPORT_SYMBOL ev_ssize_t evbuffer_copyout(struct evbuffer *buf, void *data_out, size_t datlen)
Read data from an evbuffer, and leave the buffer unchanged.
+
evbuffer_file_segment_add_cleanup_cb
EVENT2_EXPORT_SYMBOL void evbuffer_file_segment_add_cleanup_cb(struct evbuffer_file_segment *seg, evbuffer_file_segment_cleanup_cb cb, void *arg)
Add cleanup callback and argument for the callback to an evbuffer_file_segment.
+
evbuffer_expand
EVENT2_EXPORT_SYMBOL int evbuffer_expand(struct evbuffer *buf, size_t datlen)
Expands the available space in an evbuffer.
+
evbuffer_cb_clear_flags
EVENT2_EXPORT_SYMBOL int evbuffer_cb_clear_flags(struct evbuffer *buffer, struct evbuffer_cb_entry *cb, ev_uint32_t flags)
Change the flags that are set for a callback on a buffer by removing some.
+
evutil_socket_t
#define evutil_socket_t
A type wide enough to hold the output of "socket()" or "accept()".
Definition: util.h:325
+ + + + diff --git a/buffer__compat_8h.html b/buffer__compat_8h.html new file mode 100644 index 0000000..56a23f6 --- /dev/null +++ b/buffer__compat_8h.html @@ -0,0 +1,274 @@ + + + + + + + +libevent: event2/buffer_compat.h File Reference + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+Macros | +Typedefs | +Functions
+
+
buffer_compat.h File Reference
+
+
+ +

Obsolete and deprecated versions of the functions in buffer.h: provided only for backward compatibility. +More...

+
#include <event2/visibility.h>
+
+

Go to the source code of this file.

+ + + + + + + + +

+Macros

+#define EVBUFFER_DATA(x)   evbuffer_pullup((x), -1)
 deprecated in favor of calling the functions directly
 
+#define EVBUFFER_LENGTH(x)   evbuffer_get_length(x)
 deprecated in favor of calling the functions directly
 
+ + + + +

+Typedefs

typedef void(* evbuffer_cb) (struct evbuffer *buffer, size_t old_len, size_t new_len, void *arg)
 Type definition for a callback that is invoked whenever data is added or removed from an evbuffer. More...
 
+ + + + + + + + + + +

+Functions

EVENT2_EXPORT_SYMBOL unsigned char * evbuffer_find (struct evbuffer *buffer, const unsigned char *what, size_t len)
 Find a string within an evbuffer. More...
 
EVENT2_EXPORT_SYMBOL char * evbuffer_readline (struct evbuffer *buffer)
 Obsolete alias for evbuffer_readln(buffer, NULL, EVBUFFER_EOL_ANY). More...
 
EVENT2_EXPORT_SYMBOL int evbuffer_setcb (struct evbuffer *buffer, evbuffer_cb cb, void *cbarg)
 Replace all callbacks on an evbuffer with a single new callback, or remove them. More...
 
+

Detailed Description

+

Obsolete and deprecated versions of the functions in buffer.h: provided only for backward compatibility.

+

Typedef Documentation

+ +

◆ evbuffer_cb

+ +
+
+ + + + +
typedef void(* evbuffer_cb) (struct evbuffer *buffer, size_t old_len, size_t new_len, void *arg)
+
+ +

Type definition for a callback that is invoked whenever data is added or removed from an evbuffer.

+

An evbuffer may have one or more callbacks set at a time. The order in which they are executed is undefined.

+

A callback function may add more callbacks, or remove itself from the list of callbacks, or add or remove data from the buffer. It may not remove another callback from the list.

+

If a callback adds or removes data from the buffer or from another buffer, this can cause a recursive invocation of your callback or other callbacks. If you ask for an infinite loop, you might just get one: watch out!

+
Parameters
+ + + + + +
bufferthe buffer whose size has changed
old_lenthe previous length of the buffer
new_lenthe current length of the buffer
arga pointer to user data
+
+
+ +
+
+

Function Documentation

+ +

◆ evbuffer_find()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL unsigned char* evbuffer_find (struct evbufferbuffer,
const unsigned char * what,
size_t len 
)
+
+ +

Find a string within an evbuffer.

+
Parameters
+ + + + +
bufferthe evbuffer to be searched
whatthe string to be searched for
lenthe length of the search string
+
+
+
Returns
a pointer to the beginning of the search string, or NULL if the search failed.
+ +
+
+ +

◆ evbuffer_readline()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL char* evbuffer_readline (struct evbufferbuffer)
+
+ +

Obsolete alias for evbuffer_readln(buffer, NULL, EVBUFFER_EOL_ANY).

+
Deprecated:
This function is deprecated because its behavior is not correct for almost any protocol, and also because it's wholly subsumed by evbuffer_readln().
+
Parameters
+ + +
bufferthe evbuffer to read from
+
+
+
Returns
pointer to a single line, or NULL if an error occurred
+ +
+
+ +

◆ evbuffer_setcb()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evbuffer_setcb (struct evbufferbuffer,
evbuffer_cb cb,
void * cbarg 
)
+
+ +

Replace all callbacks on an evbuffer with a single new callback, or remove them.

+

Subsequent calls to evbuffer_setcb() replace callbacks set by previous calls. Setting the callback to NULL removes any previously set callback.

+
Deprecated:
This function is deprecated because it clears all previous callbacks set on the evbuffer, which can cause confusing behavior if multiple parts of the code all want to add their own callbacks on a buffer. Instead, use evbuffer_add(), evbuffer_del(), and evbuffer_setflags() to manage your own evbuffer callbacks without interfering with callbacks set by others.
+
Parameters
+ + + + +
bufferthe evbuffer to be monitored
cbthe callback function to invoke when the evbuffer is modified, or NULL to remove all callbacks.
cbargan argument to be provided to the callback function
+
+
+
Returns
0 if successful, or -1 on error
+ +
+
+
+ + + + diff --git a/buffer__compat_8h_source.html b/buffer__compat_8h_source.html new file mode 100644 index 0000000..240e0ac --- /dev/null +++ b/buffer__compat_8h_source.html @@ -0,0 +1,136 @@ + + + + + + + +libevent: event2/buffer_compat.h Source File + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
buffer_compat.h
+
+
+Go to the documentation of this file.
1 /*
+
2  * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson
+
3  *
+
4  * Redistribution and use in source and binary forms, with or without
+
5  * modification, are permitted provided that the following conditions
+
6  * are met:
+
7  * 1. Redistributions of source code must retain the above copyright
+
8  * notice, this list of conditions and the following disclaimer.
+
9  * 2. Redistributions in binary form must reproduce the above copyright
+
10  * notice, this list of conditions and the following disclaimer in the
+
11  * documentation and/or other materials provided with the distribution.
+
12  * 3. The name of the author may not be used to endorse or promote products
+
13  * derived from this software without specific prior written permission.
+
14  *
+
15  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+
16  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+
17  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+
18  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+
19  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+
20  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+
21  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+
22  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+
23  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+
24  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
25  */
+
26 
+
27 #ifndef EVENT2_BUFFER_COMPAT_H_INCLUDED_
+
28 #define EVENT2_BUFFER_COMPAT_H_INCLUDED_
+
29 
+
30 #include <event2/visibility.h>
+
31 
+
50 EVENT2_EXPORT_SYMBOL
+
51 char *evbuffer_readline(struct evbuffer *buffer);
+
52 
+
73 typedef void (*evbuffer_cb)(struct evbuffer *buffer, size_t old_len, size_t new_len, void *arg);
+
74 
+
95 EVENT2_EXPORT_SYMBOL
+
96 int evbuffer_setcb(struct evbuffer *buffer, evbuffer_cb cb, void *cbarg);
+
97 
+
98 
+
107 EVENT2_EXPORT_SYMBOL
+
108 unsigned char *evbuffer_find(struct evbuffer *buffer, const unsigned char *what, size_t len);
+
109 
+
111 #define EVBUFFER_LENGTH(x) evbuffer_get_length(x)
+
112 
+
113 #define EVBUFFER_DATA(x) evbuffer_pullup((x), -1)
+
114 
+
115 #endif
+
116 
+
+
evbuffer_find
EVENT2_EXPORT_SYMBOL unsigned char * evbuffer_find(struct evbuffer *buffer, const unsigned char *what, size_t len)
Find a string within an evbuffer.
+
evbuffer_cb
void(* evbuffer_cb)(struct evbuffer *buffer, size_t old_len, size_t new_len, void *arg)
Type definition for a callback that is invoked whenever data is added or removed from an evbuffer.
Definition: buffer_compat.h:73
+
evbuffer_setcb
EVENT2_EXPORT_SYMBOL int evbuffer_setcb(struct evbuffer *buffer, evbuffer_cb cb, void *cbarg)
Replace all callbacks on an evbuffer with a single new callback, or remove them.
+
evbuffer_readline
EVENT2_EXPORT_SYMBOL char * evbuffer_readline(struct evbuffer *buffer)
Obsolete alias for evbuffer_readln(buffer, NULL, EVBUFFER_EOL_ANY).
+
evbuffer
An evbuffer is an opaque data type for efficiently buffering data to be sent or received on the netwo...
Definition: buffer.h:97
+ + + + diff --git a/bufferevent_8h.html b/bufferevent_8h.html new file mode 100644 index 0000000..57396c9 --- /dev/null +++ b/bufferevent_8h.html @@ -0,0 +1,2431 @@ + + + + + + + +libevent: event2/bufferevent.h File Reference + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+Data Structures | +Macros | +Typedefs | +Enumerations | +Functions
+
+
bufferevent.h File Reference
+
+
+ +

Functions for buffering data for network sending or receiving. +More...

+
#include <event2/visibility.h>
+#include <event2/event-config.h>
+#include <event2/util.h>
+
+

Go to the source code of this file.

+ + + + + +

+Data Structures

struct  bufferevent
 An opaque type for handling buffered IO. More...
 
+ + + + + + + + + + + + + + + + + + + + + + + + +

+Macros

+#define EV_RATE_LIMIT_MAX   EV_SSIZE_MAX
 Maximum configurable rate- or burst-limit.
 
Bufferevent event codes

These flags are passed as arguments to a bufferevent's event callback.

+
+#define BEV_EVENT_CONNECTED   0x80
 connect operation finished.
 
+#define BEV_EVENT_EOF   0x10
 eof file reached
 
+#define BEV_EVENT_ERROR   0x20
 unrecoverable error encountered
 
+#define BEV_EVENT_READING   0x01
 error encountered while reading
 
+#define BEV_EVENT_TIMEOUT   0x40
 user-specified timeout reached
 
+#define BEV_EVENT_WRITING   0x02
 error encountered while writing
 
+ + + + + + + +

+Typedefs

typedef void(* bufferevent_data_cb) (struct bufferevent *bev, void *ctx)
 A read or write callback for a bufferevent. More...
 
typedef void(* bufferevent_event_cb) (struct bufferevent *bev, short what, void *ctx)
 An event/error callback for a bufferevent. More...
 
+ + + + + + + + + + +

+Enumerations

enum  bufferevent_flush_mode { BEV_NORMAL = 0, +BEV_FLUSH = 1, +BEV_FINISHED = 2 + }
 Flags that can be passed into filters to let them know how to deal with the incoming data. More...
 
enum  bufferevent_options { BEV_OPT_CLOSE_ON_FREE = (1<<0), +BEV_OPT_THREADSAFE = (1<<1), +BEV_OPT_DEFER_CALLBACKS = (1<<2), +BEV_OPT_UNLOCK_CALLBACKS = (1<<3) + }
 Options that can be specified when creating a bufferevent. More...
 
enum  bufferevent_trigger_options { BEV_TRIG_IGNORE_WATERMARKS = (1<<16), +BEV_TRIG_DEFER_CALLBACKS = BEV_OPT_DEFER_CALLBACKS + }
 Flags for bufferevent_trigger(_event) that modify when and how to trigger the callback. More...
 
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+Functions

EVENT2_EXPORT_SYMBOL int bufferevent_add_to_rate_limit_group (struct bufferevent *bev, struct bufferevent_rate_limit_group *g)
 Add 'bev' to the list of bufferevents whose aggregate reading and writing is restricted by 'g'. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_base_set (struct event_base *base, struct bufferevent *bufev)
 Assign a bufferevent to a specific event_base. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_decref (struct bufferevent *bufev)
 Public interface to manually decrement the reference count of a bufferevent. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_disable (struct bufferevent *bufev, short event)
 Disable a bufferevent. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_enable (struct bufferevent *bufev, short event)
 Enable a bufferevent. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_flush (struct bufferevent *bufev, short iotype, enum bufferevent_flush_mode mode)
 Triggers the bufferevent to produce more data if possible. More...
 
EVENT2_EXPORT_SYMBOL void bufferevent_free (struct bufferevent *bufev)
 Deallocate the storage associated with a bufferevent structure. More...
 
+EVENT2_EXPORT_SYMBOL struct event_basebufferevent_get_base (struct bufferevent *bev)
 Return the event_base used by a bufferevent.
 
EVENT2_EXPORT_SYMBOL short bufferevent_get_enabled (struct bufferevent *bufev)
 Return the events that are enabled on a given bufferevent. More...
 
EVENT2_EXPORT_SYMBOL struct evbufferbufferevent_get_input (struct bufferevent *bufev)
 Returns the input buffer. More...
 
+EVENT2_EXPORT_SYMBOL ev_ssize_t bufferevent_get_max_single_read (struct bufferevent *bev)
 Get the current size limit for single read operation.
 
+EVENT2_EXPORT_SYMBOL ev_ssize_t bufferevent_get_max_single_write (struct bufferevent *bev)
 Get the current size limit for single write operation.
 
EVENT2_EXPORT_SYMBOL struct evbufferbufferevent_get_output (struct bufferevent *bufev)
 Returns the output buffer. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_get_priority (const struct bufferevent *bufev)
 Return the priority of a bufferevent. More...
 
+EVENT2_EXPORT_SYMBOL struct buffereventbufferevent_get_underlying (struct bufferevent *bufev)
 Returns the underlying bufferevent associated with a bufferevent (if the bufferevent is a wrapper), or NULL if there is no underlying bufferevent.
 
EVENT2_EXPORT_SYMBOL void bufferevent_getcb (struct bufferevent *bufev, bufferevent_data_cb *readcb_ptr, bufferevent_data_cb *writecb_ptr, bufferevent_event_cb *eventcb_ptr, void **cbarg_ptr)
 Retrieves the callbacks for a bufferevent. More...
 
EVENT2_EXPORT_SYMBOL evutil_socket_t bufferevent_getfd (struct bufferevent *bufev)
 Returns the file descriptor associated with a bufferevent, or -1 if no file descriptor is associated with the bufferevent. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_getwatermark (struct bufferevent *bufev, short events, size_t *lowmark, size_t *highmark)
 Retrieves the watermarks for read or write events. More...
 
EVENT2_EXPORT_SYMBOL void bufferevent_incref (struct bufferevent *bufev)
 Public interface to manually increase the reference count of a bufferevent this is useful in situations where a user may reference the bufferevent somewhere else (unknown to libevent) More...
 
EVENT2_EXPORT_SYMBOL void bufferevent_lock (struct bufferevent *bufev)
 Acquire the lock on a bufferevent. More...
 
EVENT2_EXPORT_SYMBOL struct buffereventbufferevent_pair_get_partner (struct bufferevent *bev)
 Given one bufferevent returned by bufferevent_pair_new(), returns the other one if it still exists. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_pair_new (struct event_base *base, int options, struct bufferevent *pair[2])
 Allocate a pair of linked bufferevents. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_priority_set (struct bufferevent *bufev, int pri)
 Assign a priority to a bufferevent. More...
 
EVENT2_EXPORT_SYMBOL void bufferevent_rate_limit_group_free (struct bufferevent_rate_limit_group *)
 Free a rate-limiting group. More...
 
EVENT2_EXPORT_SYMBOL struct bufferevent_rate_limit_group * bufferevent_rate_limit_group_new (struct event_base *base, const struct ev_token_bucket_cfg *cfg)
 Create a new rate-limit group for bufferevents. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_rate_limit_group_set_cfg (struct bufferevent_rate_limit_group *, const struct ev_token_bucket_cfg *)
 Change the rate-limiting settings for a given rate-limiting group. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_rate_limit_group_set_min_share (struct bufferevent_rate_limit_group *, size_t)
 Change the smallest quantum we're willing to allocate to any single bufferevent in a group for reading or writing at a time. More...
 
EVENT2_EXPORT_SYMBOL size_t bufferevent_read (struct bufferevent *bufev, void *data, size_t size)
 Read data from a bufferevent buffer. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_read_buffer (struct bufferevent *bufev, struct evbuffer *buf)
 Read data from a bufferevent buffer into an evbuffer. More...
 
+EVENT2_EXPORT_SYMBOL int bufferevent_remove_from_rate_limit_group (struct bufferevent *bev)
 Remove 'bev' from its current rate-limit group (if any).
 
EVENT2_EXPORT_SYMBOL int bufferevent_replacefd (struct bufferevent *bufev, evutil_socket_t fd)
 Replaces the file descriptor on which the bufferevent operates. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_set_max_single_read (struct bufferevent *bev, size_t size)
 Set the size limit for single read operation. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_set_max_single_write (struct bufferevent *bev, size_t size)
 Set the size limit for single write operation. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_set_rate_limit (struct bufferevent *bev, struct ev_token_bucket_cfg *cfg)
 Set the rate-limit of a the bufferevent 'bev' to the one specified in 'cfg'. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_set_timeouts (struct bufferevent *bufev, const struct timeval *timeout_read, const struct timeval *timeout_write)
 Set the read and write timeout for a bufferevent. More...
 
EVENT2_EXPORT_SYMBOL void bufferevent_setcb (struct bufferevent *bufev, bufferevent_data_cb readcb, bufferevent_data_cb writecb, bufferevent_event_cb eventcb, void *cbarg)
 Changes the callbacks for a bufferevent. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_setfd (struct bufferevent *bufev, evutil_socket_t fd)
 Changes the file descriptor on which the bufferevent operates. More...
 
EVENT2_EXPORT_SYMBOL void bufferevent_setwatermark (struct bufferevent *bufev, short events, size_t lowmark, size_t highmark)
 Sets the watermarks for read and write events. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_socket_connect (struct bufferevent *bufev, const struct sockaddr *addr, int socklen)
 Launch a connect() attempt with a socket-based bufferevent. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_socket_connect_hostname (struct bufferevent *bufev, struct evdns_base *evdns_base, int family, const char *hostname, int port)
 Resolve the hostname 'hostname' and connect to it as with bufferevent_socket_connect(). More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_socket_connect_hostname_hints (struct bufferevent *bufev, struct evdns_base *evdns_base, const struct evutil_addrinfo *hints_in, const char *hostname, int port)
 Resolve the hostname 'hostname' and connect to it as with bufferevent_socket_connect(). More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_socket_get_dns_error (struct bufferevent *bev)
 Return the error code for the last failed DNS lookup attempt made by bufferevent_socket_connect_hostname(). More...
 
EVENT2_EXPORT_SYMBOL struct buffereventbufferevent_socket_new (struct event_base *base, evutil_socket_t fd, int options)
 Create a new socket bufferevent over an existing socket. More...
 
EVENT2_EXPORT_SYMBOL void bufferevent_trigger (struct bufferevent *bufev, short iotype, int options)
 Triggers bufferevent data callbacks. More...
 
EVENT2_EXPORT_SYMBOL void bufferevent_trigger_event (struct bufferevent *bufev, short what, int options)
 Triggers the bufferevent event callback. More...
 
EVENT2_EXPORT_SYMBOL void bufferevent_unlock (struct bufferevent *bufev)
 Release the lock on a bufferevent. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_write (struct bufferevent *bufev, const void *data, size_t size)
 Write data to a bufferevent buffer. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_write_buffer (struct bufferevent *bufev, struct evbuffer *buf)
 Write data from an evbuffer to a bufferevent buffer. More...
 
EVENT2_EXPORT_SYMBOL void ev_token_bucket_cfg_free (struct ev_token_bucket_cfg *cfg)
 Free all storage held in 'cfg'. More...
 
EVENT2_EXPORT_SYMBOL struct ev_token_bucket_cfg * ev_token_bucket_cfg_new (size_t read_rate, size_t read_burst, size_t write_rate, size_t write_burst, const struct timeval *tick_len)
 Initialize and return a new object to configure the rate-limiting behavior of bufferevents. More...
 
Rate limit inspection

Return the current read or write bucket size for a bufferevent.

+

If it is not configured with a per-bufferevent ratelimit, return EV_SSIZE_MAX. This function does not inspect the group limit, if any. Note that it can return a negative value if the bufferevent has been made to read or write more than its limit.

+
+EVENT2_EXPORT_SYMBOL ev_ssize_t bufferevent_get_max_to_read (struct bufferevent *bev)
 
+EVENT2_EXPORT_SYMBOL ev_ssize_t bufferevent_get_max_to_write (struct bufferevent *bev)
 
+EVENT2_EXPORT_SYMBOL ev_ssize_t bufferevent_get_read_limit (struct bufferevent *bev)
 
+EVENT2_EXPORT_SYMBOL const struct ev_token_bucket_cfg * bufferevent_get_token_bucket_cfg (const struct bufferevent *bev)
 
+EVENT2_EXPORT_SYMBOL ev_ssize_t bufferevent_get_write_limit (struct bufferevent *bev)
 
Group Rate limit inspection

Return the read or write bucket size for a bufferevent rate limit group.

+

Note that it can return a negative value if bufferevents in the group have been made to read or write more than their limits.

+
+EVENT2_EXPORT_SYMBOL ev_ssize_t bufferevent_rate_limit_group_get_read_limit (struct bufferevent_rate_limit_group *)
 
+EVENT2_EXPORT_SYMBOL ev_ssize_t bufferevent_rate_limit_group_get_write_limit (struct bufferevent_rate_limit_group *)
 
Rate limit manipulation

Subtract a number of bytes from a bufferevent's read or write bucket.

+

The decrement value can be negative, if you want to manually refill the bucket. If the change puts the bucket above or below zero, the bufferevent will resume or suspend reading writing as appropriate. These functions make no change in the buckets for the bufferevent's group, if any.

+

Returns 0 on success, -1 on internal error.

+
+EVENT2_EXPORT_SYMBOL int bufferevent_decrement_read_limit (struct bufferevent *bev, ev_ssize_t decr)
 
+EVENT2_EXPORT_SYMBOL int bufferevent_decrement_write_limit (struct bufferevent *bev, ev_ssize_t decr)
 
Group rate limit manipulation

Subtract a number of bytes from a bufferevent rate-limiting group's read or write bucket.

+

The decrement value can be negative, if you want to manually refill the bucket. If the change puts the bucket above or below zero, the bufferevents in the group will resume or suspend reading writing as appropriate.

+

Returns 0 on success, -1 on internal error.

+
+EVENT2_EXPORT_SYMBOL int bufferevent_rate_limit_group_decrement_read (struct bufferevent_rate_limit_group *, ev_ssize_t)
 
+EVENT2_EXPORT_SYMBOL int bufferevent_rate_limit_group_decrement_write (struct bufferevent_rate_limit_group *, ev_ssize_t)
 
EVENT2_EXPORT_SYMBOL void bufferevent_rate_limit_group_get_totals (struct bufferevent_rate_limit_group *grp, ev_uint64_t *total_read_out, ev_uint64_t *total_written_out)
 Inspect the total bytes read/written on a group. More...
 
EVENT2_EXPORT_SYMBOL void bufferevent_rate_limit_group_reset_totals (struct bufferevent_rate_limit_group *grp)
 Reset the total bytes read/written on a group. More...
 
+ + + + + + + + + + +

+Filtering support

typedef enum bufferevent_filter_result(* bufferevent_filter_cb) (struct evbuffer *src, struct evbuffer *dst, ev_ssize_t dst_limit, enum bufferevent_flush_mode mode, void *ctx)
 A callback function to implement a filter for a bufferevent. More...
 
EVENT2_EXPORT_SYMBOL struct buffereventbufferevent_filter_new (struct bufferevent *underlying, bufferevent_filter_cb input_filter, bufferevent_filter_cb output_filter, int options, void(*free_context)(void *), void *ctx)
 Allocate a new filtering bufferevent on top of an existing bufferevent. More...
 
enum  bufferevent_filter_result { BEV_OK = 0, +BEV_NEED_MORE = 1, +BEV_ERROR = 2 + }
 Values that filters can return. More...
 
+

Detailed Description

+

Functions for buffering data for network sending or receiving.

+

Bufferevents are higher level than evbuffers: each has an underlying evbuffer for reading and one for writing, and callbacks that are invoked under certain circumstances.

+

A bufferevent provides input and output buffers that get filled and drained automatically. The user of a bufferevent no longer deals directly with the I/O, but instead is reading from input and writing to output buffers.

+

Once initialized, the bufferevent structure can be used repeatedly with bufferevent_enable() and bufferevent_disable().

+

When reading is enabled, the bufferevent will try to read from the file descriptor onto its input buffer, and call the read callback. When writing is enabled, the bufferevent will try to write data onto its file descriptor when the output buffer has enough data, and call the write callback when the output buffer is sufficiently drained.

+

Bufferevents come in several flavors, including:

+
+
Socket-based bufferevents
+

A bufferevent that reads and writes data onto a network socket. Created with bufferevent_socket_new().

+

+
+
Paired bufferevents
+

A pair of bufferevents that send and receive data to one another without touching the network. Created with bufferevent_pair_new().

+

+
+
Filtering bufferevents
+

A bufferevent that transforms data, and sends or receives it over another underlying bufferevent. Created with bufferevent_filter_new().

+

+
+
SSL-backed bufferevents
+
A bufferevent that uses the openssl library to send and receive data over an encrypted connection. Created with bufferevent_openssl_socket_new() or bufferevent_openssl_filter_new().
+
+

Typedef Documentation

+ +

◆ bufferevent_data_cb

+ +
+
+ + + + +
typedef void(* bufferevent_data_cb) (struct bufferevent *bev, void *ctx)
+
+ +

A read or write callback for a bufferevent.

+

The read callback is triggered when new data arrives in the input buffer and the amount of readable data exceed the low watermark which is 0 by default.

+

The write callback is triggered if the write buffer has been exhausted or fell below its low watermark.

+
Parameters
+ + + +
bevthe bufferevent that triggered the callback
ctxthe user-specified context for this bufferevent
+
+
+ +
+
+ +

◆ bufferevent_event_cb

+ +
+
+ + + + +
typedef void(* bufferevent_event_cb) (struct bufferevent *bev, short what, void *ctx)
+
+ +

An event/error callback for a bufferevent.

+

The event callback is triggered if either an EOF condition or another unrecoverable error was encountered.

+

For bufferevents with deferred callbacks, this is a bitwise OR of all errors that have happened on the bufferevent since the last callback invocation.

+
Parameters
+ + + + +
bevthe bufferevent for which the error condition was reached
whata conjunction of flags: BEV_EVENT_READING or BEV_EVENT_WRITING to indicate if the error was encountered on the read or write path, and one of the following flags: BEV_EVENT_EOF, BEV_EVENT_ERROR, BEV_EVENT_TIMEOUT, BEV_EVENT_CONNECTED.
ctxthe user-specified context for this bufferevent
+
+
+ +
+
+ +

◆ bufferevent_filter_cb

+ +
+
+ + + + +
typedef enum bufferevent_filter_result(* bufferevent_filter_cb) (struct evbuffer *src, struct evbuffer *dst, ev_ssize_t dst_limit, enum bufferevent_flush_mode mode, void *ctx)
+
+ +

A callback function to implement a filter for a bufferevent.

+
Parameters
+ + + + + + +
srcAn evbuffer to drain data from.
dstAn evbuffer to add data to.
limitA suggested upper bound of bytes to write to dst. The filter may ignore this value, but doing so means that it will overflow the high-water mark associated with dst. -1 means "no limit".
modeWhether we should write data as may be convenient (BEV_NORMAL), or flush as much data as we can (BEV_FLUSH), or flush as much as we can, possibly including an end-of-stream marker (BEV_FINISH).
ctxA user-supplied pointer.
+
+
+
Returns
BEV_OK if we wrote some data; BEV_NEED_MORE if we can't produce any more output until we get some input; and BEV_ERROR on an error.
+ +
+
+

Enumeration Type Documentation

+ +

◆ bufferevent_filter_result

+ +
+
+ + + + +
enum bufferevent_filter_result
+
+ +

Values that filters can return.

+ + + + +
Enumerator
BEV_OK 

everything is okay

+
BEV_NEED_MORE 

the filter needs to read more data before output

+
BEV_ERROR 

the filter encountered a critical error, no further data can be processed.

+
+ +
+
+ +

◆ bufferevent_flush_mode

+ +
+
+ + + + +
enum bufferevent_flush_mode
+
+ +

Flags that can be passed into filters to let them know how to deal with the incoming data.

+ + + + +
Enumerator
BEV_NORMAL 

usually set when processing data

+
BEV_FLUSH 

want to checkpoint all data sent.

+
BEV_FINISHED 

encountered EOF on read or done sending data

+
+ +
+
+ +

◆ bufferevent_options

+ +
+
+ + + + +
enum bufferevent_options
+
+ +

Options that can be specified when creating a bufferevent.

+ + + + + +
Enumerator
BEV_OPT_CLOSE_ON_FREE 

If set, we close the underlying file descriptor/bufferevent/whatever when this bufferevent is freed.

+
BEV_OPT_THREADSAFE 

If set, and threading is enabled, operations on this bufferevent are protected by a lock.

+
BEV_OPT_DEFER_CALLBACKS 

If set, callbacks are run deferred in the event loop.

+
BEV_OPT_UNLOCK_CALLBACKS 

If set, callbacks are executed without locks being held on the bufferevent.

+

This option currently requires that BEV_OPT_DEFER_CALLBACKS also be set; a future version of Libevent might remove the requirement.

+
+ +
+
+ +

◆ bufferevent_trigger_options

+ +
+
+ + + + +
enum bufferevent_trigger_options
+
+ +

Flags for bufferevent_trigger(_event) that modify when and how to trigger the callback.

+ + + +
Enumerator
BEV_TRIG_IGNORE_WATERMARKS 

trigger the callback regardless of the watermarks

+
BEV_TRIG_DEFER_CALLBACKS 

defer even if the callbacks are not

+
+ +
+
+

Function Documentation

+ +

◆ bufferevent_add_to_rate_limit_group()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_add_to_rate_limit_group (struct buffereventbev,
struct bufferevent_rate_limit_group * g 
)
+
+ +

Add 'bev' to the list of bufferevents whose aggregate reading and writing is restricted by 'g'.

+

If 'g' is NULL, remove 'bev' from its current group.

+

A bufferevent may belong to no more than one rate-limit group at a time. If 'bev' is already a member of a group, it will be removed from its old group before being added to 'g'.

+

Return 0 on success and -1 on failure.

+ +
+
+ +

◆ bufferevent_base_set()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_base_set (struct event_basebase,
struct buffereventbufev 
)
+
+ +

Assign a bufferevent to a specific event_base.

+

NOTE that only socket bufferevents support this function.

+
Parameters
+ + + +
basean event_base returned by event_base_new()
bufeva bufferevent struct returned by bufferevent_new() or bufferevent_socket_new()
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
bufferevent_new()
+ +
+
+ +

◆ bufferevent_decref()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_decref (struct buffereventbufev)
+
+ +

Public interface to manually decrement the reference count of a bufferevent.

+

Warning: make sure you know what you're doing. This is mainly used in conjunction with bufferevent_incref(). This will free up all data associated with a bufferevent if the reference count hits 0.

+
Parameters
+ + +
bufevthe bufferevent to decrement the refcount on
+
+
+
Returns
1 if the bufferevent was freed, otherwise 0 (still referenced)
+ +
+
+ +

◆ bufferevent_disable()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_disable (struct buffereventbufev,
short event 
)
+
+ +

Disable a bufferevent.

+
Parameters
+ + + +
bufevthe bufferevent to be disabled. bufev must not be NULL.
eventany combination of EV_READ | EV_WRITE.
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
bufferevent_enable()
+ +
+
+ +

◆ bufferevent_enable()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_enable (struct buffereventbufev,
short event 
)
+
+ +

Enable a bufferevent.

+
Parameters
+ + + +
bufevthe bufferevent to be enabled. bufev must not be NULL.
eventany combination of EV_READ | EV_WRITE.
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
bufferevent_disable()
+ +
+
+ +

◆ bufferevent_filter_new()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct bufferevent* bufferevent_filter_new (struct buffereventunderlying,
bufferevent_filter_cb input_filter,
bufferevent_filter_cb output_filter,
int options,
void(*)(void *) free_context,
void * ctx 
)
+
+ +

Allocate a new filtering bufferevent on top of an existing bufferevent.

+
Parameters
+ + + + + + + +
underlyingthe underlying bufferevent.
input_filterThe filter to apply to data we read from the underlying bufferevent
output_filterThe filer to apply to data we write to the underlying bufferevent
optionsA bitfield of bufferevent options.
free_contextA function to use to free the filter context when this bufferevent is freed.
ctxA context pointer to pass to the filter functions.
+
+
+ +
+
+ +

◆ bufferevent_flush()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_flush (struct buffereventbufev,
short iotype,
enum bufferevent_flush_mode mode 
)
+
+ +

Triggers the bufferevent to produce more data if possible.

+
Parameters
+ + + + +
bufevthe bufferevent object
iotypeeither EV_READ or EV_WRITE or both.
modeeither BEV_NORMAL or BEV_FLUSH or BEV_FINISHED
+
+
+
Returns
-1 on failure, 0 if no data was produces, 1 if data was produced
+ +
+
+ +

◆ bufferevent_free()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void bufferevent_free (struct buffereventbufev)
+
+ +

Deallocate the storage associated with a bufferevent structure.

+

If there is pending data to write on the bufferevent, it probably won't be flushed before the bufferevent is freed.

+
Parameters
+ + +
bufevthe bufferevent structure to be freed. bufev must not be NULL.
+
+
+ +
+
+ +

◆ bufferevent_get_enabled()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL short bufferevent_get_enabled (struct buffereventbufev)
+
+ +

Return the events that are enabled on a given bufferevent.

+
Parameters
+ + +
bufevthe bufferevent to inspect
+
+
+
Returns
A combination of EV_READ | EV_WRITE
+ +
+
+ +

◆ bufferevent_get_input()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evbuffer* bufferevent_get_input (struct buffereventbufev)
+
+ +

Returns the input buffer.

+

The user MUST NOT set the callback on this buffer.

+
Parameters
+ + +
bufevthe bufferevent from which to get the evbuffer. bufev must not be NULL.
+
+
+
Returns
the evbuffer object for the input buffer
+ +
+
+ +

◆ bufferevent_get_output()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evbuffer* bufferevent_get_output (struct buffereventbufev)
+
+ +

Returns the output buffer.

+

The user MUST NOT set the callback on this buffer.

+

When filters are being used, the filters need to be manually triggered if the output buffer was manipulated.

+
Parameters
+ + +
bufevthe bufferevent from which to get the evbuffer. bufev must not be NULL.
+
+
+
Returns
the evbuffer object for the output buffer
+ +
+
+ +

◆ bufferevent_get_priority()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_get_priority (const struct buffereventbufev)
+
+ +

Return the priority of a bufferevent.

+

Only supported for socket bufferevents

+ +
+
+ +

◆ bufferevent_getcb()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void bufferevent_getcb (struct buffereventbufev,
bufferevent_data_cbreadcb_ptr,
bufferevent_data_cbwritecb_ptr,
bufferevent_event_cbeventcb_ptr,
void ** cbarg_ptr 
)
+
+ +

Retrieves the callbacks for a bufferevent.

+
Parameters
+ + + + + + +
bufevthe bufferevent to examine.
readcb_ptrif readcb_ptr is nonnull, *readcb_ptr is set to the current read callback for the bufferevent.
writecb_ptrif writecb_ptr is nonnull, *writecb_ptr is set to the current write callback for the bufferevent.
eventcb_ptrif eventcb_ptr is nonnull, *eventcb_ptr is set to the current event callback for the bufferevent.
cbarg_ptrif cbarg_ptr is nonnull, *cbarg_ptr is set to the current callback argument for the bufferevent.
+
+
+
See also
buffervent_setcb()
+ +
+
+ +

◆ bufferevent_getfd()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL evutil_socket_t bufferevent_getfd (struct buffereventbufev)
+
+ +

Returns the file descriptor associated with a bufferevent, or -1 if no file descriptor is associated with the bufferevent.

+

bufev must not be NULL.

+ +
+
+ +

◆ bufferevent_getwatermark()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_getwatermark (struct buffereventbufev,
short events,
size_t * lowmark,
size_t * highmark 
)
+
+ +

Retrieves the watermarks for read or write events.

+

Returns non-zero if events contains not only EV_READ or EV_WRITE. Returns zero if events equal EV_READ or EV_WRITE

+
Parameters
+ + + + + +
bufevthe bufferevent to be examined
eventsEV_READ or EV_WRITE
lowmarkreceives the lower watermark if not NULL
highmarkreceives the high watermark if not NULL
+
+
+ +
+
+ +

◆ bufferevent_incref()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void bufferevent_incref (struct buffereventbufev)
+
+ +

Public interface to manually increase the reference count of a bufferevent this is useful in situations where a user may reference the bufferevent somewhere else (unknown to libevent)

+
Parameters
+ + +
bufevthe bufferevent to increase the refcount on
+
+
+ +
+
+ +

◆ bufferevent_lock()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void bufferevent_lock (struct buffereventbufev)
+
+ +

Acquire the lock on a bufferevent.

+

Has no effect if locking was not enabled with BEV_OPT_THREADSAFE.

+ +
+
+ +

◆ bufferevent_pair_get_partner()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL struct bufferevent* bufferevent_pair_get_partner (struct buffereventbev)
+
+ +

Given one bufferevent returned by bufferevent_pair_new(), returns the other one if it still exists.

+

Otherwise returns NULL.

+ +
+
+ +

◆ bufferevent_pair_new()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_pair_new (struct event_basebase,
int options,
struct buffereventpair[2] 
)
+
+ +

Allocate a pair of linked bufferevents.

+

The bufferevents behave as would two bufferevent_sock instances connected to opposite ends of a socketpair(), except that no internal socketpair is allocated.

+
Parameters
+ + + + +
baseThe event base to associate with the socketpair.
optionsA set of options for this bufferevent
pairA pointer to an array to hold the two new bufferevent objects.
+
+
+
Returns
0 on success, -1 on failure.
+ +
+
+ +

◆ bufferevent_priority_set()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_priority_set (struct buffereventbufev,
int pri 
)
+
+ +

Assign a priority to a bufferevent.

+

Only supported for socket bufferevents.

+
Parameters
+ + + +
bufeva bufferevent struct
prithe priority to be assigned
+
+
+
Returns
0 if successful, or -1 if an error occurred
+ +
+
+ +

◆ bufferevent_rate_limit_group_free()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void bufferevent_rate_limit_group_free (struct bufferevent_rate_limit_group * )
+
+ +

Free a rate-limiting group.

+

The group must have no members when this function is called.

+ +
+
+ +

◆ bufferevent_rate_limit_group_get_totals()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void bufferevent_rate_limit_group_get_totals (struct bufferevent_rate_limit_group * grp,
ev_uint64_t * total_read_out,
ev_uint64_t * total_written_out 
)
+
+ +

Inspect the total bytes read/written on a group.

+

Set the variable pointed to by total_read_out to the total number of bytes ever read on grp, and the variable pointed to by total_written_out to the total number of bytes ever written on grp.

+ +
+
+ +

◆ bufferevent_rate_limit_group_new()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct bufferevent_rate_limit_group* bufferevent_rate_limit_group_new (struct event_basebase,
const struct ev_token_bucket_cfg * cfg 
)
+
+ +

Create a new rate-limit group for bufferevents.

+

A rate-limit group constrains the maximum number of bytes sent and received, in toto, by all of its bufferevents.

+
Parameters
+ + + +
baseAn event_base to run any necessary timeouts for the group. Note that all bufferevents in the group do not necessarily need to share this event_base.
cfgThe rate-limit for this group.
+
+
+

Note that all rate-limits hare are currently best-effort: future versions of Libevent may implement them more tightly.

+

Note also that only some bufferevent types currently respect rate-limiting. They are: socket-based bufferevents (normal and IOCP-based), and SSL-based bufferevents.

+ +
+
+ +

◆ bufferevent_rate_limit_group_reset_totals()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void bufferevent_rate_limit_group_reset_totals (struct bufferevent_rate_limit_group * grp)
+
+ +

Reset the total bytes read/written on a group.

+

Reset the number of bytes read or written on grp as given by bufferevent_rate_limit_group_reset_totals().

+ +
+
+ +

◆ bufferevent_rate_limit_group_set_cfg()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_rate_limit_group_set_cfg (struct bufferevent_rate_limit_group * ,
const struct ev_token_bucket_cfg *  
)
+
+ +

Change the rate-limiting settings for a given rate-limiting group.

+

Return 0 on success, -1 on failure.

+ +
+
+ +

◆ bufferevent_rate_limit_group_set_min_share()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_rate_limit_group_set_min_share (struct bufferevent_rate_limit_group * ,
size_t  
)
+
+ +

Change the smallest quantum we're willing to allocate to any single bufferevent in a group for reading or writing at a time.

+

The rationale is that, because of TCP/IP protocol overheads and kernel behavior, if a rate-limiting group is so tight on bandwidth that you're only willing to send 1 byte per tick per bufferevent, you might instead want to batch up the reads and writes so that you send N bytes per 1/N of the bufferevents (chosen at random) each tick, so you still wind up send 1 byte per tick per bufferevent on average, but you don't send so many tiny packets.

+

The default min-share is currently 64 bytes.

+

Returns 0 on success, -1 on failure.

+ +
+
+ +

◆ bufferevent_read()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL size_t bufferevent_read (struct buffereventbufev,
void * data,
size_t size 
)
+
+ +

Read data from a bufferevent buffer.

+

The bufferevent_read() function is used to read data from the input buffer.

+
Parameters
+ + + + +
bufevthe bufferevent to be read from
datapointer to a buffer that will store the data
sizethe size of the data buffer, in bytes
+
+
+
Returns
the amount of data read, in bytes. If 0 is returned, it is possible that there is no data in the buffer or that the read failed.
+ +
+
+ +

◆ bufferevent_read_buffer()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_read_buffer (struct buffereventbufev,
struct evbufferbuf 
)
+
+ +

Read data from a bufferevent buffer into an evbuffer.

+

This avoids memory copies.

+
Parameters
+ + + +
bufevthe bufferevent to be read from
bufthe evbuffer to which to add data
+
+
+
Returns
0 if successful, or -1 if an error occurred.
+ +
+
+ +

◆ bufferevent_replacefd()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_replacefd (struct buffereventbufev,
evutil_socket_t fd 
)
+
+ +

Replaces the file descriptor on which the bufferevent operates.

+

Not supported for all bufferevent types.

+

Unlike bufferevent_setfd() it will close previous file descriptor (if any).

+
Parameters
+ + + +
bufevthe bufferevent object for which to change the file descriptor
fdthe file descriptor to operate on
+
+
+ +
+
+ +

◆ bufferevent_set_max_single_read()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_set_max_single_read (struct buffereventbev,
size_t size 
)
+
+ +

Set the size limit for single read operation.

+

Set to 0 for a reasonable default.

+

Return 0 on success and -1 on failure.

+
See also
evbuffer_set_max_read()
+ +
+
+ +

◆ bufferevent_set_max_single_write()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_set_max_single_write (struct buffereventbev,
size_t size 
)
+
+ +

Set the size limit for single write operation.

+

Set to 0 for a reasonable default.

+

Return 0 on success and -1 on failure.

+ +
+
+ +

◆ bufferevent_set_rate_limit()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_set_rate_limit (struct buffereventbev,
struct ev_token_bucket_cfg * cfg 
)
+
+ +

Set the rate-limit of a the bufferevent 'bev' to the one specified in 'cfg'.

+

If 'cfg' is NULL, disable any per-bufferevent rate-limiting on 'bev'.

+

Note that only some bufferevent types currently respect rate-limiting. They are: socket-based bufferevents (normal and IOCP-based), and SSL-based bufferevents.

+

Return 0 on success, -1 on failure.

+ +
+
+ +

◆ bufferevent_set_timeouts()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_set_timeouts (struct buffereventbufev,
const struct timeval * timeout_read,
const struct timeval * timeout_write 
)
+
+ +

Set the read and write timeout for a bufferevent.

+

A bufferevent's timeout will fire the first time that the indicated amount of time has elapsed since a successful read or write operation, during which the bufferevent was trying to read or write.

+

(In other words, if reading or writing is disabled, or if the bufferevent's read or write operation has been suspended because there's no data to write, or not enough bandwidth, or so on, the timeout isn't active. The timeout only becomes active when we we're willing to actually read or write.)

+

Calling bufferevent_enable or setting a timeout for a bufferevent whose timeout is already pending resets its timeout.

+

If the timeout elapses, the corresponding operation (EV_READ or EV_WRITE) becomes disabled until you re-enable it again. The bufferevent's event callback is called with the BEV_EVENT_TIMEOUT|BEV_EVENT_READING or BEV_EVENT_TIMEOUT|BEV_EVENT_WRITING.

+
Parameters
+ + + + +
bufevthe bufferevent to be modified
timeout_readthe read timeout, or NULL
timeout_writethe write timeout, or NULL
+
+
+ +
+
+ +

◆ bufferevent_setcb()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void bufferevent_setcb (struct buffereventbufev,
bufferevent_data_cb readcb,
bufferevent_data_cb writecb,
bufferevent_event_cb eventcb,
void * cbarg 
)
+
+ +

Changes the callbacks for a bufferevent.

+
Parameters
+ + + + + + +
bufevthe bufferevent object for which to change callbacks. bufev must not be NULL.
readcbcallback to invoke when there is data to be read, or NULL if no callback is desired
writecbcallback to invoke when the file descriptor is ready for writing, or NULL if no callback is desired
eventcbcallback to invoke when there is an event on the file descriptor
cbargan argument that will be supplied to each of the callbacks (readcb, writecb, and errorcb)
+
+
+
See also
bufferevent_new()
+ +
+
+ +

◆ bufferevent_setfd()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_setfd (struct buffereventbufev,
evutil_socket_t fd 
)
+
+ +

Changes the file descriptor on which the bufferevent operates.

+

Not supported for all bufferevent types.

+
Parameters
+ + + +
bufevthe bufferevent object for which to change the file descriptor
fdthe file descriptor to operate on
+
+
+ +
+
+ +

◆ bufferevent_setwatermark()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void bufferevent_setwatermark (struct buffereventbufev,
short events,
size_t lowmark,
size_t highmark 
)
+
+ +

Sets the watermarks for read and write events.

+

On input, a bufferevent does not invoke the user read callback unless there is at least low watermark data in the buffer. If the read buffer is beyond the high watermark, the bufferevent stops reading from the network. But be aware that bufferevent input/read buffer can overrun high watermark limit (typical example is openssl bufferevent), so you should not relay in this.

+

On output, the user write callback is invoked whenever the buffered data falls below the low watermark. Filters that write to this bufev will try not to write more bytes to this buffer than the high watermark would allow, except when flushing.

+
Parameters
+ + + + + +
bufevthe bufferevent to be modified. bufev must not be NULL.
eventsEV_READ, EV_WRITE or both
lowmarkthe lower watermark to set
highmarkthe high watermark to set
+
+
+ +
+
+ +

◆ bufferevent_socket_connect()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_socket_connect (struct buffereventbufev,
const struct sockaddr * addr,
int socklen 
)
+
+ +

Launch a connect() attempt with a socket-based bufferevent.

+

When the connect succeeds, the eventcb will be invoked with BEV_EVENT_CONNECTED set.

+

If the bufferevent does not already have a socket set, we allocate a new socket here and make it nonblocking before we begin.

+

If no address is provided, we assume that the socket is already connecting, and configure the bufferevent so that a BEV_EVENT_CONNECTED event will be yielded when it is done connecting.

+
Parameters
+ + + + +
bufevan existing bufferevent allocated with bufferevent_socket_new().
addrthe address we should connect to
socklenThe length of the address
+
+
+
Returns
0 on success, -1 on failure.
+ +
+
+ +

◆ bufferevent_socket_connect_hostname()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_socket_connect_hostname (struct buffereventbufev,
struct evdns_base * evdns_base,
int family,
const char * hostname,
int port 
)
+
+ +

Resolve the hostname 'hostname' and connect to it as with bufferevent_socket_connect().

+
Parameters
+ + + + + + +
bufevAn existing bufferevent allocated with bufferevent_socket_new()
evdns_baseOptionally, an evdns_base to use for resolving hostnames asynchronously. May be set to NULL for a blocking resolve.
familyA preferred address family to resolve addresses to, or AF_UNSPEC for no preference. Only AF_INET, AF_INET6, and AF_UNSPEC are supported.
hostnameThe hostname to resolve; see below for notes on recognized formats
portThe port to connect to on the resolved address.
+
+
+
Returns
0 if successful, -1 on failure.
+
See also
bufferevent_socket_connect_hostname_hints()
+ +
+
+ +

◆ bufferevent_socket_connect_hostname_hints()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_socket_connect_hostname_hints (struct buffereventbufev,
struct evdns_base * evdns_base,
const struct evutil_addrinfohints_in,
const char * hostname,
int port 
)
+
+ +

Resolve the hostname 'hostname' and connect to it as with bufferevent_socket_connect().

+
Parameters
+ + + + + + +
bufevAn existing bufferevent allocated with bufferevent_socket_new()
evdns_baseOptionally, an evdns_base to use for resolving hostnames asynchronously. May be set to NULL for a blocking resolve.
hints_inpoints to an addrinfo structure that specifies criteria for selecting the socket address structures to be used
hostnameThe hostname to resolve; see below for notes on recognized formats
portThe port to connect to on the resolved address.
+
+
+
Returns
0 if successful, -1 on failure.
+

Recognized hostname formats are:

www.example.com (hostname)
+1.2.3.4     (ipv4address)
+::1     (ipv6address)
+[::1]       ([ipv6address])
+

Performance note: If you do not provide an evdns_base, this function may block while it waits for a DNS response. This is probably not what you want.

+ +
+
+ +

◆ bufferevent_socket_get_dns_error()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_socket_get_dns_error (struct buffereventbev)
+
+ +

Return the error code for the last failed DNS lookup attempt made by bufferevent_socket_connect_hostname().

+
Parameters
+ + +
bevThe bufferevent object.
+
+
+
Returns
DNS error code.
+
See also
evutil_gai_strerror()
+ +
+
+ +

◆ bufferevent_socket_new()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct bufferevent* bufferevent_socket_new (struct event_basebase,
evutil_socket_t fd,
int options 
)
+
+ +

Create a new socket bufferevent over an existing socket.

+
Parameters
+ + + + +
basethe event base to associate with the new bufferevent. base must not be NULL.
fdthe file descriptor from which data is read and written to. This file descriptor is not allowed to be a pipe(2). It is safe to set the fd to -1, so long as you later set it with bufferevent_setfd or bufferevent_socket_connect().
optionsZero or more BEV_OPT_* flags
+
+
+
Returns
a pointer to a newly allocated bufferevent struct, or NULL if an error occurred
+
See also
bufferevent_free()
+ +
+
+ +

◆ bufferevent_trigger()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void bufferevent_trigger (struct buffereventbufev,
short iotype,
int options 
)
+
+ +

Triggers bufferevent data callbacks.

+

The function will honor watermarks unless options contain BEV_TRIG_IGNORE_WATERMARKS. If the options contain BEV_OPT_DEFER_CALLBACKS, the callbacks are deferred.

+
Parameters
+ + + + +
bufevthe bufferevent object
iotypeeither EV_READ or EV_WRITE or both.
options
+
+
+ +
+
+ +

◆ bufferevent_trigger_event()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void bufferevent_trigger_event (struct buffereventbufev,
short what,
int options 
)
+
+ +

Triggers the bufferevent event callback.

+

If the options contain BEV_OPT_DEFER_CALLBACKS, the callbacks are deferred.

+
Parameters
+ + + + +
bufevthe bufferevent object
whatthe flags to pass onto the event callback
options
+
+
+ +
+
+ +

◆ bufferevent_unlock()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void bufferevent_unlock (struct buffereventbufev)
+
+ +

Release the lock on a bufferevent.

+

Has no effect if locking was not enabled with BEV_OPT_THREADSAFE.

+ +
+
+ +

◆ bufferevent_write()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_write (struct buffereventbufev,
const void * data,
size_t size 
)
+
+ +

Write data to a bufferevent buffer.

+

The bufferevent_write() function can be used to write data to the file descriptor. The data is appended to the output buffer and written to the descriptor automatically as it becomes available for writing.

+
Parameters
+ + + + +
bufevthe bufferevent to be written to
dataa pointer to the data to be written
sizethe length of the data, in bytes
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
bufferevent_write_buffer()
+ +
+
+ +

◆ bufferevent_write_buffer()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_write_buffer (struct buffereventbufev,
struct evbufferbuf 
)
+
+ +

Write data from an evbuffer to a bufferevent buffer.

+

The evbuffer is being drained as a result.

+
Parameters
+ + + +
bufevthe bufferevent to be written to
bufthe evbuffer to be written
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
bufferevent_write()
+ +
+
+ +

◆ ev_token_bucket_cfg_free()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void ev_token_bucket_cfg_free (struct ev_token_bucket_cfg * cfg)
+
+ +

Free all storage held in 'cfg'.

+

Note: 'cfg' is not currently reference-counted; it is not safe to free it until no bufferevent is using it.

+ +
+
+ +

◆ ev_token_bucket_cfg_new()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct ev_token_bucket_cfg* ev_token_bucket_cfg_new (size_t read_rate,
size_t read_burst,
size_t write_rate,
size_t write_burst,
const struct timeval * tick_len 
)
+
+ +

Initialize and return a new object to configure the rate-limiting behavior of bufferevents.

+
Parameters
+ + + + + + +
read_rateThe maximum number of bytes to read per tick on average.
read_burstThe maximum number of bytes to read in any single tick.
write_rateThe maximum number of bytes to write per tick on average.
write_burstThe maximum number of bytes to write in any single tick.
tick_lenThe length of a single tick. Defaults to one second. Any fractions of a millisecond are ignored.
+
+
+

Note that all rate-limits hare are currently best-effort: future versions of Libevent may implement them more tightly.

+ +
+
+
+ + + + diff --git a/bufferevent_8h_source.html b/bufferevent_8h_source.html new file mode 100644 index 0000000..cc4c9e1 --- /dev/null +++ b/bufferevent_8h_source.html @@ -0,0 +1,504 @@ + + + + + + + +libevent: event2/bufferevent.h Source File + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
bufferevent.h
+
+
+Go to the documentation of this file.
1 /*
+
2  * Copyright (c) 2000-2007 Niels Provos <provos@citi.umich.edu>
+
3  * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson
+
4  *
+
5  * Redistribution and use in source and binary forms, with or without
+
6  * modification, are permitted provided that the following conditions
+
7  * are met:
+
8  * 1. Redistributions of source code must retain the above copyright
+
9  * notice, this list of conditions and the following disclaimer.
+
10  * 2. Redistributions in binary form must reproduce the above copyright
+
11  * notice, this list of conditions and the following disclaimer in the
+
12  * documentation and/or other materials provided with the distribution.
+
13  * 3. The name of the author may not be used to endorse or promote products
+
14  * derived from this software without specific prior written permission.
+
15  *
+
16  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+
17  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+
18  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+
19  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+
20  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+
21  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+
22  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+
23  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+
24  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+
25  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
26  */
+
27 #ifndef EVENT2_BUFFEREVENT_H_INCLUDED_
+
28 #define EVENT2_BUFFEREVENT_H_INCLUDED_
+
29 
+
78 #include <event2/visibility.h>
+
79 
+
80 #ifdef __cplusplus
+
81 extern "C" {
+
82 #endif
+
83 
+
84 #include <event2/event-config.h>
+
85 #ifdef EVENT__HAVE_SYS_TYPES_H
+
86 #include <sys/types.h>
+
87 #endif
+
88 #ifdef EVENT__HAVE_SYS_TIME_H
+
89 #include <sys/time.h>
+
90 #endif
+
91 
+
92 /* For int types. */
+
93 #include <event2/util.h>
+
94 
+
101 #define BEV_EVENT_READING 0x01
+
102 #define BEV_EVENT_WRITING 0x02
+
103 #define BEV_EVENT_EOF 0x10
+
104 #define BEV_EVENT_ERROR 0x20
+
105 #define BEV_EVENT_TIMEOUT 0x40
+
106 #define BEV_EVENT_CONNECTED 0x80
+
114 struct bufferevent
+
115 #ifdef EVENT_IN_DOXYGEN_
+
116 {}
+
117 #endif
+
118 ;
+
119 struct event_base;
+
120 struct evbuffer;
+
121 struct sockaddr;
+
122 
+
136 typedef void (*bufferevent_data_cb)(struct bufferevent *bev, void *ctx);
+
137 
+
155 typedef void (*bufferevent_event_cb)(struct bufferevent *bev, short what, void *ctx);
+
156 
+ + +
162 
+ +
166 
+ +
169 
+ +
175 };
+
176 
+
190 EVENT2_EXPORT_SYMBOL
+
191 struct bufferevent *bufferevent_socket_new(struct event_base *base, evutil_socket_t fd, int options);
+
192 
+
212 EVENT2_EXPORT_SYMBOL
+
213 int bufferevent_socket_connect(struct bufferevent *bufev, const struct sockaddr *addr, int socklen);
+
214 
+
215 struct evdns_base;
+
233 EVENT2_EXPORT_SYMBOL
+ +
235  struct evdns_base *evdns_base, int family, const char *hostname, int port);
+
236 
+
262 EVENT2_EXPORT_SYMBOL
+ +
264  struct evdns_base *evdns_base, const struct evutil_addrinfo *hints_in, const char *hostname, int port);
+
265 
+
266 
+
275 EVENT2_EXPORT_SYMBOL
+ +
277 
+
289 EVENT2_EXPORT_SYMBOL
+
290 int bufferevent_base_set(struct event_base *base, struct bufferevent *bufev);
+
291 
+
295 EVENT2_EXPORT_SYMBOL
+
296 struct event_base *bufferevent_get_base(struct bufferevent *bev);
+
297 
+
307 EVENT2_EXPORT_SYMBOL
+
308 int bufferevent_priority_set(struct bufferevent *bufev, int pri);
+
309 
+
315 EVENT2_EXPORT_SYMBOL
+
316 int bufferevent_get_priority(const struct bufferevent *bufev);
+
317 
+
326 EVENT2_EXPORT_SYMBOL
+
327 void bufferevent_free(struct bufferevent *bufev);
+
328 
+
329 
+
344 EVENT2_EXPORT_SYMBOL
+
345 void bufferevent_setcb(struct bufferevent *bufev,
+ +
347  bufferevent_event_cb eventcb, void *cbarg);
+
348 
+
363 EVENT2_EXPORT_SYMBOL
+
364 void bufferevent_getcb(struct bufferevent *bufev,
+
365  bufferevent_data_cb *readcb_ptr,
+
366  bufferevent_data_cb *writecb_ptr,
+
367  bufferevent_event_cb *eventcb_ptr,
+
368  void **cbarg_ptr);
+
369 
+
377 EVENT2_EXPORT_SYMBOL
+
378 int bufferevent_setfd(struct bufferevent *bufev, evutil_socket_t fd);
+
379 
+
389 EVENT2_EXPORT_SYMBOL
+
390 int bufferevent_replacefd(struct bufferevent *bufev, evutil_socket_t fd);
+
391 
+
396 EVENT2_EXPORT_SYMBOL
+ +
398 
+
403 EVENT2_EXPORT_SYMBOL
+
404 struct bufferevent *bufferevent_get_underlying(struct bufferevent *bufev);
+
405 
+
419 EVENT2_EXPORT_SYMBOL
+
420 int bufferevent_write(struct bufferevent *bufev,
+
421  const void *data, size_t size);
+
422 
+
423 
+
433 EVENT2_EXPORT_SYMBOL
+
434 int bufferevent_write_buffer(struct bufferevent *bufev, struct evbuffer *buf);
+
435 
+
436 
+
448 EVENT2_EXPORT_SYMBOL
+
449 size_t bufferevent_read(struct bufferevent *bufev, void *data, size_t size);
+
450 
+
459 EVENT2_EXPORT_SYMBOL
+
460 int bufferevent_read_buffer(struct bufferevent *bufev, struct evbuffer *buf);
+
461 
+
471 EVENT2_EXPORT_SYMBOL
+
472 struct evbuffer *bufferevent_get_input(struct bufferevent *bufev);
+
473 
+
486 EVENT2_EXPORT_SYMBOL
+
487 struct evbuffer *bufferevent_get_output(struct bufferevent *bufev);
+
488 
+
497 EVENT2_EXPORT_SYMBOL
+
498 int bufferevent_enable(struct bufferevent *bufev, short event);
+
499 
+
508 EVENT2_EXPORT_SYMBOL
+
509 int bufferevent_disable(struct bufferevent *bufev, short event);
+
510 
+
517 EVENT2_EXPORT_SYMBOL
+
518 short bufferevent_get_enabled(struct bufferevent *bufev);
+
519 
+
546 EVENT2_EXPORT_SYMBOL
+
547 int bufferevent_set_timeouts(struct bufferevent *bufev,
+
548  const struct timeval *timeout_read, const struct timeval *timeout_write);
+
549 
+
571 EVENT2_EXPORT_SYMBOL
+
572 void bufferevent_setwatermark(struct bufferevent *bufev, short events,
+
573  size_t lowmark, size_t highmark);
+
574 
+
585 EVENT2_EXPORT_SYMBOL
+
586 int bufferevent_getwatermark(struct bufferevent *bufev, short events,
+
587  size_t *lowmark, size_t *highmark);
+
588 
+
593 EVENT2_EXPORT_SYMBOL
+
594 void bufferevent_lock(struct bufferevent *bufev);
+
595 
+
600 EVENT2_EXPORT_SYMBOL
+
601 void bufferevent_unlock(struct bufferevent *bufev);
+
602 
+
603 
+
612 EVENT2_EXPORT_SYMBOL
+
613 void bufferevent_incref(struct bufferevent *bufev);
+
614 
+
626 EVENT2_EXPORT_SYMBOL
+
627 int bufferevent_decref(struct bufferevent *bufev);
+
628 
+ + +
636 
+ +
639 
+ +
642 };
+
643 
+
652 EVENT2_EXPORT_SYMBOL
+
653 int bufferevent_flush(struct bufferevent *bufev,
+
654  short iotype,
+
655  enum bufferevent_flush_mode mode);
+
656 
+ + +
664 
+ +
667 
+
668  /* (Note: for internal reasons, these need to be disjoint from
+
669  * bufferevent_options, except when they mean the same thing. */
+
670 };
+
671 
+
683 EVENT2_EXPORT_SYMBOL
+
684 void bufferevent_trigger(struct bufferevent *bufev, short iotype,
+
685  int options);
+
686 
+
696 EVENT2_EXPORT_SYMBOL
+
697 void bufferevent_trigger_event(struct bufferevent *bufev, short what,
+
698  int options);
+
699 
+ +
710  BEV_OK = 0,
+
711 
+ +
714 
+ +
718 };
+
719 
+ +
739  struct evbuffer *src, struct evbuffer *dst, ev_ssize_t dst_limit,
+
740  enum bufferevent_flush_mode mode, void *ctx);
+
741 
+
755 EVENT2_EXPORT_SYMBOL
+
756 struct bufferevent *
+
757 bufferevent_filter_new(struct bufferevent *underlying,
+
758  bufferevent_filter_cb input_filter,
+
759  bufferevent_filter_cb output_filter,
+
760  int options,
+
761  void (*free_context)(void *),
+
762  void *ctx);
+
775 EVENT2_EXPORT_SYMBOL
+
776 int bufferevent_pair_new(struct event_base *base, int options,
+
777  struct bufferevent *pair[2]);
+
778 
+
783 EVENT2_EXPORT_SYMBOL
+ +
785 
+
790 struct ev_token_bucket_cfg;
+
791 
+
796 struct bufferevent_rate_limit_group;
+
797 
+
799 #define EV_RATE_LIMIT_MAX EV_SSIZE_MAX
+
800 
+
817 EVENT2_EXPORT_SYMBOL
+
818 struct ev_token_bucket_cfg *ev_token_bucket_cfg_new(
+
819  size_t read_rate, size_t read_burst,
+
820  size_t write_rate, size_t write_burst,
+
821  const struct timeval *tick_len);
+
822 
+
828 EVENT2_EXPORT_SYMBOL
+
829 void ev_token_bucket_cfg_free(struct ev_token_bucket_cfg *cfg);
+
830 
+
842 EVENT2_EXPORT_SYMBOL
+ +
844  struct ev_token_bucket_cfg *cfg);
+
845 
+
863 EVENT2_EXPORT_SYMBOL
+
864 struct bufferevent_rate_limit_group *bufferevent_rate_limit_group_new(
+
865  struct event_base *base,
+
866  const struct ev_token_bucket_cfg *cfg);
+
872 EVENT2_EXPORT_SYMBOL
+ +
874  struct bufferevent_rate_limit_group *,
+
875  const struct ev_token_bucket_cfg *);
+
876 
+
893 EVENT2_EXPORT_SYMBOL
+ +
895  struct bufferevent_rate_limit_group *, size_t);
+
896 
+
901 EVENT2_EXPORT_SYMBOL
+
902 void bufferevent_rate_limit_group_free(struct bufferevent_rate_limit_group *);
+
903 
+
914 EVENT2_EXPORT_SYMBOL
+ +
916  struct bufferevent_rate_limit_group *g);
+
917 
+
919 EVENT2_EXPORT_SYMBOL
+ +
921 
+
931 EVENT2_EXPORT_SYMBOL
+
932 int bufferevent_set_max_single_read(struct bufferevent *bev, size_t size);
+
933 
+
941 EVENT2_EXPORT_SYMBOL
+
942 int bufferevent_set_max_single_write(struct bufferevent *bev, size_t size);
+
943 
+
945 EVENT2_EXPORT_SYMBOL
+
946 ev_ssize_t bufferevent_get_max_single_read(struct bufferevent *bev);
+
947 
+
949 EVENT2_EXPORT_SYMBOL
+
950 ev_ssize_t bufferevent_get_max_single_write(struct bufferevent *bev);
+
951 
+
963 EVENT2_EXPORT_SYMBOL
+
964 ev_ssize_t bufferevent_get_read_limit(struct bufferevent *bev);
+
965 EVENT2_EXPORT_SYMBOL
+
966 ev_ssize_t bufferevent_get_write_limit(struct bufferevent *bev);
+
969 EVENT2_EXPORT_SYMBOL
+
970 ev_ssize_t bufferevent_get_max_to_read(struct bufferevent *bev);
+
971 EVENT2_EXPORT_SYMBOL
+
972 ev_ssize_t bufferevent_get_max_to_write(struct bufferevent *bev);
+
973 
+
974 EVENT2_EXPORT_SYMBOL
+
975 const struct ev_token_bucket_cfg *bufferevent_get_token_bucket_cfg(const struct bufferevent * bev);
+
976 
+
986 EVENT2_EXPORT_SYMBOL
+
987 ev_ssize_t bufferevent_rate_limit_group_get_read_limit(
+
988  struct bufferevent_rate_limit_group *);
+
989 EVENT2_EXPORT_SYMBOL
+
990 ev_ssize_t bufferevent_rate_limit_group_get_write_limit(
+
991  struct bufferevent_rate_limit_group *);
+
1008 EVENT2_EXPORT_SYMBOL
+
1009 int bufferevent_decrement_read_limit(struct bufferevent *bev, ev_ssize_t decr);
+
1010 EVENT2_EXPORT_SYMBOL
+
1011 int bufferevent_decrement_write_limit(struct bufferevent *bev, ev_ssize_t decr);
+
1027 EVENT2_EXPORT_SYMBOL
+
1028 int bufferevent_rate_limit_group_decrement_read(
+
1029  struct bufferevent_rate_limit_group *, ev_ssize_t);
+
1030 EVENT2_EXPORT_SYMBOL
+
1031 int bufferevent_rate_limit_group_decrement_write(
+
1032  struct bufferevent_rate_limit_group *, ev_ssize_t);
+
1042 EVENT2_EXPORT_SYMBOL
+ +
1044  struct bufferevent_rate_limit_group *grp,
+
1045  ev_uint64_t *total_read_out, ev_uint64_t *total_written_out);
+
1046 
+
1052 EVENT2_EXPORT_SYMBOL
+
1053 void
+ +
1055  struct bufferevent_rate_limit_group *grp);
+
1056 
+
1057 #ifdef __cplusplus
+
1058 }
+
1059 #endif
+
1060 
+
1061 #endif /* EVENT2_BUFFEREVENT_H_INCLUDED_ */
+
+
bufferevent_flush
EVENT2_EXPORT_SYMBOL int bufferevent_flush(struct bufferevent *bufev, short iotype, enum bufferevent_flush_mode mode)
Triggers the bufferevent to produce more data if possible.
+
ev_token_bucket_cfg_free
EVENT2_EXPORT_SYMBOL void ev_token_bucket_cfg_free(struct ev_token_bucket_cfg *cfg)
Free all storage held in 'cfg'.
+
BEV_OPT_CLOSE_ON_FREE
@ BEV_OPT_CLOSE_ON_FREE
If set, we close the underlying file descriptor/bufferevent/whatever when this bufferevent is freed.
Definition: bufferevent.h:161
+
bufferevent_pair_get_partner
EVENT2_EXPORT_SYMBOL struct bufferevent * bufferevent_pair_get_partner(struct bufferevent *bev)
Given one bufferevent returned by bufferevent_pair_new(), returns the other one if it still exists.
+
bufferevent_socket_connect_hostname
EVENT2_EXPORT_SYMBOL int bufferevent_socket_connect_hostname(struct bufferevent *bufev, struct evdns_base *evdns_base, int family, const char *hostname, int port)
Resolve the hostname 'hostname' and connect to it as with bufferevent_socket_connect().
+
bufferevent_setfd
EVENT2_EXPORT_SYMBOL int bufferevent_setfd(struct bufferevent *bufev, evutil_socket_t fd)
Changes the file descriptor on which the bufferevent operates.
+
bufferevent_get_output
EVENT2_EXPORT_SYMBOL struct evbuffer * bufferevent_get_output(struct bufferevent *bufev)
Returns the output buffer.
+
BEV_TRIG_IGNORE_WATERMARKS
@ BEV_TRIG_IGNORE_WATERMARKS
trigger the callback regardless of the watermarks
Definition: bufferevent.h:663
+
bufferevent_priority_set
EVENT2_EXPORT_SYMBOL int bufferevent_priority_set(struct bufferevent *bufev, int pri)
Assign a priority to a bufferevent.
+
bufferevent_set_timeouts
EVENT2_EXPORT_SYMBOL int bufferevent_set_timeouts(struct bufferevent *bufev, const struct timeval *timeout_read, const struct timeval *timeout_write)
Set the read and write timeout for a bufferevent.
+
ev_token_bucket_cfg_new
EVENT2_EXPORT_SYMBOL struct ev_token_bucket_cfg * ev_token_bucket_cfg_new(size_t read_rate, size_t read_burst, size_t write_rate, size_t write_burst, const struct timeval *tick_len)
Initialize and return a new object to configure the rate-limiting behavior of bufferevents.
+
bufferevent_flush_mode
bufferevent_flush_mode
Flags that can be passed into filters to let them know how to deal with the incoming data.
Definition: bufferevent.h:633
+
bufferevent_rate_limit_group_new
EVENT2_EXPORT_SYMBOL struct bufferevent_rate_limit_group * bufferevent_rate_limit_group_new(struct event_base *base, const struct ev_token_bucket_cfg *cfg)
Create a new rate-limit group for bufferevents.
+
bufferevent_rate_limit_group_reset_totals
EVENT2_EXPORT_SYMBOL void bufferevent_rate_limit_group_reset_totals(struct bufferevent_rate_limit_group *grp)
Reset the total bytes read/written on a group.
+
bufferevent_socket_get_dns_error
EVENT2_EXPORT_SYMBOL int bufferevent_socket_get_dns_error(struct bufferevent *bev)
Return the error code for the last failed DNS lookup attempt made by bufferevent_socket_connect_hostn...
+
bufferevent_get_underlying
EVENT2_EXPORT_SYMBOL struct bufferevent * bufferevent_get_underlying(struct bufferevent *bufev)
Returns the underlying bufferevent associated with a bufferevent (if the bufferevent is a wrapper),...
+
bufferevent_rate_limit_group_free
EVENT2_EXPORT_SYMBOL void bufferevent_rate_limit_group_free(struct bufferevent_rate_limit_group *)
Free a rate-limiting group.
+
bufferevent_socket_connect_hostname_hints
EVENT2_EXPORT_SYMBOL int bufferevent_socket_connect_hostname_hints(struct bufferevent *bufev, struct evdns_base *evdns_base, const struct evutil_addrinfo *hints_in, const char *hostname, int port)
Resolve the hostname 'hostname' and connect to it as with bufferevent_socket_connect().
+
bufferevent_get_max_single_read
EVENT2_EXPORT_SYMBOL ev_ssize_t bufferevent_get_max_single_read(struct bufferevent *bev)
Get the current size limit for single read operation.
+
bufferevent_getcb
EVENT2_EXPORT_SYMBOL void bufferevent_getcb(struct bufferevent *bufev, bufferevent_data_cb *readcb_ptr, bufferevent_data_cb *writecb_ptr, bufferevent_event_cb *eventcb_ptr, void **cbarg_ptr)
Retrieves the callbacks for a bufferevent.
+
bufferevent_base_set
EVENT2_EXPORT_SYMBOL int bufferevent_base_set(struct event_base *base, struct bufferevent *bufev)
Assign a bufferevent to a specific event_base.
+
event_base
Structure to hold information and state for a Libevent dispatch loop.
Definition: event.h:219
+
bufferevent_enable
EVENT2_EXPORT_SYMBOL int bufferevent_enable(struct bufferevent *bufev, short event)
Enable a bufferevent.
+
bufferevent_trigger_options
bufferevent_trigger_options
Flags for bufferevent_trigger(_event) that modify when and how to trigger the callback.
Definition: bufferevent.h:661
+
event
Structure to represent a single event.
Definition: event.h:276
+
BEV_OPT_THREADSAFE
@ BEV_OPT_THREADSAFE
If set, and threading is enabled, operations on this bufferevent are protected by a lock.
Definition: bufferevent.h:165
+
bufferevent_getwatermark
EVENT2_EXPORT_SYMBOL int bufferevent_getwatermark(struct bufferevent *bufev, short events, size_t *lowmark, size_t *highmark)
Retrieves the watermarks for read or write events.
+
BEV_FLUSH
@ BEV_FLUSH
want to checkpoint all data sent.
Definition: bufferevent.h:638
+
bufferevent_read_buffer
EVENT2_EXPORT_SYMBOL int bufferevent_read_buffer(struct bufferevent *bufev, struct evbuffer *buf)
Read data from a bufferevent buffer into an evbuffer.
+
bufferevent_filter_new
EVENT2_EXPORT_SYMBOL struct bufferevent * bufferevent_filter_new(struct bufferevent *underlying, bufferevent_filter_cb input_filter, bufferevent_filter_cb output_filter, int options, void(*free_context)(void *), void *ctx)
Allocate a new filtering bufferevent on top of an existing bufferevent.
+
bufferevent_get_input
EVENT2_EXPORT_SYMBOL struct evbuffer * bufferevent_get_input(struct bufferevent *bufev)
Returns the input buffer.
+
bufferevent_filter_cb
enum bufferevent_filter_result(* bufferevent_filter_cb)(struct evbuffer *src, struct evbuffer *dst, ev_ssize_t dst_limit, enum bufferevent_flush_mode mode, void *ctx)
A callback function to implement a filter for a bufferevent.
Definition: bufferevent.h:738
+
bufferevent_get_base
EVENT2_EXPORT_SYMBOL struct event_base * bufferevent_get_base(struct bufferevent *bev)
Return the event_base used by a bufferevent.
+
bufferevent_incref
EVENT2_EXPORT_SYMBOL void bufferevent_incref(struct bufferevent *bufev)
Public interface to manually increase the reference count of a bufferevent this is useful in situatio...
+
bufferevent
An opaque type for handling buffered IO.
Definition: bufferevent.h:114
+
bufferevent_lock
EVENT2_EXPORT_SYMBOL void bufferevent_lock(struct bufferevent *bufev)
Acquire the lock on a bufferevent.
+
bufferevent_set_rate_limit
EVENT2_EXPORT_SYMBOL int bufferevent_set_rate_limit(struct bufferevent *bev, struct ev_token_bucket_cfg *cfg)
Set the rate-limit of a the bufferevent 'bev' to the one specified in 'cfg'.
+
bufferevent_get_max_single_write
EVENT2_EXPORT_SYMBOL ev_ssize_t bufferevent_get_max_single_write(struct bufferevent *bev)
Get the current size limit for single write operation.
+
bufferevent_set_max_single_read
EVENT2_EXPORT_SYMBOL int bufferevent_set_max_single_read(struct bufferevent *bev, size_t size)
Set the size limit for single read operation.
+
evbuffer
An evbuffer is an opaque data type for efficiently buffering data to be sent or received on the netwo...
Definition: buffer.h:97
+
bufferevent_get_enabled
EVENT2_EXPORT_SYMBOL short bufferevent_get_enabled(struct bufferevent *bufev)
Return the events that are enabled on a given bufferevent.
+
bufferevent_socket_connect
EVENT2_EXPORT_SYMBOL int bufferevent_socket_connect(struct bufferevent *bufev, const struct sockaddr *addr, int socklen)
Launch a connect() attempt with a socket-based bufferevent.
+
bufferevent_getfd
EVENT2_EXPORT_SYMBOL evutil_socket_t bufferevent_getfd(struct bufferevent *bufev)
Returns the file descriptor associated with a bufferevent, or -1 if no file descriptor is associated ...
+
bufferevent_unlock
EVENT2_EXPORT_SYMBOL void bufferevent_unlock(struct bufferevent *bufev)
Release the lock on a bufferevent.
+
bufferevent_remove_from_rate_limit_group
EVENT2_EXPORT_SYMBOL int bufferevent_remove_from_rate_limit_group(struct bufferevent *bev)
Remove 'bev' from its current rate-limit group (if any).
+
bufferevent_get_priority
EVENT2_EXPORT_SYMBOL int bufferevent_get_priority(const struct bufferevent *bufev)
Return the priority of a bufferevent.
+
bufferevent_setwatermark
EVENT2_EXPORT_SYMBOL void bufferevent_setwatermark(struct bufferevent *bufev, short events, size_t lowmark, size_t highmark)
Sets the watermarks for read and write events.
+
bufferevent_rate_limit_group_get_totals
EVENT2_EXPORT_SYMBOL void bufferevent_rate_limit_group_get_totals(struct bufferevent_rate_limit_group *grp, ev_uint64_t *total_read_out, ev_uint64_t *total_written_out)
Inspect the total bytes read/written on a group.
+
bufferevent_trigger
EVENT2_EXPORT_SYMBOL void bufferevent_trigger(struct bufferevent *bufev, short iotype, int options)
Triggers bufferevent data callbacks.
+
bufferevent_event_cb
void(* bufferevent_event_cb)(struct bufferevent *bev, short what, void *ctx)
An event/error callback for a bufferevent.
Definition: bufferevent.h:155
+
bufferevent_data_cb
void(* bufferevent_data_cb)(struct bufferevent *bev, void *ctx)
A read or write callback for a bufferevent.
Definition: bufferevent.h:136
+
bufferevent_trigger_event
EVENT2_EXPORT_SYMBOL void bufferevent_trigger_event(struct bufferevent *bufev, short what, int options)
Triggers the bufferevent event callback.
+
BEV_FINISHED
@ BEV_FINISHED
encountered EOF on read or done sending data
Definition: bufferevent.h:641
+
bufferevent_read
EVENT2_EXPORT_SYMBOL size_t bufferevent_read(struct bufferevent *bufev, void *data, size_t size)
Read data from a bufferevent buffer.
+
bufferevent_decref
EVENT2_EXPORT_SYMBOL int bufferevent_decref(struct bufferevent *bufev)
Public interface to manually decrement the reference count of a bufferevent.
+
BEV_NEED_MORE
@ BEV_NEED_MORE
the filter needs to read more data before output
Definition: bufferevent.h:713
+
BEV_OPT_UNLOCK_CALLBACKS
@ BEV_OPT_UNLOCK_CALLBACKS
If set, callbacks are executed without locks being held on the bufferevent.
Definition: bufferevent.h:174
+
bufferevent_replacefd
EVENT2_EXPORT_SYMBOL int bufferevent_replacefd(struct bufferevent *bufev, evutil_socket_t fd)
Replaces the file descriptor on which the bufferevent operates.
+
bufferevent_setcb
EVENT2_EXPORT_SYMBOL void bufferevent_setcb(struct bufferevent *bufev, bufferevent_data_cb readcb, bufferevent_data_cb writecb, bufferevent_event_cb eventcb, void *cbarg)
Changes the callbacks for a bufferevent.
+
BEV_NORMAL
@ BEV_NORMAL
usually set when processing data
Definition: bufferevent.h:635
+
bufferevent_rate_limit_group_set_cfg
EVENT2_EXPORT_SYMBOL int bufferevent_rate_limit_group_set_cfg(struct bufferevent_rate_limit_group *, const struct ev_token_bucket_cfg *)
Change the rate-limiting settings for a given rate-limiting group.
+
bufferevent_pair_new
EVENT2_EXPORT_SYMBOL int bufferevent_pair_new(struct event_base *base, int options, struct bufferevent *pair[2])
Allocate a pair of linked bufferevents.
+
BEV_OPT_DEFER_CALLBACKS
@ BEV_OPT_DEFER_CALLBACKS
If set, callbacks are run deferred in the event loop.
Definition: bufferevent.h:168
+
bufferevent_rate_limit_group_set_min_share
EVENT2_EXPORT_SYMBOL int bufferevent_rate_limit_group_set_min_share(struct bufferevent_rate_limit_group *, size_t)
Change the smallest quantum we're willing to allocate to any single bufferevent in a group for readin...
+
bufferevent_socket_new
EVENT2_EXPORT_SYMBOL struct bufferevent * bufferevent_socket_new(struct event_base *base, evutil_socket_t fd, int options)
Create a new socket bufferevent over an existing socket.
+
bufferevent_free
EVENT2_EXPORT_SYMBOL void bufferevent_free(struct bufferevent *bufev)
Deallocate the storage associated with a bufferevent structure.
+
bufferevent_options
bufferevent_options
Options that can be specified when creating a bufferevent.
Definition: bufferevent.h:158
+
BEV_ERROR
@ BEV_ERROR
the filter encountered a critical error, no further data can be processed.
Definition: bufferevent.h:717
+
BEV_OK
@ BEV_OK
everything is okay
Definition: bufferevent.h:710
+
util.h
Common convenience functions for cross-platform portability and related socket manipulations.
+
bufferevent_add_to_rate_limit_group
EVENT2_EXPORT_SYMBOL int bufferevent_add_to_rate_limit_group(struct bufferevent *bev, struct bufferevent_rate_limit_group *g)
Add 'bev' to the list of bufferevents whose aggregate reading and writing is restricted by 'g'.
+
evutil_addrinfo
A definition of struct addrinfo for systems that lack it.
Definition: util.h:731
+
bufferevent_set_max_single_write
EVENT2_EXPORT_SYMBOL int bufferevent_set_max_single_write(struct bufferevent *bev, size_t size)
Set the size limit for single write operation.
+
bufferevent_filter_result
bufferevent_filter_result
Values that filters can return.
Definition: bufferevent.h:708
+
bufferevent_write
EVENT2_EXPORT_SYMBOL int bufferevent_write(struct bufferevent *bufev, const void *data, size_t size)
Write data to a bufferevent buffer.
+
bufferevent_disable
EVENT2_EXPORT_SYMBOL int bufferevent_disable(struct bufferevent *bufev, short event)
Disable a bufferevent.
+
bufferevent_write_buffer
EVENT2_EXPORT_SYMBOL int bufferevent_write_buffer(struct bufferevent *bufev, struct evbuffer *buf)
Write data from an evbuffer to a bufferevent buffer.
+
evutil_socket_t
#define evutil_socket_t
A type wide enough to hold the output of "socket()" or "accept()".
Definition: util.h:325
+
BEV_TRIG_DEFER_CALLBACKS
@ BEV_TRIG_DEFER_CALLBACKS
defer even if the callbacks are not
Definition: bufferevent.h:666
+ + + + diff --git a/bufferevent__compat_8h.html b/bufferevent__compat_8h.html new file mode 100644 index 0000000..a8f89e6 --- /dev/null +++ b/bufferevent__compat_8h.html @@ -0,0 +1,247 @@ + + + + + + + +libevent: event2/bufferevent_compat.h File Reference + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+Macros | +Functions
+
+
bufferevent_compat.h File Reference
+
+
+ +

Deprecated versions of the functions in bufferevent.h: provided only for backwards compatibility. +More...

+
#include <event2/visibility.h>
+
+

Go to the source code of this file.

+ + + + + + + + + + + + + + + + + + + + + + +

+Macros

+#define EVBUFFER_EOF   BEV_EVENT_EOF
 
+#define EVBUFFER_ERROR   BEV_EVENT_ERROR
 
+#define EVBUFFER_INPUT(x)   bufferevent_get_input(x)
 macro for getting access to the input buffer of a bufferevent
 
+#define EVBUFFER_OUTPUT(x)   bufferevent_get_output(x)
 macro for getting access to the output buffer of a bufferevent
 
+#define EVBUFFER_READ   BEV_EVENT_READING
 
+#define EVBUFFER_TIMEOUT   BEV_EVENT_TIMEOUT
 
+#define EVBUFFER_WRITE   BEV_EVENT_WRITING
 
+#define evbuffercb   bufferevent_data_cb
 
+#define everrorcb   bufferevent_event_cb
 
+ + + + + + + +

+Functions

EVENT2_EXPORT_SYMBOL struct buffereventbufferevent_new (evutil_socket_t fd, evbuffercb readcb, evbuffercb writecb, everrorcb errorcb, void *cbarg)
 Create a new bufferevent for an fd. More...
 
EVENT2_EXPORT_SYMBOL void bufferevent_settimeout (struct bufferevent *bufev, int timeout_read, int timeout_write)
 Set the read and write timeout for a buffered event. More...
 
+

Detailed Description

+

Deprecated versions of the functions in bufferevent.h: provided only for backwards compatibility.

+

Function Documentation

+ +

◆ bufferevent_new()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct bufferevent* bufferevent_new (evutil_socket_t fd,
evbuffercb readcb,
evbuffercb writecb,
everrorcb errorcb,
void * cbarg 
)
+
+ +

Create a new bufferevent for an fd.

+

This function is deprecated. Use bufferevent_socket_new() and bufferevent_setcb() instead.

+

Libevent provides an abstraction on top of the regular event callbacks. This abstraction is called a buffered event. A buffered event provides input and output buffers that get filled and drained automatically. The user of a buffered event no longer deals directly with the I/O, but instead is reading from input and writing to output buffers.

+

Once initialized, the bufferevent structure can be used repeatedly with bufferevent_enable() and bufferevent_disable().

+

When read enabled the bufferevent will try to read from the file descriptor and call the read callback. The write callback is executed whenever the output buffer is drained below the write low watermark, which is 0 by default.

+

If multiple bases are in use, bufferevent_base_set() must be called before enabling the bufferevent for the first time.

+
Deprecated:
This function is deprecated because it uses the current event base, and as such can be error prone for multithreaded programs. Use bufferevent_socket_new() instead.
+
Parameters
+ + + + + + +
fdthe file descriptor from which data is read and written to. This file descriptor is not allowed to be a pipe(2).
readcbcallback to invoke when there is data to be read, or NULL if no callback is desired
writecbcallback to invoke when the file descriptor is ready for writing, or NULL if no callback is desired
errorcbcallback to invoke when there is an error on the file descriptor
cbargan argument that will be supplied to each of the callbacks (readcb, writecb, and errorcb)
+
+
+
Returns
a pointer to a newly allocated bufferevent struct, or NULL if an error occurred
+
See also
bufferevent_base_set(), bufferevent_free()
+ +
+
+ +

◆ bufferevent_settimeout()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void bufferevent_settimeout (struct buffereventbufev,
int timeout_read,
int timeout_write 
)
+
+ +

Set the read and write timeout for a buffered event.

+
Deprecated:
Use bufferevent_set_timeouts instead.
+
Parameters
+ + + + +
bufevthe bufferevent to be modified
timeout_readthe read timeout
timeout_writethe write timeout
+
+
+ +
+
+
+ + + + diff --git a/bufferevent__compat_8h_source.html b/bufferevent__compat_8h_source.html new file mode 100644 index 0000000..7795950 --- /dev/null +++ b/bufferevent__compat_8h_source.html @@ -0,0 +1,141 @@ + + + + + + + +libevent: event2/bufferevent_compat.h Source File + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
bufferevent_compat.h
+
+
+Go to the documentation of this file.
1 /*
+
2  * Copyright (c) 2007-2012 Niels Provos, Nick Mathewson
+
3  * Copyright (c) 2000-2007 Niels Provos <provos@citi.umich.edu>
+
4  * All rights reserved.
+
5  *
+
6  * Redistribution and use in source and binary forms, with or without
+
7  * modification, are permitted provided that the following conditions
+
8  * are met:
+
9  * 1. Redistributions of source code must retain the above copyright
+
10  * notice, this list of conditions and the following disclaimer.
+
11  * 2. Redistributions in binary form must reproduce the above copyright
+
12  * notice, this list of conditions and the following disclaimer in the
+
13  * documentation and/or other materials provided with the distribution.
+
14  * 3. The name of the author may not be used to endorse or promote products
+
15  * derived from this software without specific prior written permission.
+
16  *
+
17  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+
18  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+
19  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+
20  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+
21  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+
22  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+
23  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+
24  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+
25  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+
26  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
27  */
+
28 #ifndef EVENT2_BUFFEREVENT_COMPAT_H_INCLUDED_
+
29 #define EVENT2_BUFFEREVENT_COMPAT_H_INCLUDED_
+
30 
+
37 #include <event2/visibility.h>
+
38 
+
39 #define evbuffercb bufferevent_data_cb
+
40 #define everrorcb bufferevent_event_cb
+
41 
+
83 EVENT2_EXPORT_SYMBOL
+ +
85  evbuffercb readcb, evbuffercb writecb, everrorcb errorcb, void *cbarg);
+
86 
+
87 
+
97 EVENT2_EXPORT_SYMBOL
+
98 void bufferevent_settimeout(struct bufferevent *bufev,
+
99  int timeout_read, int timeout_write);
+
100 
+
101 #define EVBUFFER_READ BEV_EVENT_READING
+
102 #define EVBUFFER_WRITE BEV_EVENT_WRITING
+
103 #define EVBUFFER_EOF BEV_EVENT_EOF
+
104 #define EVBUFFER_ERROR BEV_EVENT_ERROR
+
105 #define EVBUFFER_TIMEOUT BEV_EVENT_TIMEOUT
+
106 
+
108 #define EVBUFFER_INPUT(x) bufferevent_get_input(x)
+
109 
+
110 #define EVBUFFER_OUTPUT(x) bufferevent_get_output(x)
+
111 
+
112 #endif
+
+
bufferevent
An opaque type for handling buffered IO.
Definition: bufferevent.h:114
+
bufferevent_settimeout
EVENT2_EXPORT_SYMBOL void bufferevent_settimeout(struct bufferevent *bufev, int timeout_read, int timeout_write)
Set the read and write timeout for a buffered event.
+
bufferevent_new
EVENT2_EXPORT_SYMBOL struct bufferevent * bufferevent_new(evutil_socket_t fd, evbuffercb readcb, evbuffercb writecb, everrorcb errorcb, void *cbarg)
Create a new bufferevent for an fd.
+
evutil_socket_t
#define evutil_socket_t
A type wide enough to hold the output of "socket()" or "accept()".
Definition: util.h:325
+ + + + diff --git a/bufferevent__ssl_8h.html b/bufferevent__ssl_8h.html new file mode 100644 index 0000000..5d16ba0 --- /dev/null +++ b/bufferevent__ssl_8h.html @@ -0,0 +1,570 @@ + + + + + + + +libevent: event2/bufferevent_ssl.h File Reference + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+Macros | +Typedefs | +Enumerations | +Functions
+
+
bufferevent_ssl.h File Reference
+
+
+ +

OpenSSL support for bufferevents. +More...

+
#include <event2/visibility.h>
+#include <event2/event-config.h>
+#include <event2/bufferevent.h>
+#include <event2/util.h>
+
+

Go to the source code of this file.

+ + + + + + + + +

+Macros

#define BUFFEREVENT_SSL_BATCH_WRITE   2
 Control writes in the SSL bufferevents. More...
 
#define BUFFEREVENT_SSL_DIRTY_SHUTDOWN   1
 Control how to report dirty SSL shutdowns. More...
 
+ + + +

+Typedefs

+typedef struct mbedtls_ssl_context mbedtls_dyncontext
 
+ + + + +

+Enumerations

enum  bufferevent_ssl_state { BUFFEREVENT_SSL_OPEN = 0, +BUFFEREVENT_SSL_CONNECTING = 1, +BUFFEREVENT_SSL_ACCEPTING = 2 + }
 The state of an SSL object to be used when creating a new SSL bufferevent.
 
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+Functions

+EVENT2_EXPORT_SYMBOL unsigned long bufferevent_get_mbedtls_error (struct bufferevent *bev)
 Return the most recent MbedTLS error reported on an SSL bufferevent.
 
+EVENT2_EXPORT_SYMBOL unsigned long bufferevent_get_openssl_error (struct bufferevent *bev)
 Return the most recent OpenSSL error reported on an SSL bufferevent.
 
+EVENT2_EXPORT_SYMBOL void bufferevent_mbedtls_dyncontext_free (mbedtls_dyncontext *ctx)
 Deallocate heap-based MbedTLS context.
 
+EVENT2_EXPORT_SYMBOL mbedtls_dyncontext * bufferevent_mbedtls_dyncontext_new (struct mbedtls_ssl_config *conf)
 Create a new heap-based MbedTLS context for use it in bufferevent_mbedtls_* functions.
 
EVENT2_EXPORT_SYMBOL struct buffereventbufferevent_mbedtls_filter_new (struct event_base *base, struct bufferevent *underlying, mbedtls_dyncontext *ssl, enum bufferevent_ssl_state state, int options)
 Create a new SSL bufferevent to send its data over another bufferevent. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_mbedtls_get_allow_dirty_shutdown (struct bufferevent *bev)
 Get value of the BUFFEREVENT_SSL_DIRTY_SHUTDOWN flag. More...
 
+EVENT2_EXPORT_SYMBOL struct mbedtls_ssl_context * bufferevent_mbedtls_get_ssl (struct bufferevent *bufev)
 Return the underlying mbedtls SSL * object for an SSL bufferevent.
 
+EVENT2_EXPORT_SYMBOL int bufferevent_mbedtls_renegotiate (struct bufferevent *bev)
 Tells a bufferevent to begin SSL renegotiation.
 
EVENT2_EXPORT_SYMBOL void bufferevent_mbedtls_set_allow_dirty_shutdown (struct bufferevent *bev, int allow_dirty_shutdown)
 Set value of the BUFFEREVENT_SSL_DIRTY_SHUTDOWN flag. More...
 
EVENT2_EXPORT_SYMBOL struct buffereventbufferevent_mbedtls_socket_new (struct event_base *base, evutil_socket_t fd, mbedtls_dyncontext *ssl, enum bufferevent_ssl_state state, int options)
 Create a new SSL bufferevent to send its data over an SSL * on a socket. More...
 
EVENT2_EXPORT_SYMBOL struct buffereventbufferevent_openssl_filter_new (struct event_base *base, struct bufferevent *underlying, struct ssl_st *ssl, enum bufferevent_ssl_state state, int options)
 Create a new SSL bufferevent to send its data over another bufferevent. More...
 
EVENT2_EXPORT_SYMBOL int bufferevent_openssl_get_allow_dirty_shutdown (struct bufferevent *bev)
 Get value of the BUFFEREVENT_SSL_DIRTY_SHUTDOWN flag. More...
 
+EVENT2_EXPORT_SYMBOL struct ssl_st * bufferevent_openssl_get_ssl (struct bufferevent *bufev)
 Return the underlying openssl SSL * object for an SSL bufferevent.
 
EVENT2_EXPORT_SYMBOL void bufferevent_openssl_set_allow_dirty_shutdown (struct bufferevent *bev, int allow_dirty_shutdown)
 Set value of the BUFFEREVENT_SSL_DIRTY_SHUTDOWN flag. More...
 
EVENT2_EXPORT_SYMBOL struct buffereventbufferevent_openssl_socket_new (struct event_base *base, evutil_socket_t fd, struct ssl_st *ssl, enum bufferevent_ssl_state state, int options)
 Create a new SSL bufferevent to send its data over an SSL * on a socket. More...
 
+EVENT2_EXPORT_SYMBOL int bufferevent_ssl_renegotiate (struct bufferevent *bev)
 Tells a bufferevent to begin SSL renegotiation.
 
+

Detailed Description

+

OpenSSL support for bufferevents.

+

Macro Definition Documentation

+ +

◆ BUFFEREVENT_SSL_BATCH_WRITE

+ +
+
+ + + + +
#define BUFFEREVENT_SSL_BATCH_WRITE   2
+
+ +

Control writes in the SSL bufferevents.

+

By default SSL bufferevent will peek bytes from the buffer as the arrived. with respect to the segment boundaries in the buffer. However, by ignoring these segment boundaries number of packets to send can be decreased.

+

This flags will ignore the segment boundaries.

+

Useful in conjunction with http layer.

+ +
+
+ +

◆ BUFFEREVENT_SSL_DIRTY_SHUTDOWN

+ +
+
+ + + + +
#define BUFFEREVENT_SSL_DIRTY_SHUTDOWN   1
+
+ +

Control how to report dirty SSL shutdowns.

+

If the peer (or the network, or an attacker) closes the TCP connection before closing the SSL channel, and the protocol is SSL >= v3, this is a "dirty" shutdown. If BUFFEREVENT_SSL_DIRTY_SHUTDOWN is not set (default), this is reported as BEV_EVENT_ERROR.

+

If instead BUFFEREVENT_SSL_DIRTY_SHUTDOWN is set, a dirty shutdown is reported as BEV_EVENT_EOF.

+

(Note that if the protocol is < SSLv3, you will always receive BEV_EVENT_EOF, since SSL 2 and earlier cannot distinguish a secure connection close from a dirty one. This is one reason (among many) not to use SSL 2.)

+ +
+
+

Function Documentation

+ +

◆ bufferevent_mbedtls_filter_new()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct bufferevent* bufferevent_mbedtls_filter_new (struct event_basebase,
struct buffereventunderlying,
mbedtls_dyncontext * ssl,
enum bufferevent_ssl_state state,
int options 
)
+
+ +

Create a new SSL bufferevent to send its data over another bufferevent.

+
Parameters
+ + + + + + +
baseAn event_base to use to detect reading and writing. It must also be the base for the underlying bufferevent.
underlyingA socket to use for this SSL
sslA SSL* object from openssl.
stateThe current state of the SSL connection
optionsOne or more bufferevent_options
+
+
+
Returns
A new bufferevent on success, or NULL on failure
+ +
+
+ +

◆ bufferevent_mbedtls_get_allow_dirty_shutdown()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_mbedtls_get_allow_dirty_shutdown (struct buffereventbev)
+
+ +

Get value of the BUFFEREVENT_SSL_DIRTY_SHUTDOWN flag.

+
See also
BUFFEREVENT_SSL_DIRTY_SHUTDOWN
+
Deprecated:
This function is deprecated, use bufferevent_ssl_get_flags() instead.
+
See also
bufferevent_ssl_get_flags()
+ +
+
+ +

◆ bufferevent_mbedtls_set_allow_dirty_shutdown()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void bufferevent_mbedtls_set_allow_dirty_shutdown (struct buffereventbev,
int allow_dirty_shutdown 
)
+
+ +

Set value of the BUFFEREVENT_SSL_DIRTY_SHUTDOWN flag.

+
See also
BUFFEREVENT_SSL_DIRTY_SHUTDOWN
+
Deprecated:
This function is deprecated, use bufferevent_ssl_set_flags() instead.
+
See also
bufferevent_ssl_set_flags()
+ +
+
+ +

◆ bufferevent_mbedtls_socket_new()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct bufferevent* bufferevent_mbedtls_socket_new (struct event_basebase,
evutil_socket_t fd,
mbedtls_dyncontext * ssl,
enum bufferevent_ssl_state state,
int options 
)
+
+ +

Create a new SSL bufferevent to send its data over an SSL * on a socket.

+
Parameters
+ + + + + + +
baseAn event_base to use to detect reading and writing
fdA socket to use for this SSL
sslA SSL* object from mbedtls.
stateThe current state of the SSL connection
optionsOne or more bufferevent_options
+
+
+
Returns
A new bufferevent on success, or NULL on failure.
+ +
+
+ +

◆ bufferevent_openssl_filter_new()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct bufferevent* bufferevent_openssl_filter_new (struct event_basebase,
struct buffereventunderlying,
struct ssl_st * ssl,
enum bufferevent_ssl_state state,
int options 
)
+
+ +

Create a new SSL bufferevent to send its data over another bufferevent.

+
Parameters
+ + + + + + +
baseAn event_base to use to detect reading and writing. It must also be the base for the underlying bufferevent.
underlyingA socket to use for this SSL
sslA SSL* object from openssl.
stateThe current state of the SSL connection
optionsOne or more bufferevent_options
+
+
+
Returns
A new bufferevent on success, or NULL on failure
+ +
+
+ +

◆ bufferevent_openssl_get_allow_dirty_shutdown()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int bufferevent_openssl_get_allow_dirty_shutdown (struct buffereventbev)
+
+ +

Get value of the BUFFEREVENT_SSL_DIRTY_SHUTDOWN flag.

+
See also
BUFFEREVENT_SSL_DIRTY_SHUTDOWN
+
Deprecated:
This function is deprecated, use bufferevent_ssl_get_flags() instead.
+
See also
bufferevent_ssl_get_flags()
+ +
+
+ +

◆ bufferevent_openssl_set_allow_dirty_shutdown()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void bufferevent_openssl_set_allow_dirty_shutdown (struct buffereventbev,
int allow_dirty_shutdown 
)
+
+ +

Set value of the BUFFEREVENT_SSL_DIRTY_SHUTDOWN flag.

+
See also
BUFFEREVENT_SSL_DIRTY_SHUTDOWN
+
Deprecated:
This function is deprecated, use bufferevent_ssl_set_flags() instead.
+
See also
bufferevent_ssl_set_flags()
+ +
+
+ +

◆ bufferevent_openssl_socket_new()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct bufferevent* bufferevent_openssl_socket_new (struct event_basebase,
evutil_socket_t fd,
struct ssl_st * ssl,
enum bufferevent_ssl_state state,
int options 
)
+
+ +

Create a new SSL bufferevent to send its data over an SSL * on a socket.

+
Parameters
+ + + + + + +
baseAn event_base to use to detect reading and writing
fdA socket to use for this SSL
sslA SSL* object from openssl.
stateThe current state of the SSL connection
optionsOne or more bufferevent_options
+
+
+
Returns
A new bufferevent on success, or NULL on failure.
+ +
+
+
+ + + + diff --git a/bufferevent__ssl_8h_source.html b/bufferevent__ssl_8h_source.html new file mode 100644 index 0000000..620f7a7 --- /dev/null +++ b/bufferevent__ssl_8h_source.html @@ -0,0 +1,251 @@ + + + + + + + +libevent: event2/bufferevent_ssl.h Source File + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
bufferevent_ssl.h
+
+
+Go to the documentation of this file.
1 /*
+
2  * Copyright (c) 2009-2012 Niels Provos and Nick Mathewson
+
3  *
+
4  * Redistribution and use in source and binary forms, with or without
+
5  * modification, are permitted provided that the following conditions
+
6  * are met:
+
7  * 1. Redistributions of source code must retain the above copyright
+
8  * notice, this list of conditions and the following disclaimer.
+
9  * 2. Redistributions in binary form must reproduce the above copyright
+
10  * notice, this list of conditions and the following disclaimer in the
+
11  * documentation and/or other materials provided with the distribution.
+
12  * 3. The name of the author may not be used to endorse or promote products
+
13  * derived from this software without specific prior written permission.
+
14  *
+
15  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+
16  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+
17  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+
18  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+
19  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+
20  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+
21  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+
22  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+
23  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+
24  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
25  */
+
26 #ifndef EVENT2_BUFFEREVENT_SSL_H_INCLUDED_
+
27 #define EVENT2_BUFFEREVENT_SSL_H_INCLUDED_
+
28 
+
33 #include <event2/visibility.h>
+
34 #include <event2/event-config.h>
+
35 #include <event2/bufferevent.h>
+
36 #include <event2/util.h>
+
37 
+
38 #ifdef __cplusplus
+
39 extern "C" {
+
40 #endif
+
41 
+ +
47  BUFFEREVENT_SSL_OPEN = 0,
+
48  BUFFEREVENT_SSL_CONNECTING = 1,
+
49  BUFFEREVENT_SSL_ACCEPTING = 2
+
50 };
+
51 
+
67 #define BUFFEREVENT_SSL_DIRTY_SHUTDOWN 1
+
68 
+
79 #define BUFFEREVENT_SSL_BATCH_WRITE 2
+
80 
+
81 #if defined(EVENT__HAVE_OPENSSL) || defined(EVENT__HAVE_MBEDTLS)
+
82 
+
88 EVENT2_EXPORT_SYMBOL
+
89 ev_uint64_t bufferevent_ssl_get_flags(struct bufferevent *bev);
+
96 EVENT2_EXPORT_SYMBOL
+
97 ev_uint64_t bufferevent_ssl_set_flags(struct bufferevent *bev, ev_uint64_t flags);
+
104 EVENT2_EXPORT_SYMBOL
+
105 ev_uint64_t bufferevent_ssl_clear_flags(struct bufferevent *bev, ev_uint64_t flags);
+
106 
+
107 #endif /* defined(EVENT__HAVE_OPENSSL) || defined(EVENT__HAVE_MBEDTLS) */
+
108 
+
109 #if defined(EVENT__HAVE_OPENSSL) || defined(EVENT_IN_DOXYGEN_)
+
110 /* This is what openssl's SSL objects are underneath. */
+
111 struct ssl_st;
+
112 
+
124 EVENT2_EXPORT_SYMBOL
+
125 struct bufferevent *
+ +
127  struct bufferevent *underlying,
+
128  struct ssl_st *ssl,
+
129  enum bufferevent_ssl_state state,
+
130  int options);
+
131 
+
142 EVENT2_EXPORT_SYMBOL
+
143 struct bufferevent *
+ +
145  evutil_socket_t fd,
+
146  struct ssl_st *ssl,
+
147  enum bufferevent_ssl_state state,
+
148  int options);
+
149 
+
157 EVENT2_EXPORT_SYMBOL
+ +
166 EVENT2_EXPORT_SYMBOL
+ +
168  int allow_dirty_shutdown);
+
169 
+
171 EVENT2_EXPORT_SYMBOL
+
172 struct ssl_st *
+ +
174 
+
176 EVENT2_EXPORT_SYMBOL
+ +
178 
+
180 EVENT2_EXPORT_SYMBOL
+
181 unsigned long bufferevent_get_openssl_error(struct bufferevent *bev);
+
182 
+
183 #endif
+
184 #if defined(EVENT__HAVE_MBEDTLS) || defined(EVENT_IN_DOXYGEN_)
+
185 struct mbedtls_ssl_context;
+
186 struct mbedtls_ssl_config;
+
187 typedef struct mbedtls_ssl_context mbedtls_dyncontext;
+
188 
+
200 EVENT2_EXPORT_SYMBOL
+
201 struct bufferevent *
+ +
203  struct bufferevent *underlying,
+
204  mbedtls_dyncontext *ssl,
+
205  enum bufferevent_ssl_state state,
+
206  int options);
+
207 
+
218 EVENT2_EXPORT_SYMBOL
+
219 struct bufferevent *
+ +
221  evutil_socket_t fd,
+
222  mbedtls_dyncontext *ssl,
+
223  enum bufferevent_ssl_state state,
+
224  int options);
+
225 
+
233 EVENT2_EXPORT_SYMBOL
+ +
242 EVENT2_EXPORT_SYMBOL
+ +
244  int allow_dirty_shutdown);
+
245 
+
247 EVENT2_EXPORT_SYMBOL
+
248 struct mbedtls_ssl_context *
+ +
250 
+
252 EVENT2_EXPORT_SYMBOL
+ +
254 
+
256 EVENT2_EXPORT_SYMBOL
+
257 unsigned long bufferevent_get_mbedtls_error(struct bufferevent *bev);
+
258 
+
260 EVENT2_EXPORT_SYMBOL
+
261 mbedtls_dyncontext *
+
262 bufferevent_mbedtls_dyncontext_new(struct mbedtls_ssl_config *conf);
+
263 
+
265 EVENT2_EXPORT_SYMBOL
+
266 void
+
267 bufferevent_mbedtls_dyncontext_free(mbedtls_dyncontext *ctx);
+
268 
+
269 #endif
+
270 
+
271 #ifdef __cplusplus
+
272 }
+
273 #endif
+
274 
+
275 #endif /* EVENT2_BUFFEREVENT_SSL_H_INCLUDED_ */
+
+
bufferevent_mbedtls_get_ssl
EVENT2_EXPORT_SYMBOL struct mbedtls_ssl_context * bufferevent_mbedtls_get_ssl(struct bufferevent *bufev)
Return the underlying mbedtls SSL * object for an SSL bufferevent.
+
bufferevent_openssl_get_allow_dirty_shutdown
EVENT2_EXPORT_SYMBOL int bufferevent_openssl_get_allow_dirty_shutdown(struct bufferevent *bev)
Get value of the BUFFEREVENT_SSL_DIRTY_SHUTDOWN flag.
+
bufferevent_get_mbedtls_error
EVENT2_EXPORT_SYMBOL unsigned long bufferevent_get_mbedtls_error(struct bufferevent *bev)
Return the most recent MbedTLS error reported on an SSL bufferevent.
+
bufferevent_mbedtls_get_allow_dirty_shutdown
EVENT2_EXPORT_SYMBOL int bufferevent_mbedtls_get_allow_dirty_shutdown(struct bufferevent *bev)
Get value of the BUFFEREVENT_SSL_DIRTY_SHUTDOWN flag.
+
bufferevent_ssl_state
bufferevent_ssl_state
The state of an SSL object to be used when creating a new SSL bufferevent.
Definition: bufferevent_ssl.h:46
+
event_base
Structure to hold information and state for a Libevent dispatch loop.
Definition: event.h:219
+
bufferevent_mbedtls_dyncontext_free
EVENT2_EXPORT_SYMBOL void bufferevent_mbedtls_dyncontext_free(mbedtls_dyncontext *ctx)
Deallocate heap-based MbedTLS context.
+
bufferevent_openssl_filter_new
EVENT2_EXPORT_SYMBOL struct bufferevent * bufferevent_openssl_filter_new(struct event_base *base, struct bufferevent *underlying, struct ssl_st *ssl, enum bufferevent_ssl_state state, int options)
Create a new SSL bufferevent to send its data over another bufferevent.
+
bufferevent
An opaque type for handling buffered IO.
Definition: bufferevent.h:114
+
bufferevent_ssl_renegotiate
EVENT2_EXPORT_SYMBOL int bufferevent_ssl_renegotiate(struct bufferevent *bev)
Tells a bufferevent to begin SSL renegotiation.
+
bufferevent_mbedtls_filter_new
EVENT2_EXPORT_SYMBOL struct bufferevent * bufferevent_mbedtls_filter_new(struct event_base *base, struct bufferevent *underlying, mbedtls_dyncontext *ssl, enum bufferevent_ssl_state state, int options)
Create a new SSL bufferevent to send its data over another bufferevent.
+
bufferevent_openssl_socket_new
EVENT2_EXPORT_SYMBOL struct bufferevent * bufferevent_openssl_socket_new(struct event_base *base, evutil_socket_t fd, struct ssl_st *ssl, enum bufferevent_ssl_state state, int options)
Create a new SSL bufferevent to send its data over an SSL * on a socket.
+
bufferevent_mbedtls_socket_new
EVENT2_EXPORT_SYMBOL struct bufferevent * bufferevent_mbedtls_socket_new(struct event_base *base, evutil_socket_t fd, mbedtls_dyncontext *ssl, enum bufferevent_ssl_state state, int options)
Create a new SSL bufferevent to send its data over an SSL * on a socket.
+
bufferevent_mbedtls_set_allow_dirty_shutdown
EVENT2_EXPORT_SYMBOL void bufferevent_mbedtls_set_allow_dirty_shutdown(struct bufferevent *bev, int allow_dirty_shutdown)
Set value of the BUFFEREVENT_SSL_DIRTY_SHUTDOWN flag.
+
bufferevent.h
Functions for buffering data for network sending or receiving.
+
bufferevent_openssl_set_allow_dirty_shutdown
EVENT2_EXPORT_SYMBOL void bufferevent_openssl_set_allow_dirty_shutdown(struct bufferevent *bev, int allow_dirty_shutdown)
Set value of the BUFFEREVENT_SSL_DIRTY_SHUTDOWN flag.
+
bufferevent_mbedtls_renegotiate
EVENT2_EXPORT_SYMBOL int bufferevent_mbedtls_renegotiate(struct bufferevent *bev)
Tells a bufferevent to begin SSL renegotiation.
+
util.h
Common convenience functions for cross-platform portability and related socket manipulations.
+
bufferevent_mbedtls_dyncontext_new
EVENT2_EXPORT_SYMBOL mbedtls_dyncontext * bufferevent_mbedtls_dyncontext_new(struct mbedtls_ssl_config *conf)
Create a new heap-based MbedTLS context for use it in bufferevent_mbedtls_* functions.
+
bufferevent_get_openssl_error
EVENT2_EXPORT_SYMBOL unsigned long bufferevent_get_openssl_error(struct bufferevent *bev)
Return the most recent OpenSSL error reported on an SSL bufferevent.
+
bufferevent_openssl_get_ssl
EVENT2_EXPORT_SYMBOL struct ssl_st * bufferevent_openssl_get_ssl(struct bufferevent *bufev)
Return the underlying openssl SSL * object for an SSL bufferevent.
+
evutil_socket_t
#define evutil_socket_t
A type wide enough to hold the output of "socket()" or "accept()".
Definition: util.h:325
+ + + + diff --git a/classes.html b/classes.html new file mode 100644 index 0000000..799fa29 --- /dev/null +++ b/classes.html @@ -0,0 +1,106 @@ + + + + + + + +libevent: Data Structure Index + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+
Data Structure Index
+
+
+
b | e
+ + + + + + + + + + + + + + + + + + + + + + + +
  b  
+
evbuffer_cb_info   event_base   evthread_lock_callbacks   
evbuffer_iovec   event_config   evutil_addrinfo   
bufferevent   evbuffer_ptr   evhttp_ext_method   evutil_monotonic_timer   
  e  
+
event   evthread_condition_callbacks   
evbuffer   
+
b | e
+
+ + + + diff --git a/closed.png b/closed.png new file mode 100644 index 0000000..98cc2c9 Binary files /dev/null and b/closed.png differ diff --git a/deprecated.html b/deprecated.html new file mode 100644 index 0000000..2af42f7 --- /dev/null +++ b/deprecated.html @@ -0,0 +1,167 @@ + + + + + + + +libevent: Deprecated List + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ +
+
+
+
Deprecated List
+
+
+
+
Global bufferevent_mbedtls_get_allow_dirty_shutdown (struct bufferevent *bev)
+
This function is deprecated, use bufferevent_ssl_get_flags() instead.
+
Global bufferevent_mbedtls_set_allow_dirty_shutdown (struct bufferevent *bev, int allow_dirty_shutdown)
+
This function is deprecated, use bufferevent_ssl_set_flags() instead.
+
Global bufferevent_new (evutil_socket_t fd, evbuffercb readcb, evbuffercb writecb, everrorcb errorcb, void *cbarg)
+
This function is deprecated because it uses the current event base, and as such can be error prone for multithreaded programs. Use bufferevent_socket_new() instead.
+
Global bufferevent_openssl_get_allow_dirty_shutdown (struct bufferevent *bev)
+
This function is deprecated, use bufferevent_ssl_get_flags() instead.
+
Global bufferevent_openssl_set_allow_dirty_shutdown (struct bufferevent *bev, int allow_dirty_shutdown)
+
This function is deprecated, use bufferevent_ssl_set_flags() instead.
+
Global bufferevent_settimeout (struct bufferevent *bufev, int timeout_read, int timeout_write)
+
Use bufferevent_set_timeouts instead.
+
Global evbuffer_readline (struct evbuffer *buffer)
+
This function is deprecated because its behavior is not correct for almost any protocol, and also because it's wholly subsumed by evbuffer_readln().
+
Global evbuffer_setcb (struct evbuffer *buffer, evbuffer_cb cb, void *cbarg)
+
This function is deprecated because it clears all previous callbacks set on the evbuffer, which can cause confusing behavior if multiple parts of the code all want to add their own callbacks on a buffer. Instead, use evbuffer_add(), evbuffer_del(), and evbuffer_setflags() to manage your own evbuffer callbacks without interfering with callbacks set by others.
+
Global evdns_add_server_port (evutil_socket_t socket, int flags, evdns_request_callback_fn_type callback, void *user_data)
+
This function is deprecated because it does not allow the caller to specify which even_base it uses. The recommended function is evdns_add_server_port_with_base().
+
Global evdns_clear_nameservers_and_suspend (void)
+
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_clear_nameservers_and_suspend().
+
Global evdns_count_nameservers (void)
+
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_count_nameservers().
+
Global evdns_get_global_base (void)
+
This function is deprecated because use of the global evdns_base is error-prone.
+
Global evdns_init (void)
+
This function is deprecated because it always uses the current event base, and is easily confused by multiple calls to event_init(), and so is not safe for multithreaded use. Additionally, it allocates a global structure that only one thread can use. The replacement is evdns_base_new().
+
Global evdns_nameserver_add (unsigned long int address)
+
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_nameserver_add().
+
Global evdns_nameserver_ip_add (const char *ip_as_string)
+
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_nameserver_ip_add().
+
Global evdns_resolv_conf_parse (int flags, const char *const filename)
+
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_resolv_conf_parse().
+
Global evdns_resolve_ipv4 (const char *name, int flags, evdns_callback_type callback, void *ptr)
+
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_resolve_ipv4().
+
Global evdns_resolve_reverse (const struct in_addr *in, int flags, evdns_callback_type callback, void *ptr)
+
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_resolve_reverse().
+
Global evdns_resolve_reverse_ipv6 (const struct in6_addr *in, int flags, evdns_callback_type callback, void *ptr)
+
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_resolve_reverse_ipv6().
+
Global evdns_resume (void)
+
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_resume().
+
Global evdns_search_add (const char *domain)
+
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_search_add().
+
Global evdns_search_clear (void)
+
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_search_clear().
+
Global evdns_search_ndots_set (const int ndots)
+
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_search_ndots_set().
+
Global evdns_set_option (const char *option, const char *val, int flags)
+
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_set_option().
+
Global evdns_shutdown (int fail_requests)
+
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_shutdown().
+
File event_compat.h
+
All functions in this file are by definition deprecated.
+
Global event_dispatch (void)
+
This function is deprecated because it is easily confused by multiple calls to event_init(), and because it is not safe for multithreaded use. The replacement is event_base_dispatch().
+
Global event_get_method (void)
+
This function is obsolete, and has been replaced by event_base_get_method(). Its use is deprecated because it relies on the "current" base configured by event_init().
+
Global event_init (void)
+
This function is deprecated because it replaces the "current" event_base, and is totally unsafe for multithreaded use. The replacement is event_base_new().
+
Global event_loop (int)
+
This function is deprecated because it uses the event base from the last call to event_init, and is therefore not safe for multithreaded use. The replacement is event_base_loop().
+
Global event_loopbreak (void)
+
This function is deprecated because it uses the event base from the last call to event_init, and is therefore not safe for multithreaded use. The replacement is event_base_loopbreak().
+
Global event_loopexit (const struct timeval *)
+
This function is deprecated because it uses the event base from the last call to event_init, and is therefore not safe for multithreaded use. The replacement is event_base_loopexit().
+
Global event_once (evutil_socket_t, short, void(*)(evutil_socket_t, short, void *), void *, const struct timeval *)
+
This function is obsolete, and has been replaced by event_base_once(). Its use is deprecated because it relies on the "current" base configured by event_init().
+
Global event_priority_init (int)
+
This function is deprecated because it is easily confused by multiple calls to event_init(), and because it is not safe for multithreaded use. The replacement is event_base_priority_init().
+
Global event_set (struct event *, evutil_socket_t, short, void(*)(evutil_socket_t, short, void *), void *)
+
event_set() is not recommended for new code, because it requires a subsequent call to event_base_set() to be safe under most circumstances. Use event_assign() or event_new() instead.
+
Global evhttp_connection_new (const char *address, ev_uint16_t port)
+
It does not allow an event base to be specified
+
Global evhttp_connection_set_base (struct evhttp_connection *evcon, struct event_base *base)
+
XXXX Why?
+
Global evhttp_decode_uri (const char *uri)
+
This function is deprecated; you probably want to use evhttp_uridecode instead.
+
Global evhttp_parse_query (const char *uri, struct evkeyvalq *headers)
+
This function is deprecated as of Libevent 2.0.9. Use evhttp_uri_parse and evhttp_parse_query_str instead.
+
Global evhttp_start (const char *address, ev_uint16_t port)
+
It does not allow an event base to be specified
+
Module Misnamed functions
+
These macros are deprecated because their names don't follow Libevent's naming conventions.
+
Module signal_* macros
+
These macros are deprecated because their naming is inconsistent with the rest of Libevent.
+
Module timeout_* macros
+
These macros are deprecated because their naming is inconsistent with the rest of Libevent.
+
+
+
+ + + + diff --git a/dir_db160b4728e6067cf5f9cc14ec42c79d.html b/dir_db160b4728e6067cf5f9cc14ec42c79d.html new file mode 100644 index 0000000..c85d672 --- /dev/null +++ b/dir_db160b4728e6067cf5f9cc14ec42c79d.html @@ -0,0 +1,143 @@ + + + + + + + +libevent: event2 Directory Reference + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
event2 Directory Reference
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+Files

file  buffer.h [code]
 Functions for buffering data for network sending or receiving.
 
file  buffer_compat.h [code]
 Obsolete and deprecated versions of the functions in buffer.h: provided only for backward compatibility.
 
file  bufferevent.h [code]
 Functions for buffering data for network sending or receiving.
 
file  bufferevent_compat.h [code]
 Deprecated versions of the functions in bufferevent.h: provided only for backwards compatibility.
 
file  bufferevent_ssl.h [code]
 OpenSSL support for bufferevents.
 
file  dns.h [code]
 Provides a few APIs to use for resolving DNS names, and a facility for implementing simple DNS servers.
 
file  dns_compat.h [code]
 Potentially non-threadsafe versions of the functions in dns.h: provided only for backwards compatibility.
 
file  event.h [code]
 Core functions for waiting for and receiving events, and using event bases.
 
file  event_compat.h [code]
 Potentially non-threadsafe versions of the functions in event.h: provided only for backwards compatibility.
 
file  http.h [code]
 Basic support for HTTP serving.
 
file  http_compat.h [code]
 Potentially non-threadsafe versions of the functions in http.h: provided only for backwards compatibility.
 
file  listener.h [code]
 A callback that we invoke when a listener has a new connection.
 
file  rpc.h [code]
 This header files provides basic support for an RPC server and client.
 
file  rpc_compat.h [code]
 Deprecated versions of the functions in rpc.h: provided only for backwards compatibility.
 
file  tag.h [code]
 Helper functions for reading and writing tagged data onto buffers.
 
file  tag_compat.h [code]
 Obsolete/deprecated functions from tag.h; provided only for backwards compatibility.
 
file  thread.h [code]
 Functions for multi-threaded applications using Libevent.
 
file  util.h [code]
 Common convenience functions for cross-platform portability and related socket manipulations.
 
file  watch.h [code]
 "Prepare" and "check" watchers.
 
+
+ + + + diff --git a/dns_8h.html b/dns_8h.html new file mode 100644 index 0000000..1359eec --- /dev/null +++ b/dns_8h.html @@ -0,0 +1,1957 @@ + + + + + + + +libevent: event2/dns.h File Reference + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+Macros | +Typedefs | +Enumerations | +Functions
+
+
dns.h File Reference
+
+
+ +

Provides a few APIs to use for resolving DNS names, and a facility for implementing simple DNS servers. +More...

+
#include <event2/visibility.h>
+#include <event2/util.h>
+
+

Go to the source code of this file.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+Macros

+#define DNS_CNAME   4
 
+#define DNS_CNAME_CALLBACK   0x80
 Make a separate callback for CNAME in answer.
 
+#define DNS_ERR_CANCEL   69
 The request was canceled via a call to evdns_cancel_request.
 
+#define DNS_ERR_FORMAT   1
 The name server was unable to interpret the query.
 
#define DNS_ERR_NODATA   70
 There were no answers and no error condition in the DNS packet. More...
 
+#define DNS_ERR_NONE   0
 Error codes 0-5 are as described in RFC 1035.
 
+#define DNS_ERR_NOTEXIST   3
 The domain name does not exist.
 
+#define DNS_ERR_NOTIMPL   4
 The name server does not support the requested kind of query.
 
+#define DNS_ERR_REFUSED   5
 The name server refuses to reform the specified operation for policy reasons.
 
+#define DNS_ERR_SERVERFAILED   2
 The name server was unable to process this query due to a problem with the name server.
 
+#define DNS_ERR_SHUTDOWN   68
 The request was canceled because the DNS subsystem was shut down.
 
+#define DNS_ERR_TIMEOUT   67
 Communication with the server timed out.
 
+#define DNS_ERR_TRUNCATED   65
 The reply was truncated or ill-formatted.
 
+#define DNS_ERR_UNKNOWN   66
 An unknown error occurred.
 
+#define DNS_IPv4_A   1
 
+#define DNS_IPv6_AAAA   3
 
+#define DNS_NO_SEARCH   DNS_QUERY_NO_SEARCH
 
+#define DNS_OPTION_HOSTSFILE   8
 
+#define DNS_OPTION_MISC   4
 
+#define DNS_OPTION_NAMESERVERS   2
 
+#define DNS_OPTION_NAMESERVERS_NO_DEFAULT   16
 
+#define DNS_OPTION_SEARCH   1
 
#define DNS_OPTIONS_ALL
 All above: More...
 
+#define DNS_PTR   2
 
+#define DNS_QUERY_IGNTC   0x04
 Ignore truncation flag in responses (don't fallback to TCP connections).
 
+#define DNS_QUERY_NO_SEARCH   0x01
 Disable searching for the query.
 
+#define DNS_QUERY_USEVC   0x02
 Use TCP connections ("virtual circuits") for queries rather than UDP datagrams.
 
+#define EVDNS_ADDITIONAL_SECTION   2
 
+#define EVDNS_ANSWER_SECTION   0
 
+#define EVDNS_AUTHORITY_SECTION   1
 
+#define EVDNS_BASE_CONFIG_WINDOWS_NAMESERVERS_IMPLEMENTED
 
+#define EVDNS_BASE_DISABLE_WHEN_INACTIVE   0x8000
 Flag for evdns_base_new: Do not prevent the libevent event loop from exiting when we have no active dns requests.
 
#define EVDNS_BASE_INITIALIZE_NAMESERVERS   1
 Flag for evdns_base_new: process resolv.conf. More...
 
#define EVDNS_BASE_NAMESERVERS_NO_DEFAULT   0x10000
 Flag for evdns_base_new: If EVDNS_BASE_INITIALIZE_NAMESERVERS isset, do not add default nameserver if there are no nameservers in resolv.conf. More...
 
+#define EVDNS_BASE_NO_CACHE   0x10
 Flag for evdns_base_new: disable caching of DNS responses by default for async resolver.
 
+#define EVDNS_CLASS_INET   1
 
+#define EVDNS_ERROR_FAILED_TO_OPEN_FILE   1
 
+#define EVDNS_ERROR_FAILED_TO_STAT_FILE   2
 
+#define EVDNS_ERROR_FILE_TOO_LARGE   3
 
+#define EVDNS_ERROR_NO_NAMESERVERS_CONFIGURED   6
 
+#define EVDNS_ERROR_NONE   0
 
+#define EVDNS_ERROR_OUT_OF_MEMORY   4
 
+#define EVDNS_ERROR_SHORT_READ_FROM_FILE   5
 
+#define EVDNS_FLAGS_AA   0x400
 
+#define EVDNS_FLAGS_RD   0x080
 
+#define EVDNS_QTYPE_ALL   255
 
+#define EVDNS_QTYPE_AXFR   252
 
+#define EVDNS_TYPE_A   1
 
+#define EVDNS_TYPE_AAAA   28
 
+#define EVDNS_TYPE_CNAME   5
 
+#define EVDNS_TYPE_MX   15
 
+#define EVDNS_TYPE_NS   2
 
+#define EVDNS_TYPE_PTR   12
 
+#define EVDNS_TYPE_SOA   6
 
+#define EVDNS_TYPE_TXT   16
 
+ + + + + + + + + + + + + +

+Typedefs

typedef void(* evdns_callback_type) (int result, char type, int count, int ttl, void *addresses, void *arg)
 The callback that contains the results from a lookup. More...
 
typedef void(* evdns_debug_log_fn_type) (int is_warning, const char *msg)
 A callback that is invoked when a log message is generated. More...
 
+typedef void(* evdns_getaddrinfo_cb) (int result, struct evutil_addrinfo *res, void *arg)
 Callback for evdns_getaddrinfo.
 
typedef void(* evdns_request_callback_fn_type) (struct evdns_server_request *, void *)
 A callback to implement a DNS server. More...
 
+ + + + +

+Enumerations

enum  evdns_server_option { EVDNS_SOPT_TCP_MAX_CLIENTS, +EVDNS_SOPT_TCP_IDLE_TIMEOUT + }
 List of configurable evdns_server_port options. More...
 
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+Functions

EVENT2_EXPORT_SYMBOL struct evdns_server_port * evdns_add_server_port_with_base (struct event_base *base, evutil_socket_t socket, int flags, evdns_request_callback_fn_type callback, void *user_data)
 Create a new UDP DNS server port. More...
 
EVENT2_EXPORT_SYMBOL struct evdns_server_port * evdns_add_server_port_with_listener (struct event_base *base, struct evconnlistener *listener, int flags, evdns_request_callback_fn_type callback, void *user_data)
 Create a new TCP DNS server port. More...
 
EVENT2_EXPORT_SYMBOL void evdns_base_clear_host_addresses (struct evdns_base *base)
 Remove all hosts entries that have been loaded into the event_base via evdns_base_load_hosts or via event_base_resolv_conf_parse. More...
 
EVENT2_EXPORT_SYMBOL int evdns_base_clear_nameservers_and_suspend (struct evdns_base *base)
 Remove all configured nameservers, and suspend all pending resolves. More...
 
EVENT2_EXPORT_SYMBOL int evdns_base_config_windows_nameservers (struct evdns_base *)
 Obtain nameserver information using the Windows API. More...
 
EVENT2_EXPORT_SYMBOL int evdns_base_count_nameservers (struct evdns_base *base)
 Get the number of configured nameservers. More...
 
EVENT2_EXPORT_SYMBOL void evdns_base_free (struct evdns_base *base, int fail_requests)
 Shut down the asynchronous DNS resolver and terminate all active requests. More...
 
EVENT2_EXPORT_SYMBOL int evdns_base_get_nameserver_addr (struct evdns_base *base, int idx, struct sockaddr *sa, ev_socklen_t len)
 Retrieve the address of the 'idx'th configured nameserver. More...
 
EVENT2_EXPORT_SYMBOL int evdns_base_get_nameserver_fd (struct evdns_base *base, int idx)
 Retrieve the fd of the 'idx'th configured nameserver. More...
 
EVENT2_EXPORT_SYMBOL int evdns_base_load_hosts (struct evdns_base *base, const char *hosts_fname)
 Load an /etc/hosts-style file from 'hosts_fname' into 'base'. More...
 
EVENT2_EXPORT_SYMBOL int evdns_base_nameserver_add (struct evdns_base *base, unsigned long int address)
 Add a nameserver. More...
 
EVENT2_EXPORT_SYMBOL int evdns_base_nameserver_ip_add (struct evdns_base *base, const char *ip_as_string)
 Add a nameserver by string address. More...
 
+EVENT2_EXPORT_SYMBOL int evdns_base_nameserver_sockaddr_add (struct evdns_base *base, const struct sockaddr *sa, ev_socklen_t len, unsigned flags)
 Add a nameserver by sockaddr.
 
EVENT2_EXPORT_SYMBOL struct evdns_base * evdns_base_new (struct event_base *event_base, int flags)
 Initialize the asynchronous DNS library. More...
 
EVENT2_EXPORT_SYMBOL int evdns_base_resolv_conf_parse (struct evdns_base *base, int flags, const char *const filename)
 Parse a resolv.conf file. More...
 
EVENT2_EXPORT_SYMBOL struct evdns_request * evdns_base_resolve_ipv4 (struct evdns_base *base, const char *name, int flags, evdns_callback_type callback, void *ptr)
 Lookup an A record for a given name. More...
 
EVENT2_EXPORT_SYMBOL struct evdns_request * evdns_base_resolve_ipv6 (struct evdns_base *base, const char *name, int flags, evdns_callback_type callback, void *ptr)
 Lookup an AAAA record for a given name. More...
 
EVENT2_EXPORT_SYMBOL struct evdns_request * evdns_base_resolve_reverse (struct evdns_base *base, const struct in_addr *in, int flags, evdns_callback_type callback, void *ptr)
 Lookup a PTR record for a given IP address. More...
 
EVENT2_EXPORT_SYMBOL struct evdns_request * evdns_base_resolve_reverse_ipv6 (struct evdns_base *base, const struct in6_addr *in, int flags, evdns_callback_type callback, void *ptr)
 Lookup a PTR record for a given IPv6 address. More...
 
EVENT2_EXPORT_SYMBOL int evdns_base_resume (struct evdns_base *base)
 Resume normal operation and continue any suspended resolve requests. More...
 
EVENT2_EXPORT_SYMBOL void evdns_base_search_add (struct evdns_base *base, const char *domain)
 Add a domain to the list of search domains. More...
 
+EVENT2_EXPORT_SYMBOL void evdns_base_search_clear (struct evdns_base *base)
 Clear the list of search domains.
 
EVENT2_EXPORT_SYMBOL void evdns_base_search_ndots_set (struct evdns_base *base, const int ndots)
 Set the 'ndots' parameter for searches. More...
 
EVENT2_EXPORT_SYMBOL int evdns_base_set_option (struct evdns_base *base, const char *option, const char *val)
 Set the value of a configuration option. More...
 
EVENT2_EXPORT_SYMBOL int evdns_cache_lookup (struct evdns_base *base, const char *nodename, struct evutil_addrinfo *hints, ev_uint16_t port, struct evutil_addrinfo **res)
 Lookup an entry from the evdns cache. More...
 
EVENT2_EXPORT_SYMBOL void evdns_cache_write (struct evdns_base *dns_base, char *nodename, struct evutil_addrinfo *res, int ttl)
 Write an entry to the evdns cache. More...
 
EVENT2_EXPORT_SYMBOL void evdns_cancel_request (struct evdns_base *base, struct evdns_request *req)
 Cancels a pending DNS resolution request. More...
 
+EVENT2_EXPORT_SYMBOL void evdns_close_server_port (struct evdns_server_port *port)
 Close down a DNS server port, and free associated structures.
 
const EVENT2_EXPORT_SYMBOL char * evdns_err_to_string (int err)
 Convert a DNS error code to a string. More...
 
EVENT2_EXPORT_SYMBOL struct evdns_getaddrinfo_request * evdns_getaddrinfo (struct evdns_base *dns_base, const char *nodename, const char *servname, const struct evutil_addrinfo *hints_in, evdns_getaddrinfo_cb cb, void *arg)
 Make a non-blocking getaddrinfo request using the dns_base in 'dns_base'. More...
 
+EVENT2_EXPORT_SYMBOL void evdns_getaddrinfo_cancel (struct evdns_getaddrinfo_request *req)
 
EVENT2_EXPORT_SYMBOL int evdns_server_port_set_option (struct evdns_server_port *port, enum evdns_server_option option, size_t value)
 Configure DNS server. More...
 
+EVENT2_EXPORT_SYMBOL int evdns_server_request_add_a_reply (struct evdns_server_request *req, const char *name, int n, const void *addrs, int ttl)
 
+EVENT2_EXPORT_SYMBOL int evdns_server_request_add_aaaa_reply (struct evdns_server_request *req, const char *name, int n, const void *addrs, int ttl)
 
+EVENT2_EXPORT_SYMBOL int evdns_server_request_add_cname_reply (struct evdns_server_request *req, const char *name, const char *cname, int ttl)
 
+EVENT2_EXPORT_SYMBOL int evdns_server_request_add_ptr_reply (struct evdns_server_request *req, struct in_addr *in, const char *inaddr_name, const char *hostname, int ttl)
 
+EVENT2_EXPORT_SYMBOL int evdns_server_request_add_reply (struct evdns_server_request *req, int section, const char *name, int type, int dns_class, int ttl, int datalen, int is_name, const char *data)
 
+EVENT2_EXPORT_SYMBOL int evdns_server_request_drop (struct evdns_server_request *req)
 Free a DNS request without sending back a reply.
 
+EVENT2_EXPORT_SYMBOL int evdns_server_request_get_requesting_addr (struct evdns_server_request *req, struct sockaddr *sa, int addr_len)
 Get the address that made a DNS request.
 
+EVENT2_EXPORT_SYMBOL int evdns_server_request_respond (struct evdns_server_request *req, int err)
 Send back a response to a DNS request, and free the request structure.
 
EVENT2_EXPORT_SYMBOL void evdns_server_request_set_flags (struct evdns_server_request *req, int flags)
 Sets some flags in a reply we're building. More...
 
EVENT2_EXPORT_SYMBOL void evdns_set_log_fn (evdns_debug_log_fn_type fn)
 Set the callback function to handle DNS log messages. More...
 
+

Detailed Description

+

Provides a few APIs to use for resolving DNS names, and a facility for implementing simple DNS servers.

+

Welcome, gentle reader

+

Async DNS lookups are really a whole lot harder than they should be, mostly stemming from the fact that the libc resolver has never been very good at them. Before you use this library you should see if libc can do the job for you with the modern async call getaddrinfo_a (see http://www.imperialviolet.org/page25.html#e498). Otherwise, please continue.

+

The library keeps track of the state of nameservers and will avoid them when they go down. Otherwise it will round robin between them.

+

Quick start guide:

#include "evdns.h"
+
void callback(int result, char type, int count, int ttl,
+
void *addresses, void *arg);
+ +
evdns_resolve("www.hostname.com", 0, callback, NULL);
+

When the lookup is complete the callback function is called. The first argument will be one of the DNS_ERR_* defines in evdns.h. Hopefully it will be DNS_ERR_NONE, in which case type will be DNS_IPv4_A, count will be the number of IP addresses, ttl is the time which the data can be cached for (in seconds), addresses will point to an array of uint32_t's and arg will be whatever you passed to evdns_resolve.

+

Searching:

+

In order for this library to be a good replacement for glibc's resolver it supports searching. This involves setting a list of default domains, in which names will be queried for. The number of dots in the query name determines the order in which this list is used.

+

Searching appears to be a single lookup from the point of view of the API, although many DNS queries may be generated from a single call to evdns_resolve. Searching can also drastically slow down the resolution of names.

+

To disable searching:

    +
  1. Never set it up. If you never call evdns_resolv_conf_parse or evdns_search_add then no searching will occur.
  2. +
  3. If you do call evdns_resolv_conf_parse then don't pass DNS_OPTION_SEARCH (or DNS_OPTIONS_ALL, which implies it).
  4. +
  5. When calling evdns_resolve, pass the DNS_QUERY_NO_SEARCH flag.
  6. +
+

The order of searches depends on the number of dots in the name. If the number is greater than the ndots setting then the names is first tried globally. Otherwise each search domain is appended in turn.

+

The ndots setting can either be set from a resolv.conf, or by calling evdns_search_ndots_set.

+

For example, with ndots set to 1 (the default) and a search domain list of ["myhome.net"]:

+
+  Query: www
+  Order: www.myhome.net, www.
  Query: www.abc
+  Order: www.abc., www.abc.myhome.net
+ 

Internals:

+

Requests are kept in two queues. The first is the inflight queue. In this queue requests have an allocated transaction id and nameserver. They will soon be transmitted if they haven't already been.

+

The second is the waiting queue. The size of the inflight ring is limited and all other requests wait in waiting queue for space. This bounds the number of concurrent requests so that we don't flood the nameserver. Several algorithms require a full walk of the inflight queue and so bounding its size keeps thing going nicely under huge (many thousands of requests) loads.

+

If a nameserver loses too many requests it is considered down and we try not to use it. After a while we send a probe to that nameserver (a lookup for google.com) and, if it replies, we consider it working again. If the nameserver fails a probe we wait longer to try again with the next probe.

+

Macro Definition Documentation

+ +

◆ DNS_ERR_NODATA

+ +
+
+ + + + +
#define DNS_ERR_NODATA   70
+
+ +

There were no answers and no error condition in the DNS packet.

+

This can happen when you ask for an address that exists, but a record type that doesn't.

+ +
+
+ +

◆ DNS_OPTIONS_ALL

+ +
+
+ + + + +
#define DNS_OPTIONS_ALL
+
+Value:
( \
+
DNS_OPTION_SEARCH | \
+
DNS_OPTION_NAMESERVERS | \
+
DNS_OPTION_MISC | \
+
DNS_OPTION_HOSTSFILE | \
+
0 \
+
)
+
+

All above:

+
    +
  • DNS_OPTION_SEARCH
  • +
  • DNS_OPTION_NAMESERVERS
  • +
  • DNS_OPTION_MISC
  • +
  • DNS_OPTION_HOSTSFILE
  • +
+ +
+
+ +

◆ EVDNS_BASE_INITIALIZE_NAMESERVERS

+ +
+
+ + + + +
#define EVDNS_BASE_INITIALIZE_NAMESERVERS   1
+
+ +

Flag for evdns_base_new: process resolv.conf.

+


+

+ +
+
+ +

◆ EVDNS_BASE_NAMESERVERS_NO_DEFAULT

+ +
+
+ + + + +
#define EVDNS_BASE_NAMESERVERS_NO_DEFAULT   0x10000
+
+ +

Flag for evdns_base_new: If EVDNS_BASE_INITIALIZE_NAMESERVERS isset, do not add default nameserver if there are no nameservers in resolv.conf.

+
See also
DNS_OPTION_NAMESERVERS_NO_DEFAULT
+ +
+
+

Typedef Documentation

+ +

◆ evdns_callback_type

+ +
+
+ + + + +
typedef void(* evdns_callback_type) (int result, char type, int count, int ttl, void *addresses, void *arg)
+
+ +

The callback that contains the results from a lookup.

+
    +
  • result is one of the DNS_ERR_* values (DNS_ERR_NONE for success)
  • +
  • type is either DNS_IPv4_A or DNS_PTR or DNS_IPv6_AAAA
  • +
  • count contains the number of addresses of form type
  • +
  • ttl is the number of seconds the resolution may be cached for.
  • +
  • addresses needs to be cast according to type. It will be an array of 4-byte sequences for ipv4, or an array of 16-byte sequences for ipv6, or a nul-terminated string for PTR.
  • +
+ +
+
+ +

◆ evdns_debug_log_fn_type

+ +
+
+ + + + +
typedef void(* evdns_debug_log_fn_type) (int is_warning, const char *msg)
+
+ +

A callback that is invoked when a log message is generated.

+
Parameters
+ + + +
is_warningindicates if the log message is a 'warning'
msgthe content of the log message
+
+
+ +
+
+ +

◆ evdns_request_callback_fn_type

+ +
+
+ + + + +
typedef void(* evdns_request_callback_fn_type) (struct evdns_server_request *, void *)
+
+ +

A callback to implement a DNS server.

+

The callback function receives a DNS request. It should then optionally add a number of answers to the reply using the evdns_server_request_add_*_reply functions, before calling either evdns_server_request_respond to send the reply back, or evdns_server_request_drop to decline to answer the request.

+
Parameters
+ + + +
reqA newly received request
user_dataA pointer that was passed to evdns_add_server_port_with_base().
+
+
+ +
+
+

Enumeration Type Documentation

+ +

◆ evdns_server_option

+ +
+
+ + + + +
enum evdns_server_option
+
+ +

List of configurable evdns_server_port options.

+
See also
evdns_server_port_set_option()
+ + + +
Enumerator
EVDNS_SOPT_TCP_MAX_CLIENTS 

Maximum number of simultaneous tcp connections (clients) that server can hold.

+

Can be set only for TCP DNS servers.

+
EVDNS_SOPT_TCP_IDLE_TIMEOUT 

Idle timeout (in seconds) of incoming TCP connections.

+

If client doesn't send any requests via the connection during this period connection is closed by the server. Can be set only for TCP DNS servers.

+
+ +
+
+

Function Documentation

+ +

◆ evdns_add_server_port_with_base()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evdns_server_port* evdns_add_server_port_with_base (struct event_basebase,
evutil_socket_t socket,
int flags,
evdns_request_callback_fn_type callback,
void * user_data 
)
+
+ +

Create a new UDP DNS server port.

+
Parameters
+ + + + + + +
baseThe event base to handle events for the server port.
socketA UDP socket to accept DNS requests.
flagsAlways 0 for now.
callbackA function to invoke whenever we get a DNS request on the socket.
user_dataData to pass to the callback.
+
+
+
Returns
an evdns_server_port structure for this server port or NULL if an error occurred.
+ +
+
+ +

◆ evdns_add_server_port_with_listener()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evdns_server_port* evdns_add_server_port_with_listener (struct event_basebase,
struct evconnlistener * listener,
int flags,
evdns_request_callback_fn_type callback,
void * user_data 
)
+
+ +

Create a new TCP DNS server port.

+
Parameters
+ + + + + + +
baseThe event base to handle events for the server port.
listenerA TCP listener to accept DNS requests.
flagsAlways 0 for now.
callbackA function to invoke whenever we get a DNS request on the socket.
user_dataData to pass to the callback.
+
+
+
Returns
an evdns_server_port structure for this server port or NULL if an error occurred.
+ +
+
+ +

◆ evdns_base_clear_host_addresses()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void evdns_base_clear_host_addresses (struct evdns_base * base)
+
+ +

Remove all hosts entries that have been loaded into the event_base via evdns_base_load_hosts or via event_base_resolv_conf_parse.

+
Parameters
+ + +
basethe evdns base to remove outdated host addresses from
+
+
+ +
+
+ +

◆ evdns_base_clear_nameservers_and_suspend()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_base_clear_nameservers_and_suspend (struct evdns_base * base)
+
+ +

Remove all configured nameservers, and suspend all pending resolves.

+

Resolves will not necessarily be re-attempted until evdns_base_resume() is called.

+
Parameters
+ + +
basethe evdns_base to which to apply this operation
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
evdns_base_resume()
+ +
+
+ +

◆ evdns_base_config_windows_nameservers()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_base_config_windows_nameservers (struct evdns_base * )
+
+ +

Obtain nameserver information using the Windows API.

+

Attempt to configure a set of nameservers based on platform settings on a win32 host. Preferentially tries to use GetNetworkParams; if that fails, looks in the registry.

+
Returns
0 if successful, or -1 if an error occurred
+
See also
evdns_resolv_conf_parse()
+ +
+
+ +

◆ evdns_base_count_nameservers()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_base_count_nameservers (struct evdns_base * base)
+
+ +

Get the number of configured nameservers.

+

This returns the number of configured nameservers (not necessarily the number of running nameservers). This is useful for double-checking whether our calls to the various nameserver configuration functions have been successful.

+
Parameters
+ + +
basethe evdns_base to which to apply this operation
+
+
+
Returns
the number of configured nameservers
+
See also
evdns_base_nameserver_add()
+ +
+
+ +

◆ evdns_base_free()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evdns_base_free (struct evdns_base * base,
int fail_requests 
)
+
+ +

Shut down the asynchronous DNS resolver and terminate all active requests.

+

If the 'fail_requests' option is enabled, all active requests will return an empty result with the error flag set to DNS_ERR_SHUTDOWN. Otherwise, the requests will be silently discarded.

+
Parameters
+ + + +
basethe evdns base to free
fail_requestsif zero, active requests will be aborted; if non-zero, active requests will return DNS_ERR_SHUTDOWN.
+
+
+
See also
evdns_base_new()
+ +
+
+ +

◆ evdns_base_get_nameserver_addr()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_base_get_nameserver_addr (struct evdns_base * base,
int idx,
struct sockaddr * sa,
ev_socklen_t len 
)
+
+ +

Retrieve the address of the 'idx'th configured nameserver.

+
Parameters
+ + + + + +
baseThe evdns_base to examine.
idxThe index of the nameserver to get the address of.
saA location to receive the server's address.
lenThe number of bytes available at sa.
+
+
+
Returns
the number of bytes written into sa on success. On failure, returns -1 if idx is greater than the number of configured nameservers, or a value greater than 'len' if len was not high enough.
+ +
+
+ +

◆ evdns_base_get_nameserver_fd()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_base_get_nameserver_fd (struct evdns_base * base,
int idx 
)
+
+ +

Retrieve the fd of the 'idx'th configured nameserver.

+
Parameters
+ + + +
baseThe evdns_base to examine.
idxThe index of the nameserver to get the address of.
+
+
+
Returns
the fd value. On failure, returns -1 if idx is greater than the number of configured nameservers
+ +
+
+ +

◆ evdns_base_load_hosts()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_base_load_hosts (struct evdns_base * base,
const char * hosts_fname 
)
+
+ +

Load an /etc/hosts-style file from 'hosts_fname' into 'base'.

+

If hosts_fname is NULL, add minimal entries for localhost, and nothing else.

+

Note that only evdns_getaddrinfo uses the /etc/hosts entries.

+

This function does not replace previously loaded hosts entries; to do that, call evdns_base_clear_host_addresses first.

+

Return 0 on success, negative on failure.

+ +
+
+ +

◆ evdns_base_nameserver_add()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_base_nameserver_add (struct evdns_base * base,
unsigned long int address 
)
+
+ +

Add a nameserver.

+

The address should be an IPv4 address in network byte order. The type of address is chosen so that it matches in_addr.s_addr.

+
Parameters
+ + + +
basethe evdns_base to which to add the name server. base must not be NULL.
addressan IP address in network byte order
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
evdns_base_nameserver_ip_add()
+ +
+
+ +

◆ evdns_base_nameserver_ip_add()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_base_nameserver_ip_add (struct evdns_base * base,
const char * ip_as_string 
)
+
+ +

Add a nameserver by string address.

+

This function parses a n IPv4 or IPv6 address from a string and adds it as a nameserver. It supports the following formats:

    +
  • [IPv6Address]:port
  • +
  • [IPv6Address]
  • +
  • IPv6Address
  • +
  • IPv4Address:port
  • +
  • IPv4Address
  • +
+

If no port is specified, it defaults to 53.

+
Parameters
+ + +
basethe evdns_base to which to apply this operation. base must not be NULL
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
evdns_base_nameserver_add()
+ +
+
+ +

◆ evdns_base_new()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evdns_base* evdns_base_new (struct event_baseevent_base,
int flags 
)
+
+ +

Initialize the asynchronous DNS library.

+

This function initializes support for non-blocking name resolution by calling evdns_resolv_conf_parse() on UNIX and evdns_config_windows_nameservers() on Windows.

+
Parameters
+ + + +
event_basethe event base to associate the dns client with
flagsany of EVDNS_BASE_INITIALIZE_NAMESERVERS| EVDNS_BASE_DISABLE_WHEN_INACTIVE|EVDNS_BASE_NAMESERVERS_NO_DEFAULT| EVDNS_BASE_NO_CACHE
+
+
+
Returns
evdns_base object if successful, or NULL if an error occurred.
+
See also
evdns_base_free()
+ +
+
+ +

◆ evdns_base_resolv_conf_parse()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_base_resolv_conf_parse (struct evdns_base * base,
int flags,
const char *const filename 
)
+
+ +

Parse a resolv.conf file.

+

The 'flags' parameter determines what information is parsed from the resolv.conf file. See the man page for resolv.conf for the format of this file.

+

The following directives are not parsed from the file: sortlist, rotate, no-check-names, inet6, debug.

+

If this function encounters an error, the possible return values are: EVDNS_ERROR_FAILED_TO_OPEN_FILE (1) - failed to open file EVDNS_ERROR_FAILED_TO_STAT_FILE (2) - failed to stat file EVDNS_ERROR_FILE_TOO_LARGE (3) - file too large EVDNS_ERROR_OUT_OF_MEMORY (4) - out of memory EVDNS_ERROR_SHORT_READ_FROM_FILE (5) - short read from file EVDNS_ERROR_NO_NAMESERVERS_CONFIGURED (6) - no nameservers configured.

+
Parameters
+ + + + +
basethe evdns_base to which to apply this operation. base must not be NULL.
flagsany of DNS_OPTION_NAMESERVERS|DNS_OPTION_SEARCH|DNS_OPTION_MISC| DNS_OPTION_HOSTSFILE|DNS_OPTIONS_ALL|DNS_OPTION_NAMESERVERS_NO_DEFAULT
filenamethe path to the resolv.conf file
+
+
+
Returns
0 if successful, or various positive error codes if an error occurred (see above)
+
See also
resolv.conf(3), evdns_config_windows_nameservers()
+ +
+
+ +

◆ evdns_base_resolve_ipv4()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evdns_request* evdns_base_resolve_ipv4 (struct evdns_base * base,
const char * name,
int flags,
evdns_callback_type callback,
void * ptr 
)
+
+ +

Lookup an A record for a given name.

+
Parameters
+ + + + + + +
basethe evdns_base to which to apply this operation
namea DNS hostname
flagseither 0, or combination of DNS_QUERY_* flags.
callbacka callback function to invoke when the request is completed
ptran argument to pass to the callback function
+
+
+
Returns
an evdns_request object if successful, or NULL if an error occurred.
+
See also
evdns_resolve_ipv6(), evdns_resolve_reverse(), evdns_resolve_reverse_ipv6(), evdns_cancel_request()
+ +
+
+ +

◆ evdns_base_resolve_ipv6()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evdns_request* evdns_base_resolve_ipv6 (struct evdns_base * base,
const char * name,
int flags,
evdns_callback_type callback,
void * ptr 
)
+
+ +

Lookup an AAAA record for a given name.

+
Parameters
+ + + + + + +
basethe evdns_base to which to apply this operation
namea DNS hostname
flagseither 0, or combination of DNS_QUERY_* flags.
callbacka callback function to invoke when the request is completed
ptran argument to pass to the callback function
+
+
+
Returns
an evdns_request object if successful, or NULL if an error occurred.
+
See also
evdns_resolve_ipv4(), evdns_resolve_reverse(), evdns_resolve_reverse_ipv6(), evdns_cancel_request()
+ +
+
+ +

◆ evdns_base_resolve_reverse()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evdns_request* evdns_base_resolve_reverse (struct evdns_base * base,
const struct in_addr * in,
int flags,
evdns_callback_type callback,
void * ptr 
)
+
+ +

Lookup a PTR record for a given IP address.

+
Parameters
+ + + + + + +
basethe evdns_base to which to apply this operation
inan IPv4 address
flagseither 0, or combination of DNS_QUERY_* flags.
callbacka callback function to invoke when the request is completed
ptran argument to pass to the callback function
+
+
+
Returns
an evdns_request object if successful, or NULL if an error occurred.
+
See also
evdns_resolve_reverse_ipv6(), evdns_cancel_request()
+ +
+
+ +

◆ evdns_base_resolve_reverse_ipv6()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evdns_request* evdns_base_resolve_reverse_ipv6 (struct evdns_base * base,
const struct in6_addr * in,
int flags,
evdns_callback_type callback,
void * ptr 
)
+
+ +

Lookup a PTR record for a given IPv6 address.

+
Parameters
+ + + + + + +
basethe evdns_base to which to apply this operation
inan IPv6 address
flagseither 0, or combination of DNS_QUERY_* flags.
callbacka callback function to invoke when the request is completed
ptran argument to pass to the callback function
+
+
+
Returns
an evdns_request object if successful, or NULL if an error occurred.
+
See also
evdns_resolve_reverse_ipv6(), evdns_cancel_request()
+ +
+
+ +

◆ evdns_base_resume()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_base_resume (struct evdns_base * base)
+
+ +

Resume normal operation and continue any suspended resolve requests.

+

Re-attempt resolves left in limbo after an earlier call to evdns_base_clear_nameservers_and_suspend().

+
Parameters
+ + +
basethe evdns_base to which to apply this operation
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
evdns_base_clear_nameservers_and_suspend()
+ +
+
+ +

◆ evdns_base_search_add()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evdns_base_search_add (struct evdns_base * base,
const char * domain 
)
+
+ +

Add a domain to the list of search domains.

+
Parameters
+ + +
domainthe domain to be added to the search list
+
+
+ +
+
+ +

◆ evdns_base_search_ndots_set()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evdns_base_search_ndots_set (struct evdns_base * base,
const int ndots 
)
+
+ +

Set the 'ndots' parameter for searches.

+

Sets the number of dots which, when found in a name, causes the first query to be without any search domain.

+
Parameters
+ + +
ndotsthe new ndots parameter
+
+
+ +
+
+ +

◆ evdns_base_set_option()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_base_set_option (struct evdns_base * base,
const char * option,
const char * val 
)
+
+ +

Set the value of a configuration option.

+

The currently available configuration options are:

+

ndots, timeout, max-timeouts, max-inflight, attempts, randomize-case, bind-to, initial-probe-timeout, max-probe-timeout, probe-backoff-factor, getaddrinfo-allow-skew, so-rcvbuf, so-sndbuf, tcp-idle-timeout, use-vc, ignore-tc, edns-udp-size.

+
    +
  • probe-backoff-factor Backoff factor of probe timeout
  • +
  • max-probe-timeout Maximum timeout between two probe packets will change initial-probe-timeout when this value is smaller
  • +
+

In versions before Libevent 2.0.3-alpha, the option name needed to end with a colon.

+

In case of options without values (use-vc, ingore-tc) val should be an empty string or NULL.

+
Parameters
+ + + + +
basethe evdns_base to which to apply this operation. base must not be NULL.
optionthe name of the configuration option to be modified
valthe value to be set
+
+
+
Returns
0 if successful, or -1 if an error occurred
+ +
+
+ +

◆ evdns_cache_lookup()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_cache_lookup (struct evdns_base * base,
const char * nodename,
struct evutil_addrinfohints,
ev_uint16_t port,
struct evutil_addrinfo ** res 
)
+
+ +

Lookup an entry from the evdns cache.

+
Parameters
+ + + + + + +
basethe evdns base associated with the cache
nodenamethe DNS name for which information is being sought
hintssee man getaddrinfo()
portused to fill in port numbers in the resulting address list
respointer to an evutil_addrinfo struct for result
+
+
+ +
+
+ +

◆ evdns_cache_write()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evdns_cache_write (struct evdns_base * dns_base,
char * nodename,
struct evutil_addrinfores,
int ttl 
)
+
+ +

Write an entry to the evdns cache.

+
Parameters
+ + + + + +
dns_basethe evdns base to add the entry to
nodenamethe DNS name
resthe address information associated with the DNS name
ttlthe time to live associated with the address information
+
+
+ +
+
+ +

◆ evdns_cancel_request()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evdns_cancel_request (struct evdns_base * base,
struct evdns_request * req 
)
+
+ +

Cancels a pending DNS resolution request.

+
Parameters
+ + + +
basethe evdns_base that was used to make the request
reqthe evdns_request that was returned by calling a resolve function
+
+
+
See also
evdns_base_resolve_ipv4(), evdns_base_resolve_ipv6, evdns_base_resolve_reverse
+ +
+
+ +

◆ evdns_err_to_string()

+ +
+
+ + + + + + + + +
const EVENT2_EXPORT_SYMBOL char* evdns_err_to_string (int err)
+
+ +

Convert a DNS error code to a string.

+
Parameters
+ + +
errthe DNS error code
+
+
+
Returns
a string containing an explanation of the error code
+ +
+
+ +

◆ evdns_getaddrinfo()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evdns_getaddrinfo_request* evdns_getaddrinfo (struct evdns_base * dns_base,
const char * nodename,
const char * servname,
const struct evutil_addrinfohints_in,
evdns_getaddrinfo_cb cb,
void * arg 
)
+
+ +

Make a non-blocking getaddrinfo request using the dns_base in 'dns_base'.

+

If we can answer the request immediately (with an error or not!), then we invoke cb immediately and return NULL. This can happen e.g. if the requested address is in the hosts file, or cached, or invalid. Otherwise we return an evdns_getaddrinfo_request and invoke cb later.

+

When the callback is invoked, we pass as its first argument the error code that getaddrinfo would return (or 0 for no error). As its second argument, we pass the evutil_addrinfo structures we found (or NULL on error). We pass 'arg' as the third argument.

+

Limitations:

+
    +
  • The AI_V4MAPPED and AI_ALL flags are not currently implemented.
  • +
  • For ai_socktype, we only handle SOCKTYPE_STREAM, SOCKTYPE_UDP, and 0.
  • +
  • For ai_protocol, we only handle IPPROTO_TCP, IPPROTO_UDP, and 0.
  • +
  • If we cached a response exclusively for a different address type (e.g. PF_INET), we will set addrinfo to NULL (e.g. queried with PF_INET6) and return EVUTIL_EAI_ADDRFAMILY.
  • +
  • Cache isn't hit when AI_CANONNAME is set but cached server response doesn't contain CNAME.
  • +
  • If we can answer immediately (e.g. using hosts file, there is an error or when cache is hit), we invoke the call back and return NULL.
  • +
+ +
+
+ +

◆ evdns_server_port_set_option()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_server_port_set_option (struct evdns_server_port * port,
enum evdns_server_option option,
size_t value 
)
+
+ +

Configure DNS server.

+
Parameters
+ + + +
portthe evdns_server_port to which to apply this operation
option
+
+
+
See also
evdns_server_option for the list of possible options
+
Parameters
+ + +
valvalue of the option
+
+
+
Returns
0 if successful, or -1 if an error occurred
+ +
+
+ +

◆ evdns_server_request_set_flags()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evdns_server_request_set_flags (struct evdns_server_request * req,
int flags 
)
+
+ +

Sets some flags in a reply we're building.

+

Allows setting of the AA or RD flags

+ +
+
+ +

◆ evdns_set_log_fn()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void evdns_set_log_fn (evdns_debug_log_fn_type fn)
+
+ +

Set the callback function to handle DNS log messages.

+

If this callback is not set, evdns log messages are handled with the regular Libevent logging system.

+
Parameters
+ + +
fnthe callback to be invoked when a log message is generated
+
+
+ +
+
+
+
evdns_resolv_conf_parse
EVENT2_EXPORT_SYMBOL int evdns_resolv_conf_parse(int flags, const char *const filename)
Parse a resolv.conf file.
+
DNS_OPTIONS_ALL
#define DNS_OPTIONS_ALL
All above:
Definition: dns.h:225
+ + + + diff --git a/dns_8h_source.html b/dns_8h_source.html new file mode 100644 index 0000000..8472f3a --- /dev/null +++ b/dns_8h_source.html @@ -0,0 +1,495 @@ + + + + + + + +libevent: event2/dns.h Source File + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
dns.h
+
+
+Go to the documentation of this file.
1 /*
+
2  * Copyright (c) 2006-2007 Niels Provos <provos@citi.umich.edu>
+
3  * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson
+
4  *
+
5  * Redistribution and use in source and binary forms, with or without
+
6  * modification, are permitted provided that the following conditions
+
7  * are met:
+
8  * 1. Redistributions of source code must retain the above copyright
+
9  * notice, this list of conditions and the following disclaimer.
+
10  * 2. Redistributions in binary form must reproduce the above copyright
+
11  * notice, this list of conditions and the following disclaimer in the
+
12  * documentation and/or other materials provided with the distribution.
+
13  * 3. The name of the author may not be used to endorse or promote products
+
14  * derived from this software without specific prior written permission.
+
15  *
+
16  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+
17  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+
18  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+
19  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+
20  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+
21  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+
22  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+
23  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+
24  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+
25  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
26  */
+
27 
+
28 /*
+
29  * The original DNS code is due to Adam Langley with heavy
+
30  * modifications by Nick Mathewson. Adam put his DNS software in the
+
31  * public domain. You can find his original copyright below. Please,
+
32  * aware that the code as part of Libevent is governed by the 3-clause
+
33  * BSD license above.
+
34  *
+
35  * This software is Public Domain. To view a copy of the public domain dedication,
+
36  * visit http://creativecommons.org/licenses/publicdomain/ or send a letter to
+
37  * Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA.
+
38  *
+
39  * I ask and expect, but do not require, that all derivative works contain an
+
40  * attribution similar to:
+
41  * Parts developed by Adam Langley <agl@imperialviolet.org>
+
42  *
+
43  * You may wish to replace the word "Parts" with something else depending on
+
44  * the amount of original code.
+
45  *
+
46  * (Derivative works does not include programs which link against, run or include
+
47  * the source verbatim in their source distributions)
+
48  */
+
49 
+
141 #ifndef EVENT2_DNS_H_INCLUDED_
+
142 #define EVENT2_DNS_H_INCLUDED_
+
143 
+
144 #include <event2/visibility.h>
+
145 
+
146 #ifdef __cplusplus
+
147 extern "C" {
+
148 #endif
+
149 
+
150 /* For integer types. */
+
151 #include <event2/util.h>
+
152 
+
154 #define DNS_ERR_NONE 0
+
155 
+
156 #define DNS_ERR_FORMAT 1
+
157 
+
159 #define DNS_ERR_SERVERFAILED 2
+
160 
+
161 #define DNS_ERR_NOTEXIST 3
+
162 
+
163 #define DNS_ERR_NOTIMPL 4
+
164 
+
166 #define DNS_ERR_REFUSED 5
+
167 
+
168 #define DNS_ERR_TRUNCATED 65
+
169 
+
170 #define DNS_ERR_UNKNOWN 66
+
171 
+
172 #define DNS_ERR_TIMEOUT 67
+
173 
+
174 #define DNS_ERR_SHUTDOWN 68
+
175 
+
176 #define DNS_ERR_CANCEL 69
+
177 
+
180 #define DNS_ERR_NODATA 70
+
181 
+
182 #define DNS_IPv4_A 1
+
183 #define DNS_PTR 2
+
184 #define DNS_IPv6_AAAA 3
+
185 #define DNS_CNAME 4
+
186 
+
188 #define DNS_QUERY_NO_SEARCH 0x01
+
189 
+
190 #define DNS_QUERY_USEVC 0x02
+
191 
+
192 #define DNS_QUERY_IGNTC 0x04
+
193 
+
194 #define DNS_CNAME_CALLBACK 0x80
+
195 
+
196 /* Allow searching */
+
197 #define DNS_OPTION_SEARCH 1
+
198 /* Parse "nameserver" and add default if no such section */
+
199 #define DNS_OPTION_NAMESERVERS 2
+
200 /* Parse additional options like:
+
201  * - timeout:
+
202  * - getaddrinfo-allow-skew:
+
203  * - max-timeouts:
+
204  * - max-inflight:
+
205  * - attempts:
+
206  * - randomize-case:
+
207  * - initial-probe-timeout:
+
208  * - max-probe-timeout:
+
209  * - probe-backoff-factor:
+
210  * - tcp-idle-timeout:
+
211  * - edns-udp-size:
+
212  * - use-vc
+
213  * - ignore-tc
+
214  */
+
215 #define DNS_OPTION_MISC 4
+
216 /* Load hosts file (i.e. "/etc/hosts") */
+
217 #define DNS_OPTION_HOSTSFILE 8
+
218 
+
225 #define DNS_OPTIONS_ALL ( \
+
226  DNS_OPTION_SEARCH | \
+
227  DNS_OPTION_NAMESERVERS | \
+
228  DNS_OPTION_MISC | \
+
229  DNS_OPTION_HOSTSFILE | \
+
230  0 \
+
231 )
+
232 /* Do not "default" nameserver (i.e. "127.0.0.1:53") if there is no nameservers
+
233  * in resolv.conf, (iff DNS_OPTION_NAMESERVERS is set) */
+
234 #define DNS_OPTION_NAMESERVERS_NO_DEFAULT 16
+
235 
+
236 /* Obsolete name for DNS_QUERY_NO_SEARCH */
+
237 #define DNS_NO_SEARCH DNS_QUERY_NO_SEARCH
+
238 
+
249 typedef void (*evdns_callback_type) (int result, char type, int count, int ttl, void *addresses, void *arg);
+
250 
+
251 struct evdns_base;
+
252 struct event_base;
+
253 
+
255 #define EVDNS_BASE_INITIALIZE_NAMESERVERS 1
+
256 
+
258 #define EVDNS_BASE_NO_CACHE 0x10
+
259 
+
261 #define EVDNS_BASE_DISABLE_WHEN_INACTIVE 0x8000
+
262 
+
265 #define EVDNS_BASE_NAMESERVERS_NO_DEFAULT 0x10000
+
266 
+
267 /* No errors */
+
268 #define EVDNS_ERROR_NONE 0
+
269 /* Failed to open file */
+
270 #define EVDNS_ERROR_FAILED_TO_OPEN_FILE 1
+
271 /* Failed to stat file */
+
272 #define EVDNS_ERROR_FAILED_TO_STAT_FILE 2
+
273 /* File too large */
+
274 #define EVDNS_ERROR_FILE_TOO_LARGE 3
+
275 /* Out of memory */
+
276 #define EVDNS_ERROR_OUT_OF_MEMORY 4
+
277 /* Short read from file */
+
278 #define EVDNS_ERROR_SHORT_READ_FROM_FILE 5
+
279 /* No nameservers configured */
+
280 #define EVDNS_ERROR_NO_NAMESERVERS_CONFIGURED 6
+
281 
+
296 EVENT2_EXPORT_SYMBOL
+
297 struct evdns_base * evdns_base_new(struct event_base *event_base, int flags);
+
298 
+
299 
+
312 EVENT2_EXPORT_SYMBOL
+
313 void evdns_base_free(struct evdns_base *base, int fail_requests);
+
314 
+
321 EVENT2_EXPORT_SYMBOL
+
322 void evdns_base_clear_host_addresses(struct evdns_base *base);
+
323 
+
332 EVENT2_EXPORT_SYMBOL
+
333 void evdns_cache_write(struct evdns_base *dns_base, char *nodename, struct evutil_addrinfo *res, int ttl);
+
334 
+
344 EVENT2_EXPORT_SYMBOL
+
345 int evdns_cache_lookup(struct evdns_base *base, const char *nodename, struct evutil_addrinfo *hints, ev_uint16_t port, struct evutil_addrinfo **res);
+
346 
+
353 EVENT2_EXPORT_SYMBOL
+
354 const char *evdns_err_to_string(int err);
+
355 
+
356 
+
368 EVENT2_EXPORT_SYMBOL
+
369 int evdns_base_nameserver_add(struct evdns_base *base,
+
370  unsigned long int address);
+
371 
+
384 EVENT2_EXPORT_SYMBOL
+
385 int evdns_base_count_nameservers(struct evdns_base *base);
+
386 
+
396 EVENT2_EXPORT_SYMBOL
+
397 int evdns_base_clear_nameservers_and_suspend(struct evdns_base *base);
+
398 
+
399 
+
410 EVENT2_EXPORT_SYMBOL
+
411 int evdns_base_resume(struct evdns_base *base);
+
412 
+
430 EVENT2_EXPORT_SYMBOL
+
431 int evdns_base_nameserver_ip_add(struct evdns_base *base,
+
432  const char *ip_as_string);
+
433 
+
437 EVENT2_EXPORT_SYMBOL
+
438 int
+
439 evdns_base_nameserver_sockaddr_add(struct evdns_base *base,
+
440  const struct sockaddr *sa, ev_socklen_t len, unsigned flags);
+
441 
+
442 struct evdns_request;
+
443 
+
455 EVENT2_EXPORT_SYMBOL
+
456 struct evdns_request *evdns_base_resolve_ipv4(struct evdns_base *base, const char *name, int flags, evdns_callback_type callback, void *ptr);
+
457 
+
469 EVENT2_EXPORT_SYMBOL
+
470 struct evdns_request *evdns_base_resolve_ipv6(struct evdns_base *base, const char *name, int flags, evdns_callback_type callback, void *ptr);
+
471 
+
472 struct in_addr;
+
473 struct in6_addr;
+
474 
+
486 EVENT2_EXPORT_SYMBOL
+
487 struct evdns_request *evdns_base_resolve_reverse(struct evdns_base *base, const struct in_addr *in, int flags, evdns_callback_type callback, void *ptr);
+
488 
+
489 
+
501 EVENT2_EXPORT_SYMBOL
+
502 struct evdns_request *evdns_base_resolve_reverse_ipv6(struct evdns_base *base, const struct in6_addr *in, int flags, evdns_callback_type callback, void *ptr);
+
503 
+
511 EVENT2_EXPORT_SYMBOL
+
512 void evdns_cancel_request(struct evdns_base *base, struct evdns_request *req);
+
513 
+
542 EVENT2_EXPORT_SYMBOL
+
543 int evdns_base_set_option(struct evdns_base *base, const char *option, const char *val);
+
544 
+
545 
+
572 EVENT2_EXPORT_SYMBOL
+
573 int evdns_base_resolv_conf_parse(struct evdns_base *base, int flags, const char *const filename);
+
574 
+
588 EVENT2_EXPORT_SYMBOL
+
589 int evdns_base_load_hosts(struct evdns_base *base, const char *hosts_fname);
+
590 
+
591 #if defined(EVENT_IN_DOXYGEN_) || defined(_WIN32)
+
592 
+
602 EVENT2_EXPORT_SYMBOL
+
603 int evdns_base_config_windows_nameservers(struct evdns_base *);
+
604 #define EVDNS_BASE_CONFIG_WINDOWS_NAMESERVERS_IMPLEMENTED
+
605 #endif
+
606 
+
607 
+
611 EVENT2_EXPORT_SYMBOL
+
612 void evdns_base_search_clear(struct evdns_base *base);
+
613 
+
614 
+
620 EVENT2_EXPORT_SYMBOL
+
621 void evdns_base_search_add(struct evdns_base *base, const char *domain);
+
622 
+
623 
+
632 EVENT2_EXPORT_SYMBOL
+
633 void evdns_base_search_ndots_set(struct evdns_base *base, const int ndots);
+
634 
+
641 typedef void (*evdns_debug_log_fn_type)(int is_warning, const char *msg);
+
642 
+
643 
+
651 EVENT2_EXPORT_SYMBOL
+ +
653 
+
654 /*
+
655  * Functions used to implement a DNS server.
+
656  */
+
657 
+
658 struct evdns_server_request;
+
659 struct evdns_server_question;
+
660 
+
672 typedef void (*evdns_request_callback_fn_type)(struct evdns_server_request *, void *);
+
673 #define EVDNS_ANSWER_SECTION 0
+
674 #define EVDNS_AUTHORITY_SECTION 1
+
675 #define EVDNS_ADDITIONAL_SECTION 2
+
676 
+
677 #define EVDNS_TYPE_A 1
+
678 #define EVDNS_TYPE_NS 2
+
679 #define EVDNS_TYPE_CNAME 5
+
680 #define EVDNS_TYPE_SOA 6
+
681 #define EVDNS_TYPE_PTR 12
+
682 #define EVDNS_TYPE_MX 15
+
683 #define EVDNS_TYPE_TXT 16
+
684 #define EVDNS_TYPE_AAAA 28
+
685 
+
686 #define EVDNS_QTYPE_AXFR 252
+
687 #define EVDNS_QTYPE_ALL 255
+
688 
+
689 #define EVDNS_CLASS_INET 1
+
690 
+
691 /* flags that can be set in answers; as part of the err parameter */
+
692 #define EVDNS_FLAGS_AA 0x400
+
693 #define EVDNS_FLAGS_RD 0x080
+
694 
+
706 EVENT2_EXPORT_SYMBOL
+
707 struct evdns_server_port *evdns_add_server_port_with_base(struct event_base *base, evutil_socket_t socket, int flags, evdns_request_callback_fn_type callback, void *user_data);
+
708 
+
709 struct evconnlistener;
+
710 
+
722 EVENT2_EXPORT_SYMBOL
+
723 struct evdns_server_port *evdns_add_server_port_with_listener(
+
724  struct event_base *base, struct evconnlistener *listener, int flags,
+
725  evdns_request_callback_fn_type callback, void *user_data);
+
726 
+
728 EVENT2_EXPORT_SYMBOL
+
729 void evdns_close_server_port(struct evdns_server_port *port);
+
730 
+ + + +
749 };
+
750 
+
759 EVENT2_EXPORT_SYMBOL
+
760 int evdns_server_port_set_option(struct evdns_server_port *port, enum evdns_server_option option, size_t value);
+
761 
+
765 EVENT2_EXPORT_SYMBOL
+
766 void evdns_server_request_set_flags(struct evdns_server_request *req, int flags);
+
767 
+
768 /* Functions to add an answer to an in-progress DNS reply.
+
769  */
+
770 EVENT2_EXPORT_SYMBOL
+
771 int evdns_server_request_add_reply(struct evdns_server_request *req, int section, const char *name, int type, int dns_class, int ttl, int datalen, int is_name, const char *data);
+
772 EVENT2_EXPORT_SYMBOL
+
773 int evdns_server_request_add_a_reply(struct evdns_server_request *req, const char *name, int n, const void *addrs, int ttl);
+
774 EVENT2_EXPORT_SYMBOL
+
775 int evdns_server_request_add_aaaa_reply(struct evdns_server_request *req, const char *name, int n, const void *addrs, int ttl);
+
776 EVENT2_EXPORT_SYMBOL
+
777 int evdns_server_request_add_ptr_reply(struct evdns_server_request *req, struct in_addr *in, const char *inaddr_name, const char *hostname, int ttl);
+
778 EVENT2_EXPORT_SYMBOL
+
779 int evdns_server_request_add_cname_reply(struct evdns_server_request *req, const char *name, const char *cname, int ttl);
+
780 
+
784 EVENT2_EXPORT_SYMBOL
+
785 int evdns_server_request_respond(struct evdns_server_request *req, int err);
+
789 EVENT2_EXPORT_SYMBOL
+
790 int evdns_server_request_drop(struct evdns_server_request *req);
+
791 struct sockaddr;
+
795 EVENT2_EXPORT_SYMBOL
+
796 int evdns_server_request_get_requesting_addr(struct evdns_server_request *req, struct sockaddr *sa, int addr_len);
+
797 
+
799 typedef void (*evdns_getaddrinfo_cb)(int result, struct evutil_addrinfo *res, void *arg);
+
800 
+
801 struct evdns_base;
+
802 struct evdns_getaddrinfo_request;
+
828 EVENT2_EXPORT_SYMBOL
+
829 struct evdns_getaddrinfo_request *evdns_getaddrinfo(
+
830  struct evdns_base *dns_base,
+
831  const char *nodename, const char *servname,
+
832  const struct evutil_addrinfo *hints_in,
+
833  evdns_getaddrinfo_cb cb, void *arg);
+
834 
+
835 /* Cancel an in-progress evdns_getaddrinfo. This MUST NOT be called after the
+
836  * getaddrinfo's callback has been invoked. The resolves will be canceled,
+
837  * and the callback will be invoked with the error EVUTIL_EAI_CANCEL. */
+
838 EVENT2_EXPORT_SYMBOL
+
839 void evdns_getaddrinfo_cancel(struct evdns_getaddrinfo_request *req);
+
840 
+
853 EVENT2_EXPORT_SYMBOL
+
854 int evdns_base_get_nameserver_addr(struct evdns_base *base, int idx,
+
855  struct sockaddr *sa, ev_socklen_t len);
+
856 
+
866 EVENT2_EXPORT_SYMBOL
+
867 int evdns_base_get_nameserver_fd(struct evdns_base *base, int idx);
+
868 
+
869 #ifdef __cplusplus
+
870 }
+
871 #endif
+
872 
+
873 #endif /* !EVENT2_DNS_H_INCLUDED_ */
+
+
evdns_base_nameserver_sockaddr_add
EVENT2_EXPORT_SYMBOL int evdns_base_nameserver_sockaddr_add(struct evdns_base *base, const struct sockaddr *sa, ev_socklen_t len, unsigned flags)
Add a nameserver by sockaddr.
+
evdns_server_request_get_requesting_addr
EVENT2_EXPORT_SYMBOL int evdns_server_request_get_requesting_addr(struct evdns_server_request *req, struct sockaddr *sa, int addr_len)
Get the address that made a DNS request.
+
evdns_getaddrinfo_cb
void(* evdns_getaddrinfo_cb)(int result, struct evutil_addrinfo *res, void *arg)
Callback for evdns_getaddrinfo.
Definition: dns.h:799
+
evdns_base_resume
EVENT2_EXPORT_SYMBOL int evdns_base_resume(struct evdns_base *base)
Resume normal operation and continue any suspended resolve requests.
+
evdns_close_server_port
EVENT2_EXPORT_SYMBOL void evdns_close_server_port(struct evdns_server_port *port)
Close down a DNS server port, and free associated structures.
+
evdns_debug_log_fn_type
void(* evdns_debug_log_fn_type)(int is_warning, const char *msg)
A callback that is invoked when a log message is generated.
Definition: dns.h:641
+
evdns_base_get_nameserver_addr
EVENT2_EXPORT_SYMBOL int evdns_base_get_nameserver_addr(struct evdns_base *base, int idx, struct sockaddr *sa, ev_socklen_t len)
Retrieve the address of the 'idx'th configured nameserver.
+
evdns_server_request_respond
EVENT2_EXPORT_SYMBOL int evdns_server_request_respond(struct evdns_server_request *req, int err)
Send back a response to a DNS request, and free the request structure.
+
evdns_server_option
evdns_server_option
List of configurable evdns_server_port options.
Definition: dns.h:736
+
evdns_base_clear_host_addresses
EVENT2_EXPORT_SYMBOL void evdns_base_clear_host_addresses(struct evdns_base *base)
Remove all hosts entries that have been loaded into the event_base via evdns_base_load_hosts or via e...
+
evdns_base_resolve_ipv4
EVENT2_EXPORT_SYMBOL struct evdns_request * evdns_base_resolve_ipv4(struct evdns_base *base, const char *name, int flags, evdns_callback_type callback, void *ptr)
Lookup an A record for a given name.
+
evdns_server_request_drop
EVENT2_EXPORT_SYMBOL int evdns_server_request_drop(struct evdns_server_request *req)
Free a DNS request without sending back a reply.
+
event_base
Structure to hold information and state for a Libevent dispatch loop.
Definition: event.h:219
+
evdns_cache_write
EVENT2_EXPORT_SYMBOL void evdns_cache_write(struct evdns_base *dns_base, char *nodename, struct evutil_addrinfo *res, int ttl)
Write an entry to the evdns cache.
+
EVDNS_SOPT_TCP_MAX_CLIENTS
@ EVDNS_SOPT_TCP_MAX_CLIENTS
Maximum number of simultaneous tcp connections (clients) that server can hold.
Definition: dns.h:741
+
evdns_base_resolve_ipv6
EVENT2_EXPORT_SYMBOL struct evdns_request * evdns_base_resolve_ipv6(struct evdns_base *base, const char *name, int flags, evdns_callback_type callback, void *ptr)
Lookup an AAAA record for a given name.
+
evdns_base_load_hosts
EVENT2_EXPORT_SYMBOL int evdns_base_load_hosts(struct evdns_base *base, const char *hosts_fname)
Load an /etc/hosts-style file from 'hosts_fname' into 'base'.
+
evdns_base_get_nameserver_fd
EVENT2_EXPORT_SYMBOL int evdns_base_get_nameserver_fd(struct evdns_base *base, int idx)
Retrieve the fd of the 'idx'th configured nameserver.
+
evdns_base_search_ndots_set
EVENT2_EXPORT_SYMBOL void evdns_base_search_ndots_set(struct evdns_base *base, const int ndots)
Set the 'ndots' parameter for searches.
+
evdns_cancel_request
EVENT2_EXPORT_SYMBOL void evdns_cancel_request(struct evdns_base *base, struct evdns_request *req)
Cancels a pending DNS resolution request.
+
evdns_cache_lookup
EVENT2_EXPORT_SYMBOL int evdns_cache_lookup(struct evdns_base *base, const char *nodename, struct evutil_addrinfo *hints, ev_uint16_t port, struct evutil_addrinfo **res)
Lookup an entry from the evdns cache.
+
evdns_base_search_clear
EVENT2_EXPORT_SYMBOL void evdns_base_search_clear(struct evdns_base *base)
Clear the list of search domains.
+
evdns_base_resolve_reverse
EVENT2_EXPORT_SYMBOL struct evdns_request * evdns_base_resolve_reverse(struct evdns_base *base, const struct in_addr *in, int flags, evdns_callback_type callback, void *ptr)
Lookup a PTR record for a given IP address.
+
evdns_base_resolv_conf_parse
EVENT2_EXPORT_SYMBOL int evdns_base_resolv_conf_parse(struct evdns_base *base, int flags, const char *const filename)
Parse a resolv.conf file.
+
evdns_base_free
EVENT2_EXPORT_SYMBOL void evdns_base_free(struct evdns_base *base, int fail_requests)
Shut down the asynchronous DNS resolver and terminate all active requests.
+
EVDNS_SOPT_TCP_IDLE_TIMEOUT
@ EVDNS_SOPT_TCP_IDLE_TIMEOUT
Idle timeout (in seconds) of incoming TCP connections.
Definition: dns.h:748
+
evdns_add_server_port_with_base
EVENT2_EXPORT_SYMBOL struct evdns_server_port * evdns_add_server_port_with_base(struct event_base *base, evutil_socket_t socket, int flags, evdns_request_callback_fn_type callback, void *user_data)
Create a new UDP DNS server port.
+
evdns_request_callback_fn_type
void(* evdns_request_callback_fn_type)(struct evdns_server_request *, void *)
A callback to implement a DNS server.
Definition: dns.h:672
+
evdns_base_resolve_reverse_ipv6
EVENT2_EXPORT_SYMBOL struct evdns_request * evdns_base_resolve_reverse_ipv6(struct evdns_base *base, const struct in6_addr *in, int flags, evdns_callback_type callback, void *ptr)
Lookup a PTR record for a given IPv6 address.
+
evdns_set_log_fn
EVENT2_EXPORT_SYMBOL void evdns_set_log_fn(evdns_debug_log_fn_type fn)
Set the callback function to handle DNS log messages.
+
evdns_callback_type
void(* evdns_callback_type)(int result, char type, int count, int ttl, void *addresses, void *arg)
The callback that contains the results from a lookup.
Definition: dns.h:249
+
evdns_add_server_port_with_listener
EVENT2_EXPORT_SYMBOL struct evdns_server_port * evdns_add_server_port_with_listener(struct event_base *base, struct evconnlistener *listener, int flags, evdns_request_callback_fn_type callback, void *user_data)
Create a new TCP DNS server port.
+
evdns_base_config_windows_nameservers
EVENT2_EXPORT_SYMBOL int evdns_base_config_windows_nameservers(struct evdns_base *)
Obtain nameserver information using the Windows API.
+
evdns_base_nameserver_ip_add
EVENT2_EXPORT_SYMBOL int evdns_base_nameserver_ip_add(struct evdns_base *base, const char *ip_as_string)
Add a nameserver by string address.
+
evdns_getaddrinfo
EVENT2_EXPORT_SYMBOL struct evdns_getaddrinfo_request * evdns_getaddrinfo(struct evdns_base *dns_base, const char *nodename, const char *servname, const struct evutil_addrinfo *hints_in, evdns_getaddrinfo_cb cb, void *arg)
Make a non-blocking getaddrinfo request using the dns_base in 'dns_base'.
+
evdns_base_new
EVENT2_EXPORT_SYMBOL struct evdns_base * evdns_base_new(struct event_base *event_base, int flags)
Initialize the asynchronous DNS library.
+
evdns_base_search_add
EVENT2_EXPORT_SYMBOL void evdns_base_search_add(struct evdns_base *base, const char *domain)
Add a domain to the list of search domains.
+
evdns_base_set_option
EVENT2_EXPORT_SYMBOL int evdns_base_set_option(struct evdns_base *base, const char *option, const char *val)
Set the value of a configuration option.
+
util.h
Common convenience functions for cross-platform portability and related socket manipulations.
+
evdns_err_to_string
const EVENT2_EXPORT_SYMBOL char * evdns_err_to_string(int err)
Convert a DNS error code to a string.
+
evdns_base_nameserver_add
EVENT2_EXPORT_SYMBOL int evdns_base_nameserver_add(struct evdns_base *base, unsigned long int address)
Add a nameserver.
+
evutil_addrinfo
A definition of struct addrinfo for systems that lack it.
Definition: util.h:731
+
evdns_base_count_nameservers
EVENT2_EXPORT_SYMBOL int evdns_base_count_nameservers(struct evdns_base *base)
Get the number of configured nameservers.
+
evdns_server_request_set_flags
EVENT2_EXPORT_SYMBOL void evdns_server_request_set_flags(struct evdns_server_request *req, int flags)
Sets some flags in a reply we're building.
+
evdns_base_clear_nameservers_and_suspend
EVENT2_EXPORT_SYMBOL int evdns_base_clear_nameservers_and_suspend(struct evdns_base *base)
Remove all configured nameservers, and suspend all pending resolves.
+
evdns_server_port_set_option
EVENT2_EXPORT_SYMBOL int evdns_server_port_set_option(struct evdns_server_port *port, enum evdns_server_option option, size_t value)
Configure DNS server.
+
evutil_socket_t
#define evutil_socket_t
A type wide enough to hold the output of "socket()" or "accept()".
Definition: util.h:325
+ + + + diff --git a/dns__compat_8h.html b/dns__compat_8h.html new file mode 100644 index 0000000..c23a66c --- /dev/null +++ b/dns__compat_8h.html @@ -0,0 +1,778 @@ + + + + + + + +libevent: event2/dns_compat.h File Reference + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+Functions
+
+
dns_compat.h File Reference
+
+
+ +

Potentially non-threadsafe versions of the functions in dns.h: provided only for backwards compatibility. +More...

+
#include <event2/event-config.h>
+#include <event2/util.h>
+#include <event2/visibility.h>
+
+

Go to the source code of this file.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+Functions

EVENT2_EXPORT_SYMBOL struct evdns_server_port * evdns_add_server_port (evutil_socket_t socket, int flags, evdns_request_callback_fn_type callback, void *user_data)
 As evdns_server_new_with_base. More...
 
EVENT2_EXPORT_SYMBOL int evdns_clear_nameservers_and_suspend (void)
 Remove all configured nameservers, and suspend all pending resolves. More...
 
EVENT2_EXPORT_SYMBOL int evdns_count_nameservers (void)
 Get the number of configured nameservers. More...
 
EVENT2_EXPORT_SYMBOL struct evdns_base * evdns_get_global_base (void)
 Return the global evdns_base created by event_init() and used by the other deprecated functions. More...
 
EVENT2_EXPORT_SYMBOL int evdns_init (void)
 Initialize the asynchronous DNS library. More...
 
EVENT2_EXPORT_SYMBOL int evdns_nameserver_add (unsigned long int address)
 Add a nameserver. More...
 
EVENT2_EXPORT_SYMBOL int evdns_nameserver_ip_add (const char *ip_as_string)
 Add a nameserver. More...
 
EVENT2_EXPORT_SYMBOL int evdns_resolv_conf_parse (int flags, const char *const filename)
 Parse a resolv.conf file. More...
 
EVENT2_EXPORT_SYMBOL int evdns_resolve_ipv4 (const char *name, int flags, evdns_callback_type callback, void *ptr)
 Lookup an A record for a given name. More...
 
EVENT2_EXPORT_SYMBOL int evdns_resolve_ipv6 (const char *name, int flags, evdns_callback_type callback, void *ptr)
 Lookup an AAAA record for a given name. More...
 
EVENT2_EXPORT_SYMBOL int evdns_resolve_reverse (const struct in_addr *in, int flags, evdns_callback_type callback, void *ptr)
 Lookup a PTR record for a given IP address. More...
 
EVENT2_EXPORT_SYMBOL int evdns_resolve_reverse_ipv6 (const struct in6_addr *in, int flags, evdns_callback_type callback, void *ptr)
 Lookup a PTR record for a given IPv6 address. More...
 
EVENT2_EXPORT_SYMBOL int evdns_resume (void)
 Resume normal operation and continue any suspended resolve requests. More...
 
EVENT2_EXPORT_SYMBOL void evdns_search_add (const char *domain)
 Add a domain to the list of search domains. More...
 
EVENT2_EXPORT_SYMBOL void evdns_search_clear (void)
 Clear the list of search domains. More...
 
EVENT2_EXPORT_SYMBOL void evdns_search_ndots_set (const int ndots)
 Set the 'ndots' parameter for searches. More...
 
EVENT2_EXPORT_SYMBOL int evdns_set_option (const char *option, const char *val, int flags)
 Set the value of a configuration option. More...
 
EVENT2_EXPORT_SYMBOL void evdns_shutdown (int fail_requests)
 Shut down the asynchronous DNS resolver and terminate all active requests. More...
 
+

Detailed Description

+

Potentially non-threadsafe versions of the functions in dns.h: provided only for backwards compatibility.

+

Function Documentation

+ +

◆ evdns_add_server_port()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evdns_server_port* evdns_add_server_port (evutil_socket_t socket,
int flags,
evdns_request_callback_fn_type callback,
void * user_data 
)
+
+ +

As evdns_server_new_with_base.

+
Deprecated:
This function is deprecated because it does not allow the caller to specify which even_base it uses. The recommended function is evdns_add_server_port_with_base().
+ +
+
+ +

◆ evdns_clear_nameservers_and_suspend()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_clear_nameservers_and_suspend (void )
+
+ +

Remove all configured nameservers, and suspend all pending resolves.

+

Resolves will not necessarily be re-attempted until evdns_resume() is called.

+
Deprecated:
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_clear_nameservers_and_suspend().
+
Returns
0 if successful, or -1 if an error occurred
+
See also
evdns_resume()
+ +
+
+ +

◆ evdns_count_nameservers()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_count_nameservers (void )
+
+ +

Get the number of configured nameservers.

+

This returns the number of configured nameservers (not necessarily the number of running nameservers). This is useful for double-checking whether our calls to the various nameserver configuration functions have been successful.

+
Deprecated:
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_count_nameservers().
+
Returns
the number of configured nameservers
+
See also
evdns_nameserver_add()
+ +
+
+ +

◆ evdns_get_global_base()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evdns_base* evdns_get_global_base (void )
+
+ +

Return the global evdns_base created by event_init() and used by the other deprecated functions.

+
Deprecated:
This function is deprecated because use of the global evdns_base is error-prone.
+ +
+
+ +

◆ evdns_init()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_init (void )
+
+ +

Initialize the asynchronous DNS library.

+

This function initializes support for non-blocking name resolution by calling evdns_resolv_conf_parse() on UNIX and evdns_config_windows_nameservers() on Windows.

+
Deprecated:
This function is deprecated because it always uses the current event base, and is easily confused by multiple calls to event_init(), and so is not safe for multithreaded use. Additionally, it allocates a global structure that only one thread can use. The replacement is evdns_base_new().
+
Returns
0 if successful, or -1 if an error occurred
+
See also
evdns_shutdown()
+ +
+
+ +

◆ evdns_nameserver_add()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_nameserver_add (unsigned long int address)
+
+ +

Add a nameserver.

+

The address should be an IPv4 address in network byte order. The type of address is chosen so that it matches in_addr.s_addr.

+
Deprecated:
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_nameserver_add().
+
Parameters
+ + +
addressan IP address in network byte order
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
evdns_nameserver_ip_add()
+ +
+
+ +

◆ evdns_nameserver_ip_add()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_nameserver_ip_add (const char * ip_as_string)
+
+ +

Add a nameserver.

+

This wraps the evdns_nameserver_add() function by parsing a string as an IP address and adds it as a nameserver.

+
Deprecated:
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_nameserver_ip_add().
+
Returns
0 if successful, or -1 if an error occurred
+
See also
evdns_nameserver_add()
+ +
+
+ +

◆ evdns_resolv_conf_parse()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_resolv_conf_parse (int flags,
const char *const filename 
)
+
+ +

Parse a resolv.conf file.

+

The 'flags' parameter determines what information is parsed from the resolv.conf file. See the man page for resolv.conf for the format of this file.

+

The following directives are not parsed from the file: sortlist, rotate, no-check-names, inet6, debug.

+

If this function encounters an error, the possible return values are: 1 = failed to open file, 2 = failed to stat file, 3 = file too large, 4 = out of memory, 5 = short read from file, 6 = no nameservers listed in the file

+
Deprecated:
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_resolv_conf_parse().
+
Parameters
+ + + +
flagsany of DNS_OPTION_NAMESERVERS|DNS_OPTION_SEARCH|DNS_OPTION_MISC| DNS_OPTIONS_ALL
filenamethe path to the resolv.conf file
+
+
+
Returns
0 if successful, or various positive error codes if an error occurred (see above)
+
See also
resolv.conf(3), evdns_config_windows_nameservers()
+ +
+
+ +

◆ evdns_resolve_ipv4()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_resolve_ipv4 (const char * name,
int flags,
evdns_callback_type callback,
void * ptr 
)
+
+ +

Lookup an A record for a given name.

+
Deprecated:
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_resolve_ipv4().
+
Parameters
+ + + + + +
namea DNS hostname
flagseither 0, or DNS_QUERY_NO_SEARCH to disable searching for this query.
callbacka callback function to invoke when the request is completed
ptran argument to pass to the callback function
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
evdns_resolve_ipv6(), evdns_resolve_reverse(), evdns_resolve_reverse_ipv6()
+ +
+
+ +

◆ evdns_resolve_ipv6()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_resolve_ipv6 (const char * name,
int flags,
evdns_callback_type callback,
void * ptr 
)
+
+ +

Lookup an AAAA record for a given name.

+
Parameters
+ + + + + +
namea DNS hostname
flagseither 0, or DNS_QUERY_NO_SEARCH to disable searching for this query.
callbacka callback function to invoke when the request is completed
ptran argument to pass to the callback function
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
evdns_resolve_ipv4(), evdns_resolve_reverse(), evdns_resolve_reverse_ipv6()
+ +
+
+ +

◆ evdns_resolve_reverse()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_resolve_reverse (const struct in_addr * in,
int flags,
evdns_callback_type callback,
void * ptr 
)
+
+ +

Lookup a PTR record for a given IP address.

+
Deprecated:
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_resolve_reverse().
+
Parameters
+ + + + + +
inan IPv4 address
flagseither 0, or DNS_QUERY_NO_SEARCH to disable searching for this query.
callbacka callback function to invoke when the request is completed
ptran argument to pass to the callback function
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
evdns_resolve_reverse_ipv6()
+ +
+
+ +

◆ evdns_resolve_reverse_ipv6()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_resolve_reverse_ipv6 (const struct in6_addr * in,
int flags,
evdns_callback_type callback,
void * ptr 
)
+
+ +

Lookup a PTR record for a given IPv6 address.

+
Deprecated:
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_resolve_reverse_ipv6().
+
Parameters
+ + + + + +
inan IPv6 address
flagseither 0, or DNS_QUERY_NO_SEARCH to disable searching for this query.
callbacka callback function to invoke when the request is completed
ptran argument to pass to the callback function
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
evdns_resolve_reverse_ipv6()
+ +
+
+ +

◆ evdns_resume()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_resume (void )
+
+ +

Resume normal operation and continue any suspended resolve requests.

+

Re-attempt resolves left in limbo after an earlier call to evdns_clear_nameservers_and_suspend().

+
Deprecated:
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_resume().
+
Returns
0 if successful, or -1 if an error occurred
+
See also
evdns_clear_nameservers_and_suspend()
+ +
+
+ +

◆ evdns_search_add()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void evdns_search_add (const char * domain)
+
+ +

Add a domain to the list of search domains.

+
Deprecated:
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_search_add().
+
Parameters
+ + +
domainthe domain to be added to the search list
+
+
+ +
+
+ +

◆ evdns_search_clear()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void evdns_search_clear (void )
+
+ +

Clear the list of search domains.

+
Deprecated:
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_search_clear().
+ +
+
+ +

◆ evdns_search_ndots_set()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void evdns_search_ndots_set (const int ndots)
+
+ +

Set the 'ndots' parameter for searches.

+

Sets the number of dots which, when found in a name, causes the first query to be without any search domain.

+
Deprecated:
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_search_ndots_set().
+
Parameters
+ + +
ndotsthe new ndots parameter
+
+
+ +
+
+ +

◆ evdns_set_option()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evdns_set_option (const char * option,
const char * val,
int flags 
)
+
+ +

Set the value of a configuration option.

+

The currently available configuration options are:

+

ndots, timeout, max-timeouts, max-inflight, and attempts

+
Deprecated:
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_set_option().
+
Parameters
+ + + + +
optionthe name of the configuration option to be modified
valthe value to be set
flagsIgnored.
+
+
+
Returns
0 if successful, or -1 if an error occurred
+ +
+
+ +

◆ evdns_shutdown()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void evdns_shutdown (int fail_requests)
+
+ +

Shut down the asynchronous DNS resolver and terminate all active requests.

+

If the 'fail_requests' option is enabled, all active requests will return an empty result with the error flag set to DNS_ERR_SHUTDOWN. Otherwise, the requests will be silently discarded.

+
Deprecated:
This function is deprecated because it does not allow the caller to specify which evdns_base it applies to. The recommended function is evdns_base_shutdown().
+
Parameters
+ + +
fail_requestsif zero, active requests will be aborted; if non-zero, active requests will return DNS_ERR_SHUTDOWN.
+
+
+
See also
evdns_init()
+ +
+
+
+ + + + diff --git a/dns__compat_8h_source.html b/dns__compat_8h_source.html new file mode 100644 index 0000000..fc1551a --- /dev/null +++ b/dns__compat_8h_source.html @@ -0,0 +1,220 @@ + + + + + + + +libevent: event2/dns_compat.h Source File + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
dns_compat.h
+
+
+Go to the documentation of this file.
1 /*
+
2  * Copyright (c) 2006-2007 Niels Provos <provos@citi.umich.edu>
+
3  * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson
+
4  *
+
5  * Redistribution and use in source and binary forms, with or without
+
6  * modification, are permitted provided that the following conditions
+
7  * are met:
+
8  * 1. Redistributions of source code must retain the above copyright
+
9  * notice, this list of conditions and the following disclaimer.
+
10  * 2. Redistributions in binary form must reproduce the above copyright
+
11  * notice, this list of conditions and the following disclaimer in the
+
12  * documentation and/or other materials provided with the distribution.
+
13  * 3. The name of the author may not be used to endorse or promote products
+
14  * derived from this software without specific prior written permission.
+
15  *
+
16  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+
17  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+
18  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+
19  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+
20  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+
21  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+
22  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+
23  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+
24  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+
25  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
26  */
+
27 #ifndef EVENT2_DNS_COMPAT_H_INCLUDED_
+
28 #define EVENT2_DNS_COMPAT_H_INCLUDED_
+
29 
+
38 #ifdef __cplusplus
+
39 extern "C" {
+
40 #endif
+
41 
+
42 #include <event2/event-config.h>
+
43 #ifdef EVENT__HAVE_SYS_TYPES_H
+
44 #include <sys/types.h>
+
45 #endif
+
46 #ifdef EVENT__HAVE_SYS_TIME_H
+
47 #include <sys/time.h>
+
48 #endif
+
49 
+
50 /* For int types. */
+
51 #include <event2/util.h>
+
52 #include <event2/visibility.h>
+
53 
+
70 EVENT2_EXPORT_SYMBOL
+
71 int evdns_init(void);
+
72 
+
73 struct evdns_base;
+
81 EVENT2_EXPORT_SYMBOL
+
82 struct evdns_base *evdns_get_global_base(void);
+
83 
+
99 EVENT2_EXPORT_SYMBOL
+
100 void evdns_shutdown(int fail_requests);
+
101 
+
116 EVENT2_EXPORT_SYMBOL
+
117 int evdns_nameserver_add(unsigned long int address);
+
118 
+
134 EVENT2_EXPORT_SYMBOL
+
135 int evdns_count_nameservers(void);
+
136 
+
149 EVENT2_EXPORT_SYMBOL
+ +
151 
+
165 EVENT2_EXPORT_SYMBOL
+
166 int evdns_resume(void);
+
167 
+
181 EVENT2_EXPORT_SYMBOL
+
182 int evdns_nameserver_ip_add(const char *ip_as_string);
+
183 
+
198 EVENT2_EXPORT_SYMBOL
+
199 int evdns_resolve_ipv4(const char *name, int flags, evdns_callback_type callback, void *ptr);
+
200 
+
211 EVENT2_EXPORT_SYMBOL
+
212 int evdns_resolve_ipv6(const char *name, int flags, evdns_callback_type callback, void *ptr);
+
213 
+
214 struct in_addr;
+
215 struct in6_addr;
+
216 
+
231 EVENT2_EXPORT_SYMBOL
+
232 int evdns_resolve_reverse(const struct in_addr *in, int flags, evdns_callback_type callback, void *ptr);
+
233 
+
248 EVENT2_EXPORT_SYMBOL
+
249 int evdns_resolve_reverse_ipv6(const struct in6_addr *in, int flags, evdns_callback_type callback, void *ptr);
+
250 
+
267 EVENT2_EXPORT_SYMBOL
+
268 int evdns_set_option(const char *option, const char *val, int flags);
+
269 
+
295 EVENT2_EXPORT_SYMBOL
+
296 int evdns_resolv_conf_parse(int flags, const char *const filename);
+
297 
+
305 EVENT2_EXPORT_SYMBOL
+
306 void evdns_search_clear(void);
+
307 
+
317 EVENT2_EXPORT_SYMBOL
+
318 void evdns_search_add(const char *domain);
+
319 
+
332 EVENT2_EXPORT_SYMBOL
+
333 void evdns_search_ndots_set(const int ndots);
+
334 
+
343 EVENT2_EXPORT_SYMBOL
+
344 struct evdns_server_port *
+
345 evdns_add_server_port(evutil_socket_t socket, int flags,
+
346  evdns_request_callback_fn_type callback, void *user_data);
+
347 
+
348 #ifdef _WIN32
+
349 EVENT2_EXPORT_SYMBOL
+
350 int evdns_config_windows_nameservers(void);
+
351 #define EVDNS_CONFIG_WINDOWS_NAMESERVERS_IMPLEMENTED
+
352 #endif
+
353 
+
354 #ifdef __cplusplus
+
355 }
+
356 #endif
+
357 
+
358 #endif /* EVENT2_EVENT_COMPAT_H_INCLUDED_ */
+
+
evdns_resolve_reverse
EVENT2_EXPORT_SYMBOL int evdns_resolve_reverse(const struct in_addr *in, int flags, evdns_callback_type callback, void *ptr)
Lookup a PTR record for a given IP address.
+
evdns_search_add
EVENT2_EXPORT_SYMBOL void evdns_search_add(const char *domain)
Add a domain to the list of search domains.
+
evdns_resolve_reverse_ipv6
EVENT2_EXPORT_SYMBOL int evdns_resolve_reverse_ipv6(const struct in6_addr *in, int flags, evdns_callback_type callback, void *ptr)
Lookup a PTR record for a given IPv6 address.
+
evdns_resolv_conf_parse
EVENT2_EXPORT_SYMBOL int evdns_resolv_conf_parse(int flags, const char *const filename)
Parse a resolv.conf file.
+
evdns_nameserver_add
EVENT2_EXPORT_SYMBOL int evdns_nameserver_add(unsigned long int address)
Add a nameserver.
+
evdns_init
EVENT2_EXPORT_SYMBOL int evdns_init(void)
Initialize the asynchronous DNS library.
+
evdns_get_global_base
EVENT2_EXPORT_SYMBOL struct evdns_base * evdns_get_global_base(void)
Return the global evdns_base created by event_init() and used by the other deprecated functions.
+
evdns_clear_nameservers_and_suspend
EVENT2_EXPORT_SYMBOL int evdns_clear_nameservers_and_suspend(void)
Remove all configured nameservers, and suspend all pending resolves.
+
evdns_nameserver_ip_add
EVENT2_EXPORT_SYMBOL int evdns_nameserver_ip_add(const char *ip_as_string)
Add a nameserver.
+
evdns_search_ndots_set
EVENT2_EXPORT_SYMBOL void evdns_search_ndots_set(const int ndots)
Set the 'ndots' parameter for searches.
+
evdns_resolve_ipv6
EVENT2_EXPORT_SYMBOL int evdns_resolve_ipv6(const char *name, int flags, evdns_callback_type callback, void *ptr)
Lookup an AAAA record for a given name.
+
evdns_resolve_ipv4
EVENT2_EXPORT_SYMBOL int evdns_resolve_ipv4(const char *name, int flags, evdns_callback_type callback, void *ptr)
Lookup an A record for a given name.
+
evdns_resume
EVENT2_EXPORT_SYMBOL int evdns_resume(void)
Resume normal operation and continue any suspended resolve requests.
+
evdns_search_clear
EVENT2_EXPORT_SYMBOL void evdns_search_clear(void)
Clear the list of search domains.
+
evdns_request_callback_fn_type
void(* evdns_request_callback_fn_type)(struct evdns_server_request *, void *)
A callback to implement a DNS server.
Definition: dns.h:672
+
evdns_callback_type
void(* evdns_callback_type)(int result, char type, int count, int ttl, void *addresses, void *arg)
The callback that contains the results from a lookup.
Definition: dns.h:249
+
evdns_set_option
EVENT2_EXPORT_SYMBOL int evdns_set_option(const char *option, const char *val, int flags)
Set the value of a configuration option.
+
evdns_shutdown
EVENT2_EXPORT_SYMBOL void evdns_shutdown(int fail_requests)
Shut down the asynchronous DNS resolver and terminate all active requests.
+
evdns_add_server_port
EVENT2_EXPORT_SYMBOL struct evdns_server_port * evdns_add_server_port(evutil_socket_t socket, int flags, evdns_request_callback_fn_type callback, void *user_data)
As evdns_server_new_with_base.
+
evdns_count_nameservers
EVENT2_EXPORT_SYMBOL int evdns_count_nameservers(void)
Get the number of configured nameservers.
+
util.h
Common convenience functions for cross-platform portability and related socket manipulations.
+
evutil_socket_t
#define evutil_socket_t
A type wide enough to hold the output of "socket()" or "accept()".
Definition: util.h:325
+ + + + diff --git a/doc.png b/doc.png new file mode 100644 index 0000000..17edabf Binary files /dev/null and b/doc.png differ diff --git a/doxygen.css b/doxygen.css new file mode 100644 index 0000000..73ecbb2 --- /dev/null +++ b/doxygen.css @@ -0,0 +1,1771 @@ +/* The standard CSS for doxygen 1.8.17 */ + +body, table, div, p, dl { + font: 400 14px/22px Roboto,sans-serif; +} + +p.reference, p.definition { + font: 400 14px/22px Roboto,sans-serif; +} + +/* @group Heading Levels */ + +h1.groupheader { + font-size: 150%; +} + +.title { + font: 400 14px/28px Roboto,sans-serif; + font-size: 150%; + font-weight: bold; + margin: 10px 2px; +} + +h2.groupheader { + border-bottom: 1px solid #879ECB; + color: #354C7B; + font-size: 150%; + font-weight: normal; + margin-top: 1.75em; + padding-top: 8px; + padding-bottom: 4px; + width: 100%; +} + +h3.groupheader { + font-size: 100%; +} + +h1, h2, h3, h4, h5, h6 { + -webkit-transition: text-shadow 0.5s linear; + -moz-transition: text-shadow 0.5s linear; + -ms-transition: text-shadow 0.5s linear; + -o-transition: text-shadow 0.5s linear; + transition: text-shadow 0.5s linear; + margin-right: 15px; +} + +h1.glow, h2.glow, h3.glow, h4.glow, h5.glow, h6.glow { + text-shadow: 0 0 15px cyan; +} + +dt { + font-weight: bold; +} + +ul.multicol { + -moz-column-gap: 1em; + -webkit-column-gap: 1em; + column-gap: 1em; + -moz-column-count: 3; + -webkit-column-count: 3; + column-count: 3; +} + +p.startli, p.startdd { + margin-top: 2px; +} + +th p.starttd, p.intertd, p.endtd { + font-size: 100%; + font-weight: 700; +} + +p.starttd { + margin-top: 0px; +} + +p.endli { + margin-bottom: 0px; +} + +p.enddd { + margin-bottom: 4px; +} + +p.endtd { + margin-bottom: 2px; +} + +p.interli { +} + +p.interdd { +} + +p.intertd { +} + +/* @end */ + +caption { + font-weight: bold; +} + +span.legend { + font-size: 70%; + text-align: center; +} + +h3.version { + font-size: 90%; + text-align: center; +} + +div.qindex, div.navtab{ + background-color: #EBEFF6; + border: 1px solid #A3B4D7; + text-align: center; +} + +div.qindex, div.navpath { + width: 100%; + line-height: 140%; +} + +div.navtab { + margin-right: 15px; +} + +/* @group Link Styling */ + +a { + color: #3D578C; + font-weight: normal; + text-decoration: none; +} + +.contents a:visited { + color: #4665A2; +} + +a:hover { + text-decoration: underline; +} + +a.qindex { + font-weight: bold; +} + +a.qindexHL { + font-weight: bold; + background-color: #9CAFD4; + color: #FFFFFF; + border: 1px double #869DCA; +} + +.contents a.qindexHL:visited { + color: #FFFFFF; +} + +a.el { + font-weight: bold; +} + +a.elRef { +} + +a.code, a.code:visited, a.line, a.line:visited { + color: #4665A2; +} + +a.codeRef, a.codeRef:visited, a.lineRef, a.lineRef:visited { + color: #4665A2; +} + +/* @end */ + +dl.el { + margin-left: -1cm; +} + +ul { + overflow: hidden; /*Fixed: list item bullets overlap floating elements*/ +} + +#side-nav ul { + overflow: visible; /* reset ul rule for scroll bar in GENERATE_TREEVIEW window */ +} + +#main-nav ul { + overflow: visible; /* reset ul rule for the navigation bar drop down lists */ +} + +.fragment { + text-align: left; + direction: ltr; + overflow-x: auto; /*Fixed: fragment lines overlap floating elements*/ + overflow-y: hidden; +} + +pre.fragment { + border: 1px solid #C4CFE5; + background-color: #FBFCFD; + padding: 4px 6px; + margin: 4px 8px 4px 2px; + overflow: auto; + word-wrap: break-word; + font-size: 9pt; + line-height: 125%; + font-family: monospace, fixed; + font-size: 105%; +} + +div.fragment { + padding: 0 0 1px 0; /*Fixed: last line underline overlap border*/ + margin: 4px 8px 4px 2px; + background-color: #FBFCFD; + border: 1px solid #C4CFE5; +} + +div.line { + font-family: monospace, fixed; + font-size: 13px; + min-height: 13px; + line-height: 1.0; + text-wrap: unrestricted; + white-space: -moz-pre-wrap; /* Moz */ + white-space: -pre-wrap; /* Opera 4-6 */ + white-space: -o-pre-wrap; /* Opera 7 */ + white-space: pre-wrap; /* CSS3 */ + word-wrap: break-word; /* IE 5.5+ */ + text-indent: -53px; + padding-left: 53px; + padding-bottom: 0px; + margin: 0px; + -webkit-transition-property: background-color, box-shadow; + -webkit-transition-duration: 0.5s; + -moz-transition-property: background-color, box-shadow; + -moz-transition-duration: 0.5s; + -ms-transition-property: background-color, box-shadow; + -ms-transition-duration: 0.5s; + -o-transition-property: background-color, box-shadow; + -o-transition-duration: 0.5s; + transition-property: background-color, box-shadow; + transition-duration: 0.5s; +} + +div.line:after { + content:"\000A"; + white-space: pre; +} + +div.line.glow { + background-color: cyan; + box-shadow: 0 0 10px cyan; +} + + +span.lineno { + padding-right: 4px; + text-align: right; + border-right: 2px solid #0F0; + background-color: #E8E8E8; + white-space: pre; +} +span.lineno a { + background-color: #D8D8D8; +} + +span.lineno a:hover { + background-color: #C8C8C8; +} + +.lineno { + -webkit-touch-callout: none; + -webkit-user-select: none; + -khtml-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} + +div.ah, span.ah { + background-color: black; + font-weight: bold; + color: #FFFFFF; + margin-bottom: 3px; + margin-top: 3px; + padding: 0.2em; + border: solid thin #333; + border-radius: 0.5em; + -webkit-border-radius: .5em; + -moz-border-radius: .5em; + box-shadow: 2px 2px 3px #999; + -webkit-box-shadow: 2px 2px 3px #999; + -moz-box-shadow: rgba(0, 0, 0, 0.15) 2px 2px 2px; + background-image: -webkit-gradient(linear, left top, left bottom, from(#eee), to(#000),color-stop(0.3, #444)); + background-image: -moz-linear-gradient(center top, #eee 0%, #444 40%, #000 110%); +} + +div.classindex ul { + list-style: none; + padding-left: 0; +} + +div.classindex span.ai { + display: inline-block; +} + +div.groupHeader { + margin-left: 16px; + margin-top: 12px; + font-weight: bold; +} + +div.groupText { + margin-left: 16px; + font-style: italic; +} + +body { + background-color: white; + color: black; + margin: 0; +} + +div.contents { + margin-top: 10px; + margin-left: 12px; + margin-right: 8px; +} + +td.indexkey { + background-color: #EBEFF6; + font-weight: bold; + border: 1px solid #C4CFE5; + margin: 2px 0px 2px 0; + padding: 2px 10px; + white-space: nowrap; + vertical-align: top; +} + +td.indexvalue { + background-color: #EBEFF6; + border: 1px solid #C4CFE5; + padding: 2px 10px; + margin: 2px 0px; +} + +tr.memlist { + background-color: #EEF1F7; +} + +p.formulaDsp { + text-align: center; +} + +img.formulaDsp { + +} + +img.formulaInl, img.inline { + vertical-align: middle; +} + +div.center { + text-align: center; + margin-top: 0px; + margin-bottom: 0px; + padding: 0px; +} + +div.center img { + border: 0px; +} + +address.footer { + text-align: right; + padding-right: 12px; +} + +img.footer { + border: 0px; + vertical-align: middle; +} + +/* @group Code Colorization */ + +span.keyword { + color: #008000 +} + +span.keywordtype { + color: #604020 +} + +span.keywordflow { + color: #e08000 +} + +span.comment { + color: #800000 +} + +span.preprocessor { + color: #806020 +} + +span.stringliteral { + color: #002080 +} + +span.charliteral { + color: #008080 +} + +span.vhdldigit { + color: #ff00ff +} + +span.vhdlchar { + color: #000000 +} + +span.vhdlkeyword { + color: #700070 +} + +span.vhdllogic { + color: #ff0000 +} + +blockquote { + background-color: #F7F8FB; + border-left: 2px solid #9CAFD4; + margin: 0 24px 0 4px; + padding: 0 12px 0 16px; +} + +blockquote.DocNodeRTL { + border-left: 0; + border-right: 2px solid #9CAFD4; + margin: 0 4px 0 24px; + padding: 0 16px 0 12px; +} + +/* @end */ + +/* +.search { + color: #003399; + font-weight: bold; +} + +form.search { + margin-bottom: 0px; + margin-top: 0px; +} + +input.search { + font-size: 75%; + color: #000080; + font-weight: normal; + background-color: #e8eef2; +} +*/ + +td.tiny { + font-size: 75%; +} + +.dirtab { + padding: 4px; + border-collapse: collapse; + border: 1px solid #A3B4D7; +} + +th.dirtab { + background: #EBEFF6; + font-weight: bold; +} + +hr { + height: 0px; + border: none; + border-top: 1px solid #4A6AAA; +} + +hr.footer { + height: 1px; +} + +/* @group Member Descriptions */ + +table.memberdecls { + border-spacing: 0px; + padding: 0px; +} + +.memberdecls td, .fieldtable tr { + -webkit-transition-property: background-color, box-shadow; + -webkit-transition-duration: 0.5s; + -moz-transition-property: background-color, box-shadow; + -moz-transition-duration: 0.5s; + -ms-transition-property: background-color, box-shadow; + -ms-transition-duration: 0.5s; + -o-transition-property: background-color, box-shadow; + -o-transition-duration: 0.5s; + transition-property: background-color, box-shadow; + transition-duration: 0.5s; +} + +.memberdecls td.glow, .fieldtable tr.glow { + background-color: cyan; + box-shadow: 0 0 15px cyan; +} + +.mdescLeft, .mdescRight, +.memItemLeft, .memItemRight, +.memTemplItemLeft, .memTemplItemRight, .memTemplParams { + background-color: #F9FAFC; + border: none; + margin: 4px; + padding: 1px 0 0 8px; +} + +.mdescLeft, .mdescRight { + padding: 0px 8px 4px 8px; + color: #555; +} + +.memSeparator { + border-bottom: 1px solid #DEE4F0; + line-height: 1px; + margin: 0px; + padding: 0px; +} + +.memItemLeft, .memTemplItemLeft { + white-space: nowrap; +} + +.memItemRight, .memTemplItemRight { + width: 100%; +} + +.memTemplParams { + color: #4665A2; + white-space: nowrap; + font-size: 80%; +} + +/* @end */ + +/* @group Member Details */ + +/* Styles for detailed member documentation */ + +.memtitle { + padding: 8px; + border-top: 1px solid #A8B8D9; + border-left: 1px solid #A8B8D9; + border-right: 1px solid #A8B8D9; + border-top-right-radius: 4px; + border-top-left-radius: 4px; + margin-bottom: -1px; + background-image: url('nav_f.png'); + background-repeat: repeat-x; + background-color: #E2E8F2; + line-height: 1.25; + font-weight: 300; + float:left; +} + +.permalink +{ + font-size: 65%; + display: inline-block; + vertical-align: middle; +} + +.memtemplate { + font-size: 80%; + color: #4665A2; + font-weight: normal; + margin-left: 9px; +} + +.memnav { + background-color: #EBEFF6; + border: 1px solid #A3B4D7; + text-align: center; + margin: 2px; + margin-right: 15px; + padding: 2px; +} + +.mempage { + width: 100%; +} + +.memitem { + padding: 0; + margin-bottom: 10px; + margin-right: 5px; + -webkit-transition: box-shadow 0.5s linear; + -moz-transition: box-shadow 0.5s linear; + -ms-transition: box-shadow 0.5s linear; + -o-transition: box-shadow 0.5s linear; + transition: box-shadow 0.5s linear; + display: table !important; + width: 100%; +} + +.memitem.glow { + box-shadow: 0 0 15px cyan; +} + +.memname { + font-weight: 400; + margin-left: 6px; +} + +.memname td { + vertical-align: bottom; +} + +.memproto, dl.reflist dt { + border-top: 1px solid #A8B8D9; + border-left: 1px solid #A8B8D9; + border-right: 1px solid #A8B8D9; + padding: 6px 0px 6px 0px; + color: #253555; + font-weight: bold; + text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9); + background-color: #DFE5F1; + /* opera specific markup */ + box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); + border-top-right-radius: 4px; + /* firefox specific markup */ + -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; + -moz-border-radius-topright: 4px; + /* webkit specific markup */ + -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); + -webkit-border-top-right-radius: 4px; + +} + +.overload { + font-family: "courier new",courier,monospace; + font-size: 65%; +} + +.memdoc, dl.reflist dd { + border-bottom: 1px solid #A8B8D9; + border-left: 1px solid #A8B8D9; + border-right: 1px solid #A8B8D9; + padding: 6px 10px 2px 10px; + background-color: #FBFCFD; + border-top-width: 0; + background-image:url('nav_g.png'); + background-repeat:repeat-x; + background-color: #FFFFFF; + /* opera specific markup */ + border-bottom-left-radius: 4px; + border-bottom-right-radius: 4px; + box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); + /* firefox specific markup */ + -moz-border-radius-bottomleft: 4px; + -moz-border-radius-bottomright: 4px; + -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; + /* webkit specific markup */ + -webkit-border-bottom-left-radius: 4px; + -webkit-border-bottom-right-radius: 4px; + -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); +} + +dl.reflist dt { + padding: 5px; +} + +dl.reflist dd { + margin: 0px 0px 10px 0px; + padding: 5px; +} + +.paramkey { + text-align: right; +} + +.paramtype { + white-space: nowrap; +} + +.paramname { + color: #602020; + white-space: nowrap; +} +.paramname em { + font-style: normal; +} +.paramname code { + line-height: 14px; +} + +.params, .retval, .exception, .tparams { + margin-left: 0px; + padding-left: 0px; +} + +.params .paramname, .retval .paramname, .tparams .paramname, .exception .paramname { + font-weight: bold; + vertical-align: top; +} + +.params .paramtype, .tparams .paramtype { + font-style: italic; + vertical-align: top; +} + +.params .paramdir, .tparams .paramdir { + font-family: "courier new",courier,monospace; + vertical-align: top; +} + +table.mlabels { + border-spacing: 0px; +} + +td.mlabels-left { + width: 100%; + padding: 0px; +} + +td.mlabels-right { + vertical-align: bottom; + padding: 0px; + white-space: nowrap; +} + +span.mlabels { + margin-left: 8px; +} + +span.mlabel { + background-color: #728DC1; + border-top:1px solid #5373B4; + border-left:1px solid #5373B4; + border-right:1px solid #C4CFE5; + border-bottom:1px solid #C4CFE5; + text-shadow: none; + color: white; + margin-right: 4px; + padding: 2px 3px; + border-radius: 3px; + font-size: 7pt; + white-space: nowrap; + vertical-align: middle; +} + + + +/* @end */ + +/* these are for tree view inside a (index) page */ + +div.directory { + margin: 10px 0px; + border-top: 1px solid #9CAFD4; + border-bottom: 1px solid #9CAFD4; + width: 100%; +} + +.directory table { + border-collapse:collapse; +} + +.directory td { + margin: 0px; + padding: 0px; + vertical-align: top; +} + +.directory td.entry { + white-space: nowrap; + padding-right: 6px; + padding-top: 3px; +} + +.directory td.entry a { + outline:none; +} + +.directory td.entry a img { + border: none; +} + +.directory td.desc { + width: 100%; + padding-left: 6px; + padding-right: 6px; + padding-top: 3px; + border-left: 1px solid rgba(0,0,0,0.05); +} + +.directory tr.even { + padding-left: 6px; + background-color: #F7F8FB; +} + +.directory img { + vertical-align: -30%; +} + +.directory .levels { + white-space: nowrap; + width: 100%; + text-align: right; + font-size: 9pt; +} + +.directory .levels span { + cursor: pointer; + padding-left: 2px; + padding-right: 2px; + color: #3D578C; +} + +.arrow { + color: #9CAFD4; + -webkit-user-select: none; + -khtml-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + cursor: pointer; + font-size: 80%; + display: inline-block; + width: 16px; + height: 22px; +} + +.icon { + font-family: Arial, Helvetica; + font-weight: bold; + font-size: 12px; + height: 14px; + width: 16px; + display: inline-block; + background-color: #728DC1; + color: white; + text-align: center; + border-radius: 4px; + margin-left: 2px; + margin-right: 2px; +} + +.icona { + width: 24px; + height: 22px; + display: inline-block; +} + +.iconfopen { + width: 24px; + height: 18px; + margin-bottom: 4px; + background-image:url('folderopen.png'); + background-position: 0px -4px; + background-repeat: repeat-y; + vertical-align:top; + display: inline-block; +} + +.iconfclosed { + width: 24px; + height: 18px; + margin-bottom: 4px; + background-image:url('folderclosed.png'); + background-position: 0px -4px; + background-repeat: repeat-y; + vertical-align:top; + display: inline-block; +} + +.icondoc { + width: 24px; + height: 18px; + margin-bottom: 4px; + background-image:url('doc.png'); + background-position: 0px -4px; + background-repeat: repeat-y; + vertical-align:top; + display: inline-block; +} + +table.directory { + font: 400 14px Roboto,sans-serif; +} + +/* @end */ + +div.dynheader { + margin-top: 8px; + -webkit-touch-callout: none; + -webkit-user-select: none; + -khtml-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} + +address { + font-style: normal; + color: #2A3D61; +} + +table.doxtable caption { + caption-side: top; +} + +table.doxtable { + border-collapse:collapse; + margin-top: 4px; + margin-bottom: 4px; +} + +table.doxtable td, table.doxtable th { + border: 1px solid #2D4068; + padding: 3px 7px 2px; +} + +table.doxtable th { + background-color: #374F7F; + color: #FFFFFF; + font-size: 110%; + padding-bottom: 4px; + padding-top: 5px; +} + +table.fieldtable { + /*width: 100%;*/ + margin-bottom: 10px; + border: 1px solid #A8B8D9; + border-spacing: 0px; + -moz-border-radius: 4px; + -webkit-border-radius: 4px; + border-radius: 4px; + -moz-box-shadow: rgba(0, 0, 0, 0.15) 2px 2px 2px; + -webkit-box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.15); + box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.15); +} + +.fieldtable td, .fieldtable th { + padding: 3px 7px 2px; +} + +.fieldtable td.fieldtype, .fieldtable td.fieldname { + white-space: nowrap; + border-right: 1px solid #A8B8D9; + border-bottom: 1px solid #A8B8D9; + vertical-align: top; +} + +.fieldtable td.fieldname { + padding-top: 3px; +} + +.fieldtable td.fielddoc { + border-bottom: 1px solid #A8B8D9; + /*width: 100%;*/ +} + +.fieldtable td.fielddoc p:first-child { + margin-top: 0px; +} + +.fieldtable td.fielddoc p:last-child { + margin-bottom: 2px; +} + +.fieldtable tr:last-child td { + border-bottom: none; +} + +.fieldtable th { + background-image:url('nav_f.png'); + background-repeat:repeat-x; + background-color: #E2E8F2; + font-size: 90%; + color: #253555; + padding-bottom: 4px; + padding-top: 5px; + text-align:left; + font-weight: 400; + -moz-border-radius-topleft: 4px; + -moz-border-radius-topright: 4px; + -webkit-border-top-left-radius: 4px; + -webkit-border-top-right-radius: 4px; + border-top-left-radius: 4px; + border-top-right-radius: 4px; + border-bottom: 1px solid #A8B8D9; +} + + +.tabsearch { + top: 0px; + left: 10px; + height: 36px; + background-image: url('tab_b.png'); + z-index: 101; + overflow: hidden; + font-size: 13px; +} + +.navpath ul +{ + font-size: 11px; + background-image:url('tab_b.png'); + background-repeat:repeat-x; + background-position: 0 -5px; + height:30px; + line-height:30px; + color:#8AA0CC; + border:solid 1px #C2CDE4; + overflow:hidden; + margin:0px; + padding:0px; +} + +.navpath li +{ + list-style-type:none; + float:left; + padding-left:10px; + padding-right:15px; + background-image:url('bc_s.png'); + background-repeat:no-repeat; + background-position:right; + color:#364D7C; +} + +.navpath li.navelem a +{ + height:32px; + display:block; + text-decoration: none; + outline: none; + color: #283A5D; + font-family: 'Lucida Grande',Geneva,Helvetica,Arial,sans-serif; + text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9); + text-decoration: none; +} + +.navpath li.navelem a:hover +{ + color:#6884BD; +} + +.navpath li.footer +{ + list-style-type:none; + float:right; + padding-left:10px; + padding-right:15px; + background-image:none; + background-repeat:no-repeat; + background-position:right; + color:#364D7C; + font-size: 8pt; +} + + +div.summary +{ + float: right; + font-size: 8pt; + padding-right: 5px; + width: 50%; + text-align: right; +} + +div.summary a +{ + white-space: nowrap; +} + +table.classindex +{ + margin: 10px; + white-space: nowrap; + margin-left: 3%; + margin-right: 3%; + width: 94%; + border: 0; + border-spacing: 0; + padding: 0; +} + +div.ingroups +{ + font-size: 8pt; + width: 50%; + text-align: left; +} + +div.ingroups a +{ + white-space: nowrap; +} + +div.header +{ + background-image:url('nav_h.png'); + background-repeat:repeat-x; + background-color: #F9FAFC; + margin: 0px; + border-bottom: 1px solid #C4CFE5; +} + +div.headertitle +{ + padding: 5px 5px 5px 10px; +} + +.PageDocRTL-title div.headertitle { + text-align: right; + direction: rtl; +} + +dl { + padding: 0 0 0 0; +} + +/* dl.note, dl.warning, dl.attention, dl.pre, dl.post, dl.invariant, dl.deprecated, dl.todo, dl.test, dl.bug, dl.examples */ +dl.section { + margin-left: 0px; + padding-left: 0px; +} + +dl.section.DocNodeRTL { + margin-right: 0px; + padding-right: 0px; +} + +dl.note { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #D0C000; +} + +dl.note.DocNodeRTL { + margin-left: 0; + padding-left: 0; + border-left: 0; + margin-right: -7px; + padding-right: 3px; + border-right: 4px solid; + border-color: #D0C000; +} + +dl.warning, dl.attention { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #FF0000; +} + +dl.warning.DocNodeRTL, dl.attention.DocNodeRTL { + margin-left: 0; + padding-left: 0; + border-left: 0; + margin-right: -7px; + padding-right: 3px; + border-right: 4px solid; + border-color: #FF0000; +} + +dl.pre, dl.post, dl.invariant { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #00D000; +} + +dl.pre.DocNodeRTL, dl.post.DocNodeRTL, dl.invariant.DocNodeRTL { + margin-left: 0; + padding-left: 0; + border-left: 0; + margin-right: -7px; + padding-right: 3px; + border-right: 4px solid; + border-color: #00D000; +} + +dl.deprecated { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #505050; +} + +dl.deprecated.DocNodeRTL { + margin-left: 0; + padding-left: 0; + border-left: 0; + margin-right: -7px; + padding-right: 3px; + border-right: 4px solid; + border-color: #505050; +} + +dl.todo { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #00C0E0; +} + +dl.todo.DocNodeRTL { + margin-left: 0; + padding-left: 0; + border-left: 0; + margin-right: -7px; + padding-right: 3px; + border-right: 4px solid; + border-color: #00C0E0; +} + +dl.test { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #3030E0; +} + +dl.test.DocNodeRTL { + margin-left: 0; + padding-left: 0; + border-left: 0; + margin-right: -7px; + padding-right: 3px; + border-right: 4px solid; + border-color: #3030E0; +} + +dl.bug { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #C08050; +} + +dl.bug.DocNodeRTL { + margin-left: 0; + padding-left: 0; + border-left: 0; + margin-right: -7px; + padding-right: 3px; + border-right: 4px solid; + border-color: #C08050; +} + +dl.section dd { + margin-bottom: 6px; +} + + +#projectlogo +{ + text-align: center; + vertical-align: bottom; + border-collapse: separate; +} + +#projectlogo img +{ + border: 0px none; +} + +#projectalign +{ + vertical-align: middle; +} + +#projectname +{ + font: 300% Tahoma, Arial,sans-serif; + margin: 0px; + padding: 2px 0px; +} + +#projectbrief +{ + font: 120% Tahoma, Arial,sans-serif; + margin: 0px; + padding: 0px; +} + +#projectnumber +{ + font: 50% Tahoma, Arial,sans-serif; + margin: 0px; + padding: 0px; +} + +#titlearea +{ + padding: 0px; + margin: 0px; + width: 100%; + border-bottom: 1px solid #5373B4; +} + +.image +{ + text-align: center; +} + +.dotgraph +{ + text-align: center; +} + +.mscgraph +{ + text-align: center; +} + +.plantumlgraph +{ + text-align: center; +} + +.diagraph +{ + text-align: center; +} + +.caption +{ + font-weight: bold; +} + +div.zoom +{ + border: 1px solid #90A5CE; +} + +dl.citelist { + margin-bottom:50px; +} + +dl.citelist dt { + color:#334975; + float:left; + font-weight:bold; + margin-right:10px; + padding:5px; +} + +dl.citelist dd { + margin:2px 0; + padding:5px 0; +} + +div.toc { + padding: 14px 25px; + background-color: #F4F6FA; + border: 1px solid #D8DFEE; + border-radius: 7px 7px 7px 7px; + float: right; + height: auto; + margin: 0 8px 10px 10px; + width: 200px; +} + +.PageDocRTL-title div.toc { + float: left !important; + text-align: right; +} + +div.toc li { + background: url("bdwn.png") no-repeat scroll 0 5px transparent; + font: 10px/1.2 Verdana,DejaVu Sans,Geneva,sans-serif; + margin-top: 5px; + padding-left: 10px; + padding-top: 2px; +} + +.PageDocRTL-title div.toc li { + background-position-x: right !important; + padding-left: 0 !important; + padding-right: 10px; +} + +div.toc h3 { + font: bold 12px/1.2 Arial,FreeSans,sans-serif; + color: #4665A2; + border-bottom: 0 none; + margin: 0; +} + +div.toc ul { + list-style: none outside none; + border: medium none; + padding: 0px; +} + +div.toc li.level1 { + margin-left: 0px; +} + +div.toc li.level2 { + margin-left: 15px; +} + +div.toc li.level3 { + margin-left: 30px; +} + +div.toc li.level4 { + margin-left: 45px; +} + +.PageDocRTL-title div.toc li.level1 { + margin-left: 0 !important; + margin-right: 0; +} + +.PageDocRTL-title div.toc li.level2 { + margin-left: 0 !important; + margin-right: 15px; +} + +.PageDocRTL-title div.toc li.level3 { + margin-left: 0 !important; + margin-right: 30px; +} + +.PageDocRTL-title div.toc li.level4 { + margin-left: 0 !important; + margin-right: 45px; +} + +.inherit_header { + font-weight: bold; + color: gray; + cursor: pointer; + -webkit-touch-callout: none; + -webkit-user-select: none; + -khtml-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} + +.inherit_header td { + padding: 6px 0px 2px 5px; +} + +.inherit { + display: none; +} + +tr.heading h2 { + margin-top: 12px; + margin-bottom: 4px; +} + +/* tooltip related style info */ + +.ttc { + position: absolute; + display: none; +} + +#powerTip { + cursor: default; + white-space: nowrap; + background-color: white; + border: 1px solid gray; + border-radius: 4px 4px 4px 4px; + box-shadow: 1px 1px 7px gray; + display: none; + font-size: smaller; + max-width: 80%; + opacity: 0.9; + padding: 1ex 1em 1em; + position: absolute; + z-index: 2147483647; +} + +#powerTip div.ttdoc { + color: grey; + font-style: italic; +} + +#powerTip div.ttname a { + font-weight: bold; +} + +#powerTip div.ttname { + font-weight: bold; +} + +#powerTip div.ttdeci { + color: #006318; +} + +#powerTip div { + margin: 0px; + padding: 0px; + font: 12px/16px Roboto,sans-serif; +} + +#powerTip:before, #powerTip:after { + content: ""; + position: absolute; + margin: 0px; +} + +#powerTip.n:after, #powerTip.n:before, +#powerTip.s:after, #powerTip.s:before, +#powerTip.w:after, #powerTip.w:before, +#powerTip.e:after, #powerTip.e:before, +#powerTip.ne:after, #powerTip.ne:before, +#powerTip.se:after, #powerTip.se:before, +#powerTip.nw:after, #powerTip.nw:before, +#powerTip.sw:after, #powerTip.sw:before { + border: solid transparent; + content: " "; + height: 0; + width: 0; + position: absolute; +} + +#powerTip.n:after, #powerTip.s:after, +#powerTip.w:after, #powerTip.e:after, +#powerTip.nw:after, #powerTip.ne:after, +#powerTip.sw:after, #powerTip.se:after { + border-color: rgba(255, 255, 255, 0); +} + +#powerTip.n:before, #powerTip.s:before, +#powerTip.w:before, #powerTip.e:before, +#powerTip.nw:before, #powerTip.ne:before, +#powerTip.sw:before, #powerTip.se:before { + border-color: rgba(128, 128, 128, 0); +} + +#powerTip.n:after, #powerTip.n:before, +#powerTip.ne:after, #powerTip.ne:before, +#powerTip.nw:after, #powerTip.nw:before { + top: 100%; +} + +#powerTip.n:after, #powerTip.ne:after, #powerTip.nw:after { + border-top-color: #FFFFFF; + border-width: 10px; + margin: 0px -10px; +} +#powerTip.n:before { + border-top-color: #808080; + border-width: 11px; + margin: 0px -11px; +} +#powerTip.n:after, #powerTip.n:before { + left: 50%; +} + +#powerTip.nw:after, #powerTip.nw:before { + right: 14px; +} + +#powerTip.ne:after, #powerTip.ne:before { + left: 14px; +} + +#powerTip.s:after, #powerTip.s:before, +#powerTip.se:after, #powerTip.se:before, +#powerTip.sw:after, #powerTip.sw:before { + bottom: 100%; +} + +#powerTip.s:after, #powerTip.se:after, #powerTip.sw:after { + border-bottom-color: #FFFFFF; + border-width: 10px; + margin: 0px -10px; +} + +#powerTip.s:before, #powerTip.se:before, #powerTip.sw:before { + border-bottom-color: #808080; + border-width: 11px; + margin: 0px -11px; +} + +#powerTip.s:after, #powerTip.s:before { + left: 50%; +} + +#powerTip.sw:after, #powerTip.sw:before { + right: 14px; +} + +#powerTip.se:after, #powerTip.se:before { + left: 14px; +} + +#powerTip.e:after, #powerTip.e:before { + left: 100%; +} +#powerTip.e:after { + border-left-color: #FFFFFF; + border-width: 10px; + top: 50%; + margin-top: -10px; +} +#powerTip.e:before { + border-left-color: #808080; + border-width: 11px; + top: 50%; + margin-top: -11px; +} + +#powerTip.w:after, #powerTip.w:before { + right: 100%; +} +#powerTip.w:after { + border-right-color: #FFFFFF; + border-width: 10px; + top: 50%; + margin-top: -10px; +} +#powerTip.w:before { + border-right-color: #808080; + border-width: 11px; + top: 50%; + margin-top: -11px; +} + +@media print +{ + #top { display: none; } + #side-nav { display: none; } + #nav-path { display: none; } + body { overflow:visible; } + h1, h2, h3, h4, h5, h6 { page-break-after: avoid; } + .summary { display: none; } + .memitem { page-break-inside: avoid; } + #doc-content + { + margin-left:0 !important; + height:auto !important; + width:auto !important; + overflow:inherit; + display:inline; + } +} + +/* @group Markdown */ + +/* +table.markdownTable { + border-collapse:collapse; + margin-top: 4px; + margin-bottom: 4px; +} + +table.markdownTable td, table.markdownTable th { + border: 1px solid #2D4068; + padding: 3px 7px 2px; +} + +table.markdownTableHead tr { +} + +table.markdownTableBodyLeft td, table.markdownTable th { + border: 1px solid #2D4068; + padding: 3px 7px 2px; +} + +th.markdownTableHeadLeft th.markdownTableHeadRight th.markdownTableHeadCenter th.markdownTableHeadNone { + background-color: #374F7F; + color: #FFFFFF; + font-size: 110%; + padding-bottom: 4px; + padding-top: 5px; +} + +th.markdownTableHeadLeft { + text-align: left +} + +th.markdownTableHeadRight { + text-align: right +} + +th.markdownTableHeadCenter { + text-align: center +} +*/ + +table.markdownTable { + border-collapse:collapse; + margin-top: 4px; + margin-bottom: 4px; +} + +table.markdownTable td, table.markdownTable th { + border: 1px solid #2D4068; + padding: 3px 7px 2px; +} + +table.markdownTable tr { +} + +th.markdownTableHeadLeft, th.markdownTableHeadRight, th.markdownTableHeadCenter, th.markdownTableHeadNone { + background-color: #374F7F; + color: #FFFFFF; + font-size: 110%; + padding-bottom: 4px; + padding-top: 5px; +} + +th.markdownTableHeadLeft, td.markdownTableBodyLeft { + text-align: left +} + +th.markdownTableHeadRight, td.markdownTableBodyRight { + text-align: right +} + +th.markdownTableHeadCenter, td.markdownTableBodyCenter { + text-align: center +} + +.DocNodeRTL { + text-align: right; + direction: rtl; +} + +.DocNodeLTR { + text-align: left; + direction: ltr; +} + +table.DocNodeRTL { + width: auto; + margin-right: 0; + margin-left: auto; +} + +table.DocNodeLTR { + width: auto; + margin-right: auto; + margin-left: 0; +} + +tt, code, kbd, samp +{ + display: inline-block; + direction:ltr; +} +/* @end */ + +u { + text-decoration: underline; +} + diff --git a/doxygen.png b/doxygen.png new file mode 100644 index 0000000..3ff17d8 Binary files /dev/null and b/doxygen.png differ diff --git a/dynsections.js b/dynsections.js new file mode 100644 index 0000000..ea0a7b3 --- /dev/null +++ b/dynsections.js @@ -0,0 +1,120 @@ +/* + @licstart The following is the entire license notice for the + JavaScript code in this file. + + Copyright (C) 1997-2017 by Dimitri van Heesch + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + + @licend The above is the entire license notice + for the JavaScript code in this file + */ +function toggleVisibility(linkObj) +{ + var base = $(linkObj).attr('id'); + var summary = $('#'+base+'-summary'); + var content = $('#'+base+'-content'); + var trigger = $('#'+base+'-trigger'); + var src=$(trigger).attr('src'); + if (content.is(':visible')===true) { + content.hide(); + summary.show(); + $(linkObj).addClass('closed').removeClass('opened'); + $(trigger).attr('src',src.substring(0,src.length-8)+'closed.png'); + } else { + content.show(); + summary.hide(); + $(linkObj).removeClass('closed').addClass('opened'); + $(trigger).attr('src',src.substring(0,src.length-10)+'open.png'); + } + return false; +} + +function updateStripes() +{ + $('table.directory tr'). + removeClass('even').filter(':visible:even').addClass('even'); +} + +function toggleLevel(level) +{ + $('table.directory tr').each(function() { + var l = this.id.split('_').length-1; + var i = $('#img'+this.id.substring(3)); + var a = $('#arr'+this.id.substring(3)); + if (l + + + + + + +libevent: event2/event.h File Reference + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+ +
+
event.h File Reference
+
+
+ +

Core functions for waiting for and receiving events, and using event bases. +More...

+
#include <event2/visibility.h>
+#include <event2/event-config.h>
+#include <stdio.h>
+#include <event2/util.h>
+
+

Go to the source code of this file.

+ + + + + + + + + + + +

+Data Structures

struct  event
 Structure to represent a single event. More...
 
struct  event_base
 Structure to hold information and state for a Libevent dispatch loop. More...
 
struct  event_config
 Configuration for an event_base. More...
 
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+Macros

+#define _EVENT_LOG_DEBUG   EVENT_LOG_DEBUG
 
+#define _EVENT_LOG_ERR   EVENT_LOG_ERR
 
+#define _EVENT_LOG_MSG   EVENT_LOG_MSG
 
+#define _EVENT_LOG_WARN   EVENT_LOG_WARN
 
+#define EVENT_DBG_ALL   0xffffffffu
 
+#define EVENT_DBG_NONE   0
 
+#define event_get_signal(ev)   ((int)event_get_fd(ev))
 Get the signal number assigned to a signal event.
 
+#define EVENT_MAX_PRIORITIES   256
 Largest number of priorities that Libevent can support.
 
+#define EVENT_SET_MEM_FUNCTIONS_IMPLEMENTED
 This definition is present if Libevent was built with support for event_set_mem_functions()
 
+#define LIBEVENT_VERSION   EVENT__VERSION
 As event_get_version, but gives the version of Libevent's headers.
 
+#define LIBEVENT_VERSION_NUMBER   EVENT__NUMERIC_VERSION
 As event_get_version_number, but gives the version number of Libevent's headers.
 
event type flag

Flags to pass to event_base_get_num_events() to specify the kinds of events we want to aggregate counts for

+
+#define EVENT_BASE_COUNT_ACTIVE   1U
 count the number of active events, which have been triggered.
 
+#define EVENT_BASE_COUNT_ADDED   4U
 count the number of events which have been added to event base, including internal events.
 
+#define EVENT_BASE_COUNT_VIRTUAL   2U
 count the number of virtual events, which is used to represent an internal condition, other than a pending event, that keeps the loop from exiting.
 
Log severities
+#define EVENT_LOG_DEBUG   0
 
+#define EVENT_LOG_ERR   3
 
+#define EVENT_LOG_MSG   1
 
+#define EVENT_LOG_WARN   2
 
Loop flags

These flags control the behavior of event_base_loop().

+
#define EVLOOP_NO_EXIT_ON_EMPTY   0x04
 Do not exit the loop because we have no pending events. More...
 
+#define EVLOOP_NONBLOCK   0x02
 Do not block: see which events are ready now, run the callbacks of the highest-priority ones, then exit.
 
+#define EVLOOP_ONCE   0x01
 Block until we have an active event, then exit once all active events have had their callbacks run.
 
event flags

Flags to pass to event_new(), event_assign(), event_pending(), and anything else with an argument of the form "short events"

+
#define EV_CLOSED   0x80
 Detects connection close events. More...
 
+#define EV_ET   0x20
 Select edge-triggered behavior, if supported by the backend.
 
#define EV_FINALIZE   0x40
 If this option is provided, then event_del() will not block in one thread while waiting for the event callback to complete in another thread. More...
 
#define EV_PERSIST   0x10
 Persistent event: won't get removed automatically when activated. More...
 
+#define EV_READ   0x02
 Wait for a socket or FD to become readable.
 
+#define EV_SIGNAL   0x08
 Wait for a POSIX signal to be raised.
 
#define EV_TIMEOUT   0x01
 Indicates that a timeout has occurred. More...
 
+#define EV_WRITE   0x04
 Wait for a socket or FD to become writeable.
 
evtimer_* macros

Aliases for working with one-shot timer events If you need EV_PERSIST timer use event_*() functions.

+
+#define evtimer_add(ev, tv)   event_add((ev), (tv))
 
+#define evtimer_assign(ev, b, cb, arg)   event_assign((ev), (b), -1, 0, (cb), (arg))
 
+#define evtimer_del(ev)   event_del(ev)
 
+#define evtimer_initialized(ev)   event_initialized(ev)
 
+#define evtimer_new(b, cb, arg)   event_new((b), -1, 0, (cb), (arg))
 
+#define evtimer_pending(ev, tv)   event_pending((ev), EV_TIMEOUT, (tv))
 
evsignal_* macros

Aliases for working with signal events

+
+#define evsignal_add(ev, tv)   event_add((ev), (tv))
 
+#define evsignal_assign(ev, b, x, cb, arg)   event_assign((ev), (b), (x), EV_SIGNAL|EV_PERSIST, cb, (arg))
 
+#define evsignal_del(ev)   event_del(ev)
 
+#define evsignal_initialized(ev)   event_initialized(ev)
 
+#define evsignal_new(b, x, cb, arg)   event_new((b), (x), EV_SIGNAL|EV_PERSIST, (cb), (arg))
 
+#define evsignal_pending(ev, tv)   event_pending((ev), EV_SIGNAL, (tv))
 
evuser_* macros

Aliases for working with user-triggered events If you need EV_PERSIST event use event_*() functions.

+
+#define evuser_del(ev)   event_del(ev)
 
+#define evuser_initialized(ev)   event_initialized(ev)
 
+#define evuser_new(b, cb, arg)   event_new((b), -1, 0, (cb), (arg))
 
+#define evuser_pending(ev, tv)   event_pending((ev), 0, (tv))
 
+#define evuser_trigger(ev)   event_active((ev), 0, 0)
 
+ + + + + + + + + + + + + + + + +

+Typedefs

+typedef int(* event_base_foreach_event_cb) (const struct event_base *, const struct event *, void *)
 Callback for iterating events in an event base via event_base_foreach_event.
 
typedef void(* event_callback_fn) (evutil_socket_t, short, void *)
 A callback function for an event. More...
 
typedef void(* event_fatal_cb) (int err)
 A function to be called if Libevent encounters a fatal internal error. More...
 
+typedef void(* event_finalize_callback_fn) (struct event *, void *)
 Callback type for event_finalize and event_free_finalize().
 
typedef void(* event_log_cb) (int severity, const char *msg)
 A callback function used to intercept Libevent's log messages. More...
 
+ + + + + + + +

+Enumerations

enum  event_base_config_flag {
+  EVENT_BASE_FLAG_NOLOCK = 0x01, +EVENT_BASE_FLAG_IGNORE_ENV = 0x02, +EVENT_BASE_FLAG_STARTUP_IOCP = 0x04, +EVENT_BASE_FLAG_NO_CACHE_TIME = 0x08, +
+  EVENT_BASE_FLAG_EPOLL_USE_CHANGELIST = 0x10, +EVENT_BASE_FLAG_PRECISE_TIMER = 0x20, +EVENT_BASE_FLAG_EPOLL_DISALLOW_TIMERFD = 0x40, +EVENT_BASE_FLAG_USE_SIGNALFD = 0x80 +
+ }
 A flag passed to event_config_set_flag(). More...
 
enum  event_method_feature { EV_FEATURE_ET = 0x01, +EV_FEATURE_O1 = 0x02, +EV_FEATURE_FDS = 0x04, +EV_FEATURE_EARLY_CLOSE = 0x08 + }
 A flag used to describe which features an event_base (must) provide. More...
 
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+Functions

EVENT2_EXPORT_SYMBOL void event_active (struct event *ev, int res, short ncalls)
 Make an event active. More...
 
EVENT2_EXPORT_SYMBOL int event_add (struct event *ev, const struct timeval *timeout)
 Add an event to the set of pending events. More...
 
EVENT2_EXPORT_SYMBOL int event_assign (struct event *ev, struct event_base *base, evutil_socket_t fd, short events, event_callback_fn callback, void *callback_arg)
 Prepare a new, already-allocated event structure to be added. More...
 
EVENT2_EXPORT_SYMBOL void event_base_active_by_fd (struct event_base *base, evutil_socket_t fd, short events)
 Activates all pending events for the given fd and event mask. More...
 
EVENT2_EXPORT_SYMBOL void event_base_active_by_signal (struct event_base *base, int sig)
 Activates all pending signals with a given signal number. More...
 
EVENT2_EXPORT_SYMBOL int event_base_dispatch (struct event_base *base)
 Event dispatching loop. More...
 
EVENT2_EXPORT_SYMBOL void event_base_dump_events (struct event_base *base, FILE *output)
 Writes a human-readable description of all inserted and/or active events to a provided stdio stream. More...
 
EVENT2_EXPORT_SYMBOL int event_base_foreach_event (struct event_base *base, event_base_foreach_event_cb fn, void *arg)
 Iterate over all added or active events events in an event loop, and invoke a given callback on each one. More...
 
EVENT2_EXPORT_SYMBOL void event_base_free (struct event_base *eb)
 Deallocate all memory associated with an event_base, and free the base. More...
 
+EVENT2_EXPORT_SYMBOL void event_base_free_nofinalize (struct event_base *)
 As event_base_free, but do not run finalizers.
 
EVENT2_EXPORT_SYMBOL int event_base_get_features (const struct event_base *base)
 Return a bitmask of the features implemented by an event base. More...
 
EVENT2_EXPORT_SYMBOL int event_base_get_max_events (struct event_base *eb, unsigned int flags, int clear)
 Get the maximum number of events in a given event_base as specified in the flags. More...
 
const EVENT2_EXPORT_SYMBOL char * event_base_get_method (const struct event_base *eb)
 Get the kernel event notification mechanism used by Libevent. More...
 
EVENT2_EXPORT_SYMBOL int event_base_get_npriorities (struct event_base *eb)
 Get the number of different event priorities. More...
 
EVENT2_EXPORT_SYMBOL int event_base_get_num_events (struct event_base *eb, unsigned int flags)
 Gets the number of events in event_base, as specified in the flags. More...
 
EVENT2_EXPORT_SYMBOL struct eventevent_base_get_running_event (struct event_base *base)
 If called from within the callback for an event, returns that event. More...
 
const EVENT2_EXPORT_SYMBOL char * event_base_get_signal_method (const struct event_base *eb)
 Get the kernel signal handling mechanism used by Libevent. More...
 
EVENT2_EXPORT_SYMBOL int event_base_gettimeofday_cached (struct event_base *base, struct timeval *tv)
 Sets 'tv' to the current time (as returned by gettimeofday()), looking at the cached value in 'base' if possible, and calling gettimeofday() or clock_gettime() as appropriate if there is no cached time. More...
 
EVENT2_EXPORT_SYMBOL int event_base_got_break (struct event_base *eb)
 Checks if the event loop was told to abort immediately by event_base_loopbreak(). More...
 
EVENT2_EXPORT_SYMBOL int event_base_got_exit (struct event_base *eb)
 Checks if the event loop was told to exit by event_base_loopexit(). More...
 
EVENT2_EXPORT_SYMBOL const struct timeval * event_base_init_common_timeout (struct event_base *base, const struct timeval *duration)
 Prepare an event_base to use a large number of timeouts with the same duration. More...
 
EVENT2_EXPORT_SYMBOL int event_base_loop (struct event_base *eb, int flags)
 Wait for events to become active, and run their callbacks. More...
 
EVENT2_EXPORT_SYMBOL int event_base_loopbreak (struct event_base *eb)
 Abort the active event_base_loop() immediately. More...
 
EVENT2_EXPORT_SYMBOL int event_base_loopcontinue (struct event_base *eb)
 Tell the active event_base_loop() to scan for new events immediately. More...
 
EVENT2_EXPORT_SYMBOL int event_base_loopexit (struct event_base *eb, const struct timeval *tv)
 Exit the event loop after the specified time. More...
 
EVENT2_EXPORT_SYMBOL struct event_baseevent_base_new (void)
 Create and return a new event_base to use with the rest of Libevent. More...
 
EVENT2_EXPORT_SYMBOL struct event_baseevent_base_new_with_config (const struct event_config *cfg)
 Initialize the event API. More...
 
EVENT2_EXPORT_SYMBOL int event_base_once (struct event_base *base, evutil_socket_t fd, short events, event_callback_fn callback, void *arg, const struct timeval *timeout)
 Schedule a one-time event. More...
 
EVENT2_EXPORT_SYMBOL int event_base_priority_init (struct event_base *eb, int npriorities)
 Set the number of different event priorities. More...
 
EVENT2_EXPORT_SYMBOL int event_base_set (struct event_base *eb, struct event *ev)
 Associate a different event base with an event. More...
 
EVENT2_EXPORT_SYMBOL int event_base_update_cache_time (struct event_base *base)
 Update cached_tv in the 'base' to the current time. More...
 
EVENT2_EXPORT_SYMBOL int event_config_avoid_method (struct event_config *cfg, const char *method)
 Enters an event method that should be avoided into the configuration. More...
 
EVENT2_EXPORT_SYMBOL void event_config_free (struct event_config *cfg)
 Deallocates all memory associated with an event configuration object. More...
 
EVENT2_EXPORT_SYMBOL struct event_configevent_config_new (void)
 Allocates a new event configuration object. More...
 
EVENT2_EXPORT_SYMBOL int event_config_require_features (struct event_config *cfg, int feature)
 Enters a required event method feature that the application demands. More...
 
EVENT2_EXPORT_SYMBOL int event_config_set_flag (struct event_config *cfg, int flag)
 Sets one or more flags to configure what parts of the eventual event_base will be initialized, and how they'll work. More...
 
EVENT2_EXPORT_SYMBOL int event_config_set_max_dispatch_interval (struct event_config *cfg, const struct timeval *max_interval, int max_callbacks, int min_priority)
 Record an interval and/or a number of callbacks after which the event base should check for new events. More...
 
EVENT2_EXPORT_SYMBOL int event_config_set_num_cpus_hint (struct event_config *cfg, int cpus)
 Records a hint for the number of CPUs in the system. More...
 
EVENT2_EXPORT_SYMBOL void event_debug_unassign (struct event *)
 When debugging mode is enabled, informs Libevent that an event should no longer be considered as assigned. More...
 
EVENT2_EXPORT_SYMBOL int event_del (struct event *ev)
 Remove an event from the set of monitored events. More...
 
+EVENT2_EXPORT_SYMBOL int event_del_block (struct event *ev)
 As event_del(), but always blocks while the event's callback is running in another thread, even if the event was constructed with the EV_FINALIZE flag.
 
+EVENT2_EXPORT_SYMBOL int event_del_noblock (struct event *ev)
 As event_del(), but never blocks while the event's callback is running in another thread, even if the event was constructed without the EV_FINALIZE flag.
 
EVENT2_EXPORT_SYMBOL void event_enable_debug_logging (ev_uint32_t which)
 Turn on debugging logs and have them sent to the default log handler. More...
 
EVENT2_EXPORT_SYMBOL void event_enable_debug_mode (void)
 Enable some relatively expensive debugging checks in Libevent that would normally be turned off. More...
 
EVENT2_EXPORT_SYMBOL void event_free (struct event *)
 Deallocate a struct event * returned by event_new(). More...
 
EVENT2_EXPORT_SYMBOL void event_get_assignment (const struct event *event, struct event_base **base_out, evutil_socket_t *fd_out, short *events_out, event_callback_fn *callback_out, void **arg_out)
 Extract all of arguments given to construct a given event. More...
 
+EVENT2_EXPORT_SYMBOL struct event_baseevent_get_base (const struct event *ev)
 Get the event_base associated with an event.
 
+EVENT2_EXPORT_SYMBOL event_callback_fn event_get_callback (const struct event *ev)
 Return the callback assigned to an event.
 
+EVENT2_EXPORT_SYMBOL void * event_get_callback_arg (const struct event *ev)
 Return the callback argument assigned to an event.
 
+EVENT2_EXPORT_SYMBOL short event_get_events (const struct event *ev)
 Return the events (EV_READ, EV_WRITE, etc) assigned to an event.
 
+EVENT2_EXPORT_SYMBOL evutil_socket_t event_get_fd (const struct event *ev)
 Get the socket or signal assigned to an event, or -1 if the event has no socket.
 
EVENT2_EXPORT_SYMBOL int event_get_priority (const struct event *ev)
 Return the priority of an event. More...
 
EVENT2_EXPORT_SYMBOL size_t event_get_struct_event_size (void)
 Return the size of struct event that the Libevent library was compiled with. More...
 
const EVENT2_EXPORT_SYMBOL char ** event_get_supported_methods (void)
 Gets all event notification mechanisms supported by Libevent. More...
 
const EVENT2_EXPORT_SYMBOL char * event_get_version (void)
 Get the Libevent version. More...
 
EVENT2_EXPORT_SYMBOL ev_uint32_t event_get_version_number (void)
 Return a numeric representation of Libevent's version. More...
 
+EVENT2_EXPORT_SYMBOL int event_gettime_monotonic (struct event_base *base, struct timeval *tp)
 Query the current monotonic time from the timer for a struct event_base.
 
EVENT2_EXPORT_SYMBOL int event_initialized (const struct event *ev)
 Test if an event structure might be initialized. More...
 
EVENT2_EXPORT_SYMBOL struct eventevent_new (struct event_base *base, evutil_socket_t fd, short events, event_callback_fn callback, void *callback_arg)
 Allocate and assign a new event structure, ready to be added. More...
 
EVENT2_EXPORT_SYMBOL int event_pending (const struct event *ev, short events, struct timeval *tv)
 Checks if a specific event is pending or scheduled. More...
 
EVENT2_EXPORT_SYMBOL int event_priority_set (struct event *ev, int priority)
 Assign a priority to an event. More...
 
EVENT2_EXPORT_SYMBOL int event_reinit (struct event_base *base)
 Reinitialize the event base after a fork. More...
 
EVENT2_EXPORT_SYMBOL int event_remove_timer (struct event *ev)
 Remove a timer from a pending event without removing the event itself. More...
 
EVENT2_EXPORT_SYMBOL void * event_self_cbarg (void)
 Return a value used to specify that the event itself must be used as the callback argument. More...
 
EVENT2_EXPORT_SYMBOL void event_set_fatal_callback (event_fatal_cb cb)
 Override Libevent's behavior in the event of a fatal internal error. More...
 
EVENT2_EXPORT_SYMBOL void event_set_log_callback (event_log_cb cb)
 Redirect Libevent's log messages. More...
 
EVENT2_EXPORT_SYMBOL void event_set_mem_functions (void *(*malloc_fn)(size_t sz), void *(*realloc_fn)(void *ptr, size_t sz), void(*free_fn)(void *ptr))
 Override the functions that Libevent uses for memory management. More...
 
EVENT2_EXPORT_SYMBOL void libevent_global_shutdown (void)
 Release up all globally-allocated resources allocated by Libevent. More...
 
Finalization functions

These functions are used to safely tear down an event in a multithreaded application.

+

If you construct your events with EV_FINALIZE to avoid deadlocks, you will need a way to remove an event in the certainty that it will definitely not be running its callback when you deallocate it and its callback argument.

+

To do this, call one of event_finalize() or event_free_finalize with 0 for its first argument, the event to tear down as its second argument, and a callback function as its third argument. The callback will be invoked as part of the event loop, with the event's priority.

+

After you call a finalizer function, event_add() and event_active() will no longer work on the event, and event_del() will produce a no-op. You must not try to change the event's fields with event_assign() or event_set() while the finalize callback is in progress. Once the callback has been invoked, you should treat the event structure as containing uninitialized memory.

+

The event_free_finalize() function frees the event after it's finalized; event_finalize() does not.

+

A finalizer callback must not make events pending or active. It must not add events, activate events, or attempt to "resuscitate" the event being finalized in any way.

+
Returns
0 on success, -1 on failure.
+
+EVENT2_EXPORT_SYMBOL int event_finalize (unsigned, struct event *, event_finalize_callback_fn)
 
+EVENT2_EXPORT_SYMBOL int event_free_finalize (unsigned, struct event *, event_finalize_callback_fn)
 
+

Detailed Description

+

Core functions for waiting for and receiving events, and using event bases.

+

Macro Definition Documentation

+ +

◆ EV_CLOSED

+ +
+
+ + + + +
#define EV_CLOSED   0x80
+
+ +

Detects connection close events.

+

You can use this to detect when a connection has been closed, without having to read all the pending data from a connection.

+

Not all backends support EV_CLOSED. To detect or require it, use the feature flag EV_FEATURE_EARLY_CLOSE.

+ +
+
+ +

◆ EV_FINALIZE

+ +
+
+ + + + +
#define EV_FINALIZE   0x40
+
+ +

If this option is provided, then event_del() will not block in one thread while waiting for the event callback to complete in another thread.

+

To use this option safely, you may need to use event_finalize() or event_free_finalize() in order to safely tear down an event in a multithreaded application. See those functions for more information.

+ +
+
+ +

◆ EV_PERSIST

+ +
+
+ + + + +
#define EV_PERSIST   0x10
+
+ +

Persistent event: won't get removed automatically when activated.

+

When a persistent event with a timeout becomes activated, its timeout is reset to 0.

+ +
+
+ +

◆ EV_TIMEOUT

+ +
+
+ + + + +
#define EV_TIMEOUT   0x01
+
+ +

Indicates that a timeout has occurred.

+

It's not necessary to pass this flag to event_for new()/event_assign() to get a timeout.

+ +
+
+ +

◆ EVLOOP_NO_EXIT_ON_EMPTY

+ +
+
+ + + + +
#define EVLOOP_NO_EXIT_ON_EMPTY   0x04
+
+ +

Do not exit the loop because we have no pending events.

+

Instead, keep running until event_base_loopexit() or event_base_loopbreak() makes us stop.

+ +
+
+

Typedef Documentation

+ +

◆ event_callback_fn

+ +
+
+ + + + +
typedef void(* event_callback_fn) (evutil_socket_t, short, void *)
+
+ +

A callback function for an event.

+

It receives three arguments:

+
Parameters
+ + + + +
fdAn fd or signal
eventsOne or more EV_* flags
argA user-supplied argument.
+
+
+
See also
event_new()
+ +
+
+ +

◆ event_fatal_cb

+ +
+
+ + + + +
typedef void(* event_fatal_cb) (int err)
+
+ +

A function to be called if Libevent encounters a fatal internal error.

+
See also
event_set_fatal_callback
+ +
+
+ +

◆ event_log_cb

+ +
+
+ + + + +
typedef void(* event_log_cb) (int severity, const char *msg)
+
+ +

A callback function used to intercept Libevent's log messages.

+
See also
event_set_log_callback
+ +
+
+

Enumeration Type Documentation

+ +

◆ event_base_config_flag

+ +
+
+ + + + +
enum event_base_config_flag
+
+ +

A flag passed to event_config_set_flag().

+

These flags change the behavior of an allocated event_base.

+
See also
event_config_set_flag(), event_base_new_with_config(), event_method_feature
+ + + + + + + + + +
Enumerator
EVENT_BASE_FLAG_NOLOCK 

Do not allocate a lock for the event base, even if we have locking set up.

+

Setting this option will make it unsafe and nonfunctional to call functions on the base concurrently from multiple threads.

+
EVENT_BASE_FLAG_IGNORE_ENV 

Do not check the EVENT_* environment variables when configuring an event_base
+

+
EVENT_BASE_FLAG_STARTUP_IOCP 

Windows only: enable the IOCP dispatcher at startup.

+
If this flag is set then bufferevent_socket_new() and
+evconn_listener_new() will use IOCP-backed implementations
+instead of the usual select-based one on Windows.
+
+Note: it is experimental feature, and has some bugs.
+
EVENT_BASE_FLAG_NO_CACHE_TIME 

Instead of checking the current time every time the event loop is ready to run timeout callbacks, check after each timeout callback.

+
EVENT_BASE_FLAG_EPOLL_USE_CHANGELIST 

If we are using the epoll backend, this flag says that it is safe to use Libevent's internal change-list code to batch up adds and deletes in order to try to do as few syscalls as possible.

+

Setting this flag can make your code run faster, but it may trigger a Linux bug: it is not safe to use this flag if you have any fds cloned by dup() or its variants. Doing so will produce strange and hard-to-diagnose bugs.

+

This flag can also be activated by setting the EVENT_EPOLL_USE_CHANGELIST environment variable.

+

This flag has no effect if you wind up using a backend other than epoll.

+
EVENT_BASE_FLAG_PRECISE_TIMER 

Ordinarily, Libevent implements its time and timeout code using the fastest monotonic timer that we have.

+

If this flag is set, however, we use less efficient more precise timer, assuming one is present.

+
EVENT_BASE_FLAG_EPOLL_DISALLOW_TIMERFD 

With EVENT_BASE_FLAG_PRECISE_TIMER, epoll backend will use timerfd for more accurate timers, this will allows to disable this.

+

That said that this is something in between lack of (CLOCK_MONOTONIC_COARSE) and enabled EVENT_BASE_FLAG_PRECISE_TIMER (CLOCK_MONOTONIC + timerfd).

+

This flag has no effect if you wind up using a backend other than epoll and if you do not have EVENT_BASE_FLAG_PRECISE_TIMER enabled.

+
EVENT_BASE_FLAG_USE_SIGNALFD 

Use signalfd(2) to handle signals over sigaction/signal.

+

But note, that in some edge cases signalfd() may works differently.

+
+ +
+
+ +

◆ event_method_feature

+ +
+
+ + + + +
enum event_method_feature
+
+ +

A flag used to describe which features an event_base (must) provide.

+

Because of OS limitations, not every Libevent backend supports every possible feature. You can use this type with event_config_require_features() to tell Libevent to only proceed if your event_base implements a given feature, and you can receive this type from event_base_get_features() to see which features are available.

+ + + + + +
Enumerator
EV_FEATURE_ET 

Require an event method that allows edge-triggered events with EV_ET.

+
EV_FEATURE_O1 

Require an event method where having one event triggered among many is [approximately] an O(1) operation.

+

This excludes (for example) select and poll, which are approximately O(N) for N equal to the total number of possible events.

+
EV_FEATURE_FDS 

Require an event method that allows file descriptors as well as sockets.

+
EV_FEATURE_EARLY_CLOSE 

Require an event method that allows you to use EV_CLOSED to detect connection close without the necessity of reading all the pending data.

+

Methods that do support EV_CLOSED may not be able to provide support on all kernel versions.

+
+ +
+
+

Function Documentation

+ +

◆ event_active()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void event_active (struct eventev,
int res,
short ncalls 
)
+
+ +

Make an event active.

+

You can use this function on a pending or a non-pending event to make it active, so that its callback will be run by event_base_dispatch() or event_base_loop().

+

One common use in multithreaded programs is to wake the thread running event_base_loop() from another thread.

+

If event_active() is called on the same event more than once before the event is run, the flags are OR'd with the flags passed in previous calls.

+
Parameters
+ + + + +
evan event to make active.
resa set of flags to pass to the event's callback.
ncallsan obsolete argument: this is ignored.
+
+
+ +
+
+ +

◆ event_add()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_add (struct eventev,
const struct timeval * timeout 
)
+
+ +

Add an event to the set of pending events.

+

The function event_add() schedules the execution of the event 'ev' when the condition specified by event_assign() or event_new() occurs, or when the time specified in timeout has elapsed. If a timeout is NULL, no timeout occurs and the function will only be called if a matching event occurs. The event in the ev argument must be already initialized by event_assign() or event_new() and may not be used in calls to event_assign() until it is no longer pending.

+

If the event in the ev argument already has a scheduled timeout, calling event_add() replaces the old timeout with the new one if tv is non-NULL.

+
Parameters
+ + + +
evan event struct initialized via event_assign() or event_new()
timeoutthe maximum amount of time to wait for the event, or NULL to wait forever
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
event_del(), event_assign(), event_new()
+ +
+
+ +

◆ event_assign()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_assign (struct eventev,
struct event_basebase,
evutil_socket_t fd,
short events,
event_callback_fn callback,
void * callback_arg 
)
+
+ +

Prepare a new, already-allocated event structure to be added.

+

The function event_assign() prepares the event structure ev to be used in future calls to event_add() and event_del(). Unlike event_new(), it doesn't allocate memory itself: it requires that you have already allocated a struct event, probably on the heap. Doing this will typically make your code depend on the size of the event structure, and thereby create incompatibility with future versions of Libevent.

+

The easiest way to avoid this problem is just to use event_new() and event_free() instead.

+

A slightly harder way to future-proof your code is to use event_get_struct_event_size() to determine the required size of an event at runtime.

+

Note that it is NOT safe to call this function on an event that is active or pending. Doing so WILL corrupt internal data structures in Libevent, and lead to strange, hard-to-diagnose bugs. You can use event_assign to change an existing event, but only if it is not active or pending!

+

The arguments for this function, and the behavior of the events that it makes, are as for event_new().

+
Parameters
+ + + + + + + +
evan event struct to be modified
basethe event base to which ev should be attached.
fdthe file descriptor to be monitored
eventsdesired events to monitor; can be EV_READ and/or EV_WRITE
callbackcallback function to be invoked when the event occurs
callback_argan argument to be passed to the callback function
+
+
+
Returns
0 if success, or -1 on invalid arguments.
+
See also
event_new(), event_add(), event_del(), event_base_once(), event_get_struct_event_size()
+ +
+
+ +

◆ event_base_active_by_fd()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void event_base_active_by_fd (struct event_basebase,
evutil_socket_t fd,
short events 
)
+
+ +

Activates all pending events for the given fd and event mask.

+

This function activates pending events only. Events which have not been added will not become active.

+
Parameters
+ + + + +
basethe event_base on which to activate the events.
fdAn fd to active events on.
eventsOne or more of EV_{READ,WRITE,TIMEOUT}.
+
+
+ +
+
+ +

◆ event_base_active_by_signal()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void event_base_active_by_signal (struct event_basebase,
int sig 
)
+
+ +

Activates all pending signals with a given signal number.

+

This function activates pending events only. Events which have not been added will not become active.

+
Parameters
+ + + +
basethe event_base on which to activate the events.
sigThe signal to active events on.
+
+
+ +
+
+ +

◆ event_base_dispatch()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_base_dispatch (struct event_basebase)
+
+ +

Event dispatching loop.

+

This loop will run the event base until either there are no more pending or active, or until something calls event_base_loopbreak() or event_base_loopexit().

+
Parameters
+ + +
basethe event_base structure returned by event_base_new() or event_base_new_with_config(). base must not be NULL.
+
+
+
Returns
0 if successful, -1 if an error occurred, or 1 if we exited because no events were pending or active.
+
See also
event_base_loop()
+ +
+
+ +

◆ event_base_dump_events()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void event_base_dump_events (struct event_basebase,
FILE * output 
)
+
+ +

Writes a human-readable description of all inserted and/or active events to a provided stdio stream.

+

This is intended for debugging; its format is not guaranteed to be the same between libevent versions.

+
Parameters
+ + + +
baseAn event_base on which to scan the events.
outputA stdio file to write on.
+
+
+ +
+
+ +

◆ event_base_foreach_event()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_base_foreach_event (struct event_basebase,
event_base_foreach_event_cb fn,
void * arg 
)
+
+ +

Iterate over all added or active events events in an event loop, and invoke a given callback on each one.

+

The callback must not call any function that modifies the event base, that modifies any event in the event base, or that adds or removes any event to the event base. Doing so is unsupported and will lead to undefined behavior – likely, to crashes.

+

event_base_foreach_event() holds a lock on the event_base() for the whole time it's running: slow callbacks are not advisable.

+

Note that Libevent adds some events of its own to make pieces of its functionality work. You must not assume that the only events you'll encounter will be the ones you added yourself.

+

The callback function must return 0 to continue iteration, or some other integer to stop iterating.

+
Parameters
+ + + + +
baseAn event_base on which to scan the events.
fnA callback function to receive the events.
argAn argument passed to the callback function.
+
+
+
Returns
0 if we iterated over every event, or the value returned by the callback function if the loop exited early.
+ +
+
+ +

◆ event_base_free()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void event_base_free (struct event_baseeb)
+
+ +

Deallocate all memory associated with an event_base, and free the base.

+

Note that this function will not close any fds or free any memory passed to event_new as the argument to callback.

+

If there are any pending finalizer callbacks, this function will invoke them.

+
Parameters
+ + +
eban event_base to be freed
+
+
+ +
+
+ +

◆ event_base_get_features()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_base_get_features (const struct event_basebase)
+
+ +

Return a bitmask of the features implemented by an event base.

+

This will be a bitwise OR of one or more of the values of event_method_feature

+
See also
event_method_feature
+ +
+
+ +

◆ event_base_get_max_events()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_base_get_max_events (struct event_baseeb,
unsigned int flags,
int clear 
)
+
+ +

Get the maximum number of events in a given event_base as specified in the flags.

+
Parameters
+ + + + +
ebthe event_base structure returned by event_base_new()
flagsa bitwise combination of the kinds of events to aggregate counts for
clearoption used to reset the maximum count.
+
+
+
Returns
the number of events specified in the flags
+ +
+
+ +

◆ event_base_get_method()

+ +
+
+ + + + + + + + +
const EVENT2_EXPORT_SYMBOL char* event_base_get_method (const struct event_baseeb)
+
+ +

Get the kernel event notification mechanism used by Libevent.

+
Parameters
+ + +
ebthe event_base structure returned by event_base_new()
+
+
+
Returns
a string identifying the kernel event mechanism (kqueue, epoll, etc.)
+ +
+
+ +

◆ event_base_get_npriorities()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_base_get_npriorities (struct event_baseeb)
+
+ +

Get the number of different event priorities.

+
Parameters
+ + +
ebthe event_base structure returned by event_base_new()
+
+
+
Returns
Number of different event priorities
+
See also
event_base_priority_init()
+ +
+
+ +

◆ event_base_get_num_events()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_base_get_num_events (struct event_baseeb,
unsigned int flags 
)
+
+ +

Gets the number of events in event_base, as specified in the flags.

+

Since event base has some internal events added to make some of its functionalities work, EVENT_BASE_COUNT_ADDED may return more than the number of events you added using event_add().

+

If you pass EVENT_BASE_COUNT_ACTIVE and EVENT_BASE_COUNT_ADDED together, an active event will be counted twice. However, this might not be the case in future libevent versions. The return value is an indication of the work load, but the user shouldn't rely on the exact value as this may change in the future.

+
Parameters
+ + + +
ebthe event_base structure returned by event_base_new()
flagsa bitwise combination of the kinds of events to aggregate counts for
+
+
+
Returns
the number of events specified in the flags
+ +
+
+ +

◆ event_base_get_running_event()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL struct event* event_base_get_running_event (struct event_basebase)
+
+ +

If called from within the callback for an event, returns that event.

+

The behavior of this function is not defined when called from outside the callback function for an event.

+ +
+
+ +

◆ event_base_get_signal_method()

+ +
+
+ + + + + + + + +
const EVENT2_EXPORT_SYMBOL char* event_base_get_signal_method (const struct event_baseeb)
+
+ +

Get the kernel signal handling mechanism used by Libevent.

+
Parameters
+ + +
ebthe event_base structure returned by event_base_new()
+
+
+
Returns
a string identifying the kernel signal handling mechanism, which is "signal" for traditional UNIX signal handlers, "kqueue_signal" for kqueue(2)-based method on *BSD and macOS, and "signalfd_signal" for Linux-only signalfd(2)-based method.
+ +
+
+ +

◆ event_base_gettimeofday_cached()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_base_gettimeofday_cached (struct event_basebase,
struct timeval * tv 
)
+
+ +

Sets 'tv' to the current time (as returned by gettimeofday()), looking at the cached value in 'base' if possible, and calling gettimeofday() or clock_gettime() as appropriate if there is no cached time.

+

Generally, this value will only be cached while actually processing event callbacks, and may be very inaccurate if your callbacks take a long time to execute.

+

Returns 0 on success, negative on failure.

+ +
+
+ +

◆ event_base_got_break()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_base_got_break (struct event_baseeb)
+
+ +

Checks if the event loop was told to abort immediately by event_base_loopbreak().

+

This function will return true for an event_base at every point after event_base_loopbreak() is called, until the event loop is next entered.

+
Parameters
+ + +
ebthe event_base structure returned by event_init()
+
+
+
Returns
true if event_base_loopbreak() was called on this event base, or 0 otherwise
+
See also
event_base_loopbreak()
+
+event_base_got_exit()
+ +
+
+ +

◆ event_base_got_exit()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_base_got_exit (struct event_baseeb)
+
+ +

Checks if the event loop was told to exit by event_base_loopexit().

+

This function will return true for an event_base at every point after event_loopexit() is called, until the event loop is next entered.

+
Parameters
+ + +
ebthe event_base structure returned by event_init()
+
+
+
Returns
true if event_base_loopexit() was called on this event base, or 0 otherwise
+
See also
event_base_loopexit()
+
+event_base_got_break()
+ +
+
+ +

◆ event_base_init_common_timeout()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL const struct timeval* event_base_init_common_timeout (struct event_basebase,
const struct timeval * duration 
)
+
+ +

Prepare an event_base to use a large number of timeouts with the same duration.

+

Libevent's default scheduling algorithm is optimized for having a large number of timeouts with their durations more or less randomly distributed. But if you have a large number of timeouts that all have the same duration (for example, if you have a large number of connections that all have a 10-second timeout), then you can improve Libevent's performance by telling Libevent about it.

+

To do this, call this function with the common duration. It will return a pointer to a different, opaque timeout value. (Don't depend on its actual contents!) When you use this timeout value in event_add(), Libevent will schedule the event more efficiently.

+

(This optimization probably will not be worthwhile until you have thousands or tens of thousands of events with the same timeout.)

+ +
+
+ +

◆ event_base_loop()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_base_loop (struct event_baseeb,
int flags 
)
+
+ +

Wait for events to become active, and run their callbacks.

+

This is a more flexible version of event_base_dispatch().

+

By default, this loop will run the event base until either there are no more pending or active events, or until something calls event_base_loopbreak() or event_base_loopexit(). You can override this behavior with the 'flags' argument.

+
Parameters
+ + + +
ebthe event_base structure returned by event_base_new() or event_base_new_with_config()
flagsany combination of EVLOOP_ONCE | EVLOOP_NONBLOCK | EVLOOP_NO_EXIT_ON_EMPTY
+
+
+
Returns
0 if successful, -1 if an error occurred, or 1 if we exited because no events were pending or active.
+
See also
event_base_loopexit(), event_base_dispatch(), EVLOOP_ONCE, EVLOOP_NONBLOCK
+ +
+
+ +

◆ event_base_loopbreak()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_base_loopbreak (struct event_baseeb)
+
+ +

Abort the active event_base_loop() immediately.

+

event_base_loop() will abort the loop after the next event is completed; event_base_loopbreak() is typically invoked from this event's callback. This behavior is analogous to the "break;" statement.

+

Subsequent invocations of event_base_loop() will proceed normally.

+
Parameters
+ + +
ebthe event_base structure returned by event_init()
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
event_base_loopexit()
+ +
+
+ +

◆ event_base_loopcontinue()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_base_loopcontinue (struct event_baseeb)
+
+ +

Tell the active event_base_loop() to scan for new events immediately.

+

Calling this function makes the currently active event_base_loop() start the loop over again (scanning for new events) after the current event callback finishes. If the event loop is not running, this function has no effect.

+

event_base_loopbreak() is typically invoked from this event's callback. This behavior is analogous to the "continue;" statement.

+

Subsequent invocations of event loop will proceed normally.

+
Parameters
+ + +
ebthe event_base structure returned by event_init()
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
event_base_loopbreak()
+ +
+
+ +

◆ event_base_loopexit()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_base_loopexit (struct event_baseeb,
const struct timeval * tv 
)
+
+ +

Exit the event loop after the specified time.

+

The next event_base_loop() iteration after the given timer expires will complete normally (handling all queued events) then exit without blocking for events again.

+

Subsequent invocations of event_base_loop() will proceed normally.

+
Parameters
+ + + +
ebthe event_base structure returned by event_init()
tvthe amount of time after which the loop should terminate, or NULL to exit after running all currently active events.
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
event_base_loopbreak()
+ +
+
+ +

◆ event_base_new()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL struct event_base* event_base_new (void )
+
+ +

Create and return a new event_base to use with the rest of Libevent.

+
Returns
a new event_base on success, or NULL on failure.
+
See also
event_base_free(), event_base_new_with_config()
+ +
+
+ +

◆ event_base_new_with_config()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL struct event_base* event_base_new_with_config (const struct event_configcfg)
+
+ +

Initialize the event API.

+

Use event_base_new_with_config() to initialize a new event base, taking the specified configuration under consideration. The configuration object can currently be used to avoid certain event notification mechanisms.

+
Parameters
+ + +
cfgthe event configuration object
+
+
+
Returns
an initialized event_base that can be used to registering events, or NULL if no event base can be created with the requested event_config.
+
See also
event_base_new(), event_base_free(), event_init(), event_assign()
+ +
+
+ +

◆ event_base_once()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_base_once (struct event_basebase,
evutil_socket_t fd,
short events,
event_callback_fn callback,
void * arg,
const struct timeval * timeout 
)
+
+ +

Schedule a one-time event.

+

The function event_base_once() is similar to event_new(). However, it schedules a callback to be called exactly once, and does not require the caller to prepare an event structure.

+

Note that in Libevent 2.0 and earlier, if the event is never triggered, the internal memory used to hold it will never be freed. In Libevent 2.1, the internal memory will get freed by event_base_free() if the event is never triggered. The 'arg' value, however, will not get freed in either case–you'll need to free that on your own if you want it to go away.

+
Parameters
+ + + + + + + +
basean event_base
fda file descriptor to monitor, or -1 for no fd.
eventsevent(s) to monitor; can be any of EV_READ | EV_WRITE, or EV_TIMEOUT
callbackcallback function to be invoked when the event occurs
argan argument to be passed to the callback function
timeoutthe maximum amount of time to wait for the event. NULL makes an EV_READ/EV_WRITE event make forever; NULL makes an EV_TIMEOUT event success immediately.
+
+
+
Returns
0 if successful, or -1 if an error occurred
+ +
+
+ +

◆ event_base_priority_init()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_base_priority_init (struct event_baseeb,
int npriorities 
)
+
+ +

Set the number of different event priorities.

+

By default Libevent schedules all active events with the same priority. However, some time it is desirable to process some events with a higher priority than others. For that reason, Libevent supports strict priority queues. Active events with a lower priority are always processed before events with a higher priority.

+

The number of different priorities can be set initially with the event_base_priority_init() function. This function should be called before the first call to event_base_dispatch(). The event_priority_set() function can be used to assign a priority to an event. By default, Libevent assigns the middle priority to all events unless their priority is explicitly set.

+

Note that urgent-priority events can starve less-urgent events: after running all urgent-priority callbacks, Libevent checks for more urgent events again, before running less-urgent events. Less-urgent events will not have their callbacks run until there are no events more urgent than them that want to be active.

+
Parameters
+ + + +
ebthe event_base structure returned by event_base_new()
nprioritiesthe maximum number of priorities
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
event_priority_set()
+ +
+
+ +

◆ event_base_set()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_base_set (struct event_baseeb,
struct eventev 
)
+
+ +

Associate a different event base with an event.

+

The event to be associated must not be currently active or pending.

+
Parameters
+ + + +
ebthe event base
evthe event
+
+
+
Returns
0 on success, -1 on failure.
+ +
+
+ +

◆ event_base_update_cache_time()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_base_update_cache_time (struct event_basebase)
+
+ +

Update cached_tv in the 'base' to the current time.

+

You can use this function is useful for selectively increasing the accuracy of the cached time value in 'base' during callbacks that take a long time to execute.

+

This function has no effect if the base is currently not in its event loop, or if timeval caching is disabled via EVENT_BASE_FLAG_NO_CACHE_TIME.

+
Returns
0 on success, -1 on failure
+ +
+
+ +

◆ event_config_avoid_method()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_config_avoid_method (struct event_configcfg,
const char * method 
)
+
+ +

Enters an event method that should be avoided into the configuration.

+

This can be used to avoid event mechanisms that do not support certain file descriptor types, or for debugging to avoid certain event mechanisms. An application can make use of multiple event bases to accommodate incompatible file descriptor types.

+
Parameters
+ + + +
cfgthe event configuration object
methodthe name of the event method to avoid
+
+
+
Returns
0 on success, -1 on failure.
+ +
+
+ +

◆ event_config_free()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void event_config_free (struct event_configcfg)
+
+ +

Deallocates all memory associated with an event configuration object.

+
Parameters
+ + +
cfgthe event configuration object to be freed.
+
+
+ +
+
+ +

◆ event_config_new()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL struct event_config* event_config_new (void )
+
+ +

Allocates a new event configuration object.

+

The event configuration object can be used to change the behavior of an event base.

+
Returns
an event_config object that can be used to store configuration, or NULL if an error is encountered.
+
See also
event_base_new_with_config(), event_config_free(), event_config
+ +
+
+ +

◆ event_config_require_features()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_config_require_features (struct event_configcfg,
int feature 
)
+
+ +

Enters a required event method feature that the application demands.

+

Note that not every feature or combination of features is supported on every platform. Code that requests features should be prepared to handle the case where event_base_new_with_config() returns NULL, as in:

+  event_config_require_features(cfg, EV_FEATURE_ET);
+  base = event_base_new_with_config(cfg);
+  if (base == NULL) {
+    // We can't get edge-triggered behavior here.
+    event_config_require_features(cfg, 0);
+    base = event_base_new_with_config(cfg);
+  }
+
Parameters
+ + + +
cfgthe event configuration object
featurea bitfield of one or more event_method_feature values. Replaces values from previous calls to this function.
+
+
+
Returns
0 on success, -1 on failure.
+
See also
event_method_feature, event_base_new_with_config()
+ +
+
+ +

◆ event_config_set_flag()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_config_set_flag (struct event_configcfg,
int flag 
)
+
+ +

Sets one or more flags to configure what parts of the eventual event_base will be initialized, and how they'll work.

+
See also
event_base_config_flags, event_base_new_with_config()
+ +
+
+ +

◆ event_config_set_max_dispatch_interval()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_config_set_max_dispatch_interval (struct event_configcfg,
const struct timeval * max_interval,
int max_callbacks,
int min_priority 
)
+
+ +

Record an interval and/or a number of callbacks after which the event base should check for new events.

+

By default, the event base will run as many events are as activated at the highest activated priority before checking for new events. If you configure it by setting max_interval, it will check the time after each callback, and not allow more than max_interval to elapse before checking for new events. If you configure it by setting max_callbacks to a value >= 0, it will run no more than max_callbacks callbacks before checking for new events.

+

This option can decrease the latency of high-priority events, and avoid priority inversions where multiple low-priority events keep us from polling for high-priority events, but at the expense of slightly decreasing the throughput. Use it with caution!

+
Parameters
+ + + + + +
cfgThe event_base configuration object.
max_intervalAn interval after which Libevent should stop running callbacks and check for more events, or NULL if there should be no such interval.
max_callbacksA number of callbacks after which Libevent should stop running callbacks and check for more events, or -1 if there should be no such limit.
min_priorityA priority below which max_interval and max_callbacks should not be enforced. If this is set to 0, they are enforced for events of every priority; if it's set to 1, they're enforced for events of priority 1 and above, and so on.
+
+
+
Returns
0 on success, -1 on failure.
+ +
+
+ +

◆ event_config_set_num_cpus_hint()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_config_set_num_cpus_hint (struct event_configcfg,
int cpus 
)
+
+ +

Records a hint for the number of CPUs in the system.

+

This is used for tuning thread pools, etc, for optimal performance. In Libevent 2.0, it is only on Windows, and only when IOCP is in use.

+
Parameters
+ + + +
cfgthe event configuration object
cpusthe number of cpus
+
+
+
Returns
0 on success, -1 on failure.
+ +
+
+ +

◆ event_debug_unassign()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void event_debug_unassign (struct event)
+
+ +

When debugging mode is enabled, informs Libevent that an event should no longer be considered as assigned.

+

When debugging mode is not enabled, does nothing.

+

This function must only be called on a non-added event. The parameter must not be NULL.

+
See also
event_enable_debug_mode()
+ +
+
+ +

◆ event_del()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_del (struct eventev)
+
+ +

Remove an event from the set of monitored events.

+

The function event_del() will cancel the event in the argument ev. If the event has already executed or has never been added the call will have no effect.

+
Parameters
+ + +
evan event struct to be removed from the working set. ev must not be NULL.
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
event_add()
+ +
+
+ +

◆ event_enable_debug_logging()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void event_enable_debug_logging (ev_uint32_t which)
+
+ +

Turn on debugging logs and have them sent to the default log handler.

+

This is a global setting; if you are going to call it, you must call this before any calls that create an event-base. You must call it before any multithreaded use of Libevent.

+

Debug logs are verbose.

+
Parameters
+ + +
whichControls which debug messages are turned on. This option is unused for now; for forward compatibility, you must pass in the constant "EVENT_DBG_ALL" to turn debugging logs on, or "EVENT_DBG_NONE" to turn debugging logs off.
+
+
+ +
+
+ +

◆ event_enable_debug_mode()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void event_enable_debug_mode (void )
+
+ +

Enable some relatively expensive debugging checks in Libevent that would normally be turned off.

+

Generally, these checks cause code that would otherwise crash mysteriously to fail earlier with an assertion failure. Note that this method MUST be called before any events or event_bases have been created.

+

Debug mode can currently catch the following errors: An event is re-assigned while it is added Any function is called on a non-assigned event

+

Note that debugging mode uses memory to track every event that has been initialized (via event_assign, event_set, or event_new) but not yet released (via event_free or event_debug_unassign). If you want to use debug mode, and you find yourself running out of memory, you will need to use event_debug_unassign to explicitly stop tracking events that are no longer considered set-up.

+
See also
event_debug_unassign()
+ +
+
+ +

◆ event_free()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void event_free (struct event)
+
+ +

Deallocate a struct event * returned by event_new().

+

If the event is pending or active, this function makes it non-pending and non-active first.

+ +
+
+ +

◆ event_get_assignment()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void event_get_assignment (const struct eventevent,
struct event_base ** base_out,
evutil_socket_tfd_out,
short * events_out,
event_callback_fncallback_out,
void ** arg_out 
)
+
+ +

Extract all of arguments given to construct a given event.

+

The event_base is copied into *base_out, the fd is copied into *fd_out, and so on.

+

If any of the "_out" arguments is NULL, it will be ignored.

+ +
+
+ +

◆ event_get_priority()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_get_priority (const struct eventev)
+
+ +

Return the priority of an event.

+
See also
event_priority_init(), event_get_priority()
+ +
+
+ +

◆ event_get_struct_event_size()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL size_t event_get_struct_event_size (void )
+
+ +

Return the size of struct event that the Libevent library was compiled with.

+

This will be NO GREATER than sizeof(struct event) if you're running with the same version of Libevent that your application was built with, but otherwise might not.

+

Note that it might be SMALLER than sizeof(struct event) if some future version of Libevent adds extra padding to the end of struct event. We might do this to help ensure ABI-compatibility between different versions of Libevent.

+ +
+
+ +

◆ event_get_supported_methods()

+ +
+
+ + + + + + + + +
const EVENT2_EXPORT_SYMBOL char** event_get_supported_methods (void )
+
+ +

Gets all event notification mechanisms supported by Libevent.

+

This functions returns the event mechanism in order preferred by Libevent. Note that this list will include all backends that Libevent has compiled-in support for, and will not necessarily check your OS to see whether it has the required resources.

+
Returns
an array with pointers to the names of support methods. The end of the array is indicated by a NULL pointer. If an error is encountered NULL is returned.
+ +
+
+ +

◆ event_get_version()

+ +
+
+ + + + + + + + +
const EVENT2_EXPORT_SYMBOL char* event_get_version (void )
+
+ +

Get the Libevent version.

+

Note that this will give you the version of the library that you're currently linked against, not the version of the headers that you've compiled against.

+
Returns
a string containing the version number of Libevent
+ +
+
+ +

◆ event_get_version_number()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL ev_uint32_t event_get_version_number (void )
+
+ +

Return a numeric representation of Libevent's version.

+

Note that this will give you the version of the library that you're currently linked against, not the version of the headers you've used to compile.

+

The format uses one byte each for the major, minor, and patchlevel parts of the version number. The low-order byte is unused. For example, version 2.0.1-alpha has a numeric representation of 0x02000100

+ +
+
+ +

◆ event_initialized()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_initialized (const struct eventev)
+
+ +

Test if an event structure might be initialized.

+

The event_initialized() function can be used to check if an event has been initialized.

+

Warning: This function is only useful for distinguishing a zeroed-out piece of memory from an initialized event, it can easily be confused by uninitialized memory. Thus, it should ONLY be used to distinguish an initialized event from zero.

+
Parameters
+ + +
evan event structure to be tested. ev must not be NULL.
+
+
+
Returns
1 if the structure might be initialized, or 0 if it has not been initialized
+ +
+
+ +

◆ event_new()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct event* event_new (struct event_basebase,
evutil_socket_t fd,
short events,
event_callback_fn callback,
void * callback_arg 
)
+
+ +

Allocate and assign a new event structure, ready to be added.

+

The function event_new() returns a new event that can be used in future calls to event_add() and event_del(). The fd and events arguments determine which conditions will trigger the event; the callback and callback_arg arguments tell Libevent what to do when the event becomes active.

+

If events contains one of EV_READ, EV_WRITE, or EV_READ|EV_WRITE, then fd is a file descriptor or socket that should get monitored for readiness to read, readiness to write, or readiness for either operation (respectively). If events contains EV_SIGNAL, then fd is a signal number to wait for. If events contains none of those flags, then the event can be triggered only by a timeout or by manual activation with event_active(): In this case, fd must be -1.

+

The EV_PERSIST flag can also be passed in the events argument: it makes event_add() persistent until event_del() is called.

+

The EV_ET flag is compatible with EV_READ and EV_WRITE, and supported only by certain backends. It tells Libevent to use edge-triggered events.

+

The EV_TIMEOUT flag has no effect here.

+

It is okay to have multiple events all listening on the same fds; but they must either all be edge-triggered, or not be edge-triggered at all.

+

When the event becomes active, the event loop will run the provided callback function, with three arguments. The first will be the provided fd value. The second will be a bitfield of the events that triggered: EV_READ, EV_WRITE, or EV_SIGNAL. Here the EV_TIMEOUT flag indicates that a timeout occurred, and EV_ET indicates that an edge-triggered event occurred. The third event will be the callback_arg pointer that you provide.

+
Parameters
+ + + + + + +
basethe event base to which the event should be attached.
fdthe file descriptor or signal to be monitored, or -1.
eventsdesired events to monitor: bitfield of EV_READ, EV_WRITE, EV_SIGNAL, EV_PERSIST, EV_ET.
callbackcallback function to be invoked when the event occurs
callback_argan argument to be passed to the callback function
+
+
+
Returns
a newly allocated struct event that must later be freed with event_free() or NULL if an error occurred.
+
See also
event_free(), event_add(), event_del(), event_assign()
+ +
+
+ +

◆ event_pending()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_pending (const struct eventev,
short events,
struct timeval * tv 
)
+
+ +

Checks if a specific event is pending or scheduled.

+
Parameters
+ + + + +
evan event struct previously passed to event_add()
eventsthe requested event type; any of EV_TIMEOUT|EV_READ| EV_WRITE|EV_SIGNAL
tvif this field is not NULL, and the event has a timeout, this field is set to hold the time at which the timeout will expire.
+
+
+
Returns
true if the event is pending on any of the events in 'what', (that is to say, it has been added), or 0 if the event is not added.
+ +
+
+ +

◆ event_priority_set()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_priority_set (struct eventev,
int priority 
)
+
+ +

Assign a priority to an event.

+
Parameters
+ + + +
evan event struct
prioritythe new priority to be assigned
+
+
+
Returns
0 if successful, or -1 if an error occurred
+
See also
event_priority_init(), event_get_priority()
+ +
+
+ +

◆ event_reinit()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_reinit (struct event_basebase)
+
+ +

Reinitialize the event base after a fork.

+

Some event mechanisms do not survive across fork. The event base needs to be reinitialized with the event_reinit() function.

+
Parameters
+ + +
basethe event base that needs to be re-initialized
+
+
+
Returns
0 if successful, or -1 if some events could not be re-added.
+
See also
event_base_new()
+ +
+
+ +

◆ event_remove_timer()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_remove_timer (struct eventev)
+
+ +

Remove a timer from a pending event without removing the event itself.

+

If the event has a scheduled timeout, this function unschedules it but leaves the event otherwise pending.

+
Parameters
+ + +
evan event struct initialized via event_assign() or event_new()
+
+
+
Returns
0 on success, or -1 if an error occurred.
+ +
+
+ +

◆ event_self_cbarg()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void* event_self_cbarg (void )
+
+ +

Return a value used to specify that the event itself must be used as the callback argument.

+

The function event_new() takes a callback argument which is passed to the event's callback function. To specify that the argument to be passed to the callback function is the event that event_new() returns, pass in the return value of event_self_cbarg() as the callback argument for event_new().

+

For example:

+    struct event *ev = event_new(base, sock, events, callback, event_self_cbarg());
+

For consistency with event_new(), it is possible to pass the return value of this function as the callback argument for event_assign() – this achieves the same result as passing the event in directly.

+
Returns
a value to be passed as the callback argument to event_new() or event_assign().
+
See also
event_new(), event_assign()
+ +
+
+ +

◆ event_set_fatal_callback()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void event_set_fatal_callback (event_fatal_cb cb)
+
+ +

Override Libevent's behavior in the event of a fatal internal error.

+

By default, Libevent will call exit(1) if a programming error makes it impossible to continue correct operation. This function allows you to supply another callback instead. Note that if the function is ever invoked, something is wrong with your program, or with Libevent: any subsequent calls to Libevent may result in undefined behavior.

+

Libevent will (almost) always log an EVENT_LOG_ERR message before calling this function; look at the last log message to see why Libevent has died.

+ +
+
+ +

◆ event_set_log_callback()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void event_set_log_callback (event_log_cb cb)
+
+ +

Redirect Libevent's log messages.

+
Parameters
+ + +
cba function taking two arguments: an integer severity between EVENT_LOG_DEBUG and EVENT_LOG_ERR, and a string. If cb is NULL, then the default log is used.
+
+
+

NOTE: The function you provide must not call any other libevent functionality. Doing so can produce undefined behavior.

+ +
+
+ +

◆ event_set_mem_functions()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void event_set_mem_functions (void *(*)(size_t sz) malloc_fn,
void *(*)(void *ptr, size_t sz) realloc_fn,
void(*)(void *ptr) free_fn 
)
+
+ +

Override the functions that Libevent uses for memory management.

+

Usually, Libevent uses the standard libc functions malloc, realloc, and free to allocate memory. Passing replacements for those functions to event_set_mem_functions() overrides this behavior.

+

Note that all memory returned from Libevent will be allocated by the replacement functions rather than by malloc() and realloc(). Thus, if you have replaced those functions, it will not be appropriate to free() memory that you get from Libevent. Instead, you must use the free_fn replacement that you provided.

+

Note also that if you are going to call this function, you should do so before any call to any Libevent function that does allocation. Otherwise, those functions will allocate their memory using malloc(), but then later free it using your provided free_fn.

+
Parameters
+ + + + +
malloc_fnA replacement for malloc.
realloc_fnA replacement for realloc
free_fnA replacement for free.
+
+
+ +
+
+ +

◆ libevent_global_shutdown()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void libevent_global_shutdown (void )
+
+ +

Release up all globally-allocated resources allocated by Libevent.

+

This function does not free developer-controlled resources like event_bases, events, bufferevents, listeners, and so on. It only releases resources like global locks that there is no other way to free.

+

It is not actually necessary to call this function before exit: every resource that it frees would be released anyway on exit. It mainly exists so that resource-leak debugging tools don't see Libevent as holding resources at exit.

+

You should only call this function when no other Libevent functions will be invoked – e.g., when cleanly exiting a program.

+ +
+
+
+ + + + diff --git a/event_8h_source.html b/event_8h_source.html new file mode 100644 index 0000000..bd24ea8 --- /dev/null +++ b/event_8h_source.html @@ -0,0 +1,572 @@ + + + + + + + +libevent: event2/event.h Source File + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
event.h
+
+
+Go to the documentation of this file.
1 /*
+
2  * Copyright (c) 2000-2007 Niels Provos <provos@citi.umich.edu>
+
3  * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson
+
4  *
+
5  * Redistribution and use in source and binary forms, with or without
+
6  * modification, are permitted provided that the following conditions
+
7  * are met:
+
8  * 1. Redistributions of source code must retain the above copyright
+
9  * notice, this list of conditions and the following disclaimer.
+
10  * 2. Redistributions in binary form must reproduce the above copyright
+
11  * notice, this list of conditions and the following disclaimer in the
+
12  * documentation and/or other materials provided with the distribution.
+
13  * 3. The name of the author may not be used to endorse or promote products
+
14  * derived from this software without specific prior written permission.
+
15  *
+
16  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+
17  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+
18  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+
19  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+
20  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+
21  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+
22  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+
23  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+
24  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+
25  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
26  */
+
27 #ifndef EVENT2_EVENT_H_INCLUDED_
+
28 #define EVENT2_EVENT_H_INCLUDED_
+
29 
+
187 #include <event2/visibility.h>
+
188 
+
189 #ifdef __cplusplus
+
190 extern "C" {
+
191 #endif
+
192 
+
193 #include <event2/event-config.h>
+
194 #ifdef EVENT__HAVE_SYS_TYPES_H
+
195 #include <sys/types.h>
+
196 #endif
+
197 #ifdef EVENT__HAVE_SYS_TIME_H
+
198 #include <sys/time.h>
+
199 #endif
+
200 
+
201 #include <stdio.h>
+
202 
+
203 /* For int types. */
+
204 #include <event2/util.h>
+
205 
+ +
220 #ifdef EVENT_IN_DOXYGEN_
+
221 {/*Empty body so that doxygen will generate documentation here.*/}
+
222 #endif
+
223 ;
+
224 
+
276 struct event
+
277 #ifdef EVENT_IN_DOXYGEN_
+
278 {/*Empty body so that doxygen will generate documentation here.*/}
+
279 #endif
+
280 ;
+
281 
+ +
296 #ifdef EVENT_IN_DOXYGEN_
+
297 {/*Empty body so that doxygen will generate documentation here.*/}
+
298 #endif
+
299 ;
+
300 
+
321 EVENT2_EXPORT_SYMBOL
+
322 void event_enable_debug_mode(void);
+
323 
+
333 EVENT2_EXPORT_SYMBOL
+
334 void event_debug_unassign(struct event *);
+
335 
+
343 EVENT2_EXPORT_SYMBOL
+
344 struct event_base *event_base_new(void);
+
345 
+
356 EVENT2_EXPORT_SYMBOL
+
357 int event_reinit(struct event_base *base);
+
358 
+
372 EVENT2_EXPORT_SYMBOL
+
373 int event_base_dispatch(struct event_base *base);
+
374 
+
381 EVENT2_EXPORT_SYMBOL
+
382 const char *event_base_get_method(const struct event_base *eb);
+
383 
+
393 EVENT2_EXPORT_SYMBOL
+
394 const char *event_base_get_signal_method(const struct event_base *eb);
+
395 
+
408 EVENT2_EXPORT_SYMBOL
+
409 const char **event_get_supported_methods(void);
+
410 
+
414 EVENT2_EXPORT_SYMBOL
+
415 int event_gettime_monotonic(struct event_base *base, struct timeval *tp);
+
416 
+
425 #define EVENT_BASE_COUNT_ACTIVE 1U
+
426 
+
428 #define EVENT_BASE_COUNT_VIRTUAL 2U
+
429 
+
431 #define EVENT_BASE_COUNT_ADDED 4U
+
432 
+
452 EVENT2_EXPORT_SYMBOL
+
453 int event_base_get_num_events(struct event_base *eb, unsigned int flags);
+
454 
+
465 EVENT2_EXPORT_SYMBOL
+
466 int event_base_get_max_events(struct event_base *eb, unsigned int flags, int clear);
+
467 
+
478 EVENT2_EXPORT_SYMBOL
+
479 struct event_config *event_config_new(void);
+
480 
+
486 EVENT2_EXPORT_SYMBOL
+
487 void event_config_free(struct event_config *cfg);
+
488 
+
501 EVENT2_EXPORT_SYMBOL
+
502 int event_config_avoid_method(struct event_config *cfg, const char *method);
+
503 
+ + + + + +
531 };
+
532 
+ + + + + +
565 
+ +
581 
+ +
588 
+ +
601 
+ +
607 };
+
608 
+
616 EVENT2_EXPORT_SYMBOL
+
617 int event_base_get_features(const struct event_base *base);
+
618 
+
641 EVENT2_EXPORT_SYMBOL
+
642 int event_config_require_features(struct event_config *cfg, int feature);
+
643 
+
650 EVENT2_EXPORT_SYMBOL
+
651 int event_config_set_flag(struct event_config *cfg, int flag);
+
652 
+
662 EVENT2_EXPORT_SYMBOL
+
663 int event_config_set_num_cpus_hint(struct event_config *cfg, int cpus);
+
664 
+
693 EVENT2_EXPORT_SYMBOL
+ +
695  const struct timeval *max_interval, int max_callbacks,
+
696  int min_priority);
+
697 
+
710 EVENT2_EXPORT_SYMBOL
+
711 struct event_base *event_base_new_with_config(const struct event_config *cfg);
+
712 
+
724 EVENT2_EXPORT_SYMBOL
+
725 void event_base_free(struct event_base *eb);
+
726 
+
730 EVENT2_EXPORT_SYMBOL
+ +
732 
+
736 #define EVENT_LOG_DEBUG 0
+
737 #define EVENT_LOG_MSG 1
+
738 #define EVENT_LOG_WARN 2
+
739 #define EVENT_LOG_ERR 3
+
740 
+
742 /* Obsolete names: these are deprecated, but older programs might use them.
+
743  * They violate the reserved-identifier namespace. */
+
744 #define _EVENT_LOG_DEBUG EVENT_LOG_DEBUG
+
745 #define _EVENT_LOG_MSG EVENT_LOG_MSG
+
746 #define _EVENT_LOG_WARN EVENT_LOG_WARN
+
747 #define _EVENT_LOG_ERR EVENT_LOG_ERR
+
748 
+
754 typedef void (*event_log_cb)(int severity, const char *msg);
+
765 EVENT2_EXPORT_SYMBOL
+ +
767 
+
773 typedef void (*event_fatal_cb)(int err);
+
774 
+
787 EVENT2_EXPORT_SYMBOL
+ +
789 
+
790 #define EVENT_DBG_ALL 0xffffffffu
+
791 #define EVENT_DBG_NONE 0
+
792 
+
807 EVENT2_EXPORT_SYMBOL
+
808 void event_enable_debug_logging(ev_uint32_t which);
+
809 
+
819 EVENT2_EXPORT_SYMBOL
+
820 int event_base_set(struct event_base *eb, struct event *ev);
+
821 
+
829 #define EVLOOP_ONCE 0x01
+
830 
+
832 #define EVLOOP_NONBLOCK 0x02
+
833 
+
837 #define EVLOOP_NO_EXIT_ON_EMPTY 0x04
+
838 
+
859 EVENT2_EXPORT_SYMBOL
+
860 int event_base_loop(struct event_base *eb, int flags);
+
861 
+
877 EVENT2_EXPORT_SYMBOL
+
878 int event_base_loopexit(struct event_base *eb, const struct timeval *tv);
+
879 
+
893 EVENT2_EXPORT_SYMBOL
+
894 int event_base_loopbreak(struct event_base *eb);
+
895 
+
913 EVENT2_EXPORT_SYMBOL
+
914 int event_base_loopcontinue(struct event_base *eb);
+
915 
+
928 EVENT2_EXPORT_SYMBOL
+
929 int event_base_got_exit(struct event_base *eb);
+
930 
+
943 EVENT2_EXPORT_SYMBOL
+
944 int event_base_got_break(struct event_base *eb);
+
945 
+
955 #define EV_TIMEOUT 0x01
+
956 
+
957 #define EV_READ 0x02
+
958 
+
959 #define EV_WRITE 0x04
+
960 
+
961 #define EV_SIGNAL 0x08
+
962 
+
968 #define EV_PERSIST 0x10
+
969 
+
970 #define EV_ET 0x20
+
971 
+
979 #define EV_FINALIZE 0x40
+
980 
+
988 #define EV_CLOSED 0x80
+
989 
+
998 #define evtimer_assign(ev, b, cb, arg) \
+
999  event_assign((ev), (b), -1, 0, (cb), (arg))
+
1000 #define evtimer_new(b, cb, arg) event_new((b), -1, 0, (cb), (arg))
+
1001 #define evtimer_add(ev, tv) event_add((ev), (tv))
+
1002 #define evtimer_del(ev) event_del(ev)
+
1003 #define evtimer_pending(ev, tv) event_pending((ev), EV_TIMEOUT, (tv))
+
1004 #define evtimer_initialized(ev) event_initialized(ev)
+
1005 
+
1013 #define evsignal_add(ev, tv) event_add((ev), (tv))
+
1014 #define evsignal_assign(ev, b, x, cb, arg) \
+
1015  event_assign((ev), (b), (x), EV_SIGNAL|EV_PERSIST, cb, (arg))
+
1016 #define evsignal_new(b, x, cb, arg) \
+
1017  event_new((b), (x), EV_SIGNAL|EV_PERSIST, (cb), (arg))
+
1018 #define evsignal_del(ev) event_del(ev)
+
1019 #define evsignal_pending(ev, tv) event_pending((ev), EV_SIGNAL, (tv))
+
1020 #define evsignal_initialized(ev) event_initialized(ev)
+
1021 
+
1030 #define evuser_new(b, cb, arg) event_new((b), -1, 0, (cb), (arg))
+
1031 #define evuser_del(ev) event_del(ev)
+
1032 #define evuser_pending(ev, tv) event_pending((ev), 0, (tv))
+
1033 #define evuser_initialized(ev) event_initialized(ev)
+
1034 #define evuser_trigger(ev) event_active((ev), 0, 0)
+
1035 
+
1048 typedef void (*event_callback_fn)(evutil_socket_t, short, void *);
+
1049 
+
1072 EVENT2_EXPORT_SYMBOL
+
1073 void *event_self_cbarg(void);
+
1074 
+
1123 EVENT2_EXPORT_SYMBOL
+
1124 struct event *event_new(struct event_base *base, evutil_socket_t fd, short events, event_callback_fn callback, void *callback_arg);
+
1125 
+
1126 
+
1165 EVENT2_EXPORT_SYMBOL
+
1166 int event_assign(struct event *ev, struct event_base *base, evutil_socket_t fd, short events, event_callback_fn callback, void *callback_arg);
+
1167 
+
1174 EVENT2_EXPORT_SYMBOL
+
1175 void event_free(struct event *);
+
1176 
+
1180 typedef void (*event_finalize_callback_fn)(struct event *, void *);
+
1212 EVENT2_EXPORT_SYMBOL
+
1213 int event_finalize(unsigned, struct event *, event_finalize_callback_fn);
+
1214 EVENT2_EXPORT_SYMBOL
+
1215 int event_free_finalize(unsigned, struct event *, event_finalize_callback_fn);
+
1242 EVENT2_EXPORT_SYMBOL
+
1243 int event_base_once(struct event_base *base, evutil_socket_t fd, short events, event_callback_fn callback, void *arg, const struct timeval *timeout);
+
1244 
+
1266 EVENT2_EXPORT_SYMBOL
+
1267 int event_add(struct event *ev, const struct timeval *timeout);
+
1268 
+
1278 EVENT2_EXPORT_SYMBOL
+
1279 int event_remove_timer(struct event *ev);
+
1280 
+
1292 EVENT2_EXPORT_SYMBOL
+
1293 int event_del(struct event *ev);
+
1294 
+
1300 EVENT2_EXPORT_SYMBOL
+
1301 int event_del_noblock(struct event *ev);
+
1307 EVENT2_EXPORT_SYMBOL
+
1308 int event_del_block(struct event *ev);
+
1309 
+
1327 EVENT2_EXPORT_SYMBOL
+
1328 void event_active(struct event *ev, int res, short ncalls);
+
1329 
+
1343 EVENT2_EXPORT_SYMBOL
+
1344 int event_pending(const struct event *ev, short events, struct timeval *tv);
+
1345 
+
1352 EVENT2_EXPORT_SYMBOL
+
1353 struct event *event_base_get_running_event(struct event_base *base);
+
1354 
+
1370 EVENT2_EXPORT_SYMBOL
+
1371 int event_initialized(const struct event *ev);
+
1372 
+
1376 #define event_get_signal(ev) ((int)event_get_fd(ev))
+
1377 
+
1382 EVENT2_EXPORT_SYMBOL
+
1383 evutil_socket_t event_get_fd(const struct event *ev);
+
1384 
+
1388 EVENT2_EXPORT_SYMBOL
+
1389 struct event_base *event_get_base(const struct event *ev);
+
1390 
+
1394 EVENT2_EXPORT_SYMBOL
+
1395 short event_get_events(const struct event *ev);
+
1396 
+
1400 EVENT2_EXPORT_SYMBOL
+
1401 event_callback_fn event_get_callback(const struct event *ev);
+
1402 
+
1406 EVENT2_EXPORT_SYMBOL
+
1407 void *event_get_callback_arg(const struct event *ev);
+
1408 
+
1413 EVENT2_EXPORT_SYMBOL
+
1414 int event_get_priority(const struct event *ev);
+
1415 
+
1423 EVENT2_EXPORT_SYMBOL
+
1424 void event_get_assignment(const struct event *event,
+
1425  struct event_base **base_out, evutil_socket_t *fd_out, short *events_out,
+
1426  event_callback_fn *callback_out, void **arg_out);
+
1427 
+
1441 EVENT2_EXPORT_SYMBOL
+
1442 size_t event_get_struct_event_size(void);
+
1443 
+
1453 EVENT2_EXPORT_SYMBOL
+
1454 const char *event_get_version(void);
+
1455 
+
1467 EVENT2_EXPORT_SYMBOL
+
1468 ev_uint32_t event_get_version_number(void);
+
1469 
+
1471 #define LIBEVENT_VERSION EVENT__VERSION
+
1472 
+
1474 #define LIBEVENT_VERSION_NUMBER EVENT__NUMERIC_VERSION
+
1475 
+
1477 #define EVENT_MAX_PRIORITIES 256
+
1478 
+
1505 EVENT2_EXPORT_SYMBOL
+
1506 int event_base_priority_init(struct event_base *eb, int npriorities);
+
1507 
+
1515 EVENT2_EXPORT_SYMBOL
+
1516 int event_base_get_npriorities(struct event_base *eb);
+
1517 
+
1526 EVENT2_EXPORT_SYMBOL
+
1527 int event_priority_set(struct event *ev, int priority);
+
1528 
+
1548 EVENT2_EXPORT_SYMBOL
+
1549 const struct timeval *event_base_init_common_timeout(struct event_base *base,
+
1550  const struct timeval *duration);
+
1551 
+
1552 #if !defined(EVENT__DISABLE_MM_REPLACEMENT) || defined(EVENT_IN_DOXYGEN_)
+
1553 
+
1575 EVENT2_EXPORT_SYMBOL
+ +
1577  void *(*malloc_fn)(size_t sz),
+
1578  void *(*realloc_fn)(void *ptr, size_t sz),
+
1579  void (*free_fn)(void *ptr));
+
1582 #define EVENT_SET_MEM_FUNCTIONS_IMPLEMENTED
+
1583 #endif
+
1584 
+
1595 EVENT2_EXPORT_SYMBOL
+
1596 void event_base_dump_events(struct event_base *base, FILE *output);
+
1597 
+
1598 
+
1609 EVENT2_EXPORT_SYMBOL
+
1610 void event_base_active_by_fd(struct event_base *base, evutil_socket_t fd, short events);
+
1611 
+
1621 EVENT2_EXPORT_SYMBOL
+
1622 void event_base_active_by_signal(struct event_base *base, int sig);
+
1623 
+
1627 typedef int (*event_base_foreach_event_cb)(const struct event_base *, const struct event *, void *);
+
1628 
+
1654 EVENT2_EXPORT_SYMBOL
+
1655 int event_base_foreach_event(struct event_base *base, event_base_foreach_event_cb fn, void *arg);
+
1656 
+
1657 
+
1669 EVENT2_EXPORT_SYMBOL
+ +
1671  struct timeval *tv);
+
1672 
+
1685 EVENT2_EXPORT_SYMBOL
+
1686 int event_base_update_cache_time(struct event_base *base);
+
1687 
+
1702 EVENT2_EXPORT_SYMBOL
+
1703 void libevent_global_shutdown(void);
+
1704 
+
1705 #ifdef __cplusplus
+
1706 }
+
1707 #endif
+
1708 
+
1709 #endif /* EVENT2_EVENT_H_INCLUDED_ */
+
+
EVENT2_EXPORT_SYMBOL void event_free(struct event *)
Deallocate a struct event * returned by event_new().
+
const EVENT2_EXPORT_SYMBOL char * event_base_get_signal_method(const struct event_base *eb)
Get the kernel signal handling mechanism used by Libevent.
+
void(* event_fatal_cb)(int err)
A function to be called if Libevent encounters a fatal internal error.
Definition: event.h:773
+
EVENT2_EXPORT_SYMBOL int event_base_get_npriorities(struct event_base *eb)
Get the number of different event priorities.
+
EVENT2_EXPORT_SYMBOL int event_base_get_features(const struct event_base *base)
Return a bitmask of the features implemented by an event base.
+
EVENT2_EXPORT_SYMBOL int event_base_update_cache_time(struct event_base *base)
Update cached_tv in the 'base' to the current time.
+
EVENT2_EXPORT_SYMBOL void event_base_active_by_fd(struct event_base *base, evutil_socket_t fd, short events)
Activates all pending events for the given fd and event mask.
+
EVENT2_EXPORT_SYMBOL struct event * event_new(struct event_base *base, evutil_socket_t fd, short events, event_callback_fn callback, void *callback_arg)
Allocate and assign a new event structure, ready to be added.
+
EVENT2_EXPORT_SYMBOL int event_del(struct event *ev)
Remove an event from the set of monitored events.
+
EVENT2_EXPORT_SYMBOL void event_set_mem_functions(void *(*malloc_fn)(size_t sz), void *(*realloc_fn)(void *ptr, size_t sz), void(*free_fn)(void *ptr))
Override the functions that Libevent uses for memory management.
+
EVENT2_EXPORT_SYMBOL int event_assign(struct event *ev, struct event_base *base, evutil_socket_t fd, short events, event_callback_fn callback, void *callback_arg)
Prepare a new, already-allocated event structure to be added.
+
EVENT2_EXPORT_SYMBOL int event_config_set_num_cpus_hint(struct event_config *cfg, int cpus)
Records a hint for the number of CPUs in the system.
+
EVENT2_EXPORT_SYMBOL int event_base_once(struct event_base *base, evutil_socket_t fd, short events, event_callback_fn callback, void *arg, const struct timeval *timeout)
Schedule a one-time event.
+
EVENT2_EXPORT_SYMBOL int event_config_set_max_dispatch_interval(struct event_config *cfg, const struct timeval *max_interval, int max_callbacks, int min_priority)
Record an interval and/or a number of callbacks after which the event base should check for new event...
+
EVENT2_EXPORT_SYMBOL int event_get_priority(const struct event *ev)
Return the priority of an event.
+
EVENT2_EXPORT_SYMBOL int event_config_set_flag(struct event_config *cfg, int flag)
Sets one or more flags to configure what parts of the eventual event_base will be initialized,...
+
const EVENT2_EXPORT_SYMBOL char ** event_get_supported_methods(void)
Gets all event notification mechanisms supported by Libevent.
+
EVENT2_EXPORT_SYMBOL int event_gettime_monotonic(struct event_base *base, struct timeval *tp)
Query the current monotonic time from the timer for a struct event_base.
+
EVENT2_EXPORT_SYMBOL void event_set_fatal_callback(event_fatal_cb cb)
Override Libevent's behavior in the event of a fatal internal error.
+
EVENT2_EXPORT_SYMBOL void event_enable_debug_mode(void)
Enable some relatively expensive debugging checks in Libevent that would normally be turned off.
+
EVENT2_EXPORT_SYMBOL int event_reinit(struct event_base *base)
Reinitialize the event base after a fork.
+
EVENT2_EXPORT_SYMBOL struct event_base * event_base_new_with_config(const struct event_config *cfg)
Initialize the event API.
+
Structure to hold information and state for a Libevent dispatch loop.
Definition: event.h:219
+
@ EVENT_BASE_FLAG_NOLOCK
Do not allocate a lock for the event base, even if we have locking set up.
Definition: event.h:548
+
EVENT2_EXPORT_SYMBOL event_callback_fn event_get_callback(const struct event *ev)
Return the callback assigned to an event.
+
Structure to represent a single event.
Definition: event.h:276
+
EVENT2_EXPORT_SYMBOL void event_base_free_nofinalize(struct event_base *)
As event_base_free, but do not run finalizers.
+
EVENT2_EXPORT_SYMBOL void event_get_assignment(const struct event *event, struct event_base **base_out, evutil_socket_t *fd_out, short *events_out, event_callback_fn *callback_out, void **arg_out)
Extract all of arguments given to construct a given event.
+
@ EVENT_BASE_FLAG_STARTUP_IOCP
Windows only: enable the IOCP dispatcher at startup.
Definition: event.h:560
+
EVENT2_EXPORT_SYMBOL int event_priority_set(struct event *ev, int priority)
Assign a priority to an event.
+
EVENT2_EXPORT_SYMBOL ev_uint32_t event_get_version_number(void)
Return a numeric representation of Libevent's version.
+
void(* event_log_cb)(int severity, const char *msg)
A callback function used to intercept Libevent's log messages.
Definition: event.h:754
+
EVENT2_EXPORT_SYMBOL size_t event_get_struct_event_size(void)
Return the size of struct event that the Libevent library was compiled with.
+
@ EV_FEATURE_O1
Require an event method where having one event triggered among many is [approximately] an O(1) operat...
Definition: event.h:520
+
EVENT2_EXPORT_SYMBOL short event_get_events(const struct event *ev)
Return the events (EV_READ, EV_WRITE, etc) assigned to an event.
+
EVENT2_EXPORT_SYMBOL int event_initialized(const struct event *ev)
Test if an event structure might be initialized.
+
EVENT2_EXPORT_SYMBOL struct event_config * event_config_new(void)
Allocates a new event configuration object.
+
@ EVENT_BASE_FLAG_USE_SIGNALFD
Use signalfd(2) to handle signals over sigaction/signal.
Definition: event.h:606
+
EVENT2_EXPORT_SYMBOL void * event_get_callback_arg(const struct event *ev)
Return the callback argument assigned to an event.
+
EVENT2_EXPORT_SYMBOL void event_active(struct event *ev, int res, short ncalls)
Make an event active.
+
event_method_feature
A flag used to describe which features an event_base (must) provide.
Definition: event.h:513
+
void(* event_finalize_callback_fn)(struct event *, void *)
Callback type for event_finalize and event_free_finalize().
Definition: event.h:1180
+
EVENT2_EXPORT_SYMBOL int event_base_got_exit(struct event_base *eb)
Checks if the event loop was told to exit by event_base_loopexit().
+
EVENT2_EXPORT_SYMBOL int event_base_get_max_events(struct event_base *eb, unsigned int flags, int clear)
Get the maximum number of events in a given event_base as specified in the flags.
+
EVENT2_EXPORT_SYMBOL void libevent_global_shutdown(void)
Release up all globally-allocated resources allocated by Libevent.
+
const EVENT2_EXPORT_SYMBOL char * event_get_version(void)
Get the Libevent version.
+
EVENT2_EXPORT_SYMBOL evutil_socket_t event_get_fd(const struct event *ev)
Get the socket or signal assigned to an event, or -1 if the event has no socket.
+
@ EV_FEATURE_ET
Require an event method that allows edge-triggered events with EV_ET.
Definition: event.h:515
+
EVENT2_EXPORT_SYMBOL int event_del_noblock(struct event *ev)
As event_del(), but never blocks while the event's callback is running in another thread,...
+
EVENT2_EXPORT_SYMBOL void event_config_free(struct event_config *cfg)
Deallocates all memory associated with an event configuration object.
+
const EVENT2_EXPORT_SYMBOL char * event_base_get_method(const struct event_base *eb)
Get the kernel event notification mechanism used by Libevent.
+
event_base_config_flag
A flag passed to event_config_set_flag().
Definition: event.h:541
+
EVENT2_EXPORT_SYMBOL int event_config_require_features(struct event_config *cfg, int feature)
Enters a required event method feature that the application demands.
+
EVENT2_EXPORT_SYMBOL void event_base_dump_events(struct event_base *base, FILE *output)
Writes a human-readable description of all inserted and/or active events to a provided stdio stream.
+
EVENT2_EXPORT_SYMBOL void * event_self_cbarg(void)
Return a value used to specify that the event itself must be used as the callback argument.
+
EVENT2_EXPORT_SYMBOL const struct timeval * event_base_init_common_timeout(struct event_base *base, const struct timeval *duration)
Prepare an event_base to use a large number of timeouts with the same duration.
+
EVENT2_EXPORT_SYMBOL int event_base_loop(struct event_base *eb, int flags)
Wait for events to become active, and run their callbacks.
+
EVENT2_EXPORT_SYMBOL void event_base_active_by_signal(struct event_base *base, int sig)
Activates all pending signals with a given signal number.
+
EVENT2_EXPORT_SYMBOL int event_base_priority_init(struct event_base *eb, int npriorities)
Set the number of different event priorities.
+
EVENT2_EXPORT_SYMBOL int event_del_block(struct event *ev)
As event_del(), but always blocks while the event's callback is running in another thread,...
+
@ EVENT_BASE_FLAG_EPOLL_USE_CHANGELIST
If we are using the epoll backend, this flag says that it is safe to use Libevent's internal change-l...
Definition: event.h:580
+
EVENT2_EXPORT_SYMBOL int event_base_loopexit(struct event_base *eb, const struct timeval *tv)
Exit the event loop after the specified time.
+
EVENT2_EXPORT_SYMBOL void event_debug_unassign(struct event *)
When debugging mode is enabled, informs Libevent that an event should no longer be considered as assi...
+
EVENT2_EXPORT_SYMBOL struct event * event_base_get_running_event(struct event_base *base)
If called from within the callback for an event, returns that event.
+
EVENT2_EXPORT_SYMBOL void event_base_free(struct event_base *eb)
Deallocate all memory associated with an event_base, and free the base.
+
EVENT2_EXPORT_SYMBOL int event_pending(const struct event *ev, short events, struct timeval *tv)
Checks if a specific event is pending or scheduled.
+
Configuration for an event_base.
Definition: event.h:295
+
EVENT2_EXPORT_SYMBOL int event_remove_timer(struct event *ev)
Remove a timer from a pending event without removing the event itself.
+
@ EVENT_BASE_FLAG_PRECISE_TIMER
Ordinarily, Libevent implements its time and timeout code using the fastest monotonic timer that we h...
Definition: event.h:587
+
EVENT2_EXPORT_SYMBOL int event_base_dispatch(struct event_base *base)
Event dispatching loop.
+
@ EV_FEATURE_EARLY_CLOSE
Require an event method that allows you to use EV_CLOSED to detect connection close without the neces...
Definition: event.h:530
+
@ EVENT_BASE_FLAG_IGNORE_ENV
Do not check the EVENT_* environment variables when configuring an event_base
Definition: event.h:551
+
EVENT2_EXPORT_SYMBOL int event_config_avoid_method(struct event_config *cfg, const char *method)
Enters an event method that should be avoided into the configuration.
+
EVENT2_EXPORT_SYMBOL int event_base_get_num_events(struct event_base *eb, unsigned int flags)
Gets the number of events in event_base, as specified in the flags.
+
EVENT2_EXPORT_SYMBOL int event_add(struct event *ev, const struct timeval *timeout)
Add an event to the set of pending events.
+
EVENT2_EXPORT_SYMBOL int event_base_set(struct event_base *eb, struct event *ev)
Associate a different event base with an event.
+
EVENT2_EXPORT_SYMBOL int event_base_foreach_event(struct event_base *base, event_base_foreach_event_cb fn, void *arg)
Iterate over all added or active events events in an event loop, and invoke a given callback on each ...
+
EVENT2_EXPORT_SYMBOL void event_enable_debug_logging(ev_uint32_t which)
Turn on debugging logs and have them sent to the default log handler.
+
int(* event_base_foreach_event_cb)(const struct event_base *, const struct event *, void *)
Callback for iterating events in an event base via event_base_foreach_event.
Definition: event.h:1627
+
void(* event_callback_fn)(evutil_socket_t, short, void *)
A callback function for an event.
Definition: event.h:1048
+
@ EVENT_BASE_FLAG_EPOLL_DISALLOW_TIMERFD
With EVENT_BASE_FLAG_PRECISE_TIMER, epoll backend will use timerfd for more accurate timers,...
Definition: event.h:600
+
@ EV_FEATURE_FDS
Require an event method that allows file descriptors as well as sockets.
Definition: event.h:523
+
Common convenience functions for cross-platform portability and related socket manipulations.
+
@ EVENT_BASE_FLAG_NO_CACHE_TIME
Instead of checking the current time every time the event loop is ready to run timeout callbacks,...
Definition: event.h:564
+
EVENT2_EXPORT_SYMBOL struct event_base * event_base_new(void)
Create and return a new event_base to use with the rest of Libevent.
+
EVENT2_EXPORT_SYMBOL int event_base_loopcontinue(struct event_base *eb)
Tell the active event_base_loop() to scan for new events immediately.
+
EVENT2_EXPORT_SYMBOL int event_base_loopbreak(struct event_base *eb)
Abort the active event_base_loop() immediately.
+
EVENT2_EXPORT_SYMBOL int event_base_got_break(struct event_base *eb)
Checks if the event loop was told to abort immediately by event_base_loopbreak().
+
EVENT2_EXPORT_SYMBOL struct event_base * event_get_base(const struct event *ev)
Get the event_base associated with an event.
+
EVENT2_EXPORT_SYMBOL int event_base_gettimeofday_cached(struct event_base *base, struct timeval *tv)
Sets 'tv' to the current time (as returned by gettimeofday()), looking at the cached value in 'base' ...
+
#define evutil_socket_t
A type wide enough to hold the output of "socket()" or "accept()".
Definition: util.h:325
+
EVENT2_EXPORT_SYMBOL void event_set_log_callback(event_log_cb cb)
Redirect Libevent's log messages.
+ + + + diff --git a/event__compat_8h.html b/event__compat_8h.html new file mode 100644 index 0000000..77a9aff --- /dev/null +++ b/event__compat_8h.html @@ -0,0 +1,440 @@ + + + + + + + +libevent: event2/event_compat.h File Reference + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+ +
+
event_compat.h File Reference
+
+
+ +

Potentially non-threadsafe versions of the functions in event.h: provided only for backwards compatibility. +More...

+
#include <event2/visibility.h>
+#include <event2/event-config.h>
+#include <event2/util.h>
+
+

Go to the source code of this file.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+Macros

+#define EVENT_FD(ev)   ((int)event_get_fd(ev))
 
+#define EVENT_SIGNAL(ev)   event_get_signal(ev)
 
+#define evsignal_set(ev, x, cb, arg)   event_set((ev), (x), EV_SIGNAL|EV_PERSIST, (cb), (arg))
 
+#define evtimer_set(ev, cb, arg)   event_set((ev), -1, 0, (cb), (arg))
 
timeout_* macros
Deprecated:
These macros are deprecated because their naming is inconsistent with the rest of Libevent.
+

Use the evtimer_* macros instead.

+
+#define timeout_add(ev, tv)   event_add((ev), (tv))
 
+#define timeout_del(ev)   event_del(ev)
 
+#define timeout_initialized(ev)   event_initialized(ev)
 
+#define timeout_pending(ev, tv)   event_pending((ev), EV_TIMEOUT, (tv))
 
+#define timeout_set(ev, cb, arg)   event_set((ev), -1, 0, (cb), (arg))
 
signal_* macros
Deprecated:
These macros are deprecated because their naming is inconsistent with the rest of Libevent.
+

Use the evsignal_* macros instead.

+
+#define signal_add(ev, tv)   event_add((ev), (tv))
 
+#define signal_del(ev)   event_del(ev)
 
+#define signal_initialized(ev)   event_initialized(ev)
 
+#define signal_pending(ev, tv)   event_pending((ev), EV_SIGNAL, (tv))
 
+#define signal_set(ev, x, cb, arg)   event_set((ev), (x), EV_SIGNAL|EV_PERSIST, (cb), (arg))
 
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+Functions

EVENT2_EXPORT_SYMBOL int event_dispatch (void)
 Loop to process events. More...
 
const EVENT2_EXPORT_SYMBOL char * event_get_method (void)
 Get the kernel event notification mechanism used by Libevent. More...
 
EVENT2_EXPORT_SYMBOL struct event_baseevent_init (void)
 Initialize the event API. More...
 
EVENT2_EXPORT_SYMBOL int event_loop (int)
 Handle events. More...
 
EVENT2_EXPORT_SYMBOL int event_loopbreak (void)
 Abort the active event_loop() immediately. More...
 
EVENT2_EXPORT_SYMBOL int event_loopexit (const struct timeval *)
 Exit the event loop after the specified time. More...
 
EVENT2_EXPORT_SYMBOL int event_once (evutil_socket_t, short, void(*)(evutil_socket_t, short, void *), void *, const struct timeval *)
 Schedule a one-time event to occur. More...
 
EVENT2_EXPORT_SYMBOL int event_priority_init (int)
 Set the number of different event priorities. More...
 
EVENT2_EXPORT_SYMBOL void event_set (struct event *, evutil_socket_t, short, void(*)(evutil_socket_t, short, void *), void *)
 Prepare an event structure to be added. More...
 
+

Detailed Description

+

Potentially non-threadsafe versions of the functions in event.h: provided only for backwards compatibility.

+

In the oldest versions of Libevent, event_base was not a first-class structure. Instead, there was a single event base that every function manipulated. Later, when separate event bases were added, the old functions that didn't take an event_base argument needed to work by manipulating the "current" event base. This could lead to thread-safety issues, and obscure, hard-to-diagnose bugs.

+
Deprecated:
All functions in this file are by definition deprecated.
+

Function Documentation

+ +

◆ event_dispatch()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_dispatch (void )
+
+ +

Loop to process events.

+

Like event_base_dispatch(), but uses the "current" base.

+
Deprecated:
This function is deprecated because it is easily confused by multiple calls to event_init(), and because it is not safe for multithreaded use. The replacement is event_base_dispatch().
+
See also
event_base_dispatch(), event_init()
+ +
+
+ +

◆ event_get_method()

+ +
+
+ + + + + + + + +
const EVENT2_EXPORT_SYMBOL char* event_get_method (void )
+
+ +

Get the kernel event notification mechanism used by Libevent.

+
Deprecated:
This function is obsolete, and has been replaced by event_base_get_method(). Its use is deprecated because it relies on the "current" base configured by event_init().
+
See also
event_base_get_method()
+ +
+
+ +

◆ event_init()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL struct event_base* event_init (void )
+
+ +

Initialize the event API.

+

The event API needs to be initialized with event_init() before it can be used. Sets the global current base that gets used for events that have no base associated with them.

+
Deprecated:
This function is deprecated because it replaces the "current" event_base, and is totally unsafe for multithreaded use. The replacement is event_base_new().
+
See also
event_base_set(), event_base_new()
+ +
+
+ +

◆ event_loop()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_loop (int )
+
+ +

Handle events.

+

This function behaves like event_base_loop(), but uses the "current" base

+
Deprecated:
This function is deprecated because it uses the event base from the last call to event_init, and is therefore not safe for multithreaded use. The replacement is event_base_loop().
+
See also
event_base_loop(), event_init()
+ +
+
+ +

◆ event_loopbreak()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_loopbreak (void )
+
+ +

Abort the active event_loop() immediately.

+

This function behaves like event_base_loopbreakt(), except that it uses the "current" base.

+
Deprecated:
This function is deprecated because it uses the event base from the last call to event_init, and is therefore not safe for multithreaded use. The replacement is event_base_loopbreak().
+
See also
event_base_loopbreak(), event_init()
+ +
+
+ +

◆ event_loopexit()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_loopexit (const struct timeval * )
+
+ +

Exit the event loop after the specified time.

+

This function behaves like event_base_loopexit(), except that it uses the "current" base.

+
Deprecated:
This function is deprecated because it uses the event base from the last call to event_init, and is therefore not safe for multithreaded use. The replacement is event_base_loopexit().
+
See also
event_init, event_base_loopexit()
+ +
+
+ +

◆ event_once()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_once (evutil_socket_t ,
short ,
void(*)(evutil_socket_t, short, void *) ,
void * ,
const struct timeval *  
)
+
+ +

Schedule a one-time event to occur.

+
Deprecated:
This function is obsolete, and has been replaced by event_base_once(). Its use is deprecated because it relies on the "current" base configured by event_init().
+
See also
event_base_once()
+ +
+
+ +

◆ event_priority_init()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int event_priority_init (int )
+
+ +

Set the number of different event priorities.

+
Deprecated:
This function is deprecated because it is easily confused by multiple calls to event_init(), and because it is not safe for multithreaded use. The replacement is event_base_priority_init().
+
See also
event_base_priority_init()
+ +
+
+ +

◆ event_set()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void event_set (struct event,
evutil_socket_t ,
short ,
void(*)(evutil_socket_t, short, void *) ,
void *  
)
+
+ +

Prepare an event structure to be added.

+
Deprecated:
event_set() is not recommended for new code, because it requires a subsequent call to event_base_set() to be safe under most circumstances. Use event_assign() or event_new() instead.
+ +
+
+
+ + + + diff --git a/event__compat_8h_source.html b/event__compat_8h_source.html new file mode 100644 index 0000000..16f971d --- /dev/null +++ b/event__compat_8h_source.html @@ -0,0 +1,202 @@ + + + + + + + +libevent: event2/event_compat.h Source File + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
event_compat.h
+
+
+Go to the documentation of this file.
1 /*
+
2  * Copyright (c) 2000-2007 Niels Provos <provos@citi.umich.edu>
+
3  * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson
+
4  *
+
5  * Redistribution and use in source and binary forms, with or without
+
6  * modification, are permitted provided that the following conditions
+
7  * are met:
+
8  * 1. Redistributions of source code must retain the above copyright
+
9  * notice, this list of conditions and the following disclaimer.
+
10  * 2. Redistributions in binary form must reproduce the above copyright
+
11  * notice, this list of conditions and the following disclaimer in the
+
12  * documentation and/or other materials provided with the distribution.
+
13  * 3. The name of the author may not be used to endorse or promote products
+
14  * derived from this software without specific prior written permission.
+
15  *
+
16  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+
17  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+
18  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+
19  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+
20  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+
21  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+
22  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+
23  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+
24  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+
25  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
26  */
+
27 #ifndef EVENT2_EVENT_COMPAT_H_INCLUDED_
+
28 #define EVENT2_EVENT_COMPAT_H_INCLUDED_
+
29 
+
44 #include <event2/visibility.h>
+
45 
+
46 #ifdef __cplusplus
+
47 extern "C" {
+
48 #endif
+
49 
+
50 #include <event2/event-config.h>
+
51 #ifdef EVENT__HAVE_SYS_TYPES_H
+
52 #include <sys/types.h>
+
53 #endif
+
54 #ifdef EVENT__HAVE_SYS_TIME_H
+
55 #include <sys/time.h>
+
56 #endif
+
57 
+
58 /* For int types. */
+
59 #include <event2/util.h>
+
60 
+
74 EVENT2_EXPORT_SYMBOL
+
75 struct event_base *event_init(void);
+
76 
+
88 EVENT2_EXPORT_SYMBOL
+
89 int event_dispatch(void);
+
90 
+
102 EVENT2_EXPORT_SYMBOL
+
103 int event_loop(int);
+
104 
+
105 
+
118 EVENT2_EXPORT_SYMBOL
+
119 int event_loopexit(const struct timeval *);
+
120 
+
121 
+
134 EVENT2_EXPORT_SYMBOL
+
135 int event_loopbreak(void);
+
136 
+
146 EVENT2_EXPORT_SYMBOL
+
147 int event_once(evutil_socket_t , short,
+
148  void (*)(evutil_socket_t, short, void *), void *, const struct timeval *);
+
149 
+
150 
+
160 EVENT2_EXPORT_SYMBOL
+
161 const char *event_get_method(void);
+
162 
+
163 
+
173 EVENT2_EXPORT_SYMBOL
+
174 int event_priority_init(int);
+
175 
+
183 EVENT2_EXPORT_SYMBOL
+
184 void event_set(struct event *, evutil_socket_t, short, void (*)(evutil_socket_t, short, void *), void *);
+
185 
+
186 #define evtimer_set(ev, cb, arg) event_set((ev), -1, 0, (cb), (arg))
+
187 #define evsignal_set(ev, x, cb, arg) \
+
188  event_set((ev), (x), EV_SIGNAL|EV_PERSIST, (cb), (arg))
+
189 
+
190 
+
198 #define timeout_add(ev, tv) event_add((ev), (tv))
+
199 #define timeout_set(ev, cb, arg) event_set((ev), -1, 0, (cb), (arg))
+
200 #define timeout_del(ev) event_del(ev)
+
201 #define timeout_pending(ev, tv) event_pending((ev), EV_TIMEOUT, (tv))
+
202 #define timeout_initialized(ev) event_initialized(ev)
+
203 
+
212 #define signal_add(ev, tv) event_add((ev), (tv))
+
213 #define signal_set(ev, x, cb, arg) \
+
214  event_set((ev), (x), EV_SIGNAL|EV_PERSIST, (cb), (arg))
+
215 #define signal_del(ev) event_del(ev)
+
216 #define signal_pending(ev, tv) event_pending((ev), EV_SIGNAL, (tv))
+
217 #define signal_initialized(ev) event_initialized(ev)
+
218 
+
220 #ifndef EVENT_FD
+
221 /* These macros are obsolete; use event_get_fd and event_get_signal instead. */
+
222 #define EVENT_FD(ev) ((int)event_get_fd(ev))
+
223 #define EVENT_SIGNAL(ev) event_get_signal(ev)
+
224 #endif
+
225 
+
226 #ifdef __cplusplus
+
227 }
+
228 #endif
+
229 
+
230 #endif /* EVENT2_EVENT_COMPAT_H_INCLUDED_ */
+
+
EVENT2_EXPORT_SYMBOL int event_dispatch(void)
Loop to process events.
+
EVENT2_EXPORT_SYMBOL int event_loopbreak(void)
Abort the active event_loop() immediately.
+
Structure to hold information and state for a Libevent dispatch loop.
Definition: event.h:219
+
EVENT2_EXPORT_SYMBOL int event_priority_init(int)
Set the number of different event priorities.
+
Structure to represent a single event.
Definition: event.h:276
+
EVENT2_EXPORT_SYMBOL int event_loop(int)
Handle events.
+
EVENT2_EXPORT_SYMBOL int event_once(evutil_socket_t, short, void(*)(evutil_socket_t, short, void *), void *, const struct timeval *)
Schedule a one-time event to occur.
+
EVENT2_EXPORT_SYMBOL struct event_base * event_init(void)
Initialize the event API.
+
const EVENT2_EXPORT_SYMBOL char * event_get_method(void)
Get the kernel event notification mechanism used by Libevent.
+
EVENT2_EXPORT_SYMBOL int event_loopexit(const struct timeval *)
Exit the event loop after the specified time.
+
EVENT2_EXPORT_SYMBOL void event_set(struct event *, evutil_socket_t, short, void(*)(evutil_socket_t, short, void *), void *)
Prepare an event structure to be added.
+
Common convenience functions for cross-platform portability and related socket manipulations.
+
#define evutil_socket_t
A type wide enough to hold the output of "socket()" or "accept()".
Definition: util.h:325
+ + + + diff --git a/files.html b/files.html new file mode 100644 index 0000000..4735de2 --- /dev/null +++ b/files.html @@ -0,0 +1,102 @@ + + + + + + + +libevent: File List + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+
File List
+
+
+
Here is a list of all documented files with brief descriptions:
+
[detail level 12]
+ + + + + + + + + + + + + + + + + + + + +
  event2
 buffer.hFunctions for buffering data for network sending or receiving
 buffer_compat.hObsolete and deprecated versions of the functions in buffer.h: provided only for backward compatibility
 bufferevent.hFunctions for buffering data for network sending or receiving
 bufferevent_compat.hDeprecated versions of the functions in bufferevent.h: provided only for backwards compatibility
 bufferevent_ssl.hOpenSSL support for bufferevents
 dns.hProvides a few APIs to use for resolving DNS names, and a facility for implementing simple DNS servers
 dns_compat.hPotentially non-threadsafe versions of the functions in dns.h: provided only for backwards compatibility
 event.hCore functions for waiting for and receiving events, and using event bases
 event_compat.hPotentially non-threadsafe versions of the functions in event.h: provided only for backwards compatibility
 http.hBasic support for HTTP serving
 http_compat.hPotentially non-threadsafe versions of the functions in http.h: provided only for backwards compatibility
 listener.hA callback that we invoke when a listener has a new connection
 rpc.hThis header files provides basic support for an RPC server and client
 rpc_compat.hDeprecated versions of the functions in rpc.h: provided only for backwards compatibility
 tag.hHelper functions for reading and writing tagged data onto buffers
 tag_compat.hObsolete/deprecated functions from tag.h; provided only for backwards compatibility
 thread.hFunctions for multi-threaded applications using Libevent
 util.hCommon convenience functions for cross-platform portability and related socket manipulations
 watch.h"Prepare" and "check" watchers
+
+
+ + + + diff --git a/folderclosed.png b/folderclosed.png new file mode 100644 index 0000000..bb8ab35 Binary files /dev/null and b/folderclosed.png differ diff --git a/folderopen.png b/folderopen.png new file mode 100644 index 0000000..d6c7f67 Binary files /dev/null and b/folderopen.png differ diff --git a/functions.html b/functions.html new file mode 100644 index 0000000..3a2c0b5 --- /dev/null +++ b/functions.html @@ -0,0 +1,124 @@ + + + + + + + +libevent: Data Fields + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all documented struct and union fields with links to the struct/union documentation for each field:
+
+ + + + diff --git a/functions_vars.html b/functions_vars.html new file mode 100644 index 0000000..e7fdd2c --- /dev/null +++ b/functions_vars.html @@ -0,0 +1,124 @@ + + + + + + + +libevent: Data Fields - Variables + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+ + + + diff --git a/globals.html b/globals.html new file mode 100644 index 0000000..83bfedd --- /dev/null +++ b/globals.html @@ -0,0 +1,369 @@ + + + + + + + +libevent: Globals + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all documented functions, variables, defines, enums, and typedefs with links to the documentation:
+ +

- b -

+
+ + + + diff --git a/globals_d.html b/globals_d.html new file mode 100644 index 0000000..de683a9 --- /dev/null +++ b/globals_d.html @@ -0,0 +1,129 @@ + + + + + + + +libevent: Globals + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all documented functions, variables, defines, enums, and typedefs with links to the documentation:
+ +

- d -

+
+ + + + diff --git a/globals_defs.html b/globals_defs.html new file mode 100644 index 0000000..9cfecf3 --- /dev/null +++ b/globals_defs.html @@ -0,0 +1,501 @@ + + + + + + + +libevent: Globals + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+  + +

- b -

+ + +

- d -

+ + +

- e -

+ + +

- h -

+ + +

- i -

+ + +

- l -

+ + +

- o -

+
+ + + + diff --git a/globals_e.html b/globals_e.html new file mode 100644 index 0000000..3b4adb9 --- /dev/null +++ b/globals_e.html @@ -0,0 +1,1605 @@ + + + + + + + +libevent: Globals + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all documented functions, variables, defines, enums, and typedefs with links to the documentation:
+ +

- e -

+
+ + + + diff --git a/globals_enum.html b/globals_enum.html new file mode 100644 index 0000000..f6d722c --- /dev/null +++ b/globals_enum.html @@ -0,0 +1,121 @@ + + + + + + + +libevent: Globals + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+ + + + diff --git a/globals_eval.html b/globals_eval.html new file mode 100644 index 0000000..77bcb61 --- /dev/null +++ b/globals_eval.html @@ -0,0 +1,214 @@ + + + + + + + +libevent: Globals + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+  + +

- b -

+ + +

- e -

+
+ + + + diff --git a/globals_func.html b/globals_func.html new file mode 100644 index 0000000..ec3472c --- /dev/null +++ b/globals_func.html @@ -0,0 +1,285 @@ + + + + + + + +libevent: Globals + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+  + +

- b -

+
+ + + + diff --git a/globals_func_e.html b/globals_func_e.html new file mode 100644 index 0000000..d0b1cf3 --- /dev/null +++ b/globals_func_e.html @@ -0,0 +1,1221 @@ + + + + + + + +libevent: Globals + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+  + +

- e -

+
+ + + + diff --git a/globals_func_l.html b/globals_func_l.html new file mode 100644 index 0000000..e23a7cd --- /dev/null +++ b/globals_func_l.html @@ -0,0 +1,81 @@ + + + + + + + +libevent: Globals + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+  + +

- l -

+
+ + + + diff --git a/globals_h.html b/globals_h.html new file mode 100644 index 0000000..70ba34c --- /dev/null +++ b/globals_h.html @@ -0,0 +1,150 @@ + + + + + + + +libevent: Globals + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all documented functions, variables, defines, enums, and typedefs with links to the documentation:
+ +

- h -

+
+ + + + diff --git a/globals_i.html b/globals_i.html new file mode 100644 index 0000000..a54a9b6 --- /dev/null +++ b/globals_i.html @@ -0,0 +1,81 @@ + + + + + + + +libevent: Globals + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all documented functions, variables, defines, enums, and typedefs with links to the documentation:
+ +

- i -

+
+ + + + diff --git a/globals_l.html b/globals_l.html new file mode 100644 index 0000000..8752d54 --- /dev/null +++ b/globals_l.html @@ -0,0 +1,117 @@ + + + + + + + +libevent: Globals + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all documented functions, variables, defines, enums, and typedefs with links to the documentation:
+ +

- l -

+
+ + + + diff --git a/globals_o.html b/globals_o.html new file mode 100644 index 0000000..12f4273 --- /dev/null +++ b/globals_o.html @@ -0,0 +1,81 @@ + + + + + + + +libevent: Globals + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all documented functions, variables, defines, enums, and typedefs with links to the documentation:
+ +

- o -

+
+ + + + diff --git a/globals_type.html b/globals_type.html new file mode 100644 index 0000000..33bf8fa --- /dev/null +++ b/globals_type.html @@ -0,0 +1,133 @@ + + + + + + + +libevent: Globals + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+ + + + diff --git a/http_8h.html b/http_8h.html new file mode 100644 index 0000000..6459e9e --- /dev/null +++ b/http_8h.html @@ -0,0 +1,3957 @@ + + + + + + + +libevent: event2/http.h File Reference + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+ +
+
http.h File Reference
+
+
+ +

Basic support for HTTP serving. +More...

+
#include <event2/util.h>
+#include <event2/visibility.h>
+
+

Go to the source code of this file.

+ + + + + +

+Data Structures

struct  evhttp_ext_method
 structure that is passed to (and modified by) the extended method callback function More...
 
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+Macros

+#define EVHTTP_CON_LINGERING_CLOSE   0x0020
 
+#define EVHTTP_CON_PUBLIC_FLAGS_END   0x100000
 
+#define EVHTTP_CON_READ_ON_WRITE_ERROR   0x0010
 
+#define EVHTTP_CON_REUSE_CONNECTED_ADDR   0x0008
 
+#define EVHTTP_METHOD_HAS_BODY   0x0001
 
+#define EVHTTP_REQ_MAX   EVHTTP_REQ_MOVE
 
+#define EVHTTP_SERVER_LINGERING_CLOSE   0x0001
 
#define EVHTTP_URI_HOST_STRIP_BRACKETS   0x04
 Strip brackets from the IPv6 address and only for evhttp_uri_get_host(), evhttp_uri_join() returns the host with brackets. More...
 
#define EVHTTP_URI_NONCONFORMANT   0x01
 Tolerate URIs that do not conform to RFC3986. More...
 
#define EVHTTP_URI_QUERY_LAST_VAL   0x02
 Prefer last value over the first from query args. More...
 
#define EVHTTP_URI_QUERY_NONCONFORMANT   0x01
 Tolerate queries that are not standard conformant. More...
 
#define EVHTTP_URI_UNIX_SOCKET   0x08
 Parse unix domain socket URIs, for example: More...
 
+#define HTTP_ACCEPTED   202
 accepted for processing
 
+#define HTTP_BADGATEWAY   502
 received an invalid response from the upstream
 
+#define HTTP_BADMETHOD   405
 method not allowed for this uri
 
+#define HTTP_BADREQUEST   400
 invalid http request was made
 
+#define HTTP_CONTINUE   100
 client should proceed to send
 
+#define HTTP_CREATED   201
 new resource is created
 
+#define HTTP_EARLYHINTS   103
 return some response headers
 
+#define HTTP_ENTITYTOOLARGE   413
 request is larger than the server is able to process
 
+#define HTTP_EXPECTATIONFAILED   417
 we can't handle this expectation
 
+#define HTTP_FORBIDDEN   403
 user not having the necessary permissions
 
+#define HTTP_INTERNAL   500
 internal error
 
+#define HTTP_MOVEPERM   301
 the uri moved permanently
 
+#define HTTP_MOVETEMP   302
 the uri moved temporarily
 
+#define HTTP_NOCONTENT   204
 request does not have content
 
+#define HTTP_NONAUTHORITATIVE   203
 returning a modified version of the origin's response
 
+#define HTTP_NOTFOUND   404
 could not find content for uri
 
+#define HTTP_NOTIMPLEMENTED   501
 not implemented
 
+#define HTTP_NOTMODIFIED   304
 page was not modified from last
 
+#define HTTP_OK   200
 request completed ok
 
+#define HTTP_PAYMENTREQUIRED   402
 user exceeded limit on requests
 
+#define HTTP_PROCESSING   102
 processing the request, but no response is available yet
 
+#define HTTP_SERVUNAVAIL   503
 the server is not available
 
+#define HTTP_SWITCH_PROTOCOLS   101
 switching to another protocol
 
+#define HTTP_UNAUTHORIZED   401
 authentication is required
 
+ + + + + +

+Typedefs

+typedef void evhttp_bound_socket_foreach_fn(struct evhttp_bound_socket *, void *)
 
+typedef int(* evhttp_ext_method_cb) (struct evhttp_ext_method *)
 
+ + + + + + + + + + +

+Enumerations

enum  evhttp_cmd_type {
+  EVHTTP_REQ_GET = 1 << 0, +EVHTTP_REQ_POST = 1 << 1, +EVHTTP_REQ_HEAD = 1 << 2, +EVHTTP_REQ_PUT = 1 << 3, +
+  EVHTTP_REQ_DELETE = 1 << 4, +EVHTTP_REQ_OPTIONS = 1 << 5, +EVHTTP_REQ_TRACE = 1 << 6, +EVHTTP_REQ_CONNECT = 1 << 7, +
+  EVHTTP_REQ_PATCH = 1 << 8, +EVHTTP_REQ_PROPFIND = 1 << 9, +EVHTTP_REQ_PROPPATCH =1 << 10, +EVHTTP_REQ_MKCOL = 1 << 11, +
+  EVHTTP_REQ_LOCK = 1 << 12, +EVHTTP_REQ_UNLOCK = 1 << 13, +EVHTTP_REQ_COPY = 1 << 14, +EVHTTP_REQ_MOVE = 1 << 15 +
+ }
 The different request types supported by evhttp. More...
 
enum  evhttp_request_error {
+  EVREQ_HTTP_TIMEOUT, +EVREQ_HTTP_EOF, +EVREQ_HTTP_INVALID_HEADER, +EVREQ_HTTP_BUFFER_ERROR, +
+  EVREQ_HTTP_REQUEST_CANCEL, +EVREQ_HTTP_DATA_TOO_LONG +
+ }
 The different error types supported by evhttp. More...
 
enum  evhttp_request_kind { EVHTTP_REQUEST, +EVHTTP_RESPONSE + }
 a request object can represent either a request or a reply
 
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+Functions

EVENT2_EXPORT_SYMBOL int evhttp_accept_socket (struct evhttp *http, evutil_socket_t fd)
 Makes an HTTP server accept connections on the specified socket. More...
 
EVENT2_EXPORT_SYMBOL struct evhttp_bound_socket * evhttp_accept_socket_with_handle (struct evhttp *http, evutil_socket_t fd)
 Like evhttp_accept_socket(), but returns a handle for referencing the socket. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_add_header (struct evkeyvalq *headers, const char *key, const char *value)
 Adds a header to a list of existing headers. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_add_server_alias (struct evhttp *http, const char *alias)
 Add a server alias to an http object. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_add_virtual_host (struct evhttp *http, const char *pattern, struct evhttp *vhost)
 Adds a virtual host to the http server. More...
 
EVENT2_EXPORT_SYMBOL struct evhttp_bound_socket * evhttp_bind_listener (struct evhttp *http, struct evconnlistener *listener)
 The most low-level evhttp_bind/accept method: takes an evconnlistener, and returns an evhttp_bound_socket. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_bind_socket (struct evhttp *http, const char *address, ev_uint16_t port)
 Binds an HTTP server on the specified address and port. More...
 
EVENT2_EXPORT_SYMBOL struct evhttp_bound_socket * evhttp_bind_socket_with_handle (struct evhttp *http, const char *address, ev_uint16_t port)
 Like evhttp_bind_socket(), but returns a handle for referencing the socket. More...
 
+EVENT2_EXPORT_SYMBOL void evhttp_bound_set_bevcb (struct evhttp_bound_socket *bound, struct bufferevent *(*cb)(struct event_base *, void *), void *cbarg)
 
EVENT2_EXPORT_SYMBOL evutil_socket_t evhttp_bound_socket_get_fd (struct evhttp_bound_socket *bound_socket)
 Get the raw file descriptor referenced by an evhttp_bound_socket. More...
 
+EVENT2_EXPORT_SYMBOL struct evconnlistener * evhttp_bound_socket_get_listener (struct evhttp_bound_socket *bound)
 Return the listener used to implement a bound socket.
 
EVENT2_EXPORT_SYMBOL void evhttp_cancel_request (struct evhttp_request *req)
 Cancels a pending HTTP request. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_clear_headers (struct evkeyvalq *headers)
 Removes all headers from the header list. More...
 
EVENT2_EXPORT_SYMBOL struct evhttp_connection * evhttp_connection_base_bufferevent_new (struct event_base *base, struct evdns_base *dnsbase, struct bufferevent *bev, const char *address, ev_uint16_t port)
 Create and return a connection object that can be used to for making HTTP requests. More...
 
EVENT2_EXPORT_SYMBOL struct evhttp_connection * evhttp_connection_base_bufferevent_unix_new (struct event_base *base, struct bufferevent *bev, const char *path)
 Create and return a connection object that can be used to for making HTTP requests over an unix domain socket. More...
 
EVENT2_EXPORT_SYMBOL struct evhttp_connection * evhttp_connection_base_new (struct event_base *base, struct evdns_base *dnsbase, const char *address, ev_uint16_t port)
 Create and return a connection object that can be used to for making HTTP requests. More...
 
+EVENT2_EXPORT_SYMBOL void evhttp_connection_free (struct evhttp_connection *evcon)
 Frees an http connection.
 
EVENT2_EXPORT_SYMBOL void evhttp_connection_free_on_completion (struct evhttp_connection *evcon)
 Disowns a given connection object. More...
 
EVENT2_EXPORT_SYMBOL const struct sockaddr * evhttp_connection_get_addr (struct evhttp_connection *evcon)
 Get the remote address associated with this connection. More...
 
+EVENT2_EXPORT_SYMBOL struct event_baseevhttp_connection_get_base (struct evhttp_connection *req)
 Returns the underlying event_base for this connection.
 
+EVENT2_EXPORT_SYMBOL struct buffereventevhttp_connection_get_bufferevent (struct evhttp_connection *evcon)
 Return the bufferevent that an evhttp_connection is using.
 
+EVENT2_EXPORT_SYMBOL void evhttp_connection_get_peer (struct evhttp_connection *evcon, const char **address, ev_uint16_t *port)
 Get the remote address and port associated with this connection.
 
+EVENT2_EXPORT_SYMBOL struct evhttp * evhttp_connection_get_server (struct evhttp_connection *evcon)
 Return the HTTP server associated with this connection, or NULL.
 
+EVENT2_EXPORT_SYMBOL void evhttp_connection_set_closecb (struct evhttp_connection *evcon, void(*)(struct evhttp_connection *, void *), void *)
 Set a callback for connection close.
 
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_connect_timeout_tv (struct evhttp_connection *evcon, const struct timeval *tv)
 Sets the connect timeout for this connection. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_ext_method_cmp (struct evhttp_connection *evcon, evhttp_ext_method_cb cmp)
 Sets extended method cmp callback for this http connection. More...
 
+EVENT2_EXPORT_SYMBOL void evhttp_connection_set_family (struct evhttp_connection *evcon, int family)
 Set family hint for DNS requests.
 
EVENT2_EXPORT_SYMBOL int evhttp_connection_set_flags (struct evhttp_connection *evcon, int flags)
 Set connection flags. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_initial_retry_tv (struct evhttp_connection *evcon, const struct timeval *tv)
 Sets the delay before retrying requests on this connection. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_local_address (struct evhttp_connection *evcon, const char *address)
 Sets the IP address from which http connections are made. More...
 
+EVENT2_EXPORT_SYMBOL void evhttp_connection_set_local_port (struct evhttp_connection *evcon, ev_uint16_t port)
 sets the local port from which http connections are made
 
+EVENT2_EXPORT_SYMBOL void evhttp_connection_set_max_body_size (struct evhttp_connection *evcon, ev_ssize_t new_max_body_size)
 
+EVENT2_EXPORT_SYMBOL void evhttp_connection_set_max_headers_size (struct evhttp_connection *evcon, ev_ssize_t new_max_headers_size)
 
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_read_timeout_tv (struct evhttp_connection *evcon, const struct timeval *tv)
 Sets the read timeout for this connection. More...
 
+EVENT2_EXPORT_SYMBOL void evhttp_connection_set_retries (struct evhttp_connection *evcon, int retry_max)
 Sets the retry limit for this connection - -1 repeats indefinitely.
 
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_timeout (struct evhttp_connection *evcon, int timeout)
 Sets the timeout for this connection. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_timeout_tv (struct evhttp_connection *evcon, const struct timeval *tv)
 Sets the timeout for this connection for the following events: More...
 
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_write_timeout_tv (struct evhttp_connection *evcon, const struct timeval *tv)
 Sets the write timeout for this connection. More...
 
EVENT2_EXPORT_SYMBOL char * evhttp_decode_uri (const char *uri)
 Helper function to sort of decode a URI-encoded string. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_del_accept_socket (struct evhttp *http, struct evhttp_bound_socket *bound_socket)
 Makes an HTTP server stop accepting connections on the specified socket. More...
 
+EVENT2_EXPORT_SYMBOL int evhttp_del_cb (struct evhttp *, const char *)
 Removes the callback for a specified URI.
 
EVENT2_EXPORT_SYMBOL char * evhttp_encode_uri (const char *str)
 Helper function to encode a string for inclusion in a URI. More...
 
const EVENT2_EXPORT_SYMBOL char * evhttp_find_header (const struct evkeyvalq *headers, const char *key)
 Finds the value belonging to a header. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_foreach_bound_socket (struct evhttp *http, evhttp_bound_socket_foreach_fn *function, void *argument)
 Applies the function specified in the first argument to all evhttp_bound_sockets associated with "http". More...
 
EVENT2_EXPORT_SYMBOL void evhttp_free (struct evhttp *http)
 Free the previously created HTTP server. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_get_connection_count (struct evhttp *http)
 Get the current number of connections. More...
 
EVENT2_EXPORT_SYMBOL char * evhttp_htmlescape (const char *html)
 Escape HTML character entities in a string. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_make_request (struct evhttp_connection *evcon, struct evhttp_request *req, enum evhttp_cmd_type type, const char *uri)
 Make an HTTP request over the specified connection. More...
 
EVENT2_EXPORT_SYMBOL struct evhttp * evhttp_new (struct event_base *base)
 Create a new HTTP server. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_parse_query (const char *uri, struct evkeyvalq *headers)
 Helper function to parse out arguments in a query. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_parse_query_str (const char *uri, struct evkeyvalq *headers)
 
EVENT2_EXPORT_SYMBOL int evhttp_parse_query_str_flags (const char *uri, struct evkeyvalq *headers, unsigned flags)
 Helper function to parse out arguments from the query portion of an HTTP URI. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_remove_header (struct evkeyvalq *headers, const char *key)
 Removes a header from a list of existing headers. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_remove_server_alias (struct evhttp *http, const char *alias)
 Remove a server alias from an http object. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_remove_virtual_host (struct evhttp *http, struct evhttp *vhost)
 Removes a virtual host from the http server. More...
 
+EVENT2_EXPORT_SYMBOL void evhttp_request_free (struct evhttp_request *req)
 Frees the request object and removes associated events.
 
+EVENT2_EXPORT_SYMBOL enum evhttp_cmd_type evhttp_request_get_command (const struct evhttp_request *req)
 Returns the request command.
 
EVENT2_EXPORT_SYMBOL struct evhttp_connection * evhttp_request_get_connection (struct evhttp_request *req)
 Returns the connection object associated with the request or NULL. More...
 
+EVENT2_EXPORT_SYMBOL const struct evhttp_uri * evhttp_request_get_evhttp_uri (const struct evhttp_request *req)
 Returns the request URI (parsed)
 
const EVENT2_EXPORT_SYMBOL char * evhttp_request_get_host (struct evhttp_request *req)
 Returns the host associated with the request. More...
 
+EVENT2_EXPORT_SYMBOL struct evbufferevhttp_request_get_input_buffer (struct evhttp_request *req)
 Returns the input buffer.
 
+EVENT2_EXPORT_SYMBOL struct evkeyvalq * evhttp_request_get_input_headers (struct evhttp_request *req)
 Returns the input headers.
 
+EVENT2_EXPORT_SYMBOL struct evbufferevhttp_request_get_output_buffer (struct evhttp_request *req)
 Returns the output buffer.
 
+EVENT2_EXPORT_SYMBOL struct evkeyvalq * evhttp_request_get_output_headers (struct evhttp_request *req)
 Returns the output headers.
 
+EVENT2_EXPORT_SYMBOL int evhttp_request_get_response_code (const struct evhttp_request *req)
 
+const EVENT2_EXPORT_SYMBOL char * evhttp_request_get_response_code_line (const struct evhttp_request *req)
 
+const EVENT2_EXPORT_SYMBOL char * evhttp_request_get_uri (const struct evhttp_request *req)
 Returns the request URI.
 
+EVENT2_EXPORT_SYMBOL int evhttp_request_is_owned (struct evhttp_request *req)
 Returns 1 if the request is owned by the user.
 
EVENT2_EXPORT_SYMBOL struct evhttp_request * evhttp_request_new (void(*cb)(struct evhttp_request *, void *), void *arg)
 Creates a new request object that needs to be filled in with the request parameters. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_request_own (struct evhttp_request *req)
 Takes ownership of the request object. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_request_set_chunked_cb (struct evhttp_request *, void(*cb)(struct evhttp_request *, void *))
 Enable delivery of chunks to requestor. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_request_set_error_cb (struct evhttp_request *, void(*)(enum evhttp_request_error, void *))
 Set a callback for errors. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_request_set_header_cb (struct evhttp_request *, int(*cb)(struct evhttp_request *, void *))
 Register callback for additional parsing of request headers. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_request_set_on_complete_cb (struct evhttp_request *req, void(*cb)(struct evhttp_request *, void *), void *cb_arg)
 Set a callback to be called on request completion of evhttp_send_* function. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_send_error (struct evhttp_request *req, int error, const char *reason)
 Send an HTML error message to the client. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_send_reply (struct evhttp_request *req, int code, const char *reason, struct evbuffer *databuf)
 Send an HTML reply to the client. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_send_reply_chunk (struct evhttp_request *req, struct evbuffer *databuf)
 Send another data chunk as part of an ongoing chunked reply. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_send_reply_chunk_with_cb (struct evhttp_request *req, struct evbuffer *databuf, void(*cb)(struct evhttp_connection *, void *), void *arg)
 Send another data chunk as part of an ongoing chunked reply. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_send_reply_end (struct evhttp_request *req)
 Complete a chunked reply, freeing the request as appropriate. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_send_reply_start (struct evhttp_request *req, int code, const char *reason)
 Initiate a reply that uses Transfer-Encoding chunked. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_set_allowed_methods (struct evhttp *http, ev_uint32_t methods)
 Sets the what HTTP methods are supported in requests accepted by this server, and passed to user callbacks. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_set_bevcb (struct evhttp *http, struct bufferevent *(*cb)(struct event_base *, void *), void *arg)
 Set a callback used to create new bufferevents for connections to a given evhttp object. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_set_cb (struct evhttp *http, const char *path, void(*cb)(struct evhttp_request *, void *), void *cb_arg)
 Set a callback for a specified URI. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_set_default_content_type (struct evhttp *http, const char *content_type)
 Set the value to use for the Content-Type header when none was provided. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_set_errorcb (struct evhttp *http, int(*cb)(struct evhttp_request *req, struct evbuffer *buffer, int error, const char *reason, void *cbarg), void *cbarg)
 Set a callback to output for any error pages sent for requests of a given evhttp object. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_set_ext_method_cmp (struct evhttp *http, evhttp_ext_method_cb cmp)
 Sets the callback function which allows HTTP extended methods to be supported by this server. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_set_flags (struct evhttp *http, int flags)
 Set connection flags for HTTP server. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_set_gencb (struct evhttp *http, void(*cb)(struct evhttp_request *, void *), void *arg)
 Set a callback for all requests that are not caught by specific callbacks. More...
 
+EVENT2_EXPORT_SYMBOL void evhttp_set_max_body_size (struct evhttp *http, ev_ssize_t max_body_size)
 XXX Document.
 
EVENT2_EXPORT_SYMBOL void evhttp_set_max_connections (struct evhttp *http, int max_connections)
 Set the maximum number of simultaneous connections for this server. More...
 
+EVENT2_EXPORT_SYMBOL void evhttp_set_max_headers_size (struct evhttp *http, ev_ssize_t max_headers_size)
 XXX Document.
 
EVENT2_EXPORT_SYMBOL void evhttp_set_newreqcb (struct evhttp *http, int(*cb)(struct evhttp_request *, void *), void *arg)
 Set a callback which allows the user to note or throttle incoming requests. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_set_read_timeout_tv (struct evhttp *http, const struct timeval *tv)
 Set read timeout for an HTTP request. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_set_timeout (struct evhttp *http, int timeout)
 Set the timeout for an HTTP request. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_set_timeout_tv (struct evhttp *http, const struct timeval *tv)
 Set read and write timeout for an HTTP request. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_set_write_timeout_tv (struct evhttp *http, const struct timeval *tv)
 Set write timeout for an HTTP request. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_uri_free (struct evhttp_uri *uri)
 Free all memory allocated for a parsed uri. More...
 
+const EVENT2_EXPORT_SYMBOL char * evhttp_uri_get_fragment (const struct evhttp_uri *uri)
 Return the fragment part of an evhttp_uri (excluding the leading "#"), or NULL if it has no fragment set.
 
const EVENT2_EXPORT_SYMBOL char * evhttp_uri_get_host (const struct evhttp_uri *uri)
 Return the host part of an evhttp_uri, or NULL if it has no host set. More...
 
+const EVENT2_EXPORT_SYMBOL char * evhttp_uri_get_path (const struct evhttp_uri *uri)
 Return the path part of an evhttp_uri, or NULL if it has no path set.
 
+EVENT2_EXPORT_SYMBOL int evhttp_uri_get_port (const struct evhttp_uri *uri)
 Return the port part of an evhttp_uri, or -1 if there is no port set.
 
+const EVENT2_EXPORT_SYMBOL char * evhttp_uri_get_query (const struct evhttp_uri *uri)
 Return the query part of an evhttp_uri (excluding the leading "?"), or NULL if it has no query set.
 
+const EVENT2_EXPORT_SYMBOL char * evhttp_uri_get_scheme (const struct evhttp_uri *uri)
 Return the scheme of an evhttp_uri, or NULL if there is no scheme has been set and the evhttp_uri contains a Relative-Ref.
 
+const EVENT2_EXPORT_SYMBOL char * evhttp_uri_get_unixsocket (const struct evhttp_uri *uri)
 Return the unix socket part of an evhttp_uri, or NULL if there is no unix socket set.
 
+const EVENT2_EXPORT_SYMBOL char * evhttp_uri_get_userinfo (const struct evhttp_uri *uri)
 Return the userinfo part of an evhttp_uri, or NULL if it has no userinfo set.
 
EVENT2_EXPORT_SYMBOL char * evhttp_uri_join (const struct evhttp_uri *uri, char *buf, size_t limit)
 Join together the uri parts from parsed data to form a URI-Reference. More...
 
+EVENT2_EXPORT_SYMBOL struct evhttp_uri * evhttp_uri_new (void)
 Return a new empty evhttp_uri with no fields set.
 
+EVENT2_EXPORT_SYMBOL struct evhttp_uri * evhttp_uri_parse (const char *source_uri)
 Alias for evhttp_uri_parse_with_flags(source_uri, 0)
 
EVENT2_EXPORT_SYMBOL struct evhttp_uri * evhttp_uri_parse_with_flags (const char *source_uri, unsigned flags)
 Helper function to parse a URI-Reference as specified by RFC3986. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_uri_set_flags (struct evhttp_uri *uri, unsigned flags)
 Changes the flags set on a given URI. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_fragment (struct evhttp_uri *uri, const char *fragment)
 Set the fragment of an evhttp_uri, or clear the fragment if fragment==NULL. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_host (struct evhttp_uri *uri, const char *host)
 Set the host of an evhttp_uri, or clear the host if host==NULL. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_path (struct evhttp_uri *uri, const char *path)
 Set the path of an evhttp_uri, or clear the path if path==NULL. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_port (struct evhttp_uri *uri, int port)
 Set the port of an evhttp_uri, or clear the port if port==-1. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_query (struct evhttp_uri *uri, const char *query)
 Set the query of an evhttp_uri, or clear the query if query==NULL. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_scheme (struct evhttp_uri *uri, const char *scheme)
 Set the scheme of an evhttp_uri, or clear the scheme if scheme==NULL. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_unixsocket (struct evhttp_uri *uri, const char *unixsocket)
 Set the unix socket of an evhttp_uri, or clear the unix socket if unixsocket==NULL. More...
 
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_userinfo (struct evhttp_uri *uri, const char *userinfo)
 Set the userinfo of an evhttp_uri, or clear the userinfo if userinfo==NULL. More...
 
EVENT2_EXPORT_SYMBOL char * evhttp_uridecode (const char *uri, int decode_plus, size_t *size_out)
 Helper function to decode a URI-escaped string or HTTP parameter. More...
 
EVENT2_EXPORT_SYMBOL char * evhttp_uriencode (const char *str, ev_ssize_t size, int space_to_plus)
 As evhttp_encode_uri, but if 'size' is nonnegative, treat the string as being 'size' bytes long. More...
 
+

Detailed Description

+

Basic support for HTTP serving.

+

As Libevent is a library for dealing with event notification and most interesting applications are networked today, I have often found the need to write HTTP code. The following prototypes and definitions provide an application with a minimal interface for making HTTP requests and for creating a very simple HTTP server.

+

Macro Definition Documentation

+ +

◆ EVHTTP_URI_HOST_STRIP_BRACKETS

+ +
+
+ + + + +
#define EVHTTP_URI_HOST_STRIP_BRACKETS   0x04
+
+ +

Strip brackets from the IPv6 address and only for evhttp_uri_get_host(), evhttp_uri_join() returns the host with brackets.

+

Thus you can use host part of the evhttp_uri for getaddrinfo().

+
See also
also _EVHTTP_URI_HOST_HAS_BRACKETS
+ +
+
+ +

◆ EVHTTP_URI_NONCONFORMANT

+ +
+
+ + + + +
#define EVHTTP_URI_NONCONFORMANT   0x01
+
+ +

Tolerate URIs that do not conform to RFC3986.

+

Unfortunately, some HTTP clients generate URIs that, according to RFC3986, are not conformant URIs. If you need to support these URIs, you can do so by passing this flag to evhttp_uri_parse_with_flags.

+

Currently, these changes are:

    +
  • +Nonconformant URIs are allowed to contain otherwise unreasonable characters in their path, query, and fragment components.
  • +
+ +
+
+ +

◆ EVHTTP_URI_QUERY_LAST_VAL

+ +
+
+ + + + +
#define EVHTTP_URI_QUERY_LAST_VAL   0x02
+
+ +

Prefer last value over the first from query args.

+

Example: test=123&test=456 Without: test=123 With : test=456

+ +
+
+ +

◆ EVHTTP_URI_QUERY_NONCONFORMANT

+ +
+
+ + + + +
#define EVHTTP_URI_QUERY_NONCONFORMANT   0x01
+
+ +

Tolerate queries that are not standard conformant.

+

Here are some examples:

+
    +
  • test=123&test2 with with this flag test2 will be present in the output headers
  • +
  • test=123&&test2=1 will parse the query with this flag
  • +
  • test=123&=456&test2=1 will parse the queyr with this flag, however there won't be empty key present
  • +
+ +
+
+ +

◆ EVHTTP_URI_UNIX_SOCKET

+ +
+
+ + + + +
#define EVHTTP_URI_UNIX_SOCKET   0x08
+
+ +

Parse unix domain socket URIs, for example:

+

http://unix:/run/control.sock:/controller

+ +
+
+

Enumeration Type Documentation

+ +

◆ evhttp_cmd_type

+ +
+
+ + + + +
enum evhttp_cmd_type
+
+ +

The different request types supported by evhttp.

+

These are as specified in RFC2616, except for:

    +
  • PATCH which is specified by RFC5789
  • +
  • PROPFIND, PROPPATCH, MKCOL, LOCK, UNLOCK, COPY, MOVE which are specified by RFC4918
  • +
+

By default, only some of these methods are accepted and passed to user callbacks; use evhttp_set_allowed_methods() to change which methods are allowed.

+ +
+
+ +

◆ evhttp_request_error

+ +
+
+ + + + +
enum evhttp_request_error
+
+ +

The different error types supported by evhttp.

+
See also
evhttp_request_set_error_cb()
+ + + + + + + +
Enumerator
EVREQ_HTTP_TIMEOUT 

Timeout reached, also.

+
See also
evhttp_connection_set_timeout()
+
EVREQ_HTTP_EOF 

EOF reached.

+
EVREQ_HTTP_INVALID_HEADER 

Error while reading header, or invalid header.

+
EVREQ_HTTP_BUFFER_ERROR 

Error encountered while reading or writing.

+
EVREQ_HTTP_REQUEST_CANCEL 

The evhttp_cancel_request() called on this request.

+
EVREQ_HTTP_DATA_TOO_LONG 

Body is greater then evhttp_connection_set_max_body_size()

+
+ +
+
+

Function Documentation

+ +

◆ evhttp_accept_socket()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_accept_socket (struct evhttp * http,
evutil_socket_t fd 
)
+
+ +

Makes an HTTP server accept connections on the specified socket.

+

This may be useful to create a socket and then fork multiple instances of an http server, or when a socket has been communicated via file descriptor passing in situations where an http servers does not have permissions to bind to a low-numbered port.

+

Can be called multiple times to have the http server listen to multiple different sockets.

+
Parameters
+ + + +
httpa pointer to an evhttp object
fda socket fd that is ready for accepting connections
+
+
+
Returns
0 on success, -1 on failure.
+
See also
evhttp_bind_socket()
+ +
+
+ +

◆ evhttp_accept_socket_with_handle()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evhttp_bound_socket* evhttp_accept_socket_with_handle (struct evhttp * http,
evutil_socket_t fd 
)
+
+ +

Like evhttp_accept_socket(), but returns a handle for referencing the socket.

+

The returned pointer is not valid after http is freed.

+
Parameters
+ + + +
httpa pointer to an evhttp object
fda socket fd that is ready for accepting connections
+
+
+
Returns
Handle for the socket on success, NULL on failure.
+
See also
evhttp_accept_socket(), evhttp_del_accept_socket()
+ +
+
+ +

◆ evhttp_add_header()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_add_header (struct evkeyvalq * headers,
const char * key,
const char * value 
)
+
+ +

Adds a header to a list of existing headers.

+
Parameters
+ + + + +
headersthe evkeyvalq object to which to add a header. headers must not be NULL.
keythe name of the header
valuethe value belonging to the header
+
+
+
Returns
0 on success, -1 otherwise.
+
See also
evhttp_find_header(), evhttp_clear_headers()
+ +
+
+ +

◆ evhttp_add_server_alias()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_add_server_alias (struct evhttp * http,
const char * alias 
)
+
+ +

Add a server alias to an http object.

+

The http object can be a virtual host or the main server.

+
Parameters
+ + + +
httpthe evhttp object
aliasthe alias to add
+
+
+
See also
evhttp_add_remove_alias()
+ +
+
+ +

◆ evhttp_add_virtual_host()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_add_virtual_host (struct evhttp * http,
const char * pattern,
struct evhttp * vhost 
)
+
+ +

Adds a virtual host to the http server.

+

A virtual host is a newly initialized evhttp object that has request callbacks set on it via evhttp_set_cb() or evhttp_set_gencb(). It most not have any listing sockets associated with it.

+

If the virtual host has not been removed by the time that evhttp_free() is called on the main http server, it will be automatically freed, too.

+

It is possible to have hierarchical vhosts. For example: A vhost with the pattern *.example.com may have other vhosts with patterns foo.example.com and bar.example.com associated with it.

+
Parameters
+ + + + +
httpthe evhttp object to which to add a virtual host
patternthe glob pattern against which the hostname is matched. The match is case insensitive and follows otherwise regular shell matching.
vhostthe virtual host to add the regular http server.
+
+
+
Returns
0 on success, -1 on failure
+
See also
evhttp_remove_virtual_host()
+ +
+
+ +

◆ evhttp_bind_listener()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evhttp_bound_socket* evhttp_bind_listener (struct evhttp * http,
struct evconnlistener * listener 
)
+
+ +

The most low-level evhttp_bind/accept method: takes an evconnlistener, and returns an evhttp_bound_socket.

+

The listener will be freed when the bound socket is freed.

+ +
+
+ +

◆ evhttp_bind_socket()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_bind_socket (struct evhttp * http,
const char * address,
ev_uint16_t port 
)
+
+ +

Binds an HTTP server on the specified address and port.

+

Can be called multiple times to bind the same http server to multiple different ports.

+
Parameters
+ + + + +
httpa pointer to an evhttp object
addressa string containing the IP address to listen(2) on
portthe port number to listen on
+
+
+
Returns
0 on success, -1 on failure.
+
See also
evhttp_accept_socket()
+ +
+
+ +

◆ evhttp_bind_socket_with_handle()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evhttp_bound_socket* evhttp_bind_socket_with_handle (struct evhttp * http,
const char * address,
ev_uint16_t port 
)
+
+ +

Like evhttp_bind_socket(), but returns a handle for referencing the socket.

+

The returned pointer is not valid after http is freed.

+
Parameters
+ + + + +
httpa pointer to an evhttp object
addressa string containing the IP address to listen(2) on
portthe port number to listen on
+
+
+
Returns
Handle for the socket on success, NULL on failure.
+
See also
evhttp_bind_socket(), evhttp_del_accept_socket()
+ +
+
+ +

◆ evhttp_bound_socket_get_fd()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL evutil_socket_t evhttp_bound_socket_get_fd (struct evhttp_bound_socket * bound_socket)
+
+ +

Get the raw file descriptor referenced by an evhttp_bound_socket.

+
Parameters
+ + +
bound_socketa handle returned by evhttp_{bind,accept}_socket_with_handle
+
+
+
Returns
the file descriptor used by the bound socket
+
See also
evhttp_bind_socket_with_handle(), evhttp_accept_socket_with_handle()
+ +
+
+ +

◆ evhttp_cancel_request()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_cancel_request (struct evhttp_request * req)
+
+ +

Cancels a pending HTTP request.

+

Cancels an ongoing HTTP request. The callback associated with this request is not executed and the request object is freed. If the request is currently being processed, e.g. it is ongoing, the corresponding evhttp_connection object is going to get reset.

+

A request cannot be canceled if its callback has executed already. A request may be canceled reentrantly from its chunked callback.

+
Parameters
+ + +
reqthe evhttp_request to cancel; req becomes invalid after this call.
+
+
+ +
+
+ +

◆ evhttp_clear_headers()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_clear_headers (struct evkeyvalq * headers)
+
+ +

Removes all headers from the header list.

+
Parameters
+ + +
headersthe evkeyvalq object from which to remove all headers
+
+
+ +
+
+ +

◆ evhttp_connection_base_bufferevent_new()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evhttp_connection* evhttp_connection_base_bufferevent_new (struct event_basebase,
struct evdns_base * dnsbase,
struct buffereventbev,
const char * address,
ev_uint16_t port 
)
+
+ +

Create and return a connection object that can be used to for making HTTP requests.

+

The connection object tries to resolve address and establish the connection when it is given an http request object.

+

Connection also has default timeouts for the following events:

    +
  • connect HTTP_CONNECT_TIMEOUT, which is 45 seconds
  • +
  • read HTTP_READ_TIMEOUT which is 50 seconds
  • +
  • write HTTP_WRITE_TIMEOUT, which is 50 seconds
  • +
+
Parameters
+ + + + + + +
basethe event_base to use for handling the connection
dnsbasethe dns_base to use for resolving host names; if not specified host name resolution will block.
beva bufferevent to use for connecting to the server; if NULL, a socket-based bufferevent will be created. This bufferevent will be freed when the connection closes. It must have no fd set on it.
addressthe address to which to connect
portthe port to connect to
+
+
+
Returns
an evhttp_connection object that can be used for making requests or NULL on error
+ +
+
+ +

◆ evhttp_connection_base_bufferevent_unix_new()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evhttp_connection* evhttp_connection_base_bufferevent_unix_new (struct event_basebase,
struct buffereventbev,
const char * path 
)
+
+ +

Create and return a connection object that can be used to for making HTTP requests over an unix domain socket.

+
Parameters
+ + + + +
basethe event_base to use for handling the connection
beva bufferevent to use for connecting to the server; if NULL, a socket-based bufferevent will be created. This bufferevent will be freed when the connection closes. It must have no fd set on it.
pathpath of unix domain socket
+
+
+
Returns
an evhttp_connection object that can be used for making requests
+ +
+
+ +

◆ evhttp_connection_base_new()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evhttp_connection* evhttp_connection_base_new (struct event_basebase,
struct evdns_base * dnsbase,
const char * address,
ev_uint16_t port 
)
+
+ +

Create and return a connection object that can be used to for making HTTP requests.

+

The connection object tries to resolve address and establish the connection when it is given an http request object.

+
Parameters
+ + + + + +
basethe event_base to use for handling the connection
dnsbasethe dns_base to use for resolving host names; if not specified host name resolution will block.
addressthe address to which to connect
portthe port to connect to
+
+
+
Returns
an evhttp_connection object that can be used for making requests or NULL on error
+ +
+
+ +

◆ evhttp_connection_free_on_completion()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_connection_free_on_completion (struct evhttp_connection * evcon)
+
+ +

Disowns a given connection object.

+

Can be used to tell libevent to free the connection object after the last request has completed or failed.

+ +
+
+ +

◆ evhttp_connection_get_addr()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL const struct sockaddr* evhttp_connection_get_addr (struct evhttp_connection * evcon)
+
+ +

Get the remote address associated with this connection.

+

extracted from getpeername() OR from nameserver.

+
Returns
NULL if getpeername() return non success, or connection is not connected, otherwise it return pointer to struct sockaddr_storage
+ +
+
+ +

◆ evhttp_connection_set_connect_timeout_tv()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_connect_timeout_tv (struct evhttp_connection * evcon,
const struct timeval * tv 
)
+
+ +

Sets the connect timeout for this connection.

+
Parameters
+ + +
tvthe timeout, or NULL
+
+
+ +
+
+ +

◆ evhttp_connection_set_ext_method_cmp()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_ext_method_cmp (struct evhttp_connection * evcon,
evhttp_ext_method_cb cmp 
)
+
+ +

Sets extended method cmp callback for this http connection.

+
See also
evhttp_set_ext_method_cmp
+ +
+
+ +

◆ evhttp_connection_set_flags()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_connection_set_flags (struct evhttp_connection * evcon,
int flags 
)
+
+ +

Set connection flags.

+
See also
EVHTTP_CON_*
+
Returns
0 on success, otherwise non zero (for example if flag doesn't supported).
+ +
+
+ +

◆ evhttp_connection_set_initial_retry_tv()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_initial_retry_tv (struct evhttp_connection * evcon,
const struct timeval * tv 
)
+
+ +

Sets the delay before retrying requests on this connection.

+

This is only used if evhttp_connection_set_retries is used to make the number of retries at least one. Each retry after the first is twice as long as the one before it.

+

Default delay is HTTP_INITIAL_RETRY_TIMEOUT, which is 2 seconds.

+ +
+
+ +

◆ evhttp_connection_set_local_address()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_local_address (struct evhttp_connection * evcon,
const char * address 
)
+
+ +

Sets the IP address from which http connections are made.

+

Note this resets internal bufferevent fd, so any options that had been installed will be flushed.

+ +
+
+ +

◆ evhttp_connection_set_read_timeout_tv()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_read_timeout_tv (struct evhttp_connection * evcon,
const struct timeval * tv 
)
+
+ +

Sets the read timeout for this connection.

+
Parameters
+ + +
tvthe timeout, or NULL
+
+
+ +
+
+ +

◆ evhttp_connection_set_timeout()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_timeout (struct evhttp_connection * evcon,
int timeout 
)
+
+ +

Sets the timeout for this connection.

+

evcon must not be NULL.

+
See also
evhttp_connection_set_timeout_tv()
+ +
+
+ +

◆ evhttp_connection_set_timeout_tv()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_timeout_tv (struct evhttp_connection * evcon,
const struct timeval * tv 
)
+
+ +

Sets the timeout for this connection for the following events:

+
    +
  • read, if tv==NULL then it uses default timeout (HTTP_READ_TIMEOUT)
  • +
  • write, if tv==NULL then it uses default timeout (HTTP_WRITE_TIMEOUT)
  • +
+

But it does not adjust timeout for the "connect" (for historical reasons).

+
Parameters
+ + +
tvthe timeout, or NULL
+
+
+

For more precise control:

See also
evhttp_connection_set_connect_timeout_tv()
+
+evhttp_connection_set_read_timeout_tv()
+
+evhttp_connection_set_write_timeout_tv()
+ +
+
+ +

◆ evhttp_connection_set_write_timeout_tv()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_write_timeout_tv (struct evhttp_connection * evcon,
const struct timeval * tv 
)
+
+ +

Sets the write timeout for this connection.

+
Parameters
+ + +
tvthe timeout, or NULL
+
+
+ +
+
+ +

◆ evhttp_decode_uri()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL char* evhttp_decode_uri (const char * uri)
+
+ +

Helper function to sort of decode a URI-encoded string.

+

Unlike evhttp_uridecode, it decodes all plus characters that appear after the first question mark character, but no plusses that occur before. This is not a good way to decode URIs in whole or in part.

+

The returned string must be freed by the caller

+
Deprecated:
This function is deprecated; you probably want to use evhttp_uridecode instead.
+
Parameters
+ + +
urian encoded URI
+
+
+
Returns
a newly allocated unencoded URI or NULL on failure
+ +
+
+ +

◆ evhttp_del_accept_socket()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_del_accept_socket (struct evhttp * http,
struct evhttp_bound_socket * bound_socket 
)
+
+ +

Makes an HTTP server stop accepting connections on the specified socket.

+

This may be useful when a socket has been sent via file descriptor passing and is no longer needed by the current process.

+

If you created this bound socket with evhttp_bind_socket_with_handle or evhttp_accept_socket_with_handle, this function closes the fd you provided. If you created this bound socket with evhttp_bind_listener, this function frees the listener you provided.

+

bound_socket is an invalid pointer after this call returns.

+
Parameters
+ + + +
httpa pointer to an evhttp object
bound_socketa handle returned by evhttp_{bind,accept}_socket_with_handle
+
+
+
See also
evhttp_bind_socket_with_handle(), evhttp_accept_socket_with_handle()
+ +
+
+ +

◆ evhttp_encode_uri()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL char* evhttp_encode_uri (const char * str)
+
+ +

Helper function to encode a string for inclusion in a URI.

+

All characters are replaced by their hex-escaped (%22) equivalents, except for characters explicitly unreserved by RFC3986 – that is, ASCII alphanumeric characters, hyphen, dot, underscore, and tilde.

+

The returned string must be freed by the caller.

+
Parameters
+ + +
stran unencoded string
+
+
+
Returns
a newly allocated URI-encoded string or NULL on failure
+ +
+
+ +

◆ evhttp_find_header()

+ +
+
+ + + + + + + + + + + + + + + + + + +
const EVENT2_EXPORT_SYMBOL char* evhttp_find_header (const struct evkeyvalq * headers,
const char * key 
)
+
+ +

Finds the value belonging to a header.

+
Parameters
+ + + +
headersthe evkeyvalq object in which to find the header
keythe name of the header to find
+
+
+
Returns
a pointer to the value for the header or NULL if the header could not be found.
+
See also
evhttp_add_header(), evhttp_remove_header()
+ +
+
+ +

◆ evhttp_foreach_bound_socket()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_foreach_bound_socket (struct evhttp * http,
evhttp_bound_socket_foreach_fn * function,
void * argument 
)
+
+ +

Applies the function specified in the first argument to all evhttp_bound_sockets associated with "http".

+

The user must not attempt to free or remove any connections, sockets or listeners in the callback "function".

+
Parameters
+ + + + +
httppointer to an evhttp object
functionfunction to apply to every bound socket
argumentpointer value passed to function for every socket iterated
+
+
+ +
+
+ +

◆ evhttp_free()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_free (struct evhttp * http)
+
+ +

Free the previously created HTTP server.

+

Works only if no requests are currently being served.

+
Parameters
+ + +
httpthe evhttp server object to be freed. http must not be NULL.
+
+
+
See also
evhttp_start()
+ +
+
+ +

◆ evhttp_get_connection_count()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_get_connection_count (struct evhttp * http)
+
+ +

Get the current number of connections.

+
Returns
The current number of connections for this server.
+ +
+
+ +

◆ evhttp_htmlescape()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL char* evhttp_htmlescape (const char * html)
+
+ +

Escape HTML character entities in a string.

+

Replaces <, >, ", ' and & with <, >, ", &#039; and & correspondingly.

+

The returned string needs to be freed by the caller.

+
Parameters
+ + +
htmlan unescaped HTML string
+
+
+
Returns
an escaped HTML string or NULL on error
+ +
+
+ +

◆ evhttp_make_request()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_make_request (struct evhttp_connection * evcon,
struct evhttp_request * req,
enum evhttp_cmd_type type,
const char * uri 
)
+
+ +

Make an HTTP request over the specified connection.

+

The connection gets ownership of the request. On failure, the request object is no longer valid as it has been freed.

+
Parameters
+ + + + + +
evconthe evhttp_connection object over which to send the request
reqthe previously created and configured request object
typethe request type EVHTTP_REQ_GET, EVHTTP_REQ_POST, etc.
urithe URI associated with the request
+
+
+
Returns
0 on success, -1 on failure
+
See also
evhttp_cancel_request()
+ +
+
+ +

◆ evhttp_new()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evhttp* evhttp_new (struct event_basebase)
+
+ +

Create a new HTTP server.

+
Parameters
+ + +
base(optional) the event base to receive the HTTP events
+
+
+
Returns
a pointer to a newly initialized evhttp server structure or NULL on error
+
See also
evhttp_free()
+ +
+
+ +

◆ evhttp_parse_query()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_parse_query (const char * uri,
struct evkeyvalq * headers 
)
+
+ +

Helper function to parse out arguments in a query.

+

Parsing a URI like

+

http://foo.com/?q=test&s=some+thing

+

will result in two entries in the key value queue.

+

The first entry is: key="q", value="test" The second entry is: key="s", value="some thing"

+
Deprecated:
This function is deprecated as of Libevent 2.0.9. Use evhttp_uri_parse and evhttp_parse_query_str instead.
+
Parameters
+ + + +
urithe request URI
headersthe head of the evkeyval queue
+
+
+
Returns
0 on success, -1 on failure
+ +
+
+ +

◆ evhttp_parse_query_str()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_parse_query_str (const char * uri,
struct evkeyvalq * headers 
)
+
+
+ +

◆ evhttp_parse_query_str_flags()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_parse_query_str_flags (const char * uri,
struct evkeyvalq * headers,
unsigned flags 
)
+
+ +

Helper function to parse out arguments from the query portion of an HTTP URI.

+

Parsing a query string like

+

q=test&s=some+thing

+

will result in two entries in the key value queue.

+

The first entry is: key="q", value="test" The second entry is: key="s", value="some thing"

+
Parameters
+ + + + +
urithe query portion of the URI
headersthe head of the evkeyval queue
flagsone or more of EVHTTP_URI_QUERY_*
+
+
+
Returns
0 on success, -1 on failure
+ +
+
+ +

◆ evhttp_remove_header()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_remove_header (struct evkeyvalq * headers,
const char * key 
)
+
+ +

Removes a header from a list of existing headers.

+
Parameters
+ + + +
headersthe evkeyvalq object from which to remove a header
keythe name of the header to remove
+
+
+
Returns
0 if the header was removed, -1 otherwise.
+
See also
evhttp_find_header(), evhttp_add_header()
+ +
+
+ +

◆ evhttp_remove_server_alias()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_remove_server_alias (struct evhttp * http,
const char * alias 
)
+
+ +

Remove a server alias from an http object.

+
Parameters
+ + + +
httpthe evhttp object
aliasthe alias to remove
+
+
+
See also
evhttp_add_server_alias()
+ +
+
+ +

◆ evhttp_remove_virtual_host()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_remove_virtual_host (struct evhttp * http,
struct evhttp * vhost 
)
+
+ +

Removes a virtual host from the http server.

+
Parameters
+ + + +
httpthe evhttp object from which to remove the virtual host
vhostthe virtual host to remove from the regular http server.
+
+
+
Returns
0 on success, -1 on failure
+
See also
evhttp_add_virtual_host()
+ +
+
+ +

◆ evhttp_request_get_connection()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evhttp_connection* evhttp_request_get_connection (struct evhttp_request * req)
+
+ +

Returns the connection object associated with the request or NULL.

+

req must not be NULL.

+

The user needs to either free the request explicitly or call evhttp_send_reply_end().

+ +
+
+ +

◆ evhttp_request_get_host()

+ +
+
+ + + + + + + + +
const EVENT2_EXPORT_SYMBOL char* evhttp_request_get_host (struct evhttp_request * req)
+
+ +

Returns the host associated with the request.

+

If a client sends an absolute URI, the host part of that is preferred. Otherwise, the input headers are searched for a Host: header. NULL is returned if no absolute URI or Host: header is provided.

+ +
+
+ +

◆ evhttp_request_new()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evhttp_request* evhttp_request_new (void(*)(struct evhttp_request *, void *) cb,
void * arg 
)
+
+ +

Creates a new request object that needs to be filled in with the request parameters.

+

The callback is executed when the request completed or an error occurred.

+ +
+
+ +

◆ evhttp_request_own()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_request_own (struct evhttp_request * req)
+
+ +

Takes ownership of the request object.

+

Can be used in a request callback to keep onto the request until evhttp_request_free() is explicitly called by the user.

+ +
+
+ +

◆ evhttp_request_set_chunked_cb()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_request_set_chunked_cb (struct evhttp_request * ,
void(*)(struct evhttp_request *, void *) cb 
)
+
+ +

Enable delivery of chunks to requestor.

+
Parameters
+ + +
cbwill be called after every read of data with the same argument as the completion callback. Will never be called on an empty response. May drain the input buffer; it will be drained automatically on return.
+
+
+ +
+
+ +

◆ evhttp_request_set_error_cb()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_request_set_error_cb (struct evhttp_request * ,
void(*)(enum evhttp_request_error, void *)  
)
+
+ +

Set a callback for errors.

+
See also
evhttp_request_error for error types.
+

On error, both the error callback and the regular callback will be called, error callback is called before the regular callback.

+ +
+
+ +

◆ evhttp_request_set_header_cb()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_request_set_header_cb (struct evhttp_request * ,
int(*)(struct evhttp_request *, void *) cb 
)
+
+ +

Register callback for additional parsing of request headers.

+
Parameters
+ + +
cbwill be called after receiving and parsing the full header. It allows analyzing the header and possibly closing the connection by returning a value < 0.
+
+
+ +
+
+ +

◆ evhttp_request_set_on_complete_cb()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_request_set_on_complete_cb (struct evhttp_request * req,
void(*)(struct evhttp_request *, void *) cb,
void * cb_arg 
)
+
+ +

Set a callback to be called on request completion of evhttp_send_* function.

+

The callback function will be called on the completion of the request after the output data has been written and before the evhttp_request object is destroyed. This can be useful for tracking resources associated with a request (ex: timing metrics).

+
Parameters
+ + + + +
reqa request object
cbcallback function that will be called on request completion
cb_argan additional context argument for the callback
+
+
+ +
+
+ +

◆ evhttp_send_error()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_send_error (struct evhttp_request * req,
int error,
const char * reason 
)
+
+ +

Send an HTML error message to the client.

+
Parameters
+ + + + +
reqa request object
errorthe HTTP error code
reasona brief explanation of the error. If this is NULL, we'll just use the standard meaning of the error code.
+
+
+ +
+
+ +

◆ evhttp_send_reply()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_send_reply (struct evhttp_request * req,
int code,
const char * reason,
struct evbufferdatabuf 
)
+
+ +

Send an HTML reply to the client.

+

The body of the reply consists of the data in databuf. After calling evhttp_send_reply() databuf will be empty, but the buffer is still owned by the caller and needs to be deallocated by the caller if necessary.

+
Parameters
+ + + + + +
reqa request object
codethe HTTP response code to send
reasona brief message to send with the response code
databufthe body of the response
+
+
+ +
+
+ +

◆ evhttp_send_reply_chunk()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_send_reply_chunk (struct evhttp_request * req,
struct evbufferdatabuf 
)
+
+ +

Send another data chunk as part of an ongoing chunked reply.

+

The reply chunk consists of the data in databuf. After calling evhttp_send_reply_chunk() databuf will be empty, but the buffer is still owned by the caller and needs to be deallocated by the caller if necessary.

+
Parameters
+ + + +
reqa request object
databufthe data chunk to send as part of the reply.
+
+
+ +
+
+ +

◆ evhttp_send_reply_chunk_with_cb()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_send_reply_chunk_with_cb (struct evhttp_request * req,
struct evbufferdatabuf,
void(*)(struct evhttp_connection *, void *) cb,
void * arg 
)
+
+ +

Send another data chunk as part of an ongoing chunked reply.

+

The reply chunk consists of the data in databuf. After calling evhttp_send_reply_chunk() databuf will be empty, but the buffer is still owned by the caller and needs to be deallocated by the caller if necessary.

+
Parameters
+ + + + + +
reqa request object
databufthe data chunk to send as part of the reply.
cbcallback funcion
argcall back's argument.
+
+
+ +
+
+ +

◆ evhttp_send_reply_end()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_send_reply_end (struct evhttp_request * req)
+
+ +

Complete a chunked reply, freeing the request as appropriate.

+
Parameters
+ + +
reqa request object
+
+
+ +
+
+ +

◆ evhttp_send_reply_start()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_send_reply_start (struct evhttp_request * req,
int code,
const char * reason 
)
+
+ +

Initiate a reply that uses Transfer-Encoding chunked.

+

This allows the caller to stream the reply back to the client and is useful when either not all of the reply data is immediately available or when sending very large replies.

+

The caller needs to supply data chunks with evhttp_send_reply_chunk() and complete the reply by calling evhttp_send_reply_end().

+
Parameters
+ + + + +
reqa request object
codethe HTTP response code to send
reasona brief message to send with the response code
+
+
+ +
+
+ +

◆ evhttp_set_allowed_methods()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_set_allowed_methods (struct evhttp * http,
ev_uint32_t methods 
)
+
+ +

Sets the what HTTP methods are supported in requests accepted by this server, and passed to user callbacks.

+

If not supported they will generate a "405 Method not allowed" response.

+

By default this includes the following methods: GET, POST, HEAD, PUT, DELETE

+
Parameters
+ + + +
httpthe http server on which to set the methods
methodsbit mask constructed from evhttp_cmd_type values
+
+
+ +
+
+ +

◆ evhttp_set_bevcb()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_set_bevcb (struct evhttp * http,
struct bufferevent *(*)(struct event_base *, void *) cb,
void * arg 
)
+
+ +

Set a callback used to create new bufferevents for connections to a given evhttp object.

+

cb is not called if a non-NULL bufferevent was supplied by evhttp_bound_set_bevcb.

+

You can use this to override the default bufferevent type – for example, to make this evhttp object use SSL bufferevents rather than unencrypted ones.

+

New bufferevents must be allocated with no fd set on them.

+
Parameters
+ + + + +
httpthe evhttp server object for which to set the callback
cbthe callback to invoke for incoming connections
argan additional context argument for the callback
+
+
+ +
+
+ +

◆ evhttp_set_cb()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_set_cb (struct evhttp * http,
const char * path,
void(*)(struct evhttp_request *, void *) cb,
void * cb_arg 
)
+
+ +

Set a callback for a specified URI.

+
Parameters
+ + + + + +
httpthe http sever on which to set the callback
paththe path for which to invoke the callback
cbthe callback function that gets invoked on requesting path
cb_argan additional context argument for the callback
+
+
+
Returns
0 on success, -1 if the callback existed already, -2 on failure
+ +
+
+ +

◆ evhttp_set_default_content_type()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_set_default_content_type (struct evhttp * http,
const char * content_type 
)
+
+ +

Set the value to use for the Content-Type header when none was provided.

+

If the content type string is NULL, the Content-Type header will not be automatically added.

+
Parameters
+ + + +
httpthe http server on which to set the default content type
content_typethe value for the Content-Type header
+
+
+ +
+
+ +

◆ evhttp_set_errorcb()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_set_errorcb (struct evhttp * http,
int(*)(struct evhttp_request *req, struct evbuffer *buffer, int error, const char *reason, void *cbarg) cb,
void * cbarg 
)
+
+ +

Set a callback to output for any error pages sent for requests of a given evhttp object.

+

You can use this to override the default error pages sent, allowing such things as multi-lingual support or customization to match other pages.

+

The callback should use the supplied buffer to output the text for an error page. If the callback returns a negative value or doesn't output anything to the buffer, the default error page will be sent instead. The buffer will be automatically be sent when the callback returns, so the callback shouldn't do so itself.

+

Microsoft Internet Explorer may display its own error pages if ones sent by an HTTP server are smaller than certain sizes, depending on the status code. To reliably suppress this feature an error page should be at least 512 bytes in size.

+
Parameters
+ + + + +
httpthe evhttp server object for which to set the callback
cbthe callback to invoke to format error pages
argan additional context argument for the callback
+
+
+ +
+
+ +

◆ evhttp_set_ext_method_cmp()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_set_ext_method_cmp (struct evhttp * http,
evhttp_ext_method_cb cmp 
)
+
+ +

Sets the callback function which allows HTTP extended methods to be supported by this server.

+

The callback should :

    +
  • if method field is NULL : set method field according to type field
  • +
  • else : set type and flags fields according to method string
  • +
  • return 0 for success (known method / type)
  • +
  • return -1 for error (unknown method / type)
  • +
+

evhttp_set_allowed_methods still needs to be called.

+
Parameters
+ + + +
httpthe http server on which to add support to the methods
cmpthe extended method callback
+
+
+
See also
evhttp_ext_method
+ +
+
+ +

◆ evhttp_set_flags()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_set_flags (struct evhttp * http,
int flags 
)
+
+ +

Set connection flags for HTTP server.

+
See also
EVHTTP_SERVER_*
+
Returns
0 on success, otherwise non zero (for example if flag doesn't supported).
+ +
+
+ +

◆ evhttp_set_gencb()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_set_gencb (struct evhttp * http,
void(*)(struct evhttp_request *, void *) cb,
void * arg 
)
+
+ +

Set a callback for all requests that are not caught by specific callbacks.

+

Invokes the specified callback for all requests that do not match any of the previously specified request paths. This is catchall for requests not specifically configured with evhttp_set_cb().

+
Parameters
+ + + + +
httpthe evhttp server object for which to set the callback
cbthe callback to invoke for any unmatched requests
argan additional context argument for the callback
+
+
+ +
+
+ +

◆ evhttp_set_max_connections()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_set_max_connections (struct evhttp * http,
int max_connections 
)
+
+ +

Set the maximum number of simultaneous connections for this server.

+

A value of zero or less disables the limit.

+
Parameters
+ + + +
httpthe http server on which to set the max connection limit
max_connectionsthe maximum number of simultaneous connections or 0
+
+
+ +
+
+ +

◆ evhttp_set_newreqcb()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_set_newreqcb (struct evhttp * http,
int(*)(struct evhttp_request *, void *) cb,
void * arg 
)
+
+ +

Set a callback which allows the user to note or throttle incoming requests.

+

The requests are not populated with HTTP level information. They are just associated to a connection.

+

If the callback returns -1, the associated connection is terminated and the request is closed.

+
Parameters
+ + + + +
httpthe evhttp server object for which to set the callback
cbthe callback to invoke for incoming connections
argan additional context argument for the callback
+
+
+ +
+
+ +

◆ evhttp_set_read_timeout_tv()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_set_read_timeout_tv (struct evhttp * http,
const struct timeval * tv 
)
+
+ +

Set read timeout for an HTTP request.

+
Parameters
+ + + +
httpan evhttp object
tvthe timeout, or NULL
+
+
+ +
+
+ +

◆ evhttp_set_timeout()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_set_timeout (struct evhttp * http,
int timeout 
)
+
+ +

Set the timeout for an HTTP request.

+
Parameters
+ + + +
httpan evhttp object
timeoutthe timeout, in seconds
+
+
+
See also
evhttp_set_timeout_tv()
+ +
+
+ +

◆ evhttp_set_timeout_tv()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_set_timeout_tv (struct evhttp * http,
const struct timeval * tv 
)
+
+ +

Set read and write timeout for an HTTP request.

+
Parameters
+ + + +
httpan evhttp object
tvthe timeout, or NULL
+
+
+

For more precise control:

See also
evhttp_set_read_timeout_tv()
+
+evhttp_set_write_timeout_tv()
+ +
+
+ +

◆ evhttp_set_write_timeout_tv()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_set_write_timeout_tv (struct evhttp * http,
const struct timeval * tv 
)
+
+ +

Set write timeout for an HTTP request.

+
Parameters
+ + + +
httpan evhttp object
tvthe timeout, or NULL
+
+
+ +
+
+ +

◆ evhttp_uri_free()

+ +
+
+ + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_uri_free (struct evhttp_uri * uri)
+
+ +

Free all memory allocated for a parsed uri.

+

Only use this for URIs generated by evhttp_uri_parse.

+
Parameters
+ + +
uricontainer with parsed data. uri must not be NULL.
+
+
+
See also
evhttp_uri_parse()
+ +
+
+ +

◆ evhttp_uri_get_host()

+ +
+
+ + + + + + + + +
const EVENT2_EXPORT_SYMBOL char* evhttp_uri_get_host (const struct evhttp_uri * uri)
+
+ +

Return the host part of an evhttp_uri, or NULL if it has no host set.

+

The host may either be a regular hostname (conforming to the RFC 3986 "regname" production), or an IPv4 address, or the empty string, or a bracketed IPv6 address, or a bracketed 'IP-Future' address.

+

Note that having a NULL host means that the URI has no authority section, but having an empty-string host means that the URI has an authority section with no host part. For example, "mailto:user@example.com" has a host of NULL, but "file:///etc/motd" has a host of "".

+ +
+
+ +

◆ evhttp_uri_join()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL char* evhttp_uri_join (const struct evhttp_uri * uri,
char * buf,
size_t limit 
)
+
+ +

Join together the uri parts from parsed data to form a URI-Reference.

+

Note that no escaping of reserved characters is done on the members of the evhttp_uri, so the generated string might not be a valid URI unless the members of evhttp_uri are themselves valid.

+
Parameters
+ + + + +
uricontainer with parsed data
bufdestination buffer
limitdestination buffer size
+
+
+
Returns
an joined uri as string or NULL on error
+
See also
evhttp_uri_parse()
+ +
+
+ +

◆ evhttp_uri_parse_with_flags()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evhttp_uri* evhttp_uri_parse_with_flags (const char * source_uri,
unsigned flags 
)
+
+ +

Helper function to parse a URI-Reference as specified by RFC3986.

+

This function matches the URI-Reference production from RFC3986, which includes both URIs like

+

scheme://[[userinfo]@]foo.com[:port]]/[path][?query][#fragment]

+

and relative-refs like

+

[path][?query][#fragment]

+

Any optional elements portions not present in the original URI are left set to NULL in the resulting evhttp_uri. If no port is specified, the port is set to -1.

+

Note that no decoding is performed on percent-escaped characters in the string; if you want to parse them, use evhttp_uridecode or evhttp_parse_query_str as appropriate.

+

Note also that most URI schemes will have additional constraints that this function does not know about, and cannot check. For example, mailto://www.example.com/cgi-bin/fortune.pl is not a reasonable mailto url, http://www.example.com:99999/ is not a reasonable HTTP URL, and ftp:username@example.com is not a reasonable FTP URL. Nevertheless, all of these URLs conform to RFC3986, and this function accepts all of them as valid.

+
Parameters
+ + + +
source_urithe request URI
flagsZero or more EVHTTP_URI_* flags to affect the behavior of the parser.
+
+
+
Returns
uri container to hold parsed data, or NULL if there is error
+
See also
evhttp_uri_free()
+ +
+
+ +

◆ evhttp_uri_set_flags()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_uri_set_flags (struct evhttp_uri * uri,
unsigned flags 
)
+
+ +

Changes the flags set on a given URI.

+

See EVHTTP_URI_* for a list of flags.

+ +
+
+ +

◆ evhttp_uri_set_fragment()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_fragment (struct evhttp_uri * uri,
const char * fragment 
)
+
+ +

Set the fragment of an evhttp_uri, or clear the fragment if fragment==NULL.

+

The fragment should not include a leading "#". Returns 0 on success, -1 if fragment is not well-formed.

+ +
+
+ +

◆ evhttp_uri_set_host()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_host (struct evhttp_uri * uri,
const char * host 
)
+
+ +

Set the host of an evhttp_uri, or clear the host if host==NULL.

+

Returns 0 on success, -1 if host is not well-formed.

+ +
+
+ +

◆ evhttp_uri_set_path()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_path (struct evhttp_uri * uri,
const char * path 
)
+
+ +

Set the path of an evhttp_uri, or clear the path if path==NULL.

+

Returns 0 on success, -1 if path is not well-formed.

+ +
+
+ +

◆ evhttp_uri_set_port()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_port (struct evhttp_uri * uri,
int port 
)
+
+ +

Set the port of an evhttp_uri, or clear the port if port==-1.

+

Returns 0 on success, -1 if port is not well-formed.

+ +
+
+ +

◆ evhttp_uri_set_query()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_query (struct evhttp_uri * uri,
const char * query 
)
+
+ +

Set the query of an evhttp_uri, or clear the query if query==NULL.

+

The query should not include a leading "?". Returns 0 on success, -1 if query is not well-formed.

+ +
+
+ +

◆ evhttp_uri_set_scheme()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_scheme (struct evhttp_uri * uri,
const char * scheme 
)
+
+ +

Set the scheme of an evhttp_uri, or clear the scheme if scheme==NULL.

+

Returns 0 on success, -1 if scheme is not well-formed.

+ +
+
+ +

◆ evhttp_uri_set_unixsocket()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_unixsocket (struct evhttp_uri * uri,
const char * unixsocket 
)
+
+ +

Set the unix socket of an evhttp_uri, or clear the unix socket if unixsocket==NULL.

+

Returns 0 on success, -1 if unixsocket is not well-formed

+ +
+
+ +

◆ evhttp_uri_set_userinfo()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_userinfo (struct evhttp_uri * uri,
const char * userinfo 
)
+
+ +

Set the userinfo of an evhttp_uri, or clear the userinfo if userinfo==NULL.

+

Returns 0 on success, -1 if userinfo is not well-formed.

+ +
+
+ +

◆ evhttp_uridecode()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL char* evhttp_uridecode (const char * uri,
int decode_plus,
size_t * size_out 
)
+
+ +

Helper function to decode a URI-escaped string or HTTP parameter.

+

If 'decode_plus' is 1, then we decode the string as an HTTP parameter value, and convert all plus ('+') characters to spaces. If 'decode_plus' is 0, we leave all plus characters unchanged.

+

The returned string must be freed by the caller.

+
Parameters
+ + + + +
uria URI-encode encoded URI
decode_plusdetermines whether we convert '+' to space.
size_outif size_out is not NULL, *size_out is set to the size of the returned string
+
+
+
Returns
a newly allocated unencoded URI or NULL on failure
+ +
+
+ +

◆ evhttp_uriencode()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL char* evhttp_uriencode (const char * str,
ev_ssize_t size,
int space_to_plus 
)
+
+ +

As evhttp_encode_uri, but if 'size' is nonnegative, treat the string as being 'size' bytes long.

+

This allows you to encode strings that may contain 0-valued bytes.

+

The returned string must be freed by the caller.

+
Parameters
+ + + + +
stran unencoded string
sizethe length of the string to encode, or -1 if the string is NUL-terminated
space_to_plusif true, space characters in 'str' are encoded as +, not %20.
+
+
+
Returns
a newly allocate URI-encoded string, or NULL on failure.
+ +
+
+
+ + + + diff --git a/http_8h_source.html b/http_8h_source.html new file mode 100644 index 0000000..b28c190 --- /dev/null +++ b/http_8h_source.html @@ -0,0 +1,763 @@ + + + + + + + +libevent: event2/http.h Source File + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
http.h
+
+
+Go to the documentation of this file.
1 /*
+
2  * Copyright (c) 2000-2007 Niels Provos <provos@citi.umich.edu>
+
3  * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson
+
4  *
+
5  * Redistribution and use in source and binary forms, with or without
+
6  * modification, are permitted provided that the following conditions
+
7  * are met:
+
8  * 1. Redistributions of source code must retain the above copyright
+
9  * notice, this list of conditions and the following disclaimer.
+
10  * 2. Redistributions in binary form must reproduce the above copyright
+
11  * notice, this list of conditions and the following disclaimer in the
+
12  * documentation and/or other materials provided with the distribution.
+
13  * 3. The name of the author may not be used to endorse or promote products
+
14  * derived from this software without specific prior written permission.
+
15  *
+
16  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+
17  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+
18  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+
19  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+
20  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+
21  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+
22  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+
23  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+
24  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+
25  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
26  */
+
27 #ifndef EVENT2_HTTP_H_INCLUDED_
+
28 #define EVENT2_HTTP_H_INCLUDED_
+
29 
+
30 /* For int types. */
+
31 #include <event2/util.h>
+
32 #include <event2/visibility.h>
+
33 
+
34 #ifdef __cplusplus
+
35 extern "C" {
+
36 #endif
+
37 
+
38 /* In case we haven't included the right headers yet. */
+
39 struct evbuffer;
+
40 struct event_base;
+
41 struct bufferevent;
+
42 struct evhttp_connection;
+
43 
+
55 /* Response codes */
+
56 #define HTTP_CONTINUE 100
+
57 #define HTTP_SWITCH_PROTOCOLS 101
+
58 #define HTTP_PROCESSING 102
+
59 #define HTTP_EARLYHINTS 103
+
60 #define HTTP_OK 200
+
61 #define HTTP_CREATED 201
+
62 #define HTTP_ACCEPTED 202
+
63 #define HTTP_NONAUTHORITATIVE 203
+
64 #define HTTP_NOCONTENT 204
+
65 #define HTTP_MOVEPERM 301
+
66 #define HTTP_MOVETEMP 302
+
67 #define HTTP_NOTMODIFIED 304
+
68 #define HTTP_BADREQUEST 400
+
69 #define HTTP_UNAUTHORIZED 401
+
70 #define HTTP_PAYMENTREQUIRED 402
+
71 #define HTTP_FORBIDDEN 403
+
72 #define HTTP_NOTFOUND 404
+
73 #define HTTP_BADMETHOD 405
+
74 #define HTTP_ENTITYTOOLARGE 413
+
75 #define HTTP_EXPECTATIONFAILED 417
+
76 #define HTTP_INTERNAL 500
+
77 #define HTTP_NOTIMPLEMENTED 501
+
78 #define HTTP_BADGATEWAY 502
+
79 #define HTTP_SERVUNAVAIL 503
+
81 struct evhttp;
+
82 struct evhttp_request;
+
83 struct evkeyvalq;
+
84 struct evhttp_bound_socket;
+
85 struct evconnlistener;
+
86 struct evdns_base;
+
87 struct evhttp_ext_method;
+
88 
+
97 EVENT2_EXPORT_SYMBOL
+
98 struct evhttp *evhttp_new(struct event_base *base);
+
99 
+
112 EVENT2_EXPORT_SYMBOL
+
113 int evhttp_bind_socket(struct evhttp *http, const char *address, ev_uint16_t port);
+
114 
+
126 EVENT2_EXPORT_SYMBOL
+
127 struct evhttp_bound_socket *evhttp_bind_socket_with_handle(struct evhttp *http, const char *address, ev_uint16_t port);
+
128 
+
145 EVENT2_EXPORT_SYMBOL
+
146 int evhttp_accept_socket(struct evhttp *http, evutil_socket_t fd);
+
147 
+
158 EVENT2_EXPORT_SYMBOL
+
159 struct evhttp_bound_socket *evhttp_accept_socket_with_handle(struct evhttp *http, evutil_socket_t fd);
+
160 
+
166 EVENT2_EXPORT_SYMBOL
+
167 struct evhttp_bound_socket *evhttp_bind_listener(struct evhttp *http, struct evconnlistener *listener);
+
168 
+
172 EVENT2_EXPORT_SYMBOL
+
173 struct evconnlistener *evhttp_bound_socket_get_listener(struct evhttp_bound_socket *bound);
+
174 
+
175 /*
+
176  * Like evhttp_set_bevcb.
+
177  * If cb returns a non-NULL bufferevent, * the callback supplied through
+
178  * evhttp_set_bevcb isn't used.
+
179  */
+
180 EVENT2_EXPORT_SYMBOL
+
181 void evhttp_bound_set_bevcb(struct evhttp_bound_socket *bound, struct bufferevent* (*cb)(struct event_base *, void *), void *cbarg);
+
182 
+
183 typedef void evhttp_bound_socket_foreach_fn(struct evhttp_bound_socket *, void *);
+
194 EVENT2_EXPORT_SYMBOL
+
195 void evhttp_foreach_bound_socket(struct evhttp *http, evhttp_bound_socket_foreach_fn *function, void *argument);
+
196 
+
214 EVENT2_EXPORT_SYMBOL
+
215 void evhttp_del_accept_socket(struct evhttp *http, struct evhttp_bound_socket *bound_socket);
+
216 
+
224 EVENT2_EXPORT_SYMBOL
+
225 evutil_socket_t evhttp_bound_socket_get_fd(struct evhttp_bound_socket *bound_socket);
+
226 
+
235 EVENT2_EXPORT_SYMBOL
+
236 void evhttp_free(struct evhttp* http);
+
237 
+
239 EVENT2_EXPORT_SYMBOL
+
240 void evhttp_set_max_headers_size(struct evhttp* http, ev_ssize_t max_headers_size);
+
242 EVENT2_EXPORT_SYMBOL
+
243 void evhttp_set_max_body_size(struct evhttp* http, ev_ssize_t max_body_size);
+
244 
+
252 EVENT2_EXPORT_SYMBOL
+
253 void evhttp_set_max_connections(struct evhttp* http, int max_connections);
+
254 
+
260 EVENT2_EXPORT_SYMBOL
+
261 int evhttp_get_connection_count(struct evhttp* http);
+
262 
+
271 EVENT2_EXPORT_SYMBOL
+
272 void evhttp_set_default_content_type(struct evhttp *http,
+
273  const char *content_type);
+
274 
+
286 EVENT2_EXPORT_SYMBOL
+
287 void evhttp_set_allowed_methods(struct evhttp* http, ev_uint32_t methods);
+
288 
+
289 typedef int (*evhttp_ext_method_cb)(struct evhttp_ext_method *);
+
306 EVENT2_EXPORT_SYMBOL
+
307 void evhttp_set_ext_method_cmp(struct evhttp *http, evhttp_ext_method_cb cmp);
+
308 
+
318 EVENT2_EXPORT_SYMBOL
+
319 int evhttp_set_cb(struct evhttp *http, const char *path,
+
320  void (*cb)(struct evhttp_request *, void *), void *cb_arg);
+
321 
+
323 EVENT2_EXPORT_SYMBOL
+
324 int evhttp_del_cb(struct evhttp *, const char *);
+
325 
+
337 EVENT2_EXPORT_SYMBOL
+
338 void evhttp_set_gencb(struct evhttp *http,
+
339  void (*cb)(struct evhttp_request *, void *), void *arg);
+
340 
+
357 EVENT2_EXPORT_SYMBOL
+
358 void evhttp_set_bevcb(struct evhttp *http,
+
359  struct bufferevent *(*cb)(struct event_base *, void *), void *arg);
+
360 
+
361 
+
375 EVENT2_EXPORT_SYMBOL
+
376 void evhttp_set_newreqcb(struct evhttp *http,
+
377  int (*cb)(struct evhttp_request*, void *), void *arg);
+
378 
+
401 EVENT2_EXPORT_SYMBOL
+
402 void evhttp_set_errorcb(struct evhttp *http,
+
403  int (*cb)(struct evhttp_request *req, struct evbuffer *buffer, int error, const char *reason, void *cbarg),
+
404  void *cbarg);
+
405 
+
428 EVENT2_EXPORT_SYMBOL
+
429 int evhttp_add_virtual_host(struct evhttp* http, const char *pattern,
+
430  struct evhttp* vhost);
+
431 
+
440 EVENT2_EXPORT_SYMBOL
+
441 int evhttp_remove_virtual_host(struct evhttp* http, struct evhttp* vhost);
+
442 
+
451 EVENT2_EXPORT_SYMBOL
+
452 int evhttp_add_server_alias(struct evhttp *http, const char *alias);
+
453 
+
461 EVENT2_EXPORT_SYMBOL
+
462 int evhttp_remove_server_alias(struct evhttp *http, const char *alias);
+
463 
+
471 EVENT2_EXPORT_SYMBOL
+
472 void evhttp_set_timeout(struct evhttp *http, int timeout);
+
473 
+
484 EVENT2_EXPORT_SYMBOL
+
485 void evhttp_set_timeout_tv(struct evhttp *http, const struct timeval* tv);
+
486 
+
493 EVENT2_EXPORT_SYMBOL
+
494 void evhttp_set_read_timeout_tv(struct evhttp *http, const struct timeval* tv);
+
495 
+
502 EVENT2_EXPORT_SYMBOL
+
503 void evhttp_set_write_timeout_tv(struct evhttp *http, const struct timeval* tv);
+
504 
+
505 /* Read all the clients body, and only after this respond with an error if the
+
506  * clients body exceed max_body_size */
+
507 #define EVHTTP_SERVER_LINGERING_CLOSE 0x0001
+
508 
+
515 EVENT2_EXPORT_SYMBOL
+
516 int evhttp_set_flags(struct evhttp *http, int flags);
+
517 
+
518 /* Request/Response functionality */
+
519 
+
528 EVENT2_EXPORT_SYMBOL
+
529 void evhttp_send_error(struct evhttp_request *req, int error,
+
530  const char *reason);
+
531 
+
545 EVENT2_EXPORT_SYMBOL
+
546 void evhttp_send_reply(struct evhttp_request *req, int code,
+
547  const char *reason, struct evbuffer *databuf);
+
548 
+
549 /* Low-level response interface, for streaming/chunked replies */
+
550 
+
565 EVENT2_EXPORT_SYMBOL
+
566 void evhttp_send_reply_start(struct evhttp_request *req, int code,
+
567  const char *reason);
+
568 
+
580 EVENT2_EXPORT_SYMBOL
+
581 void evhttp_send_reply_chunk(struct evhttp_request *req,
+
582  struct evbuffer *databuf);
+
583 
+
597 EVENT2_EXPORT_SYMBOL
+
598 void evhttp_send_reply_chunk_with_cb(struct evhttp_request *req, struct evbuffer *databuf,
+
599  void (*cb)(struct evhttp_connection *, void *), void *arg);
+
600 
+
606 EVENT2_EXPORT_SYMBOL
+
607 void evhttp_send_reply_end(struct evhttp_request *req);
+
608 
+
609 /*
+
610  * Interfaces for making requests
+
611  */
+
612 
+ +
624  EVHTTP_REQ_GET = 1 << 0,
+
625  EVHTTP_REQ_POST = 1 << 1,
+
626  EVHTTP_REQ_HEAD = 1 << 2,
+
627  EVHTTP_REQ_PUT = 1 << 3,
+
628  EVHTTP_REQ_DELETE = 1 << 4,
+
629  EVHTTP_REQ_OPTIONS = 1 << 5,
+
630  EVHTTP_REQ_TRACE = 1 << 6,
+
631  EVHTTP_REQ_CONNECT = 1 << 7,
+
632  EVHTTP_REQ_PATCH = 1 << 8,
+
633  EVHTTP_REQ_PROPFIND= 1 << 9,
+
634  EVHTTP_REQ_PROPPATCH=1 << 10,
+
635  EVHTTP_REQ_MKCOL = 1 << 11,
+
636  EVHTTP_REQ_LOCK = 1 << 12,
+
637  EVHTTP_REQ_UNLOCK = 1 << 13,
+
638  EVHTTP_REQ_COPY = 1 << 14,
+
639  EVHTTP_REQ_MOVE = 1 << 15,
+
640 };
+
641 
+
642 #define EVHTTP_REQ_MAX EVHTTP_REQ_MOVE
+
643 
+ +
652  const char *method;
+
653  ev_uint32_t type; /* @see enum evhttp_cmd_type */
+
654  ev_uint16_t flags; /* Available flag : EVHTTP_METHOD_HAS_BODY */
+
655 };
+
656 
+
657 #define EVHTTP_METHOD_HAS_BODY 0x0001
+
658 
+
660 enum evhttp_request_kind { EVHTTP_REQUEST, EVHTTP_RESPONSE };
+
661 
+
683 EVENT2_EXPORT_SYMBOL
+
684 struct evhttp_connection *evhttp_connection_base_bufferevent_new(
+
685  struct event_base *base, struct evdns_base *dnsbase, struct bufferevent* bev, const char *address, ev_uint16_t port);
+
686 
+
698 EVENT2_EXPORT_SYMBOL
+
699 struct evhttp_connection *evhttp_connection_base_bufferevent_unix_new(
+
700  struct event_base *base, struct bufferevent* bev, const char *path);
+
701 
+
705 EVENT2_EXPORT_SYMBOL
+
706 struct bufferevent* evhttp_connection_get_bufferevent(struct evhttp_connection *evcon);
+
707 
+
711 EVENT2_EXPORT_SYMBOL
+
712 struct evhttp *evhttp_connection_get_server(struct evhttp_connection *evcon);
+
713 
+
719 EVENT2_EXPORT_SYMBOL
+
720 struct evhttp_request *evhttp_request_new(
+
721  void (*cb)(struct evhttp_request *, void *), void *arg);
+
722 
+
730 EVENT2_EXPORT_SYMBOL
+
731 void evhttp_request_set_chunked_cb(struct evhttp_request *,
+
732  void (*cb)(struct evhttp_request *, void *));
+
733 
+
740 EVENT2_EXPORT_SYMBOL
+
741 void evhttp_request_set_header_cb(struct evhttp_request *,
+
742  int (*cb)(struct evhttp_request *, void *));
+
743 
+ + + + + + + +
774 };
+
782 EVENT2_EXPORT_SYMBOL
+
783 void evhttp_request_set_error_cb(struct evhttp_request *,
+
784  void (*)(enum evhttp_request_error, void *));
+
785 
+
798 EVENT2_EXPORT_SYMBOL
+
799 void evhttp_request_set_on_complete_cb(struct evhttp_request *req,
+
800  void (*cb)(struct evhttp_request *, void *), void *cb_arg);
+
801 
+
803 EVENT2_EXPORT_SYMBOL
+
804 void evhttp_request_free(struct evhttp_request *req);
+
805 
+
819 EVENT2_EXPORT_SYMBOL
+
820 struct evhttp_connection *evhttp_connection_base_new(
+
821  struct event_base *base, struct evdns_base *dnsbase,
+
822  const char *address, ev_uint16_t port);
+
823 
+
827 EVENT2_EXPORT_SYMBOL
+
828 void evhttp_connection_set_family(struct evhttp_connection *evcon,
+
829  int family);
+
830 
+
831 /* reuse connection address on retry */
+
832 #define EVHTTP_CON_REUSE_CONNECTED_ADDR 0x0008
+
833 /* Try to read error, since server may already send and close
+
834  * connection, but if at that time we have some data to send then we
+
835  * can send get EPIPE and fail, while we can read that HTTP error. */
+
836 #define EVHTTP_CON_READ_ON_WRITE_ERROR 0x0010
+
837 /* @see EVHTTP_SERVER_LINGERING_CLOSE */
+
838 #define EVHTTP_CON_LINGERING_CLOSE 0x0020
+
839 /* Padding for public flags, @see EVHTTP_CON_* in http-internal.h */
+
840 #define EVHTTP_CON_PUBLIC_FLAGS_END 0x100000
+
841 
+
848 EVENT2_EXPORT_SYMBOL
+
849 int evhttp_connection_set_flags(struct evhttp_connection *evcon,
+
850  int flags);
+
851 
+
857 EVENT2_EXPORT_SYMBOL
+
858 void evhttp_request_own(struct evhttp_request *req);
+
859 
+
861 EVENT2_EXPORT_SYMBOL
+
862 int evhttp_request_is_owned(struct evhttp_request *req);
+
863 
+
869 EVENT2_EXPORT_SYMBOL
+
870 void evhttp_connection_set_ext_method_cmp(struct evhttp_connection *evcon,
+
871  evhttp_ext_method_cb cmp);
+
872 
+
879 EVENT2_EXPORT_SYMBOL
+
880 struct evhttp_connection *evhttp_request_get_connection(struct evhttp_request *req);
+
881 
+
885 EVENT2_EXPORT_SYMBOL
+
886 struct event_base *evhttp_connection_get_base(struct evhttp_connection *req);
+
887 
+
888 EVENT2_EXPORT_SYMBOL
+
889 void evhttp_connection_set_max_headers_size(struct evhttp_connection *evcon,
+
890  ev_ssize_t new_max_headers_size);
+
891 
+
892 EVENT2_EXPORT_SYMBOL
+
893 void evhttp_connection_set_max_body_size(struct evhttp_connection* evcon,
+
894  ev_ssize_t new_max_body_size);
+
895 
+
897 EVENT2_EXPORT_SYMBOL
+
898 void evhttp_connection_free(struct evhttp_connection *evcon);
+
899 
+
905 EVENT2_EXPORT_SYMBOL
+
906 void evhttp_connection_free_on_completion(struct evhttp_connection *evcon);
+
907 
+
913 EVENT2_EXPORT_SYMBOL
+
914 void evhttp_connection_set_local_address(struct evhttp_connection *evcon,
+
915  const char *address);
+
916 
+
918 EVENT2_EXPORT_SYMBOL
+
919 void evhttp_connection_set_local_port(struct evhttp_connection *evcon,
+
920  ev_uint16_t port);
+
921 
+
927 EVENT2_EXPORT_SYMBOL
+
928 void evhttp_connection_set_timeout(struct evhttp_connection *evcon,
+
929  int timeout);
+
930 
+
945 EVENT2_EXPORT_SYMBOL
+
946 void evhttp_connection_set_timeout_tv(struct evhttp_connection *evcon,
+
947  const struct timeval *tv);
+
948 
+
954 EVENT2_EXPORT_SYMBOL
+
955 void evhttp_connection_set_connect_timeout_tv(struct evhttp_connection *evcon,
+
956  const struct timeval *tv);
+
957 
+
963 EVENT2_EXPORT_SYMBOL
+
964 void evhttp_connection_set_read_timeout_tv(struct evhttp_connection *evcon,
+
965  const struct timeval *tv);
+
966 
+
972 EVENT2_EXPORT_SYMBOL
+
973 void evhttp_connection_set_write_timeout_tv(struct evhttp_connection *evcon,
+
974  const struct timeval *tv);
+
975 
+
985 EVENT2_EXPORT_SYMBOL
+
986 void evhttp_connection_set_initial_retry_tv(struct evhttp_connection *evcon,
+
987  const struct timeval *tv);
+
988 
+
990 EVENT2_EXPORT_SYMBOL
+
991 void evhttp_connection_set_retries(struct evhttp_connection *evcon,
+
992  int retry_max);
+
993 
+
995 EVENT2_EXPORT_SYMBOL
+
996 void evhttp_connection_set_closecb(struct evhttp_connection *evcon,
+
997  void (*)(struct evhttp_connection *, void *), void *);
+
998 
+
1000 EVENT2_EXPORT_SYMBOL
+
1001 void evhttp_connection_get_peer(struct evhttp_connection *evcon,
+
1002  const char **address, ev_uint16_t *port);
+
1003 
+
1010 EVENT2_EXPORT_SYMBOL
+
1011 const struct sockaddr*
+
1012 evhttp_connection_get_addr(struct evhttp_connection *evcon);
+
1013 
+
1027 EVENT2_EXPORT_SYMBOL
+
1028 int evhttp_make_request(struct evhttp_connection *evcon,
+
1029  struct evhttp_request *req,
+
1030  enum evhttp_cmd_type type, const char *uri);
+
1031 
+
1045 EVENT2_EXPORT_SYMBOL
+
1046 void evhttp_cancel_request(struct evhttp_request *req);
+
1047 
+
1051 struct evhttp_uri;
+
1052 
+
1054 EVENT2_EXPORT_SYMBOL
+
1055 const char *evhttp_request_get_uri(const struct evhttp_request *req);
+
1057 EVENT2_EXPORT_SYMBOL
+
1058 const struct evhttp_uri *evhttp_request_get_evhttp_uri(const struct evhttp_request *req);
+
1060 EVENT2_EXPORT_SYMBOL
+
1061 enum evhttp_cmd_type evhttp_request_get_command(const struct evhttp_request *req);
+
1062 
+
1063 EVENT2_EXPORT_SYMBOL
+
1064 int evhttp_request_get_response_code(const struct evhttp_request *req);
+
1065 EVENT2_EXPORT_SYMBOL
+
1066 const char * evhttp_request_get_response_code_line(const struct evhttp_request *req);
+
1067 
+
1069 EVENT2_EXPORT_SYMBOL
+
1070 struct evkeyvalq *evhttp_request_get_input_headers(struct evhttp_request *req);
+
1072 EVENT2_EXPORT_SYMBOL
+
1073 struct evkeyvalq *evhttp_request_get_output_headers(struct evhttp_request *req);
+
1075 EVENT2_EXPORT_SYMBOL
+
1076 struct evbuffer *evhttp_request_get_input_buffer(struct evhttp_request *req);
+
1078 EVENT2_EXPORT_SYMBOL
+
1079 struct evbuffer *evhttp_request_get_output_buffer(struct evhttp_request *req);
+
1084 EVENT2_EXPORT_SYMBOL
+
1085 const char *evhttp_request_get_host(struct evhttp_request *req);
+
1086 
+
1087 /* Interfaces for dealing with HTTP headers */
+
1088 
+
1098 EVENT2_EXPORT_SYMBOL
+
1099 const char *evhttp_find_header(const struct evkeyvalq *headers,
+
1100  const char *key);
+
1101 
+
1110 EVENT2_EXPORT_SYMBOL
+
1111 int evhttp_remove_header(struct evkeyvalq *headers, const char *key);
+
1112 
+
1122 EVENT2_EXPORT_SYMBOL
+
1123 int evhttp_add_header(struct evkeyvalq *headers, const char *key, const char *value);
+
1124 
+
1130 EVENT2_EXPORT_SYMBOL
+
1131 void evhttp_clear_headers(struct evkeyvalq *headers);
+
1132 
+
1133 /* Miscellaneous utility functions */
+
1134 
+
1135 
+
1147 EVENT2_EXPORT_SYMBOL
+
1148 char *evhttp_encode_uri(const char *str);
+
1149 
+
1164 EVENT2_EXPORT_SYMBOL
+
1165 char *evhttp_uriencode(const char *str, ev_ssize_t size, int space_to_plus);
+
1166 
+
1181 EVENT2_EXPORT_SYMBOL
+
1182 char *evhttp_decode_uri(const char *uri);
+
1183 
+
1199 EVENT2_EXPORT_SYMBOL
+
1200 char *evhttp_uridecode(const char *uri, int decode_plus,
+
1201  size_t *size_out);
+
1202 
+
1222 EVENT2_EXPORT_SYMBOL
+
1223 int evhttp_parse_query(const char *uri, struct evkeyvalq *headers);
+
1224 
+
1226 EVENT2_EXPORT_SYMBOL
+
1227 int evhttp_parse_query_str(const char *uri, struct evkeyvalq *headers);
+
1228 
+
1243 #define EVHTTP_URI_QUERY_NONCONFORMANT 0x01
+
1244 
+
1250 #define EVHTTP_URI_QUERY_LAST_VAL 0x02
+
1251 
+
1270 EVENT2_EXPORT_SYMBOL
+
1271 int evhttp_parse_query_str_flags(const char *uri, struct evkeyvalq *headers, unsigned flags);
+
1272 
+
1284 EVENT2_EXPORT_SYMBOL
+
1285 char *evhttp_htmlescape(const char *html);
+
1286 
+
1290 EVENT2_EXPORT_SYMBOL
+
1291 struct evhttp_uri *evhttp_uri_new(void);
+
1292 
+
1297 EVENT2_EXPORT_SYMBOL
+
1298 void evhttp_uri_set_flags(struct evhttp_uri *uri, unsigned flags);
+
1299 
+
1302 EVENT2_EXPORT_SYMBOL
+
1303 const char *evhttp_uri_get_scheme(const struct evhttp_uri *uri);
+
1308 EVENT2_EXPORT_SYMBOL
+
1309 const char *evhttp_uri_get_userinfo(const struct evhttp_uri *uri);
+
1322 EVENT2_EXPORT_SYMBOL
+
1323 const char *evhttp_uri_get_host(const struct evhttp_uri *uri);
+
1326 EVENT2_EXPORT_SYMBOL
+
1327 const char *evhttp_uri_get_unixsocket(const struct evhttp_uri *uri);
+
1329 EVENT2_EXPORT_SYMBOL
+
1330 int evhttp_uri_get_port(const struct evhttp_uri *uri);
+
1332 EVENT2_EXPORT_SYMBOL
+
1333 const char *evhttp_uri_get_path(const struct evhttp_uri *uri);
+
1336 EVENT2_EXPORT_SYMBOL
+
1337 const char *evhttp_uri_get_query(const struct evhttp_uri *uri);
+
1340 EVENT2_EXPORT_SYMBOL
+
1341 const char *evhttp_uri_get_fragment(const struct evhttp_uri *uri);
+
1342 
+
1345 EVENT2_EXPORT_SYMBOL
+
1346 int evhttp_uri_set_scheme(struct evhttp_uri *uri, const char *scheme);
+
1349 EVENT2_EXPORT_SYMBOL
+
1350 int evhttp_uri_set_userinfo(struct evhttp_uri *uri, const char *userinfo);
+
1353 EVENT2_EXPORT_SYMBOL
+
1354 int evhttp_uri_set_host(struct evhttp_uri *uri, const char *host);
+
1357 EVENT2_EXPORT_SYMBOL
+
1358 int evhttp_uri_set_unixsocket(struct evhttp_uri *uri, const char *unixsocket);
+
1359 
+
1362 EVENT2_EXPORT_SYMBOL
+
1363 int evhttp_uri_set_port(struct evhttp_uri *uri, int port);
+
1366 EVENT2_EXPORT_SYMBOL
+
1367 int evhttp_uri_set_path(struct evhttp_uri *uri, const char *path);
+
1371 EVENT2_EXPORT_SYMBOL
+
1372 int evhttp_uri_set_query(struct evhttp_uri *uri, const char *query);
+
1376 EVENT2_EXPORT_SYMBOL
+
1377 int evhttp_uri_set_fragment(struct evhttp_uri *uri, const char *fragment);
+
1378 
+
1413 EVENT2_EXPORT_SYMBOL
+
1414 struct evhttp_uri *evhttp_uri_parse_with_flags(const char *source_uri,
+
1415  unsigned flags);
+
1416 
+
1429 #define EVHTTP_URI_NONCONFORMANT 0x01
+
1430 
+
1439 #define EVHTTP_URI_HOST_STRIP_BRACKETS 0x04
+
1440 
+
1446 #define EVHTTP_URI_UNIX_SOCKET 0x08
+
1447 
+
1449 EVENT2_EXPORT_SYMBOL
+
1450 struct evhttp_uri *evhttp_uri_parse(const char *source_uri);
+
1451 
+
1459 EVENT2_EXPORT_SYMBOL
+
1460 void evhttp_uri_free(struct evhttp_uri *uri);
+
1461 
+
1475 EVENT2_EXPORT_SYMBOL
+
1476 char *evhttp_uri_join(const struct evhttp_uri *uri, char *buf, size_t limit);
+
1477 
+
1478 #ifdef __cplusplus
+
1479 }
+
1480 #endif
+
1481 
+
1482 #endif /* EVENT2_HTTP_H_INCLUDED_ */
+
+
EVENT2_EXPORT_SYMBOL char * evhttp_decode_uri(const char *uri)
Helper function to sort of decode a URI-encoded string.
+
EVENT2_EXPORT_SYMBOL void evhttp_request_free(struct evhttp_request *req)
Frees the request object and removes associated events.
+
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_family(struct evhttp_connection *evcon, int family)
Set family hint for DNS requests.
+
EVENT2_EXPORT_SYMBOL void evhttp_foreach_bound_socket(struct evhttp *http, evhttp_bound_socket_foreach_fn *function, void *argument)
Applies the function specified in the first argument to all evhttp_bound_sockets associated with "htt...
+
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_ext_method_cmp(struct evhttp_connection *evcon, evhttp_ext_method_cb cmp)
Sets extended method cmp callback for this http connection.
+
EVENT2_EXPORT_SYMBOL struct evkeyvalq * evhttp_request_get_input_headers(struct evhttp_request *req)
Returns the input headers.
+
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_retries(struct evhttp_connection *evcon, int retry_max)
Sets the retry limit for this connection - -1 repeats indefinitely.
+
EVENT2_EXPORT_SYMBOL int evhttp_remove_server_alias(struct evhttp *http, const char *alias)
Remove a server alias from an http object.
+
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_write_timeout_tv(struct evhttp_connection *evcon, const struct timeval *tv)
Sets the write timeout for this connection.
+
EVENT2_EXPORT_SYMBOL struct evconnlistener * evhttp_bound_socket_get_listener(struct evhttp_bound_socket *bound)
Return the listener used to implement a bound socket.
+
EVENT2_EXPORT_SYMBOL struct evhttp * evhttp_connection_get_server(struct evhttp_connection *evcon)
Return the HTTP server associated with this connection, or NULL.
+
EVENT2_EXPORT_SYMBOL void evhttp_request_set_on_complete_cb(struct evhttp_request *req, void(*cb)(struct evhttp_request *, void *), void *cb_arg)
Set a callback to be called on request completion of evhttp_send_* function.
+
EVENT2_EXPORT_SYMBOL const struct sockaddr * evhttp_connection_get_addr(struct evhttp_connection *evcon)
Get the remote address associated with this connection.
+
EVENT2_EXPORT_SYMBOL struct bufferevent * evhttp_connection_get_bufferevent(struct evhttp_connection *evcon)
Return the bufferevent that an evhttp_connection is using.
+
EVENT2_EXPORT_SYMBOL void evhttp_set_read_timeout_tv(struct evhttp *http, const struct timeval *tv)
Set read timeout for an HTTP request.
+
EVENT2_EXPORT_SYMBOL evutil_socket_t evhttp_bound_socket_get_fd(struct evhttp_bound_socket *bound_socket)
Get the raw file descriptor referenced by an evhttp_bound_socket.
+
EVENT2_EXPORT_SYMBOL void evhttp_set_max_headers_size(struct evhttp *http, ev_ssize_t max_headers_size)
XXX Document.
+
const EVENT2_EXPORT_SYMBOL char * evhttp_request_get_uri(const struct evhttp_request *req)
Returns the request URI.
+
EVENT2_EXPORT_SYMBOL void evhttp_send_reply_end(struct evhttp_request *req)
Complete a chunked reply, freeing the request as appropriate.
+
EVENT2_EXPORT_SYMBOL void evhttp_set_bevcb(struct evhttp *http, struct bufferevent *(*cb)(struct event_base *, void *), void *arg)
Set a callback used to create new bufferevents for connections to a given evhttp object.
+
EVENT2_EXPORT_SYMBOL int evhttp_connection_set_flags(struct evhttp_connection *evcon, int flags)
Set connection flags.
+
EVENT2_EXPORT_SYMBOL char * evhttp_uri_join(const struct evhttp_uri *uri, char *buf, size_t limit)
Join together the uri parts from parsed data to form a URI-Reference.
+
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_userinfo(struct evhttp_uri *uri, const char *userinfo)
Set the userinfo of an evhttp_uri, or clear the userinfo if userinfo==NULL.
+
EVENT2_EXPORT_SYMBOL void evhttp_clear_headers(struct evkeyvalq *headers)
Removes all headers from the header list.
+
@ EVREQ_HTTP_EOF
EOF reached.
Definition: http.h:757
+
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_fragment(struct evhttp_uri *uri, const char *fragment)
Set the fragment of an evhttp_uri, or clear the fragment if fragment==NULL.
+
EVENT2_EXPORT_SYMBOL void evhttp_set_errorcb(struct evhttp *http, int(*cb)(struct evhttp_request *req, struct evbuffer *buffer, int error, const char *reason, void *cbarg), void *cbarg)
Set a callback to output for any error pages sent for requests of a given evhttp object.
+
EVENT2_EXPORT_SYMBOL void evhttp_uri_free(struct evhttp_uri *uri)
Free all memory allocated for a parsed uri.
+
EVENT2_EXPORT_SYMBOL void evhttp_request_set_error_cb(struct evhttp_request *, void(*)(enum evhttp_request_error, void *))
Set a callback for errors.
+
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_port(struct evhttp_uri *uri, int port)
Set the port of an evhttp_uri, or clear the port if port==-1.
+
Structure to hold information and state for a Libevent dispatch loop.
Definition: event.h:219
+
@ EVREQ_HTTP_BUFFER_ERROR
Error encountered while reading or writing.
Definition: http.h:765
+
EVENT2_EXPORT_SYMBOL void evhttp_set_allowed_methods(struct evhttp *http, ev_uint32_t methods)
Sets the what HTTP methods are supported in requests accepted by this server, and passed to user call...
+
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_local_port(struct evhttp_connection *evcon, ev_uint16_t port)
sets the local port from which http connections are made
+
EVENT2_EXPORT_SYMBOL void evhttp_set_timeout_tv(struct evhttp *http, const struct timeval *tv)
Set read and write timeout for an HTTP request.
+
const EVENT2_EXPORT_SYMBOL char * evhttp_uri_get_query(const struct evhttp_uri *uri)
Return the query part of an evhttp_uri (excluding the leading "?"), or NULL if it has no query set.
+
EVENT2_EXPORT_SYMBOL int evhttp_remove_header(struct evkeyvalq *headers, const char *key)
Removes a header from a list of existing headers.
+
EVENT2_EXPORT_SYMBOL int evhttp_add_virtual_host(struct evhttp *http, const char *pattern, struct evhttp *vhost)
Adds a virtual host to the http server.
+
EVENT2_EXPORT_SYMBOL void evhttp_send_reply_start(struct evhttp_request *req, int code, const char *reason)
Initiate a reply that uses Transfer-Encoding chunked.
+
EVENT2_EXPORT_SYMBOL void evhttp_set_max_body_size(struct evhttp *http, ev_ssize_t max_body_size)
XXX Document.
+
EVENT2_EXPORT_SYMBOL int evhttp_add_server_alias(struct evhttp *http, const char *alias)
Add a server alias to an http object.
+
EVENT2_EXPORT_SYMBOL void evhttp_send_reply(struct evhttp_request *req, int code, const char *reason, struct evbuffer *databuf)
Send an HTML reply to the client.
+
EVENT2_EXPORT_SYMBOL int evhttp_make_request(struct evhttp_connection *evcon, struct evhttp_request *req, enum evhttp_cmd_type type, const char *uri)
Make an HTTP request over the specified connection.
+
EVENT2_EXPORT_SYMBOL int evhttp_set_cb(struct evhttp *http, const char *path, void(*cb)(struct evhttp_request *, void *), void *cb_arg)
Set a callback for a specified URI.
+
evhttp_request_error
The different error types supported by evhttp.
Definition: http.h:749
+
EVENT2_EXPORT_SYMBOL int evhttp_set_flags(struct evhttp *http, int flags)
Set connection flags for HTTP server.
+
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_read_timeout_tv(struct evhttp_connection *evcon, const struct timeval *tv)
Sets the read timeout for this connection.
+
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_local_address(struct evhttp_connection *evcon, const char *address)
Sets the IP address from which http connections are made.
+
EVENT2_EXPORT_SYMBOL int evhttp_parse_query_str_flags(const char *uri, struct evkeyvalq *headers, unsigned flags)
Helper function to parse out arguments from the query portion of an HTTP URI.
+
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_connect_timeout_tv(struct evhttp_connection *evcon, const struct timeval *tv)
Sets the connect timeout for this connection.
+
EVENT2_EXPORT_SYMBOL struct event_base * evhttp_connection_get_base(struct evhttp_connection *req)
Returns the underlying event_base for this connection.
+
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_query(struct evhttp_uri *uri, const char *query)
Set the query of an evhttp_uri, or clear the query if query==NULL.
+
EVENT2_EXPORT_SYMBOL void evhttp_set_newreqcb(struct evhttp *http, int(*cb)(struct evhttp_request *, void *), void *arg)
Set a callback which allows the user to note or throttle incoming requests.
+
@ EVREQ_HTTP_REQUEST_CANCEL
The evhttp_cancel_request() called on this request.
Definition: http.h:769
+
@ EVREQ_HTTP_INVALID_HEADER
Error while reading header, or invalid header.
Definition: http.h:761
+
EVENT2_EXPORT_SYMBOL int evhttp_uri_get_port(const struct evhttp_uri *uri)
Return the port part of an evhttp_uri, or -1 if there is no port set.
+
EVENT2_EXPORT_SYMBOL void evhttp_set_timeout(struct evhttp *http, int timeout)
Set the timeout for an HTTP request.
+
An opaque type for handling buffered IO.
Definition: bufferevent.h:114
+
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_closecb(struct evhttp_connection *evcon, void(*)(struct evhttp_connection *, void *), void *)
Set a callback for connection close.
+
EVENT2_EXPORT_SYMBOL void evhttp_request_own(struct evhttp_request *req)
Takes ownership of the request object.
+
EVENT2_EXPORT_SYMBOL int evhttp_get_connection_count(struct evhttp *http)
Get the current number of connections.
+
EVENT2_EXPORT_SYMBOL struct evhttp_connection * evhttp_connection_base_bufferevent_new(struct event_base *base, struct evdns_base *dnsbase, struct bufferevent *bev, const char *address, ev_uint16_t port)
Create and return a connection object that can be used to for making HTTP requests.
+
const EVENT2_EXPORT_SYMBOL char * evhttp_uri_get_path(const struct evhttp_uri *uri)
Return the path part of an evhttp_uri, or NULL if it has no path set.
+
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_path(struct evhttp_uri *uri, const char *path)
Set the path of an evhttp_uri, or clear the path if path==NULL.
+
EVENT2_EXPORT_SYMBOL int evhttp_accept_socket(struct evhttp *http, evutil_socket_t fd)
Makes an HTTP server accept connections on the specified socket.
+
EVENT2_EXPORT_SYMBOL struct evbuffer * evhttp_request_get_input_buffer(struct evhttp_request *req)
Returns the input buffer.
+
EVENT2_EXPORT_SYMBOL int evhttp_remove_virtual_host(struct evhttp *http, struct evhttp *vhost)
Removes a virtual host from the http server.
+
EVENT2_EXPORT_SYMBOL void evhttp_free(struct evhttp *http)
Free the previously created HTTP server.
+
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_host(struct evhttp_uri *uri, const char *host)
Set the host of an evhttp_uri, or clear the host if host==NULL.
+
structure that is passed to (and modified by) the extended method callback function
Definition: http.h:651
+
An evbuffer is an opaque data type for efficiently buffering data to be sent or received on the netwo...
Definition: buffer.h:97
+
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_initial_retry_tv(struct evhttp_connection *evcon, const struct timeval *tv)
Sets the delay before retrying requests on this connection.
+
EVENT2_EXPORT_SYMBOL struct evbuffer * evhttp_request_get_output_buffer(struct evhttp_request *req)
Returns the output buffer.
+
const EVENT2_EXPORT_SYMBOL char * evhttp_request_get_host(struct evhttp_request *req)
Returns the host associated with the request.
+
const EVENT2_EXPORT_SYMBOL char * evhttp_uri_get_userinfo(const struct evhttp_uri *uri)
Return the userinfo part of an evhttp_uri, or NULL if it has no userinfo set.
+
EVENT2_EXPORT_SYMBOL enum evhttp_cmd_type evhttp_request_get_command(const struct evhttp_request *req)
Returns the request command.
+
EVENT2_EXPORT_SYMBOL struct evhttp * evhttp_new(struct event_base *base)
Create a new HTTP server.
+
EVENT2_EXPORT_SYMBOL int evhttp_request_is_owned(struct evhttp_request *req)
Returns 1 if the request is owned by the user.
+
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_timeout(struct evhttp_connection *evcon, int timeout)
Sets the timeout for this connection.
+
EVENT2_EXPORT_SYMBOL struct evhttp_request * evhttp_request_new(void(*cb)(struct evhttp_request *, void *), void *arg)
Creates a new request object that needs to be filled in with the request parameters.
+
EVENT2_EXPORT_SYMBOL void evhttp_connection_free_on_completion(struct evhttp_connection *evcon)
Disowns a given connection object.
+
EVENT2_EXPORT_SYMBOL struct evhttp_bound_socket * evhttp_bind_socket_with_handle(struct evhttp *http, const char *address, ev_uint16_t port)
Like evhttp_bind_socket(), but returns a handle for referencing the socket.
+
EVENT2_EXPORT_SYMBOL int evhttp_parse_query(const char *uri, struct evkeyvalq *headers)
Helper function to parse out arguments in a query.
+
EVENT2_EXPORT_SYMBOL struct evhttp_uri * evhttp_uri_new(void)
Return a new empty evhttp_uri with no fields set.
+
EVENT2_EXPORT_SYMBOL int evhttp_bind_socket(struct evhttp *http, const char *address, ev_uint16_t port)
Binds an HTTP server on the specified address and port.
+
EVENT2_EXPORT_SYMBOL struct evhttp_connection * evhttp_connection_base_bufferevent_unix_new(struct event_base *base, struct bufferevent *bev, const char *path)
Create and return a connection object that can be used to for making HTTP requests over an unix domai...
+
EVENT2_EXPORT_SYMBOL void evhttp_set_write_timeout_tv(struct evhttp *http, const struct timeval *tv)
Set write timeout for an HTTP request.
+
EVENT2_EXPORT_SYMBOL struct evhttp_uri * evhttp_uri_parse_with_flags(const char *source_uri, unsigned flags)
Helper function to parse a URI-Reference as specified by RFC3986.
+
EVENT2_EXPORT_SYMBOL void evhttp_del_accept_socket(struct evhttp *http, struct evhttp_bound_socket *bound_socket)
Makes an HTTP server stop accepting connections on the specified socket.
+
EVENT2_EXPORT_SYMBOL void evhttp_send_reply_chunk(struct evhttp_request *req, struct evbuffer *databuf)
Send another data chunk as part of an ongoing chunked reply.
+
evhttp_cmd_type
The different request types supported by evhttp.
Definition: http.h:623
+
evhttp_request_kind
a request object can represent either a request or a reply
Definition: http.h:660
+
EVENT2_EXPORT_SYMBOL struct evhttp_uri * evhttp_uri_parse(const char *source_uri)
Alias for evhttp_uri_parse_with_flags(source_uri, 0)
+
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_timeout_tv(struct evhttp_connection *evcon, const struct timeval *tv)
Sets the timeout for this connection for the following events:
+
EVENT2_EXPORT_SYMBOL void evhttp_request_set_header_cb(struct evhttp_request *, int(*cb)(struct evhttp_request *, void *))
Register callback for additional parsing of request headers.
+
const EVENT2_EXPORT_SYMBOL char * evhttp_uri_get_unixsocket(const struct evhttp_uri *uri)
Return the unix socket part of an evhttp_uri, or NULL if there is no unix socket set.
+
EVENT2_EXPORT_SYMBOL void evhttp_request_set_chunked_cb(struct evhttp_request *, void(*cb)(struct evhttp_request *, void *))
Enable delivery of chunks to requestor.
+
EVENT2_EXPORT_SYMBOL void evhttp_connection_free(struct evhttp_connection *evcon)
Frees an http connection.
+
EVENT2_EXPORT_SYMBOL struct evhttp_connection * evhttp_connection_base_new(struct event_base *base, struct evdns_base *dnsbase, const char *address, ev_uint16_t port)
Create and return a connection object that can be used to for making HTTP requests.
+
@ EVREQ_HTTP_DATA_TOO_LONG
Body is greater then evhttp_connection_set_max_body_size()
Definition: http.h:773
+
EVENT2_EXPORT_SYMBOL void evhttp_set_default_content_type(struct evhttp *http, const char *content_type)
Set the value to use for the Content-Type header when none was provided.
+
const EVENT2_EXPORT_SYMBOL char * evhttp_uri_get_fragment(const struct evhttp_uri *uri)
Return the fragment part of an evhttp_uri (excluding the leading "#"), or NULL if it has no fragment ...
+
EVENT2_EXPORT_SYMBOL void evhttp_connection_get_peer(struct evhttp_connection *evcon, const char **address, ev_uint16_t *port)
Get the remote address and port associated with this connection.
+
EVENT2_EXPORT_SYMBOL void evhttp_set_max_connections(struct evhttp *http, int max_connections)
Set the maximum number of simultaneous connections for this server.
+
EVENT2_EXPORT_SYMBOL int evhttp_add_header(struct evkeyvalq *headers, const char *key, const char *value)
Adds a header to a list of existing headers.
+
EVENT2_EXPORT_SYMBOL void evhttp_uri_set_flags(struct evhttp_uri *uri, unsigned flags)
Changes the flags set on a given URI.
+
EVENT2_EXPORT_SYMBOL int evhttp_parse_query_str(const char *uri, struct evkeyvalq *headers)
+
EVENT2_EXPORT_SYMBOL void evhttp_send_error(struct evhttp_request *req, int error, const char *reason)
Send an HTML error message to the client.
+
@ EVREQ_HTTP_TIMEOUT
Timeout reached, also.
Definition: http.h:753
+
EVENT2_EXPORT_SYMBOL char * evhttp_encode_uri(const char *str)
Helper function to encode a string for inclusion in a URI.
+
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_unixsocket(struct evhttp_uri *uri, const char *unixsocket)
Set the unix socket of an evhttp_uri, or clear the unix socket if unixsocket==NULL.
+
EVENT2_EXPORT_SYMBOL char * evhttp_uridecode(const char *uri, int decode_plus, size_t *size_out)
Helper function to decode a URI-escaped string or HTTP parameter.
+
EVENT2_EXPORT_SYMBOL void evhttp_cancel_request(struct evhttp_request *req)
Cancels a pending HTTP request.
+
EVENT2_EXPORT_SYMBOL const struct evhttp_uri * evhttp_request_get_evhttp_uri(const struct evhttp_request *req)
Returns the request URI (parsed)
+
const EVENT2_EXPORT_SYMBOL char * evhttp_uri_get_scheme(const struct evhttp_uri *uri)
Return the scheme of an evhttp_uri, or NULL if there is no scheme has been set and the evhttp_uri con...
+
EVENT2_EXPORT_SYMBOL int evhttp_uri_set_scheme(struct evhttp_uri *uri, const char *scheme)
Set the scheme of an evhttp_uri, or clear the scheme if scheme==NULL.
+
EVENT2_EXPORT_SYMBOL struct evkeyvalq * evhttp_request_get_output_headers(struct evhttp_request *req)
Returns the output headers.
+
const EVENT2_EXPORT_SYMBOL char * evhttp_find_header(const struct evkeyvalq *headers, const char *key)
Finds the value belonging to a header.
+
EVENT2_EXPORT_SYMBOL struct evhttp_connection * evhttp_request_get_connection(struct evhttp_request *req)
Returns the connection object associated with the request or NULL.
+
EVENT2_EXPORT_SYMBOL void evhttp_set_gencb(struct evhttp *http, void(*cb)(struct evhttp_request *, void *), void *arg)
Set a callback for all requests that are not caught by specific callbacks.
+
Common convenience functions for cross-platform portability and related socket manipulations.
+
EVENT2_EXPORT_SYMBOL char * evhttp_uriencode(const char *str, ev_ssize_t size, int space_to_plus)
As evhttp_encode_uri, but if 'size' is nonnegative, treat the string as being 'size' bytes long.
+
EVENT2_EXPORT_SYMBOL void evhttp_set_ext_method_cmp(struct evhttp *http, evhttp_ext_method_cb cmp)
Sets the callback function which allows HTTP extended methods to be supported by this server.
+
EVENT2_EXPORT_SYMBOL struct evhttp_bound_socket * evhttp_bind_listener(struct evhttp *http, struct evconnlistener *listener)
The most low-level evhttp_bind/accept method: takes an evconnlistener, and returns an evhttp_bound_so...
+
EVENT2_EXPORT_SYMBOL void evhttp_send_reply_chunk_with_cb(struct evhttp_request *req, struct evbuffer *databuf, void(*cb)(struct evhttp_connection *, void *), void *arg)
Send another data chunk as part of an ongoing chunked reply.
+
const EVENT2_EXPORT_SYMBOL char * evhttp_uri_get_host(const struct evhttp_uri *uri)
Return the host part of an evhttp_uri, or NULL if it has no host set.
+
EVENT2_EXPORT_SYMBOL char * evhttp_htmlescape(const char *html)
Escape HTML character entities in a string.
+
EVENT2_EXPORT_SYMBOL struct evhttp_bound_socket * evhttp_accept_socket_with_handle(struct evhttp *http, evutil_socket_t fd)
Like evhttp_accept_socket(), but returns a handle for referencing the socket.
+
#define evutil_socket_t
A type wide enough to hold the output of "socket()" or "accept()".
Definition: util.h:325
+
EVENT2_EXPORT_SYMBOL int evhttp_del_cb(struct evhttp *, const char *)
Removes the callback for a specified URI.
+ + + + diff --git a/http__compat_8h.html b/http__compat_8h.html new file mode 100644 index 0000000..13abe70 --- /dev/null +++ b/http__compat_8h.html @@ -0,0 +1,217 @@ + + + + + + + +libevent: event2/http_compat.h File Reference + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+ +
+
http_compat.h File Reference
+
+
+ +

Potentially non-threadsafe versions of the functions in http.h: provided only for backwards compatibility. +More...

+
#include <event2/event-config.h>
+#include <event2/util.h>
+
+

Go to the source code of this file.

+ + + + + +

+Macros

+#define evhttp_request_uri   evhttp_request_get_uri
 Returns the request URI.
 
+ + + + + + + + + + +

+Functions

EVENT2_EXPORT_SYMBOL struct evhttp_connection * evhttp_connection_new (const char *address, ev_uint16_t port)
 A connection object that can be used to for making HTTP requests. More...
 
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_base (struct evhttp_connection *evcon, struct event_base *base)
 Associates an event base with the connection - can only be called on a freshly created connection object that has not been used yet. More...
 
EVENT2_EXPORT_SYMBOL struct evhttp * evhttp_start (const char *address, ev_uint16_t port)
 Start an HTTP server on the specified address and port. More...
 
+

Detailed Description

+

Potentially non-threadsafe versions of the functions in http.h: provided only for backwards compatibility.

+

Function Documentation

+ +

◆ evhttp_connection_new()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evhttp_connection* evhttp_connection_new (const char * address,
ev_uint16_t port 
)
+
+ +

A connection object that can be used to for making HTTP requests.

+

The connection object tries to establish the connection when it is given an http request object.

+
Deprecated:
It does not allow an event base to be specified
+ +
+
+ +

◆ evhttp_connection_set_base()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_base (struct evhttp_connection * evcon,
struct event_basebase 
)
+
+ +

Associates an event base with the connection - can only be called on a freshly created connection object that has not been used yet.

+
Deprecated:
XXXX Why?
+ +
+
+ +

◆ evhttp_start()

+ +
+
+ + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evhttp* evhttp_start (const char * address,
ev_uint16_t port 
)
+
+ +

Start an HTTP server on the specified address and port.

+
Deprecated:
It does not allow an event base to be specified
+
Parameters
+ + + +
addressthe address to which the HTTP server should be bound
portthe port number on which the HTTP server should listen
+
+
+
Returns
a pointer to a newly initialized evhttp server structure or NULL on error
+ +
+
+
+ + + + diff --git a/http__compat_8h_source.html b/http__compat_8h_source.html new file mode 100644 index 0000000..f08db64 --- /dev/null +++ b/http__compat_8h_source.html @@ -0,0 +1,150 @@ + + + + + + + +libevent: event2/http_compat.h Source File + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
http_compat.h
+
+
+Go to the documentation of this file.
1 /*
+
2  * Copyright (c) 2000-2007 Niels Provos <provos@citi.umich.edu>
+
3  * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson
+
4  *
+
5  * Redistribution and use in source and binary forms, with or without
+
6  * modification, are permitted provided that the following conditions
+
7  * are met:
+
8  * 1. Redistributions of source code must retain the above copyright
+
9  * notice, this list of conditions and the following disclaimer.
+
10  * 2. Redistributions in binary form must reproduce the above copyright
+
11  * notice, this list of conditions and the following disclaimer in the
+
12  * documentation and/or other materials provided with the distribution.
+
13  * 3. The name of the author may not be used to endorse or promote products
+
14  * derived from this software without specific prior written permission.
+
15  *
+
16  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+
17  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+
18  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+
19  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+
20  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+
21  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+
22  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+
23  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+
24  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+
25  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
26  */
+
27 #ifndef EVENT2_HTTP_COMPAT_H_INCLUDED_
+
28 #define EVENT2_HTTP_COMPAT_H_INCLUDED_
+
29 
+
37 #ifdef __cplusplus
+
38 extern "C" {
+
39 #endif
+
40 
+
41 #include <event2/event-config.h>
+
42 #ifdef EVENT__HAVE_SYS_TYPES_H
+
43 #include <sys/types.h>
+
44 #endif
+
45 #ifdef EVENT__HAVE_SYS_TIME_H
+
46 #include <sys/time.h>
+
47 #endif
+
48 
+
49 /* For int types. */
+
50 #include <event2/util.h>
+
51 
+
62 EVENT2_EXPORT_SYMBOL
+
63 struct evhttp *evhttp_start(const char *address, ev_uint16_t port);
+
64 
+
72 EVENT2_EXPORT_SYMBOL
+
73 struct evhttp_connection *evhttp_connection_new(
+
74  const char *address, ev_uint16_t port);
+
75 
+
82 EVENT2_EXPORT_SYMBOL
+
83 void evhttp_connection_set_base(struct evhttp_connection *evcon,
+
84  struct event_base *base);
+
85 
+
86 
+
88 #define evhttp_request_uri evhttp_request_get_uri
+
89 
+
90 #ifdef __cplusplus
+
91 }
+
92 #endif
+
93 
+
94 #endif /* EVENT2_EVENT_COMPAT_H_INCLUDED_ */
+
+
Structure to hold information and state for a Libevent dispatch loop.
Definition: event.h:219
+
EVENT2_EXPORT_SYMBOL struct evhttp_connection * evhttp_connection_new(const char *address, ev_uint16_t port)
A connection object that can be used to for making HTTP requests.
+
EVENT2_EXPORT_SYMBOL struct evhttp * evhttp_start(const char *address, ev_uint16_t port)
Start an HTTP server on the specified address and port.
+
EVENT2_EXPORT_SYMBOL void evhttp_connection_set_base(struct evhttp_connection *evcon, struct event_base *base)
Associates an event base with the connection - can only be called on a freshly created connection obj...
+
Common convenience functions for cross-platform portability and related socket manipulations.
+ + + + diff --git a/index.html b/index.html new file mode 100644 index 0000000..891aa2c --- /dev/null +++ b/index.html @@ -0,0 +1,131 @@ + + + + + + + +libevent: Main Page + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+
libevent Documentation
+
+
+

+Introduction

+

Libevent is an event notification library for developing scalable network servers. The Libevent API provides a mechanism to execute a callback function when a specific event occurs on a file descriptor or after a timeout has been reached. Furthermore, Libevent also support callbacks due to signals or regular timeouts.

+

Libevent is meant to replace the event loop found in event driven network servers. An application just needs to call event_base_dispatch() and then add or remove events dynamically without having to change the event loop.

+

Currently, Libevent supports /dev/poll, kqueue(2), select(2), poll(2), epoll(4), and evports. The internal event mechanism is completely independent of the exposed event API, and a simple update of Libevent can provide new functionality without having to redesign the applications. As a result, Libevent allows for portable application development and provides the most scalable event notification mechanism available on an operating system. Libevent can also be used for multithreaded programs. Libevent should compile on Linux, *BSD, Mac OS X, Solaris and, Windows.

+

+Standard usage

+

Every program that uses Libevent must include the <event2/event.h> header, and pass the -levent flag to the linker. (You can instead link -levent_core if you only want the main event and buffered IO-based code, and don't want to link any protocol code.)

+

+Library setup

+

Before you call any other Libevent functions, you need to set up the library. If you're going to use Libevent from multiple threads in a multithreaded application, you need to initialize thread support – typically by using evthread_use_pthreads() or evthread_use_windows_threads(). See <event2/thread.h> for more information.

+

This is also the point where you can replace Libevent's memory management functions with event_set_mem_functions, and enable debug mode with event_enable_debug_mode().

+

+Creating an event base

+

Next, you need to create an event_base structure, using event_base_new() or event_base_new_with_config(). The event_base is responsible for keeping track of which events are "pending" (that is to say, being watched to see if they become active) and which events are "active". Every event is associated with a single event_base.

+

+Event notification

+

For each file descriptor that you wish to monitor, you must create an event structure with event_new(). (You may also declare an event structure and call event_assign() to initialize the members of the structure.) To enable notification, you add the structure to the list of monitored events by calling event_add(). The event structure must remain allocated as long as it is active, so it should generally be allocated on the heap.

+

+Dispatching events.

+

Finally, you call event_base_dispatch() to loop and dispatch events. You can also use event_base_loop() for more fine-grained control.

+

Currently, only one thread can be dispatching a given event_base at a time. If you want to run events in multiple threads at once, you can either have a single event_base whose events add work to a work queue, or you can create multiple event_base objects.

+

+I/O Buffers

+

Libevent provides a buffered I/O abstraction on top of the regular event callbacks. This abstraction is called a bufferevent. A bufferevent provides input and output buffers that get filled and drained automatically. The user of a buffered event no longer deals directly with the I/O, but instead is reading from input and writing to output buffers.

+

Once initialized via bufferevent_socket_new(), the bufferevent structure can be used repeatedly with bufferevent_enable() and bufferevent_disable(). Instead of reading and writing directly to a socket, you would call bufferevent_read() and bufferevent_write().

+

When read enabled the bufferevent will try to read from the file descriptor and call the read callback. The write callback is executed whenever the output buffer is drained below the write low watermark, which is 0 by default.

+

See <event2/bufferevent*.h> for more information.

+

+Timers

+

Libevent can also be used to create timers that invoke a callback after a certain amount of time has expired. The evtimer_new() macro returns an event struct to use as a timer. To activate the timer, call evtimer_add(). Timers can be deactivated by calling evtimer_del(). (These macros are thin wrappers around event_new(), event_add(), and event_del(); you can also use those instead.)

+

+Asynchronous DNS resolution

+

Libevent provides an asynchronous DNS resolver that should be used instead of the standard DNS resolver functions. See the <event2/dns.h> functions for more detail.

+

+Event-driven HTTP servers

+

Libevent provides a very simple event-driven HTTP server that can be embedded in your program and used to service HTTP requests.

+

To use this capability, you need to include the <event2/http.h> header in your program. See that header for more information.

+

+A framework for RPC servers and clients

+

Libevent provides a framework for creating RPC servers and clients. It takes care of marshaling and unmarshaling all data structures.

+

+API Reference

+

To browse the complete documentation of the libevent API, click on any of the following links.

+

event2/event.h The primary libevent header

+

event2/thread.h Functions for use by multithreaded programs

+

event2/buffer.h and event2/bufferevent.h Buffer management for network reading and writing

+

event2/util.h Utility functions for portable nonblocking network code

+

event2/dns.h Asynchronous DNS resolution

+

event2/http.h An embedded libevent-based HTTP server

+

event2/rpc.h A framework for creating RPC servers and clients

+

event2/watch.h "Prepare" and "check" watchers.

+
+
+ + + + diff --git a/jquery.js b/jquery.js new file mode 100644 index 0000000..103c32d --- /dev/null +++ b/jquery.js @@ -0,0 +1,35 @@ +/*! jQuery v3.4.1 | (c) JS Foundation and other contributors | jquery.org/license */ +!function(e,t){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(C,e){"use strict";var t=[],E=C.document,r=Object.getPrototypeOf,s=t.slice,g=t.concat,u=t.push,i=t.indexOf,n={},o=n.toString,v=n.hasOwnProperty,a=v.toString,l=a.call(Object),y={},m=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType},x=function(e){return null!=e&&e===e.window},c={type:!0,src:!0,nonce:!0,noModule:!0};function b(e,t,n){var r,i,o=(n=n||E).createElement("script");if(o.text=e,t)for(r in c)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function w(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?n[o.call(e)]||"object":typeof e}var f="3.4.1",k=function(e,t){return new k.fn.init(e,t)},p=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;function d(e){var t=!!e&&"length"in e&&e.length,n=w(e);return!m(e)&&!x(e)&&("array"===n||0===t||"number"==typeof t&&0+~]|"+M+")"+M+"*"),U=new RegExp(M+"|>"),X=new RegExp($),V=new RegExp("^"+I+"$"),G={ID:new RegExp("^#("+I+")"),CLASS:new RegExp("^\\.("+I+")"),TAG:new RegExp("^("+I+"|[*])"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+$),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+R+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\d$/i,K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\([\\da-f]{1,6}"+M+"?|("+M+")|.)","ig"),ne=function(e,t,n){var r="0x"+t-65536;return r!=r||n?t:r<0?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ie=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){T()},ae=be(function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{H.apply(t=O.call(m.childNodes),m.childNodes),t[m.childNodes.length].nodeType}catch(e){H={apply:t.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&((e?e.ownerDocument||e:m)!==C&&T(e),e=e||C,E)){if(11!==p&&(u=Z.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return H.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&d.getElementsByClassName&&e.getElementsByClassName)return H.apply(n,e.getElementsByClassName(i)),n}if(d.qsa&&!A[t+" "]&&(!v||!v.test(t))&&(1!==p||"object"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===p&&U.test(t)){(s=e.getAttribute("id"))?s=s.replace(re,ie):e.setAttribute("id",s=k),o=(l=h(t)).length;while(o--)l[o]="#"+s+" "+xe(l[o]);c=l.join(","),f=ee.test(t)&&ye(e.parentNode)||e}try{return H.apply(n,f.querySelectorAll(c)),n}catch(e){A(t,!0)}finally{s===k&&e.removeAttribute("id")}}}return g(t.replace(B,"$1"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+" ")>b.cacheLength&&delete e[r.shift()],e[t+" "]=n}}function le(e){return e[k]=!0,e}function ce(e){var t=C.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split("|"),r=n.length;while(r--)b.attrHandle[n[r]]=t}function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function de(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===n}}function ge(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(e in d=se.support={},i=se.isXML=function(e){var t=e.namespaceURI,n=(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||"HTML")},T=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:m;return r!==C&&9===r.nodeType&&r.documentElement&&(a=(C=r).documentElement,E=!i(C),m!==C&&(n=C.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",oe,!1):n.attachEvent&&n.attachEvent("onunload",oe)),d.attributes=ce(function(e){return e.className="i",!e.getAttribute("className")}),d.getElementsByTagName=ce(function(e){return e.appendChild(C.createComment("")),!e.getElementsByTagName("*").length}),d.getElementsByClassName=K.test(C.getElementsByClassName),d.getById=ce(function(e){return a.appendChild(e).id=k,!C.getElementsByName||!C.getElementsByName(k).length}),d.getById?(b.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):d.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},b.find.CLASS=d.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(d.qsa=K.test(C.querySelectorAll))&&(ce(function(e){a.appendChild(e).innerHTML="",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+M+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\["+M+"*(?:value|"+R+")"),e.querySelectorAll("[id~="+k+"-]").length||v.push("~="),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+k+"+*").length||v.push(".#.+[+~]")}),ce(function(e){e.innerHTML="";var t=C.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name"+M+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")})),(d.matchesSelector=K.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){d.disconnectedMatch=c.call(e,"*"),c.call(e,"[s!='']:x"),s.push("!=",$)}),v=v.length&&new RegExp(v.join("|")),s=s.length&&new RegExp(s.join("|")),t=K.test(a.compareDocumentPosition),y=t||K.test(a.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},D=t?function(e,t){if(e===t)return l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!d.sortDetached&&t.compareDocumentPosition(e)===n?e===C||e.ownerDocument===m&&y(m,e)?-1:t===C||t.ownerDocument===m&&y(m,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e===C?-1:t===C?1:i?-1:o?1:u?P(u,e)-P(u,t):0;if(i===o)return pe(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?pe(a[r],s[r]):a[r]===m?-1:s[r]===m?1:0}),C},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if((e.ownerDocument||e)!==C&&T(e),d.matchesSelector&&E&&!A[t+" "]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){A(t,!0)}return 0":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||se.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&X.test(n)&&(t=h(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=p[e+" "];return t||(t=new RegExp("(^|"+M+")"+e+"("+M+"|$)"))&&p(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function j(e,n,r){return m(n)?k.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?k.grep(e,function(e){return e===n!==r}):"string"!=typeof n?k.grep(e,function(e){return-1)[^>]*|#([\w-]+))$/;(k.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||q,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:L.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof k?t[0]:t,k.merge(this,k.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:E,!0)),D.test(r[1])&&k.isPlainObject(t))for(r in t)m(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=E.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(k):k.makeArray(e,this)}).prototype=k.fn,q=k(E);var H=/^(?:parents|prev(?:Until|All))/,O={children:!0,contents:!0,next:!0,prev:!0};function P(e,t){while((e=e[t])&&1!==e.nodeType);return e}k.fn.extend({has:function(e){var t=k(e,this),n=t.length;return this.filter(function(){for(var e=0;e\x20\t\r\n\f]*)/i,he=/^$|^module$|\/(?:java|ecma)script/i,ge={option:[1,""],thead:[1,"","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};function ve(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&A(e,t)?k.merge([e],n):n}function ye(e,t){for(var n=0,r=e.length;nx",y.noCloneChecked=!!me.cloneNode(!0).lastChild.defaultValue;var Te=/^key/,Ce=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Ee=/^([^.]*)(?:\.(.+)|)/;function ke(){return!0}function Se(){return!1}function Ne(e,t){return e===function(){try{return E.activeElement}catch(e){}}()==("focus"===t)}function Ae(e,t,n,r,i,o){var a,s;if("object"==typeof t){for(s in"string"!=typeof n&&(r=r||n,n=void 0),t)Ae(e,s,n,r,t[s],o);return e}if(null==r&&null==i?(i=n,r=n=void 0):null==i&&("string"==typeof n?(i=r,r=void 0):(i=r,r=n,n=void 0)),!1===i)i=Se;else if(!i)return e;return 1===o&&(a=i,(i=function(e){return k().off(e),a.apply(this,arguments)}).guid=a.guid||(a.guid=k.guid++)),e.each(function(){k.event.add(this,t,i,r,n)})}function De(e,i,o){o?(Q.set(e,i,!1),k.event.add(e,i,{namespace:!1,handler:function(e){var t,n,r=Q.get(this,i);if(1&e.isTrigger&&this[i]){if(r.length)(k.event.special[i]||{}).delegateType&&e.stopPropagation();else if(r=s.call(arguments),Q.set(this,i,r),t=o(this,i),this[i](),r!==(n=Q.get(this,i))||t?Q.set(this,i,!1):n={},r!==n)return e.stopImmediatePropagation(),e.preventDefault(),n.value}else r.length&&(Q.set(this,i,{value:k.event.trigger(k.extend(r[0],k.Event.prototype),r.slice(1),this)}),e.stopImmediatePropagation())}})):void 0===Q.get(e,i)&&k.event.add(e,i,ke)}k.event={global:{},add:function(t,e,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Q.get(t);if(v){n.handler&&(n=(o=n).handler,i=o.selector),i&&k.find.matchesSelector(ie,i),n.guid||(n.guid=k.guid++),(u=v.events)||(u=v.events={}),(a=v.handle)||(a=v.handle=function(e){return"undefined"!=typeof k&&k.event.triggered!==e.type?k.event.dispatch.apply(t,arguments):void 0}),l=(e=(e||"").match(R)||[""]).length;while(l--)d=g=(s=Ee.exec(e[l])||[])[1],h=(s[2]||"").split(".").sort(),d&&(f=k.event.special[d]||{},d=(i?f.delegateType:f.bindType)||d,f=k.event.special[d]||{},c=k.extend({type:d,origType:g,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&k.expr.match.needsContext.test(i),namespace:h.join(".")},o),(p=u[d])||((p=u[d]=[]).delegateCount=0,f.setup&&!1!==f.setup.call(t,r,h,a)||t.addEventListener&&t.addEventListener(d,a)),f.add&&(f.add.call(t,c),c.handler.guid||(c.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,c):p.push(c),k.event.global[d]=!0)}},remove:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Q.hasData(e)&&Q.get(e);if(v&&(u=v.events)){l=(t=(t||"").match(R)||[""]).length;while(l--)if(d=g=(s=Ee.exec(t[l])||[])[1],h=(s[2]||"").split(".").sort(),d){f=k.event.special[d]||{},p=u[d=(r?f.delegateType:f.bindType)||d]||[],s=s[2]&&new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),a=o=p.length;while(o--)c=p[o],!i&&g!==c.origType||n&&n.guid!==c.guid||s&&!s.test(c.namespace)||r&&r!==c.selector&&("**"!==r||!c.selector)||(p.splice(o,1),c.selector&&p.delegateCount--,f.remove&&f.remove.call(e,c));a&&!p.length&&(f.teardown&&!1!==f.teardown.call(e,h,v.handle)||k.removeEvent(e,d,v.handle),delete u[d])}else for(d in u)k.event.remove(e,d+t[l],n,r,!0);k.isEmptyObject(u)&&Q.remove(e,"handle events")}},dispatch:function(e){var t,n,r,i,o,a,s=k.event.fix(e),u=new Array(arguments.length),l=(Q.get(this,"events")||{})[s.type]||[],c=k.event.special[s.type]||{};for(u[0]=s,t=1;t\x20\t\r\n\f]*)[^>]*)\/>/gi,qe=/\s*$/g;function Oe(e,t){return A(e,"table")&&A(11!==t.nodeType?t:t.firstChild,"tr")&&k(e).children("tbody")[0]||e}function Pe(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function Re(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Me(e,t){var n,r,i,o,a,s,u,l;if(1===t.nodeType){if(Q.hasData(e)&&(o=Q.access(e),a=Q.set(t,o),l=o.events))for(i in delete a.handle,a.events={},l)for(n=0,r=l[i].length;n")},clone:function(e,t,n){var r,i,o,a,s,u,l,c=e.cloneNode(!0),f=oe(e);if(!(y.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||k.isXMLDoc(e)))for(a=ve(c),r=0,i=(o=ve(e)).length;r").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",i=function(e){r.remove(),i=null,e&&t("error"===e.type?404:200,e.type)}),E.head.appendChild(r[0])},abort:function(){i&&i()}}});var Vt,Gt=[],Yt=/(=)\?(?=&|$)|\?\?/;k.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Gt.pop()||k.expando+"_"+kt++;return this[e]=!0,e}}),k.ajaxPrefilter("json jsonp",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Yt.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&Yt.test(e.data)&&"data");if(a||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=m(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Yt,"$1"+r):!1!==e.jsonp&&(e.url+=(St.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return o||k.error(r+" was not called"),o[0]},e.dataTypes[0]="json",i=C[r],C[r]=function(){o=arguments},n.always(function(){void 0===i?k(C).removeProp(r):C[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,Gt.push(r)),o&&m(i)&&i(o[0]),o=i=void 0}),"script"}),y.createHTMLDocument=((Vt=E.implementation.createHTMLDocument("").body).innerHTML="
",2===Vt.childNodes.length),k.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(y.createHTMLDocument?((r=(t=E.implementation.createHTMLDocument("")).createElement("base")).href=E.location.href,t.head.appendChild(r)):t=E),o=!n&&[],(i=D.exec(e))?[t.createElement(i[1])]:(i=we([e],t,o),o&&o.length&&k(o).remove(),k.merge([],i.childNodes)));var r,i,o},k.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return-1").append(k.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},k.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){k.fn[t]=function(e){return this.on(t,e)}}),k.expr.pseudos.animated=function(t){return k.grep(k.timers,function(e){return t===e.elem}).length},k.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=k.css(e,"position"),c=k(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=k.css(e,"top"),u=k.css(e,"left"),("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),m(t)&&(t=t.call(e,n,k.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):c.css(f)}},k.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){k.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===k.css(r,"position"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&"static"===k.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=k(e).offset()).top+=k.css(e,"borderTopWidth",!0),i.left+=k.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-k.css(r,"marginTop",!0),left:t.left-i.left-k.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===k.css(e,"position"))e=e.offsetParent;return e||ie})}}),k.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,i){var o="pageYOffset"===i;k.fn[t]=function(e){return _(this,function(e,t,n){var r;if(x(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),k.each(["top","left"],function(e,n){k.cssHooks[n]=ze(y.pixelPosition,function(e,t){if(t)return t=_e(e,n),$e.test(t)?k(e).position()[n]+"px":t})}),k.each({Height:"height",Width:"width"},function(a,s){k.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){k.fn[o]=function(e,t){var n=arguments.length&&(r||"boolean"!=typeof e),i=r||(!0===e||!0===t?"margin":"border");return _(this,function(e,t,n){var r;return x(e)?0===o.indexOf("outer")?e["inner"+a]:e.document.documentElement["client"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body["scroll"+a],r["scroll"+a],e.body["offset"+a],r["offset"+a],r["client"+a])):void 0===n?k.css(e,t,i):k.style(e,t,n,i)},s,n?e:void 0,n)}})}),k.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,n){k.fn[n]=function(e,t){return 0a;a++)for(i in o[a])n=o[a][i],o[a].hasOwnProperty(i)&&void 0!==n&&(e[i]=t.isPlainObject(n)?t.isPlainObject(e[i])?t.widget.extend({},e[i],n):t.widget.extend({},n):n);return e},t.widget.bridge=function(e,i){var n=i.prototype.widgetFullName||e;t.fn[e]=function(o){var a="string"==typeof o,r=s.call(arguments,1),h=this;return a?this.length||"instance"!==o?this.each(function(){var i,s=t.data(this,n);return"instance"===o?(h=s,!1):s?t.isFunction(s[o])&&"_"!==o.charAt(0)?(i=s[o].apply(s,r),i!==s&&void 0!==i?(h=i&&i.jquery?h.pushStack(i.get()):i,!1):void 0):t.error("no such method '"+o+"' for "+e+" widget instance"):t.error("cannot call methods on "+e+" prior to initialization; "+"attempted to call method '"+o+"'")}):h=void 0:(r.length&&(o=t.widget.extend.apply(null,[o].concat(r))),this.each(function(){var e=t.data(this,n);e?(e.option(o||{}),e._init&&e._init()):t.data(this,n,new i(o,this))})),h}},t.Widget=function(){},t.Widget._childConstructors=[],t.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",defaultElement:"
",options:{classes:{},disabled:!1,create:null},_createWidget:function(e,s){s=t(s||this.defaultElement||this)[0],this.element=t(s),this.uuid=i++,this.eventNamespace="."+this.widgetName+this.uuid,this.bindings=t(),this.hoverable=t(),this.focusable=t(),this.classesElementLookup={},s!==this&&(t.data(s,this.widgetFullName,this),this._on(!0,this.element,{remove:function(t){t.target===s&&this.destroy()}}),this.document=t(s.style?s.ownerDocument:s.document||s),this.window=t(this.document[0].defaultView||this.document[0].parentWindow)),this.options=t.widget.extend({},this.options,this._getCreateOptions(),e),this._create(),this.options.disabled&&this._setOptionDisabled(this.options.disabled),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:t.noop,_create:t.noop,_init:t.noop,destroy:function(){var e=this;this._destroy(),t.each(this.classesElementLookup,function(t,i){e._removeClass(i,t)}),this.element.off(this.eventNamespace).removeData(this.widgetFullName),this.widget().off(this.eventNamespace).removeAttr("aria-disabled"),this.bindings.off(this.eventNamespace)},_destroy:t.noop,widget:function(){return this.element},option:function(e,i){var s,n,o,a=e;if(0===arguments.length)return t.widget.extend({},this.options);if("string"==typeof e)if(a={},s=e.split("."),e=s.shift(),s.length){for(n=a[e]=t.widget.extend({},this.options[e]),o=0;s.length-1>o;o++)n[s[o]]=n[s[o]]||{},n=n[s[o]];if(e=s.pop(),1===arguments.length)return void 0===n[e]?null:n[e];n[e]=i}else{if(1===arguments.length)return void 0===this.options[e]?null:this.options[e];a[e]=i}return this._setOptions(a),this},_setOptions:function(t){var e;for(e in t)this._setOption(e,t[e]);return this},_setOption:function(t,e){return"classes"===t&&this._setOptionClasses(e),this.options[t]=e,"disabled"===t&&this._setOptionDisabled(e),this},_setOptionClasses:function(e){var i,s,n;for(i in e)n=this.classesElementLookup[i],e[i]!==this.options.classes[i]&&n&&n.length&&(s=t(n.get()),this._removeClass(n,i),s.addClass(this._classes({element:s,keys:i,classes:e,add:!0})))},_setOptionDisabled:function(t){this._toggleClass(this.widget(),this.widgetFullName+"-disabled",null,!!t),t&&(this._removeClass(this.hoverable,null,"ui-state-hover"),this._removeClass(this.focusable,null,"ui-state-focus"))},enable:function(){return this._setOptions({disabled:!1})},disable:function(){return this._setOptions({disabled:!0})},_classes:function(e){function i(i,o){var a,r;for(r=0;i.length>r;r++)a=n.classesElementLookup[i[r]]||t(),a=e.add?t(t.unique(a.get().concat(e.element.get()))):t(a.not(e.element).get()),n.classesElementLookup[i[r]]=a,s.push(i[r]),o&&e.classes[i[r]]&&s.push(e.classes[i[r]])}var s=[],n=this;return e=t.extend({element:this.element,classes:this.options.classes||{}},e),this._on(e.element,{remove:"_untrackClassesElement"}),e.keys&&i(e.keys.match(/\S+/g)||[],!0),e.extra&&i(e.extra.match(/\S+/g)||[]),s.join(" ")},_untrackClassesElement:function(e){var i=this;t.each(i.classesElementLookup,function(s,n){-1!==t.inArray(e.target,n)&&(i.classesElementLookup[s]=t(n.not(e.target).get()))})},_removeClass:function(t,e,i){return this._toggleClass(t,e,i,!1)},_addClass:function(t,e,i){return this._toggleClass(t,e,i,!0)},_toggleClass:function(t,e,i,s){s="boolean"==typeof s?s:i;var n="string"==typeof t||null===t,o={extra:n?e:i,keys:n?t:e,element:n?this.element:t,add:s};return o.element.toggleClass(this._classes(o),s),this},_on:function(e,i,s){var n,o=this;"boolean"!=typeof e&&(s=i,i=e,e=!1),s?(i=n=t(i),this.bindings=this.bindings.add(i)):(s=i,i=this.element,n=this.widget()),t.each(s,function(s,a){function r(){return e||o.options.disabled!==!0&&!t(this).hasClass("ui-state-disabled")?("string"==typeof a?o[a]:a).apply(o,arguments):void 0}"string"!=typeof a&&(r.guid=a.guid=a.guid||r.guid||t.guid++);var h=s.match(/^([\w:-]*)\s*(.*)$/),l=h[1]+o.eventNamespace,c=h[2];c?n.on(l,c,r):i.on(l,r)})},_off:function(e,i){i=(i||"").split(" ").join(this.eventNamespace+" ")+this.eventNamespace,e.off(i).off(i),this.bindings=t(this.bindings.not(e).get()),this.focusable=t(this.focusable.not(e).get()),this.hoverable=t(this.hoverable.not(e).get())},_delay:function(t,e){function i(){return("string"==typeof t?s[t]:t).apply(s,arguments)}var s=this;return setTimeout(i,e||0)},_hoverable:function(e){this.hoverable=this.hoverable.add(e),this._on(e,{mouseenter:function(e){this._addClass(t(e.currentTarget),null,"ui-state-hover")},mouseleave:function(e){this._removeClass(t(e.currentTarget),null,"ui-state-hover")}})},_focusable:function(e){this.focusable=this.focusable.add(e),this._on(e,{focusin:function(e){this._addClass(t(e.currentTarget),null,"ui-state-focus")},focusout:function(e){this._removeClass(t(e.currentTarget),null,"ui-state-focus")}})},_trigger:function(e,i,s){var n,o,a=this.options[e];if(s=s||{},i=t.Event(i),i.type=(e===this.widgetEventPrefix?e:this.widgetEventPrefix+e).toLowerCase(),i.target=this.element[0],o=i.originalEvent)for(n in o)n in i||(i[n]=o[n]);return this.element.trigger(i,s),!(t.isFunction(a)&&a.apply(this.element[0],[i].concat(s))===!1||i.isDefaultPrevented())}},t.each({show:"fadeIn",hide:"fadeOut"},function(e,i){t.Widget.prototype["_"+e]=function(s,n,o){"string"==typeof n&&(n={effect:n});var a,r=n?n===!0||"number"==typeof n?i:n.effect||i:e;n=n||{},"number"==typeof n&&(n={duration:n}),a=!t.isEmptyObject(n),n.complete=o,n.delay&&s.delay(n.delay),a&&t.effects&&t.effects.effect[r]?s[e](n):r!==e&&s[r]?s[r](n.duration,n.easing,o):s.queue(function(i){t(this)[e](),o&&o.call(s[0]),i()})}}),t.widget,function(){function e(t,e,i){return[parseFloat(t[0])*(u.test(t[0])?e/100:1),parseFloat(t[1])*(u.test(t[1])?i/100:1)]}function i(e,i){return parseInt(t.css(e,i),10)||0}function s(e){var i=e[0];return 9===i.nodeType?{width:e.width(),height:e.height(),offset:{top:0,left:0}}:t.isWindow(i)?{width:e.width(),height:e.height(),offset:{top:e.scrollTop(),left:e.scrollLeft()}}:i.preventDefault?{width:0,height:0,offset:{top:i.pageY,left:i.pageX}}:{width:e.outerWidth(),height:e.outerHeight(),offset:e.offset()}}var n,o=Math.max,a=Math.abs,r=/left|center|right/,h=/top|center|bottom/,l=/[\+\-]\d+(\.[\d]+)?%?/,c=/^\w+/,u=/%$/,d=t.fn.position;t.position={scrollbarWidth:function(){if(void 0!==n)return n;var e,i,s=t("
"),o=s.children()[0];return t("body").append(s),e=o.offsetWidth,s.css("overflow","scroll"),i=o.offsetWidth,e===i&&(i=s[0].clientWidth),s.remove(),n=e-i},getScrollInfo:function(e){var i=e.isWindow||e.isDocument?"":e.element.css("overflow-x"),s=e.isWindow||e.isDocument?"":e.element.css("overflow-y"),n="scroll"===i||"auto"===i&&e.widthi?"left":e>0?"right":"center",vertical:0>r?"top":s>0?"bottom":"middle"};l>p&&p>a(e+i)&&(u.horizontal="center"),c>f&&f>a(s+r)&&(u.vertical="middle"),u.important=o(a(e),a(i))>o(a(s),a(r))?"horizontal":"vertical",n.using.call(this,t,u)}),h.offset(t.extend(D,{using:r}))})},t.ui.position={fit:{left:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollLeft:s.offset.left,a=s.width,r=t.left-e.collisionPosition.marginLeft,h=n-r,l=r+e.collisionWidth-a-n;e.collisionWidth>a?h>0&&0>=l?(i=t.left+h+e.collisionWidth-a-n,t.left+=h-i):t.left=l>0&&0>=h?n:h>l?n+a-e.collisionWidth:n:h>0?t.left+=h:l>0?t.left-=l:t.left=o(t.left-r,t.left)},top:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollTop:s.offset.top,a=e.within.height,r=t.top-e.collisionPosition.marginTop,h=n-r,l=r+e.collisionHeight-a-n;e.collisionHeight>a?h>0&&0>=l?(i=t.top+h+e.collisionHeight-a-n,t.top+=h-i):t.top=l>0&&0>=h?n:h>l?n+a-e.collisionHeight:n:h>0?t.top+=h:l>0?t.top-=l:t.top=o(t.top-r,t.top)}},flip:{left:function(t,e){var i,s,n=e.within,o=n.offset.left+n.scrollLeft,r=n.width,h=n.isWindow?n.scrollLeft:n.offset.left,l=t.left-e.collisionPosition.marginLeft,c=l-h,u=l+e.collisionWidth-r-h,d="left"===e.my[0]?-e.elemWidth:"right"===e.my[0]?e.elemWidth:0,p="left"===e.at[0]?e.targetWidth:"right"===e.at[0]?-e.targetWidth:0,f=-2*e.offset[0];0>c?(i=t.left+d+p+f+e.collisionWidth-r-o,(0>i||a(c)>i)&&(t.left+=d+p+f)):u>0&&(s=t.left-e.collisionPosition.marginLeft+d+p+f-h,(s>0||u>a(s))&&(t.left+=d+p+f))},top:function(t,e){var i,s,n=e.within,o=n.offset.top+n.scrollTop,r=n.height,h=n.isWindow?n.scrollTop:n.offset.top,l=t.top-e.collisionPosition.marginTop,c=l-h,u=l+e.collisionHeight-r-h,d="top"===e.my[1],p=d?-e.elemHeight:"bottom"===e.my[1]?e.elemHeight:0,f="top"===e.at[1]?e.targetHeight:"bottom"===e.at[1]?-e.targetHeight:0,m=-2*e.offset[1];0>c?(s=t.top+p+f+m+e.collisionHeight-r-o,(0>s||a(c)>s)&&(t.top+=p+f+m)):u>0&&(i=t.top-e.collisionPosition.marginTop+p+f+m-h,(i>0||u>a(i))&&(t.top+=p+f+m))}},flipfit:{left:function(){t.ui.position.flip.left.apply(this,arguments),t.ui.position.fit.left.apply(this,arguments)},top:function(){t.ui.position.flip.top.apply(this,arguments),t.ui.position.fit.top.apply(this,arguments)}}}}(),t.ui.position,t.extend(t.expr[":"],{data:t.expr.createPseudo?t.expr.createPseudo(function(e){return function(i){return!!t.data(i,e)}}):function(e,i,s){return!!t.data(e,s[3])}}),t.fn.extend({disableSelection:function(){var t="onselectstart"in document.createElement("div")?"selectstart":"mousedown";return function(){return this.on(t+".ui-disableSelection",function(t){t.preventDefault()})}}(),enableSelection:function(){return this.off(".ui-disableSelection")}}),t.ui.focusable=function(i,s){var n,o,a,r,h,l=i.nodeName.toLowerCase();return"area"===l?(n=i.parentNode,o=n.name,i.href&&o&&"map"===n.nodeName.toLowerCase()?(a=t("img[usemap='#"+o+"']"),a.length>0&&a.is(":visible")):!1):(/^(input|select|textarea|button|object)$/.test(l)?(r=!i.disabled,r&&(h=t(i).closest("fieldset")[0],h&&(r=!h.disabled))):r="a"===l?i.href||s:s,r&&t(i).is(":visible")&&e(t(i)))},t.extend(t.expr[":"],{focusable:function(e){return t.ui.focusable(e,null!=t.attr(e,"tabindex"))}}),t.ui.focusable,t.fn.form=function(){return"string"==typeof this[0].form?this.closest("form"):t(this[0].form)},t.ui.formResetMixin={_formResetHandler:function(){var e=t(this);setTimeout(function(){var i=e.data("ui-form-reset-instances");t.each(i,function(){this.refresh()})})},_bindFormResetHandler:function(){if(this.form=this.element.form(),this.form.length){var t=this.form.data("ui-form-reset-instances")||[];t.length||this.form.on("reset.ui-form-reset",this._formResetHandler),t.push(this),this.form.data("ui-form-reset-instances",t)}},_unbindFormResetHandler:function(){if(this.form.length){var e=this.form.data("ui-form-reset-instances");e.splice(t.inArray(this,e),1),e.length?this.form.data("ui-form-reset-instances",e):this.form.removeData("ui-form-reset-instances").off("reset.ui-form-reset")}}},"1.7"===t.fn.jquery.substring(0,3)&&(t.each(["Width","Height"],function(e,i){function s(e,i,s,o){return t.each(n,function(){i-=parseFloat(t.css(e,"padding"+this))||0,s&&(i-=parseFloat(t.css(e,"border"+this+"Width"))||0),o&&(i-=parseFloat(t.css(e,"margin"+this))||0)}),i}var n="Width"===i?["Left","Right"]:["Top","Bottom"],o=i.toLowerCase(),a={innerWidth:t.fn.innerWidth,innerHeight:t.fn.innerHeight,outerWidth:t.fn.outerWidth,outerHeight:t.fn.outerHeight};t.fn["inner"+i]=function(e){return void 0===e?a["inner"+i].call(this):this.each(function(){t(this).css(o,s(this,e)+"px")})},t.fn["outer"+i]=function(e,n){return"number"!=typeof e?a["outer"+i].call(this,e):this.each(function(){t(this).css(o,s(this,e,!0,n)+"px")})}}),t.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),t.ui.keyCode={BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38},t.ui.escapeSelector=function(){var t=/([!"#$%&'()*+,./:;<=>?@[\]^`{|}~])/g;return function(e){return e.replace(t,"\\$1")}}(),t.fn.labels=function(){var e,i,s,n,o;return this[0].labels&&this[0].labels.length?this.pushStack(this[0].labels):(n=this.eq(0).parents("label"),s=this.attr("id"),s&&(e=this.eq(0).parents().last(),o=e.add(e.length?e.siblings():this.siblings()),i="label[for='"+t.ui.escapeSelector(s)+"']",n=n.add(o.find(i).addBack(i))),this.pushStack(n))},t.fn.scrollParent=function(e){var i=this.css("position"),s="absolute"===i,n=e?/(auto|scroll|hidden)/:/(auto|scroll)/,o=this.parents().filter(function(){var e=t(this);return s&&"static"===e.css("position")?!1:n.test(e.css("overflow")+e.css("overflow-y")+e.css("overflow-x"))}).eq(0);return"fixed"!==i&&o.length?o:t(this[0].ownerDocument||document)},t.extend(t.expr[":"],{tabbable:function(e){var i=t.attr(e,"tabindex"),s=null!=i;return(!s||i>=0)&&t.ui.focusable(e,s)}}),t.fn.extend({uniqueId:function(){var t=0;return function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++t)})}}(),removeUniqueId:function(){return this.each(function(){/^ui-id-\d+$/.test(this.id)&&t(this).removeAttr("id")})}}),t.ui.ie=!!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase());var n=!1;t(document).on("mouseup",function(){n=!1}),t.widget("ui.mouse",{version:"1.12.1",options:{cancel:"input, textarea, button, select, option",distance:1,delay:0},_mouseInit:function(){var e=this;this.element.on("mousedown."+this.widgetName,function(t){return e._mouseDown(t)}).on("click."+this.widgetName,function(i){return!0===t.data(i.target,e.widgetName+".preventClickEvent")?(t.removeData(i.target,e.widgetName+".preventClickEvent"),i.stopImmediatePropagation(),!1):void 0}),this.started=!1},_mouseDestroy:function(){this.element.off("."+this.widgetName),this._mouseMoveDelegate&&this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate)},_mouseDown:function(e){if(!n){this._mouseMoved=!1,this._mouseStarted&&this._mouseUp(e),this._mouseDownEvent=e;var i=this,s=1===e.which,o="string"==typeof this.options.cancel&&e.target.nodeName?t(e.target).closest(this.options.cancel).length:!1;return s&&!o&&this._mouseCapture(e)?(this.mouseDelayMet=!this.options.delay,this.mouseDelayMet||(this._mouseDelayTimer=setTimeout(function(){i.mouseDelayMet=!0},this.options.delay)),this._mouseDistanceMet(e)&&this._mouseDelayMet(e)&&(this._mouseStarted=this._mouseStart(e)!==!1,!this._mouseStarted)?(e.preventDefault(),!0):(!0===t.data(e.target,this.widgetName+".preventClickEvent")&&t.removeData(e.target,this.widgetName+".preventClickEvent"),this._mouseMoveDelegate=function(t){return i._mouseMove(t)},this._mouseUpDelegate=function(t){return i._mouseUp(t)},this.document.on("mousemove."+this.widgetName,this._mouseMoveDelegate).on("mouseup."+this.widgetName,this._mouseUpDelegate),e.preventDefault(),n=!0,!0)):!0}},_mouseMove:function(e){if(this._mouseMoved){if(t.ui.ie&&(!document.documentMode||9>document.documentMode)&&!e.button)return this._mouseUp(e);if(!e.which)if(e.originalEvent.altKey||e.originalEvent.ctrlKey||e.originalEvent.metaKey||e.originalEvent.shiftKey)this.ignoreMissingWhich=!0;else if(!this.ignoreMissingWhich)return this._mouseUp(e)}return(e.which||e.button)&&(this._mouseMoved=!0),this._mouseStarted?(this._mouseDrag(e),e.preventDefault()):(this._mouseDistanceMet(e)&&this._mouseDelayMet(e)&&(this._mouseStarted=this._mouseStart(this._mouseDownEvent,e)!==!1,this._mouseStarted?this._mouseDrag(e):this._mouseUp(e)),!this._mouseStarted)},_mouseUp:function(e){this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate),this._mouseStarted&&(this._mouseStarted=!1,e.target===this._mouseDownEvent.target&&t.data(e.target,this.widgetName+".preventClickEvent",!0),this._mouseStop(e)),this._mouseDelayTimer&&(clearTimeout(this._mouseDelayTimer),delete this._mouseDelayTimer),this.ignoreMissingWhich=!1,n=!1,e.preventDefault()},_mouseDistanceMet:function(t){return Math.max(Math.abs(this._mouseDownEvent.pageX-t.pageX),Math.abs(this._mouseDownEvent.pageY-t.pageY))>=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return!0}}),t.ui.plugin={add:function(e,i,s){var n,o=t.ui[e].prototype;for(n in s)o.plugins[n]=o.plugins[n]||[],o.plugins[n].push([i,s[n]])},call:function(t,e,i,s){var n,o=t.plugins[e];if(o&&(s||t.element[0].parentNode&&11!==t.element[0].parentNode.nodeType))for(n=0;o.length>n;n++)t.options[o[n][0]]&&o[n][1].apply(t.element,i)}},t.widget("ui.resizable",t.ui.mouse,{version:"1.12.1",widgetEventPrefix:"resize",options:{alsoResize:!1,animate:!1,animateDuration:"slow",animateEasing:"swing",aspectRatio:!1,autoHide:!1,classes:{"ui-resizable-se":"ui-icon ui-icon-gripsmall-diagonal-se"},containment:!1,ghost:!1,grid:!1,handles:"e,s,se",helper:!1,maxHeight:null,maxWidth:null,minHeight:10,minWidth:10,zIndex:90,resize:null,start:null,stop:null},_num:function(t){return parseFloat(t)||0},_isNumber:function(t){return!isNaN(parseFloat(t))},_hasScroll:function(e,i){if("hidden"===t(e).css("overflow"))return!1;var s=i&&"left"===i?"scrollLeft":"scrollTop",n=!1;return e[s]>0?!0:(e[s]=1,n=e[s]>0,e[s]=0,n)},_create:function(){var e,i=this.options,s=this;this._addClass("ui-resizable"),t.extend(this,{_aspectRatio:!!i.aspectRatio,aspectRatio:i.aspectRatio,originalElement:this.element,_proportionallyResizeElements:[],_helper:i.helper||i.ghost||i.animate?i.helper||"ui-resizable-helper":null}),this.element[0].nodeName.match(/^(canvas|textarea|input|select|button|img)$/i)&&(this.element.wrap(t("
").css({position:this.element.css("position"),width:this.element.outerWidth(),height:this.element.outerHeight(),top:this.element.css("top"),left:this.element.css("left")})),this.element=this.element.parent().data("ui-resizable",this.element.resizable("instance")),this.elementIsWrapper=!0,e={marginTop:this.originalElement.css("marginTop"),marginRight:this.originalElement.css("marginRight"),marginBottom:this.originalElement.css("marginBottom"),marginLeft:this.originalElement.css("marginLeft")},this.element.css(e),this.originalElement.css("margin",0),this.originalResizeStyle=this.originalElement.css("resize"),this.originalElement.css("resize","none"),this._proportionallyResizeElements.push(this.originalElement.css({position:"static",zoom:1,display:"block"})),this.originalElement.css(e),this._proportionallyResize()),this._setupHandles(),i.autoHide&&t(this.element).on("mouseenter",function(){i.disabled||(s._removeClass("ui-resizable-autohide"),s._handles.show())}).on("mouseleave",function(){i.disabled||s.resizing||(s._addClass("ui-resizable-autohide"),s._handles.hide())}),this._mouseInit()},_destroy:function(){this._mouseDestroy();var e,i=function(e){t(e).removeData("resizable").removeData("ui-resizable").off(".resizable").find(".ui-resizable-handle").remove()};return this.elementIsWrapper&&(i(this.element),e=this.element,this.originalElement.css({position:e.css("position"),width:e.outerWidth(),height:e.outerHeight(),top:e.css("top"),left:e.css("left")}).insertAfter(e),e.remove()),this.originalElement.css("resize",this.originalResizeStyle),i(this.originalElement),this},_setOption:function(t,e){switch(this._super(t,e),t){case"handles":this._removeHandles(),this._setupHandles();break;default:}},_setupHandles:function(){var e,i,s,n,o,a=this.options,r=this;if(this.handles=a.handles||(t(".ui-resizable-handle",this.element).length?{n:".ui-resizable-n",e:".ui-resizable-e",s:".ui-resizable-s",w:".ui-resizable-w",se:".ui-resizable-se",sw:".ui-resizable-sw",ne:".ui-resizable-ne",nw:".ui-resizable-nw"}:"e,s,se"),this._handles=t(),this.handles.constructor===String)for("all"===this.handles&&(this.handles="n,e,s,w,se,sw,ne,nw"),s=this.handles.split(","),this.handles={},i=0;s.length>i;i++)e=t.trim(s[i]),n="ui-resizable-"+e,o=t("
"),this._addClass(o,"ui-resizable-handle "+n),o.css({zIndex:a.zIndex}),this.handles[e]=".ui-resizable-"+e,this.element.append(o);this._renderAxis=function(e){var i,s,n,o;e=e||this.element;for(i in this.handles)this.handles[i].constructor===String?this.handles[i]=this.element.children(this.handles[i]).first().show():(this.handles[i].jquery||this.handles[i].nodeType)&&(this.handles[i]=t(this.handles[i]),this._on(this.handles[i],{mousedown:r._mouseDown})),this.elementIsWrapper&&this.originalElement[0].nodeName.match(/^(textarea|input|select|button)$/i)&&(s=t(this.handles[i],this.element),o=/sw|ne|nw|se|n|s/.test(i)?s.outerHeight():s.outerWidth(),n=["padding",/ne|nw|n/.test(i)?"Top":/se|sw|s/.test(i)?"Bottom":/^e$/.test(i)?"Right":"Left"].join(""),e.css(n,o),this._proportionallyResize()),this._handles=this._handles.add(this.handles[i])},this._renderAxis(this.element),this._handles=this._handles.add(this.element.find(".ui-resizable-handle")),this._handles.disableSelection(),this._handles.on("mouseover",function(){r.resizing||(this.className&&(o=this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i)),r.axis=o&&o[1]?o[1]:"se")}),a.autoHide&&(this._handles.hide(),this._addClass("ui-resizable-autohide"))},_removeHandles:function(){this._handles.remove()},_mouseCapture:function(e){var i,s,n=!1;for(i in this.handles)s=t(this.handles[i])[0],(s===e.target||t.contains(s,e.target))&&(n=!0);return!this.options.disabled&&n},_mouseStart:function(e){var i,s,n,o=this.options,a=this.element;return this.resizing=!0,this._renderProxy(),i=this._num(this.helper.css("left")),s=this._num(this.helper.css("top")),o.containment&&(i+=t(o.containment).scrollLeft()||0,s+=t(o.containment).scrollTop()||0),this.offset=this.helper.offset(),this.position={left:i,top:s},this.size=this._helper?{width:this.helper.width(),height:this.helper.height()}:{width:a.width(),height:a.height()},this.originalSize=this._helper?{width:a.outerWidth(),height:a.outerHeight()}:{width:a.width(),height:a.height()},this.sizeDiff={width:a.outerWidth()-a.width(),height:a.outerHeight()-a.height()},this.originalPosition={left:i,top:s},this.originalMousePosition={left:e.pageX,top:e.pageY},this.aspectRatio="number"==typeof o.aspectRatio?o.aspectRatio:this.originalSize.width/this.originalSize.height||1,n=t(".ui-resizable-"+this.axis).css("cursor"),t("body").css("cursor","auto"===n?this.axis+"-resize":n),this._addClass("ui-resizable-resizing"),this._propagate("start",e),!0},_mouseDrag:function(e){var i,s,n=this.originalMousePosition,o=this.axis,a=e.pageX-n.left||0,r=e.pageY-n.top||0,h=this._change[o];return this._updatePrevProperties(),h?(i=h.apply(this,[e,a,r]),this._updateVirtualBoundaries(e.shiftKey),(this._aspectRatio||e.shiftKey)&&(i=this._updateRatio(i,e)),i=this._respectSize(i,e),this._updateCache(i),this._propagate("resize",e),s=this._applyChanges(),!this._helper&&this._proportionallyResizeElements.length&&this._proportionallyResize(),t.isEmptyObject(s)||(this._updatePrevProperties(),this._trigger("resize",e,this.ui()),this._applyChanges()),!1):!1},_mouseStop:function(e){this.resizing=!1;var i,s,n,o,a,r,h,l=this.options,c=this;return this._helper&&(i=this._proportionallyResizeElements,s=i.length&&/textarea/i.test(i[0].nodeName),n=s&&this._hasScroll(i[0],"left")?0:c.sizeDiff.height,o=s?0:c.sizeDiff.width,a={width:c.helper.width()-o,height:c.helper.height()-n},r=parseFloat(c.element.css("left"))+(c.position.left-c.originalPosition.left)||null,h=parseFloat(c.element.css("top"))+(c.position.top-c.originalPosition.top)||null,l.animate||this.element.css(t.extend(a,{top:h,left:r})),c.helper.height(c.size.height),c.helper.width(c.size.width),this._helper&&!l.animate&&this._proportionallyResize()),t("body").css("cursor","auto"),this._removeClass("ui-resizable-resizing"),this._propagate("stop",e),this._helper&&this.helper.remove(),!1},_updatePrevProperties:function(){this.prevPosition={top:this.position.top,left:this.position.left},this.prevSize={width:this.size.width,height:this.size.height}},_applyChanges:function(){var t={};return this.position.top!==this.prevPosition.top&&(t.top=this.position.top+"px"),this.position.left!==this.prevPosition.left&&(t.left=this.position.left+"px"),this.size.width!==this.prevSize.width&&(t.width=this.size.width+"px"),this.size.height!==this.prevSize.height&&(t.height=this.size.height+"px"),this.helper.css(t),t},_updateVirtualBoundaries:function(t){var e,i,s,n,o,a=this.options;o={minWidth:this._isNumber(a.minWidth)?a.minWidth:0,maxWidth:this._isNumber(a.maxWidth)?a.maxWidth:1/0,minHeight:this._isNumber(a.minHeight)?a.minHeight:0,maxHeight:this._isNumber(a.maxHeight)?a.maxHeight:1/0},(this._aspectRatio||t)&&(e=o.minHeight*this.aspectRatio,s=o.minWidth/this.aspectRatio,i=o.maxHeight*this.aspectRatio,n=o.maxWidth/this.aspectRatio,e>o.minWidth&&(o.minWidth=e),s>o.minHeight&&(o.minHeight=s),o.maxWidth>i&&(o.maxWidth=i),o.maxHeight>n&&(o.maxHeight=n)),this._vBoundaries=o},_updateCache:function(t){this.offset=this.helper.offset(),this._isNumber(t.left)&&(this.position.left=t.left),this._isNumber(t.top)&&(this.position.top=t.top),this._isNumber(t.height)&&(this.size.height=t.height),this._isNumber(t.width)&&(this.size.width=t.width)},_updateRatio:function(t){var e=this.position,i=this.size,s=this.axis;return this._isNumber(t.height)?t.width=t.height*this.aspectRatio:this._isNumber(t.width)&&(t.height=t.width/this.aspectRatio),"sw"===s&&(t.left=e.left+(i.width-t.width),t.top=null),"nw"===s&&(t.top=e.top+(i.height-t.height),t.left=e.left+(i.width-t.width)),t},_respectSize:function(t){var e=this._vBoundaries,i=this.axis,s=this._isNumber(t.width)&&e.maxWidth&&e.maxWidtht.width,a=this._isNumber(t.height)&&e.minHeight&&e.minHeight>t.height,r=this.originalPosition.left+this.originalSize.width,h=this.originalPosition.top+this.originalSize.height,l=/sw|nw|w/.test(i),c=/nw|ne|n/.test(i);return o&&(t.width=e.minWidth),a&&(t.height=e.minHeight),s&&(t.width=e.maxWidth),n&&(t.height=e.maxHeight),o&&l&&(t.left=r-e.minWidth),s&&l&&(t.left=r-e.maxWidth),a&&c&&(t.top=h-e.minHeight),n&&c&&(t.top=h-e.maxHeight),t.width||t.height||t.left||!t.top?t.width||t.height||t.top||!t.left||(t.left=null):t.top=null,t},_getPaddingPlusBorderDimensions:function(t){for(var e=0,i=[],s=[t.css("borderTopWidth"),t.css("borderRightWidth"),t.css("borderBottomWidth"),t.css("borderLeftWidth")],n=[t.css("paddingTop"),t.css("paddingRight"),t.css("paddingBottom"),t.css("paddingLeft")];4>e;e++)i[e]=parseFloat(s[e])||0,i[e]+=parseFloat(n[e])||0;return{height:i[0]+i[2],width:i[1]+i[3]}},_proportionallyResize:function(){if(this._proportionallyResizeElements.length)for(var t,e=0,i=this.helper||this.element;this._proportionallyResizeElements.length>e;e++)t=this._proportionallyResizeElements[e],this.outerDimensions||(this.outerDimensions=this._getPaddingPlusBorderDimensions(t)),t.css({height:i.height()-this.outerDimensions.height||0,width:i.width()-this.outerDimensions.width||0})},_renderProxy:function(){var e=this.element,i=this.options;this.elementOffset=e.offset(),this._helper?(this.helper=this.helper||t("
"),this._addClass(this.helper,this._helper),this.helper.css({width:this.element.outerWidth(),height:this.element.outerHeight(),position:"absolute",left:this.elementOffset.left+"px",top:this.elementOffset.top+"px",zIndex:++i.zIndex}),this.helper.appendTo("body").disableSelection()):this.helper=this.element +},_change:{e:function(t,e){return{width:this.originalSize.width+e}},w:function(t,e){var i=this.originalSize,s=this.originalPosition;return{left:s.left+e,width:i.width-e}},n:function(t,e,i){var s=this.originalSize,n=this.originalPosition;return{top:n.top+i,height:s.height-i}},s:function(t,e,i){return{height:this.originalSize.height+i}},se:function(e,i,s){return t.extend(this._change.s.apply(this,arguments),this._change.e.apply(this,[e,i,s]))},sw:function(e,i,s){return t.extend(this._change.s.apply(this,arguments),this._change.w.apply(this,[e,i,s]))},ne:function(e,i,s){return t.extend(this._change.n.apply(this,arguments),this._change.e.apply(this,[e,i,s]))},nw:function(e,i,s){return t.extend(this._change.n.apply(this,arguments),this._change.w.apply(this,[e,i,s]))}},_propagate:function(e,i){t.ui.plugin.call(this,e,[i,this.ui()]),"resize"!==e&&this._trigger(e,i,this.ui())},plugins:{},ui:function(){return{originalElement:this.originalElement,element:this.element,helper:this.helper,position:this.position,size:this.size,originalSize:this.originalSize,originalPosition:this.originalPosition}}}),t.ui.plugin.add("resizable","animate",{stop:function(e){var i=t(this).resizable("instance"),s=i.options,n=i._proportionallyResizeElements,o=n.length&&/textarea/i.test(n[0].nodeName),a=o&&i._hasScroll(n[0],"left")?0:i.sizeDiff.height,r=o?0:i.sizeDiff.width,h={width:i.size.width-r,height:i.size.height-a},l=parseFloat(i.element.css("left"))+(i.position.left-i.originalPosition.left)||null,c=parseFloat(i.element.css("top"))+(i.position.top-i.originalPosition.top)||null;i.element.animate(t.extend(h,c&&l?{top:c,left:l}:{}),{duration:s.animateDuration,easing:s.animateEasing,step:function(){var s={width:parseFloat(i.element.css("width")),height:parseFloat(i.element.css("height")),top:parseFloat(i.element.css("top")),left:parseFloat(i.element.css("left"))};n&&n.length&&t(n[0]).css({width:s.width,height:s.height}),i._updateCache(s),i._propagate("resize",e)}})}}),t.ui.plugin.add("resizable","containment",{start:function(){var e,i,s,n,o,a,r,h=t(this).resizable("instance"),l=h.options,c=h.element,u=l.containment,d=u instanceof t?u.get(0):/parent/.test(u)?c.parent().get(0):u;d&&(h.containerElement=t(d),/document/.test(u)||u===document?(h.containerOffset={left:0,top:0},h.containerPosition={left:0,top:0},h.parentData={element:t(document),left:0,top:0,width:t(document).width(),height:t(document).height()||document.body.parentNode.scrollHeight}):(e=t(d),i=[],t(["Top","Right","Left","Bottom"]).each(function(t,s){i[t]=h._num(e.css("padding"+s))}),h.containerOffset=e.offset(),h.containerPosition=e.position(),h.containerSize={height:e.innerHeight()-i[3],width:e.innerWidth()-i[1]},s=h.containerOffset,n=h.containerSize.height,o=h.containerSize.width,a=h._hasScroll(d,"left")?d.scrollWidth:o,r=h._hasScroll(d)?d.scrollHeight:n,h.parentData={element:d,left:s.left,top:s.top,width:a,height:r}))},resize:function(e){var i,s,n,o,a=t(this).resizable("instance"),r=a.options,h=a.containerOffset,l=a.position,c=a._aspectRatio||e.shiftKey,u={top:0,left:0},d=a.containerElement,p=!0;d[0]!==document&&/static/.test(d.css("position"))&&(u=h),l.left<(a._helper?h.left:0)&&(a.size.width=a.size.width+(a._helper?a.position.left-h.left:a.position.left-u.left),c&&(a.size.height=a.size.width/a.aspectRatio,p=!1),a.position.left=r.helper?h.left:0),l.top<(a._helper?h.top:0)&&(a.size.height=a.size.height+(a._helper?a.position.top-h.top:a.position.top),c&&(a.size.width=a.size.height*a.aspectRatio,p=!1),a.position.top=a._helper?h.top:0),n=a.containerElement.get(0)===a.element.parent().get(0),o=/relative|absolute/.test(a.containerElement.css("position")),n&&o?(a.offset.left=a.parentData.left+a.position.left,a.offset.top=a.parentData.top+a.position.top):(a.offset.left=a.element.offset().left,a.offset.top=a.element.offset().top),i=Math.abs(a.sizeDiff.width+(a._helper?a.offset.left-u.left:a.offset.left-h.left)),s=Math.abs(a.sizeDiff.height+(a._helper?a.offset.top-u.top:a.offset.top-h.top)),i+a.size.width>=a.parentData.width&&(a.size.width=a.parentData.width-i,c&&(a.size.height=a.size.width/a.aspectRatio,p=!1)),s+a.size.height>=a.parentData.height&&(a.size.height=a.parentData.height-s,c&&(a.size.width=a.size.height*a.aspectRatio,p=!1)),p||(a.position.left=a.prevPosition.left,a.position.top=a.prevPosition.top,a.size.width=a.prevSize.width,a.size.height=a.prevSize.height)},stop:function(){var e=t(this).resizable("instance"),i=e.options,s=e.containerOffset,n=e.containerPosition,o=e.containerElement,a=t(e.helper),r=a.offset(),h=a.outerWidth()-e.sizeDiff.width,l=a.outerHeight()-e.sizeDiff.height;e._helper&&!i.animate&&/relative/.test(o.css("position"))&&t(this).css({left:r.left-n.left-s.left,width:h,height:l}),e._helper&&!i.animate&&/static/.test(o.css("position"))&&t(this).css({left:r.left-n.left-s.left,width:h,height:l})}}),t.ui.plugin.add("resizable","alsoResize",{start:function(){var e=t(this).resizable("instance"),i=e.options;t(i.alsoResize).each(function(){var e=t(this);e.data("ui-resizable-alsoresize",{width:parseFloat(e.width()),height:parseFloat(e.height()),left:parseFloat(e.css("left")),top:parseFloat(e.css("top"))})})},resize:function(e,i){var s=t(this).resizable("instance"),n=s.options,o=s.originalSize,a=s.originalPosition,r={height:s.size.height-o.height||0,width:s.size.width-o.width||0,top:s.position.top-a.top||0,left:s.position.left-a.left||0};t(n.alsoResize).each(function(){var e=t(this),s=t(this).data("ui-resizable-alsoresize"),n={},o=e.parents(i.originalElement[0]).length?["width","height"]:["width","height","top","left"];t.each(o,function(t,e){var i=(s[e]||0)+(r[e]||0);i&&i>=0&&(n[e]=i||null)}),e.css(n)})},stop:function(){t(this).removeData("ui-resizable-alsoresize")}}),t.ui.plugin.add("resizable","ghost",{start:function(){var e=t(this).resizable("instance"),i=e.size;e.ghost=e.originalElement.clone(),e.ghost.css({opacity:.25,display:"block",position:"relative",height:i.height,width:i.width,margin:0,left:0,top:0}),e._addClass(e.ghost,"ui-resizable-ghost"),t.uiBackCompat!==!1&&"string"==typeof e.options.ghost&&e.ghost.addClass(this.options.ghost),e.ghost.appendTo(e.helper)},resize:function(){var e=t(this).resizable("instance");e.ghost&&e.ghost.css({position:"relative",height:e.size.height,width:e.size.width})},stop:function(){var e=t(this).resizable("instance");e.ghost&&e.helper&&e.helper.get(0).removeChild(e.ghost.get(0))}}),t.ui.plugin.add("resizable","grid",{resize:function(){var e,i=t(this).resizable("instance"),s=i.options,n=i.size,o=i.originalSize,a=i.originalPosition,r=i.axis,h="number"==typeof s.grid?[s.grid,s.grid]:s.grid,l=h[0]||1,c=h[1]||1,u=Math.round((n.width-o.width)/l)*l,d=Math.round((n.height-o.height)/c)*c,p=o.width+u,f=o.height+d,m=s.maxWidth&&p>s.maxWidth,g=s.maxHeight&&f>s.maxHeight,_=s.minWidth&&s.minWidth>p,v=s.minHeight&&s.minHeight>f;s.grid=h,_&&(p+=l),v&&(f+=c),m&&(p-=l),g&&(f-=c),/^(se|s|e)$/.test(r)?(i.size.width=p,i.size.height=f):/^(ne)$/.test(r)?(i.size.width=p,i.size.height=f,i.position.top=a.top-d):/^(sw)$/.test(r)?(i.size.width=p,i.size.height=f,i.position.left=a.left-u):((0>=f-c||0>=p-l)&&(e=i._getPaddingPlusBorderDimensions(this)),f-c>0?(i.size.height=f,i.position.top=a.top-d):(f=c-e.height,i.size.height=f,i.position.top=a.top+o.height-f),p-l>0?(i.size.width=p,i.position.left=a.left-u):(p=l-e.width,i.size.width=p,i.position.left=a.left+o.width-p))}}),t.ui.resizable});/** + * Copyright (c) 2007 Ariel Flesler - aflesler ○ gmail • com | https://github.com/flesler + * Licensed under MIT + * @author Ariel Flesler + * @version 2.1.2 + */ +;(function(f){"use strict";"function"===typeof define&&define.amd?define(["jquery"],f):"undefined"!==typeof module&&module.exports?module.exports=f(require("jquery")):f(jQuery)})(function($){"use strict";function n(a){return!a.nodeName||-1!==$.inArray(a.nodeName.toLowerCase(),["iframe","#document","html","body"])}function h(a){return $.isFunction(a)||$.isPlainObject(a)?a:{top:a,left:a}}var p=$.scrollTo=function(a,d,b){return $(window).scrollTo(a,d,b)};p.defaults={axis:"xy",duration:0,limit:!0};$.fn.scrollTo=function(a,d,b){"object"=== typeof d&&(b=d,d=0);"function"===typeof b&&(b={onAfter:b});"max"===a&&(a=9E9);b=$.extend({},p.defaults,b);d=d||b.duration;var u=b.queue&&1=f[g]?0:Math.min(f[g],n));!a&&1-1){targetElements.on(evt+EVENT_NAMESPACE,function elementToggle(event){$.powerTip.toggle(this,event)})}else{targetElements.on(evt+EVENT_NAMESPACE,function elementOpen(event){$.powerTip.show(this,event)})}});$.each(options.closeEvents,function(idx,evt){if($.inArray(evt,options.openEvents)<0){targetElements.on(evt+EVENT_NAMESPACE,function elementClose(event){$.powerTip.hide(this,!isMouseEvent(event))})}});targetElements.on("keydown"+EVENT_NAMESPACE,function elementKeyDown(event){if(event.keyCode===27){$.powerTip.hide(this,true)}})}return targetElements};$.fn.powerTip.defaults={fadeInTime:200,fadeOutTime:100,followMouse:false,popupId:"powerTip",popupClass:null,intentSensitivity:7,intentPollInterval:100,closeDelay:100,placement:"n",smartPlacement:false,offset:10,mouseOnToPopup:false,manual:false,openEvents:["mouseenter","focus"],closeEvents:["mouseleave","blur"]};$.fn.powerTip.smartPlacementLists={n:["n","ne","nw","s"],e:["e","ne","se","w","nw","sw","n","s","e"],s:["s","se","sw","n"],w:["w","nw","sw","e","ne","se","n","s","w"],nw:["nw","w","sw","n","s","se","nw"],ne:["ne","e","se","n","s","sw","ne"],sw:["sw","w","nw","s","n","ne","sw"],se:["se","e","ne","s","n","nw","se"],"nw-alt":["nw-alt","n","ne-alt","sw-alt","s","se-alt","w","e"],"ne-alt":["ne-alt","n","nw-alt","se-alt","s","sw-alt","e","w"],"sw-alt":["sw-alt","s","se-alt","nw-alt","n","ne-alt","w","e"],"se-alt":["se-alt","s","sw-alt","ne-alt","n","nw-alt","e","w"]};$.powerTip={show:function apiShowTip(element,event){if(isMouseEvent(event)){trackMouse(event);session.previousX=event.pageX;session.previousY=event.pageY;$(element).data(DATA_DISPLAYCONTROLLER).show()}else{$(element).first().data(DATA_DISPLAYCONTROLLER).show(true,true)}return element},reposition:function apiResetPosition(element){$(element).first().data(DATA_DISPLAYCONTROLLER).resetPosition();return element},hide:function apiCloseTip(element,immediate){var displayController;immediate=element?immediate:true;if(element){displayController=$(element).first().data(DATA_DISPLAYCONTROLLER)}else if(session.activeHover){displayController=session.activeHover.data(DATA_DISPLAYCONTROLLER)}if(displayController){displayController.hide(immediate)}return element},toggle:function apiToggle(element,event){if(session.activeHover&&session.activeHover.is(element)){$.powerTip.hide(element,!isMouseEvent(event))}else{$.powerTip.show(element,event)}return element}};$.powerTip.showTip=$.powerTip.show;$.powerTip.closeTip=$.powerTip.hide;function CSSCoordinates(){var me=this;me.top="auto";me.left="auto";me.right="auto";me.bottom="auto";me.set=function(property,value){if($.isNumeric(value)){me[property]=Math.round(value)}}}function DisplayController(element,options,tipController){var hoverTimer=null,myCloseDelay=null;function openTooltip(immediate,forceOpen){cancelTimer();if(!element.data(DATA_HASACTIVEHOVER)){if(!immediate){session.tipOpenImminent=true;hoverTimer=setTimeout(function intentDelay(){hoverTimer=null;checkForIntent()},options.intentPollInterval)}else{if(forceOpen){element.data(DATA_FORCEDOPEN,true)}closeAnyDelayed();tipController.showTip(element)}}else{cancelClose()}}function closeTooltip(disableDelay){if(myCloseDelay){myCloseDelay=session.closeDelayTimeout=clearTimeout(myCloseDelay);session.delayInProgress=false}cancelTimer();session.tipOpenImminent=false;if(element.data(DATA_HASACTIVEHOVER)){element.data(DATA_FORCEDOPEN,false);if(!disableDelay){session.delayInProgress=true;session.closeDelayTimeout=setTimeout(function closeDelay(){session.closeDelayTimeout=null;tipController.hideTip(element);session.delayInProgress=false;myCloseDelay=null},options.closeDelay);myCloseDelay=session.closeDelayTimeout}else{tipController.hideTip(element)}}}function checkForIntent(){var xDifference=Math.abs(session.previousX-session.currentX),yDifference=Math.abs(session.previousY-session.currentY),totalDifference=xDifference+yDifference;if(totalDifference",{id:options.popupId});if($body.length===0){$body=$("body")}$body.append(tipElement);session.tooltips=session.tooltips?session.tooltips.add(tipElement):tipElement}if(options.followMouse){if(!tipElement.data(DATA_HASMOUSEMOVE)){$document.on("mousemove"+EVENT_NAMESPACE,positionTipOnCursor);$window.on("scroll"+EVENT_NAMESPACE,positionTipOnCursor);tipElement.data(DATA_HASMOUSEMOVE,true)}}function beginShowTip(element){element.data(DATA_HASACTIVEHOVER,true);tipElement.queue(function queueTipInit(next){showTip(element);next()})}function showTip(element){var tipContent;if(!element.data(DATA_HASACTIVEHOVER)){return}if(session.isTipOpen){if(!session.isClosing){hideTip(session.activeHover)}tipElement.delay(100).queue(function queueTipAgain(next){showTip(element);next()});return}element.trigger("powerTipPreRender");tipContent=getTooltipContent(element);if(tipContent){tipElement.empty().append(tipContent)}else{return}element.trigger("powerTipRender");session.activeHover=element;session.isTipOpen=true;tipElement.data(DATA_MOUSEONTOTIP,options.mouseOnToPopup);tipElement.addClass(options.popupClass);if(!options.followMouse||element.data(DATA_FORCEDOPEN)){positionTipOnElement(element);session.isFixedTipOpen=true}else{positionTipOnCursor()}if(!element.data(DATA_FORCEDOPEN)&&!options.followMouse){$document.on("click"+EVENT_NAMESPACE,function documentClick(event){var target=event.target;if(target!==element[0]){if(options.mouseOnToPopup){if(target!==tipElement[0]&&!$.contains(tipElement[0],target)){$.powerTip.hide()}}else{$.powerTip.hide()}}})}if(options.mouseOnToPopup&&!options.manual){tipElement.on("mouseenter"+EVENT_NAMESPACE,function tipMouseEnter(){if(session.activeHover){session.activeHover.data(DATA_DISPLAYCONTROLLER).cancel()}});tipElement.on("mouseleave"+EVENT_NAMESPACE,function tipMouseLeave(){if(session.activeHover){session.activeHover.data(DATA_DISPLAYCONTROLLER).hide()}})}tipElement.fadeIn(options.fadeInTime,function fadeInCallback(){if(!session.desyncTimeout){session.desyncTimeout=setInterval(closeDesyncedTip,500)}element.trigger("powerTipOpen")})}function hideTip(element){session.isClosing=true;session.isTipOpen=false;session.desyncTimeout=clearInterval(session.desyncTimeout);element.data(DATA_HASACTIVEHOVER,false);element.data(DATA_FORCEDOPEN,false);$document.off("click"+EVENT_NAMESPACE);tipElement.off(EVENT_NAMESPACE);tipElement.fadeOut(options.fadeOutTime,function fadeOutCallback(){var coords=new CSSCoordinates;session.activeHover=null;session.isClosing=false;session.isFixedTipOpen=false;tipElement.removeClass();coords.set("top",session.currentY+options.offset);coords.set("left",session.currentX+options.offset);tipElement.css(coords);element.trigger("powerTipClose")})}function positionTipOnCursor(){var tipWidth,tipHeight,coords,collisions,collisionCount;if(!session.isFixedTipOpen&&(session.isTipOpen||session.tipOpenImminent&&tipElement.data(DATA_HASMOUSEMOVE))){tipWidth=tipElement.outerWidth();tipHeight=tipElement.outerHeight();coords=new CSSCoordinates;coords.set("top",session.currentY+options.offset);coords.set("left",session.currentX+options.offset);collisions=getViewportCollisions(coords,tipWidth,tipHeight);if(collisions!==Collision.none){collisionCount=countFlags(collisions);if(collisionCount===1){if(collisions===Collision.right){coords.set("left",session.scrollLeft+session.windowWidth-tipWidth)}else if(collisions===Collision.bottom){coords.set("top",session.scrollTop+session.windowHeight-tipHeight)}}else{coords.set("left",session.currentX-tipWidth-options.offset);coords.set("top",session.currentY-tipHeight-options.offset)}}tipElement.css(coords)}}function positionTipOnElement(element){var priorityList,finalPlacement;if(options.smartPlacement||options.followMouse&&element.data(DATA_FORCEDOPEN)){priorityList=$.fn.powerTip.smartPlacementLists[options.placement];$.each(priorityList,function(idx,pos){var collisions=getViewportCollisions(placeTooltip(element,pos),tipElement.outerWidth(),tipElement.outerHeight());finalPlacement=pos;return collisions!==Collision.none})}else{placeTooltip(element,options.placement);finalPlacement=options.placement}tipElement.removeClass("w nw sw e ne se n s w se-alt sw-alt ne-alt nw-alt");tipElement.addClass(finalPlacement)}function placeTooltip(element,placement){var iterationCount=0,tipWidth,tipHeight,coords=new CSSCoordinates;coords.set("top",0);coords.set("left",0);tipElement.css(coords);do{tipWidth=tipElement.outerWidth();tipHeight=tipElement.outerHeight();coords=placementCalculator.compute(element,placement,tipWidth,tipHeight,options.offset);tipElement.css(coords)}while(++iterationCount<=5&&(tipWidth!==tipElement.outerWidth()||tipHeight!==tipElement.outerHeight()));return coords}function closeDesyncedTip(){var isDesynced=false,hasDesyncableCloseEvent=$.grep(["mouseleave","mouseout","blur","focusout"],function(eventType){return $.inArray(eventType,options.closeEvents)!==-1}).length>0;if(session.isTipOpen&&!session.isClosing&&!session.delayInProgress&&hasDesyncableCloseEvent){if(session.activeHover.data(DATA_HASACTIVEHOVER)===false||session.activeHover.is(":disabled")){isDesynced=true}else if(!isMouseOver(session.activeHover)&&!session.activeHover.is(":focus")&&!session.activeHover.data(DATA_FORCEDOPEN)){if(tipElement.data(DATA_MOUSEONTOTIP)){if(!isMouseOver(tipElement)){isDesynced=true}}else{isDesynced=true}}if(isDesynced){hideTip(session.activeHover)}}}this.showTip=beginShowTip;this.hideTip=hideTip;this.resetPosition=positionTipOnElement}function isSvgElement(element){return Boolean(window.SVGElement&&element[0]instanceof SVGElement)}function isMouseEvent(event){return Boolean(event&&$.inArray(event.type,MOUSE_EVENTS)>-1&&typeof event.pageX==="number")}function initTracking(){if(!session.mouseTrackingActive){session.mouseTrackingActive=true;getViewportDimensions();$(getViewportDimensions);$document.on("mousemove"+EVENT_NAMESPACE,trackMouse);$window.on("resize"+EVENT_NAMESPACE,trackResize);$window.on("scroll"+EVENT_NAMESPACE,trackScroll)}}function getViewportDimensions(){session.scrollLeft=$window.scrollLeft();session.scrollTop=$window.scrollTop();session.windowWidth=$window.width();session.windowHeight=$window.height()}function trackResize(){session.windowWidth=$window.width();session.windowHeight=$window.height()}function trackScroll(){var x=$window.scrollLeft(),y=$window.scrollTop();if(x!==session.scrollLeft){session.currentX+=x-session.scrollLeft;session.scrollLeft=x}if(y!==session.scrollTop){session.currentY+=y-session.scrollTop;session.scrollTop=y}}function trackMouse(event){session.currentX=event.pageX;session.currentY=event.pageY}function isMouseOver(element){var elementPosition=element.offset(),elementBox=element[0].getBoundingClientRect(),elementWidth=elementBox.right-elementBox.left,elementHeight=elementBox.bottom-elementBox.top;return session.currentX>=elementPosition.left&&session.currentX<=elementPosition.left+elementWidth&&session.currentY>=elementPosition.top&&session.currentY<=elementPosition.top+elementHeight}function getTooltipContent(element){var tipText=element.data(DATA_POWERTIP),tipObject=element.data(DATA_POWERTIPJQ),tipTarget=element.data(DATA_POWERTIPTARGET),targetElement,content;if(tipText){if($.isFunction(tipText)){tipText=tipText.call(element[0])}content=tipText}else if(tipObject){if($.isFunction(tipObject)){tipObject=tipObject.call(element[0])}if(tipObject.length>0){content=tipObject.clone(true,true)}}else if(tipTarget){targetElement=$("#"+tipTarget);if(targetElement.length>0){content=targetElement.html()}}return content}function getViewportCollisions(coords,elementWidth,elementHeight){var viewportTop=session.scrollTop,viewportLeft=session.scrollLeft,viewportBottom=viewportTop+session.windowHeight,viewportRight=viewportLeft+session.windowWidth,collisions=Collision.none;if(coords.topviewportBottom||Math.abs(coords.bottom-session.windowHeight)>viewportBottom){collisions|=Collision.bottom}if(coords.leftviewportRight){collisions|=Collision.left}if(coords.left+elementWidth>viewportRight||coords.right1)){a.preventDefault();var c=a.originalEvent.changedTouches[0],d=document.createEvent("MouseEvents");d.initMouseEvent(b,!0,!0,window,1,c.screenX,c.screenY,c.clientX,c.clientY,!1,!1,!1,!1,0,null),a.target.dispatchEvent(d)}}if(a.support.touch="ontouchend"in document,a.support.touch){var e,b=a.ui.mouse.prototype,c=b._mouseInit,d=b._mouseDestroy;b._touchStart=function(a){var b=this;!e&&b._mouseCapture(a.originalEvent.changedTouches[0])&&(e=!0,b._touchMoved=!1,f(a,"mouseover"),f(a,"mousemove"),f(a,"mousedown"))},b._touchMove=function(a){e&&(this._touchMoved=!0,f(a,"mousemove"))},b._touchEnd=function(a){e&&(f(a,"mouseup"),f(a,"mouseout"),this._touchMoved||f(a,"click"),e=!1)},b._mouseInit=function(){var b=this;b.element.bind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),c.call(b)},b._mouseDestroy=function(){var b=this;b.element.unbind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),d.call(b)}}}(jQuery);/*! SmartMenus jQuery Plugin - v1.1.0 - September 17, 2017 + * http://www.smartmenus.org/ + * Copyright Vasil Dinkov, Vadikom Web Ltd. http://vadikom.com; Licensed MIT */(function(t){"function"==typeof define&&define.amd?define(["jquery"],t):"object"==typeof module&&"object"==typeof module.exports?module.exports=t(require("jquery")):t(jQuery)})(function($){function initMouseDetection(t){var e=".smartmenus_mouse";if(mouseDetectionEnabled||t)mouseDetectionEnabled&&t&&($(document).off(e),mouseDetectionEnabled=!1);else{var i=!0,s=null,o={mousemove:function(t){var e={x:t.pageX,y:t.pageY,timeStamp:(new Date).getTime()};if(s){var o=Math.abs(s.x-e.x),a=Math.abs(s.y-e.y);if((o>0||a>0)&&2>=o&&2>=a&&300>=e.timeStamp-s.timeStamp&&(mouse=!0,i)){var n=$(t.target).closest("a");n.is("a")&&$.each(menuTrees,function(){return $.contains(this.$root[0],n[0])?(this.itemEnter({currentTarget:n[0]}),!1):void 0}),i=!1}}s=e}};o[touchEvents?"touchstart":"pointerover pointermove pointerout MSPointerOver MSPointerMove MSPointerOut"]=function(t){isTouchEvent(t.originalEvent)&&(mouse=!1)},$(document).on(getEventsNS(o,e)),mouseDetectionEnabled=!0}}function isTouchEvent(t){return!/^(4|mouse)$/.test(t.pointerType)}function getEventsNS(t,e){e||(e="");var i={};for(var s in t)i[s.split(" ").join(e+" ")+e]=t[s];return i}var menuTrees=[],mouse=!1,touchEvents="ontouchstart"in window,mouseDetectionEnabled=!1,requestAnimationFrame=window.requestAnimationFrame||function(t){return setTimeout(t,1e3/60)},cancelAnimationFrame=window.cancelAnimationFrame||function(t){clearTimeout(t)},canAnimate=!!$.fn.animate;return $.SmartMenus=function(t,e){this.$root=$(t),this.opts=e,this.rootId="",this.accessIdPrefix="",this.$subArrow=null,this.activatedItems=[],this.visibleSubMenus=[],this.showTimeout=0,this.hideTimeout=0,this.scrollTimeout=0,this.clickActivated=!1,this.focusActivated=!1,this.zIndexInc=0,this.idInc=0,this.$firstLink=null,this.$firstSub=null,this.disabled=!1,this.$disableOverlay=null,this.$touchScrollingSub=null,this.cssTransforms3d="perspective"in t.style||"webkitPerspective"in t.style,this.wasCollapsible=!1,this.init()},$.extend($.SmartMenus,{hideAll:function(){$.each(menuTrees,function(){this.menuHideAll()})},destroy:function(){for(;menuTrees.length;)menuTrees[0].destroy();initMouseDetection(!0)},prototype:{init:function(t){var e=this;if(!t){menuTrees.push(this),this.rootId=((new Date).getTime()+Math.random()+"").replace(/\D/g,""),this.accessIdPrefix="sm-"+this.rootId+"-",this.$root.hasClass("sm-rtl")&&(this.opts.rightToLeftSubMenus=!0);var i=".smartmenus";this.$root.data("smartmenus",this).attr("data-smartmenus-id",this.rootId).dataSM("level",1).on(getEventsNS({"mouseover focusin":$.proxy(this.rootOver,this),"mouseout focusout":$.proxy(this.rootOut,this),keydown:$.proxy(this.rootKeyDown,this)},i)).on(getEventsNS({mouseenter:$.proxy(this.itemEnter,this),mouseleave:$.proxy(this.itemLeave,this),mousedown:$.proxy(this.itemDown,this),focus:$.proxy(this.itemFocus,this),blur:$.proxy(this.itemBlur,this),click:$.proxy(this.itemClick,this)},i),"a"),i+=this.rootId,this.opts.hideOnClick&&$(document).on(getEventsNS({touchstart:$.proxy(this.docTouchStart,this),touchmove:$.proxy(this.docTouchMove,this),touchend:$.proxy(this.docTouchEnd,this),click:$.proxy(this.docClick,this)},i)),$(window).on(getEventsNS({"resize orientationchange":$.proxy(this.winResize,this)},i)),this.opts.subIndicators&&(this.$subArrow=$("").addClass("sub-arrow"),this.opts.subIndicatorsText&&this.$subArrow.html(this.opts.subIndicatorsText)),initMouseDetection()}if(this.$firstSub=this.$root.find("ul").each(function(){e.menuInit($(this))}).eq(0),this.$firstLink=this.$root.find("a").eq(0),this.opts.markCurrentItem){var s=/(index|default)\.[^#\?\/]*/i,o=/#.*/,a=window.location.href.replace(s,""),n=a.replace(o,"");this.$root.find("a").each(function(){var t=this.href.replace(s,""),i=$(this);(t==a||t==n)&&(i.addClass("current"),e.opts.markCurrentTree&&i.parentsUntil("[data-smartmenus-id]","ul").each(function(){$(this).dataSM("parent-a").addClass("current")}))})}this.wasCollapsible=this.isCollapsible()},destroy:function(t){if(!t){var e=".smartmenus";this.$root.removeData("smartmenus").removeAttr("data-smartmenus-id").removeDataSM("level").off(e),e+=this.rootId,$(document).off(e),$(window).off(e),this.opts.subIndicators&&(this.$subArrow=null)}this.menuHideAll();var i=this;this.$root.find("ul").each(function(){var t=$(this);t.dataSM("scroll-arrows")&&t.dataSM("scroll-arrows").remove(),t.dataSM("shown-before")&&((i.opts.subMenusMinWidth||i.opts.subMenusMaxWidth)&&t.css({width:"",minWidth:"",maxWidth:""}).removeClass("sm-nowrap"),t.dataSM("scroll-arrows")&&t.dataSM("scroll-arrows").remove(),t.css({zIndex:"",top:"",left:"",marginLeft:"",marginTop:"",display:""})),0==(t.attr("id")||"").indexOf(i.accessIdPrefix)&&t.removeAttr("id")}).removeDataSM("in-mega").removeDataSM("shown-before").removeDataSM("scroll-arrows").removeDataSM("parent-a").removeDataSM("level").removeDataSM("beforefirstshowfired").removeAttr("role").removeAttr("aria-hidden").removeAttr("aria-labelledby").removeAttr("aria-expanded"),this.$root.find("a.has-submenu").each(function(){var t=$(this);0==t.attr("id").indexOf(i.accessIdPrefix)&&t.removeAttr("id")}).removeClass("has-submenu").removeDataSM("sub").removeAttr("aria-haspopup").removeAttr("aria-controls").removeAttr("aria-expanded").closest("li").removeDataSM("sub"),this.opts.subIndicators&&this.$root.find("span.sub-arrow").remove(),this.opts.markCurrentItem&&this.$root.find("a.current").removeClass("current"),t||(this.$root=null,this.$firstLink=null,this.$firstSub=null,this.$disableOverlay&&(this.$disableOverlay.remove(),this.$disableOverlay=null),menuTrees.splice($.inArray(this,menuTrees),1))},disable:function(t){if(!this.disabled){if(this.menuHideAll(),!t&&!this.opts.isPopup&&this.$root.is(":visible")){var e=this.$root.offset();this.$disableOverlay=$('
').css({position:"absolute",top:e.top,left:e.left,width:this.$root.outerWidth(),height:this.$root.outerHeight(),zIndex:this.getStartZIndex(!0),opacity:0}).appendTo(document.body)}this.disabled=!0}},docClick:function(t){return this.$touchScrollingSub?(this.$touchScrollingSub=null,void 0):((this.visibleSubMenus.length&&!$.contains(this.$root[0],t.target)||$(t.target).closest("a").length)&&this.menuHideAll(),void 0)},docTouchEnd:function(){if(this.lastTouch){if(!(!this.visibleSubMenus.length||void 0!==this.lastTouch.x2&&this.lastTouch.x1!=this.lastTouch.x2||void 0!==this.lastTouch.y2&&this.lastTouch.y1!=this.lastTouch.y2||this.lastTouch.target&&$.contains(this.$root[0],this.lastTouch.target))){this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0);var t=this;this.hideTimeout=setTimeout(function(){t.menuHideAll()},350)}this.lastTouch=null}},docTouchMove:function(t){if(this.lastTouch){var e=t.originalEvent.touches[0];this.lastTouch.x2=e.pageX,this.lastTouch.y2=e.pageY}},docTouchStart:function(t){var e=t.originalEvent.touches[0];this.lastTouch={x1:e.pageX,y1:e.pageY,target:e.target}},enable:function(){this.disabled&&(this.$disableOverlay&&(this.$disableOverlay.remove(),this.$disableOverlay=null),this.disabled=!1)},getClosestMenu:function(t){for(var e=$(t).closest("ul");e.dataSM("in-mega");)e=e.parent().closest("ul");return e[0]||null},getHeight:function(t){return this.getOffset(t,!0)},getOffset:function(t,e){var i;"none"==t.css("display")&&(i={position:t[0].style.position,visibility:t[0].style.visibility},t.css({position:"absolute",visibility:"hidden"}).show());var s=t[0].getBoundingClientRect&&t[0].getBoundingClientRect(),o=s&&(e?s.height||s.bottom-s.top:s.width||s.right-s.left);return o||0===o||(o=e?t[0].offsetHeight:t[0].offsetWidth),i&&t.hide().css(i),o},getStartZIndex:function(t){var e=parseInt(this[t?"$root":"$firstSub"].css("z-index"));return!t&&isNaN(e)&&(e=parseInt(this.$root.css("z-index"))),isNaN(e)?1:e},getTouchPoint:function(t){return t.touches&&t.touches[0]||t.changedTouches&&t.changedTouches[0]||t},getViewport:function(t){var e=t?"Height":"Width",i=document.documentElement["client"+e],s=window["inner"+e];return s&&(i=Math.min(i,s)),i},getViewportHeight:function(){return this.getViewport(!0)},getViewportWidth:function(){return this.getViewport()},getWidth:function(t){return this.getOffset(t)},handleEvents:function(){return!this.disabled&&this.isCSSOn()},handleItemEvents:function(t){return this.handleEvents()&&!this.isLinkInMegaMenu(t)},isCollapsible:function(){return"static"==this.$firstSub.css("position")},isCSSOn:function(){return"inline"!=this.$firstLink.css("display")},isFixed:function(){var t="fixed"==this.$root.css("position");return t||this.$root.parentsUntil("body").each(function(){return"fixed"==$(this).css("position")?(t=!0,!1):void 0}),t},isLinkInMegaMenu:function(t){return $(this.getClosestMenu(t[0])).hasClass("mega-menu")},isTouchMode:function(){return!mouse||this.opts.noMouseOver||this.isCollapsible()},itemActivate:function(t,e){var i=t.closest("ul"),s=i.dataSM("level");if(s>1&&(!this.activatedItems[s-2]||this.activatedItems[s-2][0]!=i.dataSM("parent-a")[0])){var o=this;$(i.parentsUntil("[data-smartmenus-id]","ul").get().reverse()).add(i).each(function(){o.itemActivate($(this).dataSM("parent-a"))})}if((!this.isCollapsible()||e)&&this.menuHideSubMenus(this.activatedItems[s-1]&&this.activatedItems[s-1][0]==t[0]?s:s-1),this.activatedItems[s-1]=t,this.$root.triggerHandler("activate.smapi",t[0])!==!1){var a=t.dataSM("sub");a&&(this.isTouchMode()||!this.opts.showOnClick||this.clickActivated)&&this.menuShow(a)}},itemBlur:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&this.$root.triggerHandler("blur.smapi",e[0])},itemClick:function(t){var e=$(t.currentTarget);if(this.handleItemEvents(e)){if(this.$touchScrollingSub&&this.$touchScrollingSub[0]==e.closest("ul")[0])return this.$touchScrollingSub=null,t.stopPropagation(),!1;if(this.$root.triggerHandler("click.smapi",e[0])===!1)return!1;var i=$(t.target).is(".sub-arrow"),s=e.dataSM("sub"),o=s?2==s.dataSM("level"):!1,a=this.isCollapsible(),n=/toggle$/.test(this.opts.collapsibleBehavior),r=/link$/.test(this.opts.collapsibleBehavior),h=/^accordion/.test(this.opts.collapsibleBehavior);if(s&&!s.is(":visible")){if((!r||!a||i)&&(this.opts.showOnClick&&o&&(this.clickActivated=!0),this.itemActivate(e,h),s.is(":visible")))return this.focusActivated=!0,!1}else if(a&&(n||i))return this.itemActivate(e,h),this.menuHide(s),n&&(this.focusActivated=!1),!1;return this.opts.showOnClick&&o||e.hasClass("disabled")||this.$root.triggerHandler("select.smapi",e[0])===!1?!1:void 0}},itemDown:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&e.dataSM("mousedown",!0)},itemEnter:function(t){var e=$(t.currentTarget);if(this.handleItemEvents(e)){if(!this.isTouchMode()){this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0);var i=this;this.showTimeout=setTimeout(function(){i.itemActivate(e)},this.opts.showOnClick&&1==e.closest("ul").dataSM("level")?1:this.opts.showTimeout)}this.$root.triggerHandler("mouseenter.smapi",e[0])}},itemFocus:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&(!this.focusActivated||this.isTouchMode()&&e.dataSM("mousedown")||this.activatedItems.length&&this.activatedItems[this.activatedItems.length-1][0]==e[0]||this.itemActivate(e,!0),this.$root.triggerHandler("focus.smapi",e[0]))},itemLeave:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&(this.isTouchMode()||(e[0].blur(),this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0)),e.removeDataSM("mousedown"),this.$root.triggerHandler("mouseleave.smapi",e[0]))},menuHide:function(t){if(this.$root.triggerHandler("beforehide.smapi",t[0])!==!1&&(canAnimate&&t.stop(!0,!0),"none"!=t.css("display"))){var e=function(){t.css("z-index","")};this.isCollapsible()?canAnimate&&this.opts.collapsibleHideFunction?this.opts.collapsibleHideFunction.call(this,t,e):t.hide(this.opts.collapsibleHideDuration,e):canAnimate&&this.opts.hideFunction?this.opts.hideFunction.call(this,t,e):t.hide(this.opts.hideDuration,e),t.dataSM("scroll")&&(this.menuScrollStop(t),t.css({"touch-action":"","-ms-touch-action":"","-webkit-transform":"",transform:""}).off(".smartmenus_scroll").removeDataSM("scroll").dataSM("scroll-arrows").hide()),t.dataSM("parent-a").removeClass("highlighted").attr("aria-expanded","false"),t.attr({"aria-expanded":"false","aria-hidden":"true"});var i=t.dataSM("level");this.activatedItems.splice(i-1,1),this.visibleSubMenus.splice($.inArray(t,this.visibleSubMenus),1),this.$root.triggerHandler("hide.smapi",t[0])}},menuHideAll:function(){this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0);for(var t=this.opts.isPopup?1:0,e=this.visibleSubMenus.length-1;e>=t;e--)this.menuHide(this.visibleSubMenus[e]);this.opts.isPopup&&(canAnimate&&this.$root.stop(!0,!0),this.$root.is(":visible")&&(canAnimate&&this.opts.hideFunction?this.opts.hideFunction.call(this,this.$root):this.$root.hide(this.opts.hideDuration))),this.activatedItems=[],this.visibleSubMenus=[],this.clickActivated=!1,this.focusActivated=!1,this.zIndexInc=0,this.$root.triggerHandler("hideAll.smapi")},menuHideSubMenus:function(t){for(var e=this.activatedItems.length-1;e>=t;e--){var i=this.activatedItems[e].dataSM("sub");i&&this.menuHide(i)}},menuInit:function(t){if(!t.dataSM("in-mega")){t.hasClass("mega-menu")&&t.find("ul").dataSM("in-mega",!0);for(var e=2,i=t[0];(i=i.parentNode.parentNode)!=this.$root[0];)e++;var s=t.prevAll("a").eq(-1);s.length||(s=t.prevAll().find("a").eq(-1)),s.addClass("has-submenu").dataSM("sub",t),t.dataSM("parent-a",s).dataSM("level",e).parent().dataSM("sub",t);var o=s.attr("id")||this.accessIdPrefix+ ++this.idInc,a=t.attr("id")||this.accessIdPrefix+ ++this.idInc;s.attr({id:o,"aria-haspopup":"true","aria-controls":a,"aria-expanded":"false"}),t.attr({id:a,role:"group","aria-hidden":"true","aria-labelledby":o,"aria-expanded":"false"}),this.opts.subIndicators&&s[this.opts.subIndicatorsPos](this.$subArrow.clone())}},menuPosition:function(t){var e,i,s=t.dataSM("parent-a"),o=s.closest("li"),a=o.parent(),n=t.dataSM("level"),r=this.getWidth(t),h=this.getHeight(t),u=s.offset(),l=u.left,c=u.top,d=this.getWidth(s),m=this.getHeight(s),p=$(window),f=p.scrollLeft(),v=p.scrollTop(),b=this.getViewportWidth(),S=this.getViewportHeight(),g=a.parent().is("[data-sm-horizontal-sub]")||2==n&&!a.hasClass("sm-vertical"),M=this.opts.rightToLeftSubMenus&&!o.is("[data-sm-reverse]")||!this.opts.rightToLeftSubMenus&&o.is("[data-sm-reverse]"),w=2==n?this.opts.mainMenuSubOffsetX:this.opts.subMenusSubOffsetX,T=2==n?this.opts.mainMenuSubOffsetY:this.opts.subMenusSubOffsetY;if(g?(e=M?d-r-w:w,i=this.opts.bottomToTopSubMenus?-h-T:m+T):(e=M?w-r:d-w,i=this.opts.bottomToTopSubMenus?m-T-h:T),this.opts.keepInViewport){var y=l+e,I=c+i;if(M&&f>y?e=g?f-y+e:d-w:!M&&y+r>f+b&&(e=g?f+b-r-y+e:w-r),g||(S>h&&I+h>v+S?i+=v+S-h-I:(h>=S||v>I)&&(i+=v-I)),g&&(I+h>v+S+.49||v>I)||!g&&h>S+.49){var x=this;t.dataSM("scroll-arrows")||t.dataSM("scroll-arrows",$([$('')[0],$('')[0]]).on({mouseenter:function(){t.dataSM("scroll").up=$(this).hasClass("scroll-up"),x.menuScroll(t)},mouseleave:function(e){x.menuScrollStop(t),x.menuScrollOut(t,e)},"mousewheel DOMMouseScroll":function(t){t.preventDefault()}}).insertAfter(t));var A=".smartmenus_scroll";if(t.dataSM("scroll",{y:this.cssTransforms3d?0:i-m,step:1,itemH:m,subH:h,arrowDownH:this.getHeight(t.dataSM("scroll-arrows").eq(1))}).on(getEventsNS({mouseover:function(e){x.menuScrollOver(t,e)},mouseout:function(e){x.menuScrollOut(t,e)},"mousewheel DOMMouseScroll":function(e){x.menuScrollMousewheel(t,e)}},A)).dataSM("scroll-arrows").css({top:"auto",left:"0",marginLeft:e+(parseInt(t.css("border-left-width"))||0),width:r-(parseInt(t.css("border-left-width"))||0)-(parseInt(t.css("border-right-width"))||0),zIndex:t.css("z-index")}).eq(g&&this.opts.bottomToTopSubMenus?0:1).show(),this.isFixed()){var C={};C[touchEvents?"touchstart touchmove touchend":"pointerdown pointermove pointerup MSPointerDown MSPointerMove MSPointerUp"]=function(e){x.menuScrollTouch(t,e)},t.css({"touch-action":"none","-ms-touch-action":"none"}).on(getEventsNS(C,A))}}}t.css({top:"auto",left:"0",marginLeft:e,marginTop:i-m})},menuScroll:function(t,e,i){var s,o=t.dataSM("scroll"),a=t.dataSM("scroll-arrows"),n=o.up?o.upEnd:o.downEnd;if(!e&&o.momentum){if(o.momentum*=.92,s=o.momentum,.5>s)return this.menuScrollStop(t),void 0}else s=i||(e||!this.opts.scrollAccelerate?this.opts.scrollStep:Math.floor(o.step));var r=t.dataSM("level");if(this.activatedItems[r-1]&&this.activatedItems[r-1].dataSM("sub")&&this.activatedItems[r-1].dataSM("sub").is(":visible")&&this.menuHideSubMenus(r-1),o.y=o.up&&o.y>=n||!o.up&&n>=o.y?o.y:Math.abs(n-o.y)>s?o.y+(o.up?s:-s):n,t.css(this.cssTransforms3d?{"-webkit-transform":"translate3d(0, "+o.y+"px, 0)",transform:"translate3d(0, "+o.y+"px, 0)"}:{marginTop:o.y}),mouse&&(o.up&&o.y>o.downEnd||!o.up&&o.y0;t.dataSM("scroll-arrows").eq(i?0:1).is(":visible")&&(t.dataSM("scroll").up=i,this.menuScroll(t,!0))}e.preventDefault()},menuScrollOut:function(t,e){mouse&&(/^scroll-(up|down)/.test((e.relatedTarget||"").className)||(t[0]==e.relatedTarget||$.contains(t[0],e.relatedTarget))&&this.getClosestMenu(e.relatedTarget)==t[0]||t.dataSM("scroll-arrows").css("visibility","hidden"))},menuScrollOver:function(t,e){if(mouse&&!/^scroll-(up|down)/.test(e.target.className)&&this.getClosestMenu(e.target)==t[0]){this.menuScrollRefreshData(t);var i=t.dataSM("scroll"),s=$(window).scrollTop()-t.dataSM("parent-a").offset().top-i.itemH;t.dataSM("scroll-arrows").eq(0).css("margin-top",s).end().eq(1).css("margin-top",s+this.getViewportHeight()-i.arrowDownH).end().css("visibility","visible")}},menuScrollRefreshData:function(t){var e=t.dataSM("scroll"),i=$(window).scrollTop()-t.dataSM("parent-a").offset().top-e.itemH;this.cssTransforms3d&&(i=-(parseFloat(t.css("margin-top"))-i)),$.extend(e,{upEnd:i,downEnd:i+this.getViewportHeight()-e.subH})},menuScrollStop:function(t){return this.scrollTimeout?(cancelAnimationFrame(this.scrollTimeout),this.scrollTimeout=0,t.dataSM("scroll").step=1,!0):void 0},menuScrollTouch:function(t,e){if(e=e.originalEvent,isTouchEvent(e)){var i=this.getTouchPoint(e);if(this.getClosestMenu(i.target)==t[0]){var s=t.dataSM("scroll");if(/(start|down)$/i.test(e.type))this.menuScrollStop(t)?(e.preventDefault(),this.$touchScrollingSub=t):this.$touchScrollingSub=null,this.menuScrollRefreshData(t),$.extend(s,{touchStartY:i.pageY,touchStartTime:e.timeStamp});else if(/move$/i.test(e.type)){var o=void 0!==s.touchY?s.touchY:s.touchStartY;if(void 0!==o&&o!=i.pageY){this.$touchScrollingSub=t;var a=i.pageY>o;void 0!==s.up&&s.up!=a&&$.extend(s,{touchStartY:i.pageY,touchStartTime:e.timeStamp}),$.extend(s,{up:a,touchY:i.pageY}),this.menuScroll(t,!0,Math.abs(i.pageY-o))}e.preventDefault()}else void 0!==s.touchY&&((s.momentum=15*Math.pow(Math.abs(i.pageY-s.touchStartY)/(e.timeStamp-s.touchStartTime),2))&&(this.menuScrollStop(t),this.menuScroll(t),e.preventDefault()),delete s.touchY)}}},menuShow:function(t){if((t.dataSM("beforefirstshowfired")||(t.dataSM("beforefirstshowfired",!0),this.$root.triggerHandler("beforefirstshow.smapi",t[0])!==!1))&&this.$root.triggerHandler("beforeshow.smapi",t[0])!==!1&&(t.dataSM("shown-before",!0),canAnimate&&t.stop(!0,!0),!t.is(":visible"))){var e=t.dataSM("parent-a"),i=this.isCollapsible();if((this.opts.keepHighlighted||i)&&e.addClass("highlighted"),i)t.removeClass("sm-nowrap").css({zIndex:"",width:"auto",minWidth:"",maxWidth:"",top:"",left:"",marginLeft:"",marginTop:""});else{if(t.css("z-index",this.zIndexInc=(this.zIndexInc||this.getStartZIndex())+1),(this.opts.subMenusMinWidth||this.opts.subMenusMaxWidth)&&(t.css({width:"auto",minWidth:"",maxWidth:""}).addClass("sm-nowrap"),this.opts.subMenusMinWidth&&t.css("min-width",this.opts.subMenusMinWidth),this.opts.subMenusMaxWidth)){var s=this.getWidth(t);t.css("max-width",this.opts.subMenusMaxWidth),s>this.getWidth(t)&&t.removeClass("sm-nowrap").css("width",this.opts.subMenusMaxWidth)}this.menuPosition(t)}var o=function(){t.css("overflow","")};i?canAnimate&&this.opts.collapsibleShowFunction?this.opts.collapsibleShowFunction.call(this,t,o):t.show(this.opts.collapsibleShowDuration,o):canAnimate&&this.opts.showFunction?this.opts.showFunction.call(this,t,o):t.show(this.opts.showDuration,o),e.attr("aria-expanded","true"),t.attr({"aria-expanded":"true","aria-hidden":"false"}),this.visibleSubMenus.push(t),this.$root.triggerHandler("show.smapi",t[0])}},popupHide:function(t){this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0);var e=this;this.hideTimeout=setTimeout(function(){e.menuHideAll()},t?1:this.opts.hideTimeout)},popupShow:function(t,e){if(!this.opts.isPopup)return alert('SmartMenus jQuery Error:\n\nIf you want to show this menu via the "popupShow" method, set the isPopup:true option.'),void 0;if(this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0),this.$root.dataSM("shown-before",!0),canAnimate&&this.$root.stop(!0,!0),!this.$root.is(":visible")){this.$root.css({left:t,top:e});var i=this,s=function(){i.$root.css("overflow","")};canAnimate&&this.opts.showFunction?this.opts.showFunction.call(this,this.$root,s):this.$root.show(this.opts.showDuration,s),this.visibleSubMenus[0]=this.$root}},refresh:function(){this.destroy(!0),this.init(!0)},rootKeyDown:function(t){if(this.handleEvents())switch(t.keyCode){case 27:var e=this.activatedItems[0];if(e){this.menuHideAll(),e[0].focus();var i=e.dataSM("sub");i&&this.menuHide(i)}break;case 32:var s=$(t.target);if(s.is("a")&&this.handleItemEvents(s)){var i=s.dataSM("sub");i&&!i.is(":visible")&&(this.itemClick({currentTarget:t.target}),t.preventDefault())}}},rootOut:function(t){if(this.handleEvents()&&!this.isTouchMode()&&t.target!=this.$root[0]&&(this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0),!this.opts.showOnClick||!this.opts.hideOnClick)){var e=this;this.hideTimeout=setTimeout(function(){e.menuHideAll()},this.opts.hideTimeout)}},rootOver:function(t){this.handleEvents()&&!this.isTouchMode()&&t.target!=this.$root[0]&&this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0)},winResize:function(t){if(this.handleEvents()){if(!("onorientationchange"in window)||"orientationchange"==t.type){var e=this.isCollapsible();this.wasCollapsible&&e||(this.activatedItems.length&&this.activatedItems[this.activatedItems.length-1][0].blur(),this.menuHideAll()),this.wasCollapsible=e}}else if(this.$disableOverlay){var i=this.$root.offset();this.$disableOverlay.css({top:i.top,left:i.left,width:this.$root.outerWidth(),height:this.$root.outerHeight()})}}}}),$.fn.dataSM=function(t,e){return e?this.data(t+"_smartmenus",e):this.data(t+"_smartmenus")},$.fn.removeDataSM=function(t){return this.removeData(t+"_smartmenus")},$.fn.smartmenus=function(options){if("string"==typeof options){var args=arguments,method=options;return Array.prototype.shift.call(args),this.each(function(){var t=$(this).data("smartmenus");t&&t[method]&&t[method].apply(t,args)})}return this.each(function(){var dataOpts=$(this).data("sm-options")||null;if(dataOpts)try{dataOpts=eval("("+dataOpts+")")}catch(e){dataOpts=null,alert('ERROR\n\nSmartMenus jQuery init:\nInvalid "data-sm-options" attribute value syntax.')}new $.SmartMenus(this,$.extend({},$.fn.smartmenus.defaults,options,dataOpts))})},$.fn.smartmenus.defaults={isPopup:!1,mainMenuSubOffsetX:0,mainMenuSubOffsetY:0,subMenusSubOffsetX:0,subMenusSubOffsetY:0,subMenusMinWidth:"10em",subMenusMaxWidth:"20em",subIndicators:!0,subIndicatorsPos:"append",subIndicatorsText:"",scrollStep:30,scrollAccelerate:!0,showTimeout:250,hideTimeout:500,showDuration:0,showFunction:null,hideDuration:0,hideFunction:function(t,e){t.fadeOut(200,e)},collapsibleShowDuration:0,collapsibleShowFunction:function(t,e){t.slideDown(200,e)},collapsibleHideDuration:0,collapsibleHideFunction:function(t,e){t.slideUp(200,e)},showOnClick:!1,hideOnClick:!0,noMouseOver:!1,keepInViewport:!0,keepHighlighted:!0,markCurrentItem:!1,markCurrentTree:!0,rightToLeftSubMenus:!1,bottomToTopSubMenus:!1,collapsibleBehavior:"default"},$}); \ No newline at end of file diff --git a/listener_8h.html b/listener_8h.html new file mode 100644 index 0000000..e371a5e --- /dev/null +++ b/listener_8h.html @@ -0,0 +1,442 @@ + + + + + + + +libevent: event2/listener.h File Reference + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+ +
+
listener.h File Reference
+
+
+ +

A callback that we invoke when a listener has a new connection. +More...

+
#include <event2/visibility.h>
+#include <event2/event.h>
+
+

Go to the source code of this file.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+Macros

#define LEV_OPT_BIND_IPV4_AND_IPV6   (1u<<9)
 Flag: Indicates that the listener wants to work only in both IPv4 and IPv6 socket. More...
 
#define LEV_OPT_BIND_IPV6ONLY   (1u<<8)
 Flag: Indicates that the listener wants to work only in IPv6 socket. More...
 
+#define LEV_OPT_CLOSE_ON_EXEC   (1u<<2)
 Flag: Indicates that we should set the close-on-exec flag, if possible.
 
+#define LEV_OPT_CLOSE_ON_FREE   (1u<<1)
 Flag: Indicates that freeing the listener should close the underlying socket.
 
#define LEV_OPT_DEFERRED_ACCEPT   (1u<<6)
 Flag: Indicates that the listener should defer accept() until data is available, if possible. More...
 
#define LEV_OPT_DISABLED   (1u<<5)
 Flag: Indicates that the listener should be created in disabled state. More...
 
+#define LEV_OPT_LEAVE_SOCKETS_BLOCKING   (1u<<0)
 Flag: Indicates that we should not make incoming sockets nonblocking before passing them to the callback.
 
+#define LEV_OPT_REUSEABLE   (1u<<3)
 Flag: Indicates that we should disable the timeout (if any) between when this socket is closed and when we can listen again on the same port.
 
#define LEV_OPT_REUSEABLE_PORT   (1u<<7)
 Flag: Indicates that we ask to allow multiple servers (processes or threads) to bind to the same port if they each set the option for incoming connections/datagrams to be distributed evenly across all of the threads (or processes). More...
 
+#define LEV_OPT_THREADSAFE   (1u<<4)
 Flag: Indicates that the listener should be locked so it's safe to use from multiple threadcs at once.
 
+ + + + + + +

+Typedefs

+typedef void(* evconnlistener_cb) (struct evconnlistener *, evutil_socket_t, struct sockaddr *, int socklen, void *)
 
typedef void(* evconnlistener_errorcb) (struct evconnlistener *, void *)
 A callback that we invoke when a listener encounters a non-retriable error. More...
 
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+Functions

+EVENT2_EXPORT_SYMBOL int evconnlistener_disable (struct evconnlistener *lev)
 Stop listening for connections on an evconnlistener.
 
+EVENT2_EXPORT_SYMBOL int evconnlistener_enable (struct evconnlistener *lev)
 Re-enable an evconnlistener that has been disabled.
 
+EVENT2_EXPORT_SYMBOL void evconnlistener_free (struct evconnlistener *lev)
 Disable and deallocate an evconnlistener.
 
+EVENT2_EXPORT_SYMBOL struct event_baseevconnlistener_get_base (struct evconnlistener *lev)
 Return an evconnlistener's associated event_base.
 
+EVENT2_EXPORT_SYMBOL evutil_socket_t evconnlistener_get_fd (struct evconnlistener *lev)
 Return the socket that an evconnlistner is listening on.
 
EVENT2_EXPORT_SYMBOL struct evconnlistener * evconnlistener_new (struct event_base *base, evconnlistener_cb cb, void *ptr, unsigned flags, int backlog, evutil_socket_t fd)
 Allocate a new evconnlistener object to listen for incoming TCP connections on a given file descriptor. More...
 
EVENT2_EXPORT_SYMBOL struct evconnlistener * evconnlistener_new_bind (struct event_base *base, evconnlistener_cb cb, void *ptr, unsigned flags, int backlog, const struct sockaddr *sa, int socklen)
 Allocate a new evconnlistener object to listen for incoming TCP connections on a given address. More...
 
+EVENT2_EXPORT_SYMBOL void evconnlistener_set_cb (struct evconnlistener *lev, evconnlistener_cb cb, void *arg)
 Change the callback on the listener to cb and its user_data to arg.
 
+EVENT2_EXPORT_SYMBOL void evconnlistener_set_error_cb (struct evconnlistener *lev, evconnlistener_errorcb errorcb)
 Set an evconnlistener's error callback.
 
+

Detailed Description

+

A callback that we invoke when a listener has a new connection.

+
Parameters
+ + + + + + +
listenerThe evconnlistener
fdThe new file descriptor
addrThe source address of the connection
socklenThe length of addr
user_argthe pointer passed to evconnlistener_new()
+
+
+

Macro Definition Documentation

+ +

◆ LEV_OPT_BIND_IPV4_AND_IPV6

+ +
+
+ + + + +
#define LEV_OPT_BIND_IPV4_AND_IPV6   (1u<<9)
+
+ +

Flag: Indicates that the listener wants to work only in both IPv4 and IPv6 socket.

+

This flag exists as complement to LEV_OPT_BIND_IPV6ONLY to account for the different default behaviour on Windows so that the code can explicitly request the socket to support both modes without having to rely on the default option.

+ +
+
+ +

◆ LEV_OPT_BIND_IPV6ONLY

+ +
+
+ + + + +
#define LEV_OPT_BIND_IPV6ONLY   (1u<<8)
+
+ +

Flag: Indicates that the listener wants to work only in IPv6 socket.

+

According to RFC3493 and most Linux distributions, default value is to work in IPv4-mapped mode. If there is a requirement to bind same port on same ip addresses but different handlers for both IPv4 and IPv6, it is required to set IPV6_V6ONLY socket option to be sure that the code works as expected without affected by bindv6only sysctl setting in system.

+

This socket option on Windows is instead enabled by default.

+ +
+
+ +

◆ LEV_OPT_DEFERRED_ACCEPT

+ +
+
+ + + + +
#define LEV_OPT_DEFERRED_ACCEPT   (1u<<6)
+
+ +

Flag: Indicates that the listener should defer accept() until data is available, if possible.

+

Ignored on platforms that do not support this.

+

This option can help performance for protocols where the client transmits immediately after connecting. Do not use this option if your protocol doesn't start out with the client transmitting data, since in that case this option will sometimes cause the kernel to never tell you about the connection.

+

This option is only supported by evconnlistener_new_bind(): it can't work with evconnlistener_new_fd(), since the listener needs to be told to use the option before it is actually bound.

+ +
+
+ +

◆ LEV_OPT_DISABLED

+ +
+
+ + + + +
#define LEV_OPT_DISABLED   (1u<<5)
+
+ +

Flag: Indicates that the listener should be created in disabled state.

+

Use evconnlistener_enable() to enable it later.

+ +
+
+ +

◆ LEV_OPT_REUSEABLE_PORT

+ +
+
+ + + + +
#define LEV_OPT_REUSEABLE_PORT   (1u<<7)
+
+ +

Flag: Indicates that we ask to allow multiple servers (processes or threads) to bind to the same port if they each set the option for incoming connections/datagrams to be distributed evenly across all of the threads (or processes).

+

SO_REUSEPORT is what most people would expect SO_REUSEADDR to be, however SO_REUSEPORT does not imply SO_REUSEADDR.

+

This feature is available only on Linux 3.9+, DragonFlyBSD 3.6+, FreeBSD 12.0+, Solaris 11.4, AIX 7.2.5 for now.

+ +
+
+

Typedef Documentation

+ +

◆ evconnlistener_errorcb

+ +
+
+ + + + +
typedef void(* evconnlistener_errorcb) (struct evconnlistener *, void *)
+
+ +

A callback that we invoke when a listener encounters a non-retriable error.

+
Parameters
+ + + +
listenerThe evconnlistener
user_argthe pointer passed to evconnlistener_new()
+
+
+ +
+
+

Function Documentation

+ +

◆ evconnlistener_new()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evconnlistener* evconnlistener_new (struct event_basebase,
evconnlistener_cb cb,
void * ptr,
unsigned flags,
int backlog,
evutil_socket_t fd 
)
+
+ +

Allocate a new evconnlistener object to listen for incoming TCP connections on a given file descriptor.

+
Parameters
+ + + + + + + +
baseThe event base to associate the listener with.
cbA callback to be invoked when a new connection arrives. If the callback is NULL, the listener will be treated as disabled until the callback is set.
ptrA user-supplied pointer to give to the callback.
flagsAny number of LEV_OPT_* flags
backlogPassed to the listen() call to determine the length of the acceptable connection backlog. Set to -1 for a reasonable default. Set to 0 if the socket is already listening.
fdThe file descriptor to listen on. It must be a nonblocking file descriptor, and it should already be bound to an appropriate port and address.
+
+
+ +
+
+ +

◆ evconnlistener_new_bind()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EVENT2_EXPORT_SYMBOL struct evconnlistener* evconnlistener_new_bind (struct event_basebase,
evconnlistener_cb cb,
void * ptr,
unsigned flags,
int backlog,
const struct sockaddr * sa,
int socklen 
)
+
+ +

Allocate a new evconnlistener object to listen for incoming TCP connections on a given address.

+
Parameters
+ + + + + + + + +
baseThe event base to associate the listener with.
cbA callback to be invoked when a new connection arrives. If the callback is NULL, the listener will be treated as disabled until the callback is set.
ptrA user-supplied pointer to give to the callback.
flagsAny number of LEV_OPT_* flags
backlogPassed to the listen() call to determine the length of the acceptable connection backlog. Set to -1 for a reasonable default.
saThe address to listen for connections on.
socklenThe length of the address.
+
+
+ +
+
+
+ + + + diff --git a/listener_8h_source.html b/listener_8h_source.html new file mode 100644 index 0000000..7c2d7cd --- /dev/null +++ b/listener_8h_source.html @@ -0,0 +1,193 @@ + + + + + + + +libevent: event2/listener.h Source File + + + + + + + + + +
+
+ + + + + + +
+
libevent +  2.2.1 +
+
Event notification library
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
listener.h
+
+
+Go to the documentation of this file.
1 /*
+
2  * Copyright (c) 2000-2007 Niels Provos <provos@citi.umich.edu>
+
3  * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson
+
4  *
+
5  * Redistribution and use in source and binary forms, with or without
+
6  * modification, are permitted provided that the following conditions
+
7  * are met:
+
8  * 1. Redistributions of source code must retain the above copyright
+
9  * notice, this list of conditions and the following disclaimer.
+
10  * 2. Redistributions in binary form must reproduce the above copyright
+
11  * notice, this list of conditions and the following disclaimer in the
+
12  * documentation and/or other materials provided with the distribution.
+
13  * 3. The name of the author may not be used to endorse or promote products
+
14  * derived from this software without specific prior written permission.
+
15  *
+
16  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+
17  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+
18  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+
19  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+
20  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+
21  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+
22  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+
23  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+
24  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+
25  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
26  */
+
27 #ifndef EVENT2_LISTENER_H_INCLUDED_
+
28 #define EVENT2_LISTENER_H_INCLUDED_
+
29 
+
30 #include <event2/visibility.h>
+
31 
+
32 #ifdef __cplusplus
+
33 extern "C" {
+
34 #endif
+
35 
+
36 #include <event2/event.h>
+
37 
+
38 struct sockaddr;
+
39 struct evconnlistener;
+
40 
+
51 typedef void (*evconnlistener_cb)(struct evconnlistener *, evutil_socket_t, struct sockaddr *, int socklen, void *);
+
52 
+
59 typedef void (*evconnlistener_errorcb)(struct evconnlistener *, void *);
+
60 
+
63 #define LEV_OPT_LEAVE_SOCKETS_BLOCKING (1u<<0)
+
64 
+
66 #define LEV_OPT_CLOSE_ON_FREE (1u<<1)
+
67 
+
68 #define LEV_OPT_CLOSE_ON_EXEC (1u<<2)
+
69 
+
71 #define LEV_OPT_REUSEABLE (1u<<3)
+
72 
+
74 #define LEV_OPT_THREADSAFE (1u<<4)
+
75 
+
77 #define LEV_OPT_DISABLED (1u<<5)
+
78 
+
91 #define LEV_OPT_DEFERRED_ACCEPT (1u<<6)
+
92 
+
104 #define LEV_OPT_REUSEABLE_PORT (1u<<7)
+
105 
+
116 #define LEV_OPT_BIND_IPV6ONLY (1u<<8)
+
117 
+
125 #define LEV_OPT_BIND_IPV4_AND_IPV6 (1u<<9)
+
126 
+
144 EVENT2_EXPORT_SYMBOL
+
145 struct evconnlistener *evconnlistener_new(struct event_base *base,
+
146  evconnlistener_cb cb, void *ptr, unsigned flags, int backlog,
+
147  evutil_socket_t fd);
+
163 EVENT2_EXPORT_SYMBOL
+
164 struct evconnlistener *evconnlistener_new_bind(struct event_base *base,
+
165  evconnlistener_cb cb, void *ptr, unsigned flags, int backlog,
+
166  const struct sockaddr *sa, int socklen);
+
170 EVENT2_EXPORT_SYMBOL
+
171 void evconnlistener_free(struct evconnlistener *lev);
+
175 EVENT2_EXPORT_SYMBOL
+
176 int evconnlistener_enable(struct evconnlistener *lev);
+
180 EVENT2_EXPORT_SYMBOL
+
181 int evconnlistener_disable(struct evconnlistener *lev);
+
182 
+
184 EVENT2_EXPORT_SYMBOL
+
185 struct event_base *evconnlistener_get_base(struct evconnlistener *lev);
+
186 
+
188 EVENT2_EXPORT_SYMBOL
+
189 evutil_socket_t evconnlistener_get_fd(struct evconnlistener *lev);
+
190 
+
193 EVENT2_EXPORT_SYMBOL
+
194 void evconnlistener_set_cb(struct evconnlistener *lev,
+
195  evconnlistener_cb cb, void *arg);
+
196 
+
198 EVENT2_EXPORT_SYMBOL
+
199 void evconnlistener_set_error_cb(struct evconnlistener *lev,
+
200  evconnlistener_errorcb errorcb);
+
201 
+
202 #ifdef __cplusplus
+
203 }
+
204 #endif
+
205 
+
206 #endif
+
+
Structure to hold information and state for a Libevent dispatch loop.
Definition: event.h:219
+
EVENT2_EXPORT_SYMBOL evutil_socket_t evconnlistener_get_fd(struct evconnlistener *lev)
Return the socket that an evconnlistner is listening on.
+
EVENT2_EXPORT_SYMBOL struct evconnlistener * evconnlistener_new(struct event_base *base, evconnlistener_cb cb, void *ptr, unsigned flags, int backlog, evutil_socket_t fd)
Allocate a new evconnlistener object to listen for incoming TCP connections on a given file descripto...
+
Core functions for waiting for and receiving events, and using event bases.
+
EVENT2_EXPORT_SYMBOL struct evconnlistener * evconnlistener_new_bind(struct event_base *base, evconnlistener_cb cb, void *ptr, unsigned flags, int backlog, const struct sockaddr *sa, int socklen)
Allocate a new evconnlistener object to listen for incoming TCP connections on a given address.
+
void(* evconnlistener_errorcb)(struct evconnlistener *, void *)
A callback that we invoke when a listener encounters a non-retriable error.
Definition: listener.h:59
+
EVENT2_EXPORT_SYMBOL int evconnlistener_disable(struct evconnlistener *lev)
Stop listening for connections on an evconnlistener.
+
EVENT2_EXPORT_SYMBOL void evconnlistener_free(struct evconnlistener *lev)
Disable and deallocate an evconnlistener.
+
EVENT2_EXPORT_SYMBOL void evconnlistener_set_cb(struct evconnlistener *lev, evconnlistener_cb cb, void *arg)
Change the callback on the listener to cb and its user_data to arg.
+
EVENT2_EXPORT_SYMBOL struct event_base * evconnlistener_get_base(struct evconnlistener *lev)
Return an evconnlistener's associated event_base.
+
EVENT2_EXPORT_SYMBOL int evconnlistener_enable(struct evconnlistener *lev)
Re-enable an evconnlistener that has been disabled.
+
EVENT2_EXPORT_SYMBOL void evconnlistener_set_error_cb(struct evconnlistener *lev, evconnlistener_errorcb errorcb)
Set an evconnlistener's error callback.
+
#define evutil_socket_t
A type wide enough to hold the output of "socket()" or "accept()".
Definition: util.h:325
+ + + + diff --git a/menu.js b/menu.js new file mode 100644 index 0000000..433c15b --- /dev/null +++ b/menu.js @@ -0,0 +1,50 @@ +/* + @licstart The following is the entire license notice for the + JavaScript code in this file. + + Copyright (C) 1997-2017 by Dimitri van Heesch + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + + @licend The above is the entire license notice + for the JavaScript code in this file + */ +function initMenu(relPath,searchEnabled,serverSide,searchPage,search) { + function makeTree(data,relPath) { + var result=''; + if ('children' in data) { + result+=''; + } + return result; + } + + $('#main-nav').append(makeTree(menudata,relPath)); + $('#main-nav').children(':first').addClass('sm sm-dox').attr('id','main-menu'); + if (searchEnabled) { + if (serverSide) { + $('#main-menu').append('
  • '); + } else { + $('#main-menu').append('
  • '); + } + } + $('#main-menu').smartmenus(); +} +/* @license-end */ diff --git a/menudata.js b/menudata.js new file mode 100644 index 0000000..607e996 --- /dev/null +++ b/menudata.js @@ -0,0 +1,59 @@ +/* +@licstart The following is the entire license notice for the +JavaScript code in this file. + +Copyright (C) 1997-2019 by Dimitri van Heesch + +This program is free software; you can redistribute it and/or modify +it under the terms of version 2 of the GNU General Public License as published by +the Free Software Foundation + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License along +with this program; if not, write to the Free Software Foundation, Inc., +51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + +@licend The above is the entire license notice +for the JavaScript code in this file +*/ +var menudata={children:[ +{text:"Main Page",url:"index.html"}, +{text:"Related Pages",url:"pages.html"}, +{text:"Data Structures",url:"annotated.html",children:[ +{text:"Data Structures",url:"annotated.html"}, +{text:"Data Structure Index",url:"classes.html"}, +{text:"Data Fields",url:"functions.html",children:[ +{text:"All",url:"functions.html"}, +{text:"Variables",url:"functions_vars.html"}]}]}, +{text:"Files",url:"files.html",children:[ +{text:"File List",url:"files.html"}, +{text:"Globals",url:"globals.html",children:[ +{text:"All",url:"globals.html",children:[ +{text:"b",url:"globals.html#index_b"}, +{text:"d",url:"globals_d.html#index_d"}, +{text:"e",url:"globals_e.html#index_e"}, +{text:"h",url:"globals_h.html#index_h"}, +{text:"i",url:"globals_i.html#index_i"}, +{text:"l",url:"globals_l.html#index_l"}, +{text:"o",url:"globals_o.html#index_o"}]}, +{text:"Functions",url:"globals_func.html",children:[ +{text:"b",url:"globals_func.html#index_b"}, +{text:"e",url:"globals_func_e.html#index_e"}, +{text:"l",url:"globals_func_l.html#index_l"}]}, +{text:"Typedefs",url:"globals_type.html"}, +{text:"Enumerations",url:"globals_enum.html"}, +{text:"Enumerator",url:"globals_eval.html",children:[ +{text:"b",url:"globals_eval.html#index_b"}, +{text:"e",url:"globals_eval.html#index_e"}]}, +{text:"Macros",url:"globals_defs.html",children:[ +{text:"b",url:"globals_defs.html#index_b"}, +{text:"d",url:"globals_defs.html#index_d"}, +{text:"e",url:"globals_defs.html#index_e"}, +{text:"h",url:"globals_defs.html#index_h"}, +{text:"i",url:"globals_defs.html#index_i"}, +{text:"l",url:"globals_defs.html#index_l"}, +{text:"o",url:"globals_defs.html#index_o"}]}]}]}]} diff --git a/nav_f.png b/nav_f.png new file mode 100644 index 0000000..72a58a5 Binary files /dev/null and b/nav_f.png differ diff --git a/nav_g.png b/nav_g.png new file mode 100644 index 0000000..2093a23 Binary files /dev/null and b/nav_g.png differ diff --git a/nav_h.png b/nav_h.png new file mode 100644 index 0000000..33389b1 Binary files /dev/null and b/nav_h.png differ diff --git a/open.png b/open.png new file mode 100644 index 0000000..30f75c7 Binary files /dev/null and b/open.png differ diff --git a/pages.html b/pages.html new file mode 100644 index 0000000..d84e536 --- /dev/null +++ b/pages.html @@ -0,0 +1,83 @@ + + + + + + + +libevent: Related Pages + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + +
    + +
    +
    + + +
    + +
    + +
    +
    +
    Related Pages
    +
    +
    +
    Here is a list of all related documentation pages:
    + + +
     Deprecated List
    +
    +
    + + + + diff --git a/rpc_8h.html b/rpc_8h.html new file mode 100644 index 0000000..23aa4fe --- /dev/null +++ b/rpc_8h.html @@ -0,0 +1,1808 @@ + + + + + + + +libevent: event2/rpc.h File Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    + +
    +
    rpc.h File Reference
    +
    +
    + +

    This header files provides basic support for an RPC server and client. +More...

    +
    #include <event2/util.h>
    +#include <event2/visibility.h>
    +
    +

    Go to the source code of this file.

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +Macros

    #define EVRPC_GENERATE(rpcname, reqstruct, rplystruct)
     Generates the code for receiving and sending an RPC message. More...
     
    #define EVRPC_HEADER(rpcname, reqstruct, rplystruct)
     Creates the definitions and prototypes for an RPC. More...
     
    #define EVRPC_MAKE_CTX(rpcname, reqstruct, rplystruct, pool, request, reply, cb, cbarg)
     Creates a context structure that contains rpc specific information. More...
     
    #define EVRPC_MAKE_REQUEST(name, pool, request, reply, cb, cbarg)   evrpc_send_request_##name((pool), (request), (reply), (cb), (cbarg))
     launches an RPC and sends it to the server More...
     
    #define EVRPC_REGISTER(base, name, request, reply, callback, cbarg)
     register RPCs with the HTTP Server More...
     
    #define EVRPC_REQUEST_DONE(rpc_req)
     Creates the reply to an RPC request. More...
     
    #define EVRPC_REQUEST_HTTP(rpc_req)   (rpc_req)->http_req
     Provides access to the HTTP request object underlying an RPC. More...
     
    #define EVRPC_STRUCT(rpcname)   struct evrpc_req__##rpcname
     The type of a specific RPC Message. More...
     
    #define EVRPC_UNREGISTER(base, name)   evrpc_unregister_rpc((base), #name)
     Unregisters an already registered RPC. More...
     
    +#define EVTAG_ARRAY_ADD(msg, member)   (*(msg)->base->member##_add)(msg)
     Allocates a new entry in the array and returns it.
     
    +#define EVTAG_ARRAY_ADD_VALUE(msg, member, value)   (*(msg)->base->member##_add)((msg), (value))
     Adds a value to an array.
     
    +#define EVTAG_ARRAY_GET(msg, member, offset, pvalue)   (*(msg)->base->member##_get)((msg), (offset), (pvalue))
     Gets a variable at the specified offset from the array.
     
    +#define EVTAG_ARRAY_LEN(msg, member)   ((msg)->member##_length)
     Returns the number of entries in the array.
     
    #define EVTAG_ASSIGN(msg, member, value)   (*(msg)->base->member##_assign)((msg), (value))
     Assigns a value to the member in the message. More...
     
    #define EVTAG_ASSIGN_WITH_LEN(msg, member, value, len)   (*(msg)->base->member##_assign)((msg), (value), (len))
     Assigns a value to the member in the message. More...
     
    #define EVTAG_GET(msg, member, pvalue)   (*(msg)->base->member##_get)((msg), (pvalue))
     Returns the value for a member. More...
     
    #define EVTAG_GET_WITH_LEN(msg, member, pvalue, plen)   (*(msg)->base->member##_get)((msg), (pvalue), (plen))
     Returns the value for a member. More...
     
    #define EVTAG_HAS(msg, member)   ((msg)->member##_set == 1)
     Determines if the member has been set in the message. More...
     
    #define INPUT   EVRPC_INPUT
     Deprecated alias for EVRPC_INPUT. More...
     
    #define OUTPUT   EVRPC_OUTPUT
     Deprecated alias for EVRPC_OUTPUT. More...
     
    + + + + + + + +

    +Enumerations

    enum  EVRPC_HOOK_RESULT { EVRPC_TERMINATE = -1, +EVRPC_CONTINUE = 0, +EVRPC_PAUSE = 1 + }
     Return value from hook processing functions. More...
     
    enum  EVRPC_HOOK_TYPE { EVRPC_INPUT, +EVRPC_OUTPUT + }
     Hooks for changing the input and output of RPCs; this can be used to implement compression, authentication, encryption, ... More...
     
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +Functions

    EVENT2_EXPORT_SYMBOL void * evrpc_add_hook (void *vbase, enum EVRPC_HOOK_TYPE hook_type, int(*cb)(void *, struct evhttp_request *, struct evbuffer *, void *), void *cb_arg)
     adds a processing hook to either an rpc base or rpc pool More...
     
    EVENT2_EXPORT_SYMBOL void evrpc_free (struct evrpc_base *base)
     Frees the evrpc base. More...
     
    +EVENT2_EXPORT_SYMBOL void * evrpc_get_reply (struct evrpc_req_generic *req)
     
    +EVENT2_EXPORT_SYMBOL void * evrpc_get_request (struct evrpc_req_generic *req)
     accessors for request and reply
     
    EVENT2_EXPORT_SYMBOL int evrpc_hook_add_meta (void *ctx, const char *key, const void *data, size_t data_size)
     adds meta data to request More...
     
    EVENT2_EXPORT_SYMBOL int evrpc_hook_find_meta (void *ctx, const char *key, void **data, size_t *data_size)
     retrieves meta data previously associated More...
     
    EVENT2_EXPORT_SYMBOL struct evhttp_connection * evrpc_hook_get_connection (void *ctx)
     returns the connection object associated with the request More...
     
    EVENT2_EXPORT_SYMBOL struct evrpc_base * evrpc_init (struct evhttp *server)
     Creates a new rpc base from which RPC requests can be received. More...
     
    EVENT2_EXPORT_SYMBOL int evrpc_make_request (struct evrpc_request_wrapper *ctx)
     Makes an RPC request based on the provided context. More...
     
    +EVENT2_EXPORT_SYMBOL struct evrpc_request_wrapper * evrpc_make_request_ctx (struct evrpc_pool *pool, void *request, void *reply, const char *rpcname, void(*req_marshal)(struct evbuffer *, void *), void(*rpl_clear)(void *), int(*rpl_unmarshal)(void *, struct evbuffer *), void(*cb)(struct evrpc_status *, void *, void *, void *), void *cbarg)
     use EVRPC_GENERATE instead
     
    EVENT2_EXPORT_SYMBOL void evrpc_pool_add_connection (struct evrpc_pool *pool, struct evhttp_connection *evcon)
     Adds a connection over which rpc can be dispatched to the pool. More...
     
    EVENT2_EXPORT_SYMBOL void evrpc_pool_free (struct evrpc_pool *pool)
     frees an rpc connection pool More...
     
    EVENT2_EXPORT_SYMBOL struct evrpc_pool * evrpc_pool_new (struct event_base *base)
     creates an rpc connection pool More...
     
    EVENT2_EXPORT_SYMBOL void evrpc_pool_remove_connection (struct evrpc_pool *pool, struct evhttp_connection *evcon)
     Removes a connection from the pool. More...
     
    EVENT2_EXPORT_SYMBOL void evrpc_pool_set_timeout (struct evrpc_pool *pool, int timeout_in_secs)
     Sets the timeout in secs after which a request has to complete. More...
     
    EVENT2_EXPORT_SYMBOL int evrpc_register_generic (struct evrpc_base *base, const char *name, void(*callback)(struct evrpc_req_generic *, void *), void *cbarg, void *(*req_new)(void *), void *req_new_arg, void(*req_free)(void *), int(*req_unmarshal)(void *, struct evbuffer *), void *(*rpl_new)(void *), void *rpl_new_arg, void(*rpl_free)(void *), int(*rpl_complete)(void *), void(*rpl_marshal)(struct evbuffer *, void *))
     Function for registering a generic RPC with the RPC base. More...
     
    EVENT2_EXPORT_SYMBOL int evrpc_register_rpc (struct evrpc_base *, struct evrpc *, void(*)(struct evrpc_req_generic *, void *), void *)
     Low level function for registering an RPC with a server. More...
     
    EVENT2_EXPORT_SYMBOL int evrpc_remove_hook (void *vbase, enum EVRPC_HOOK_TYPE hook_type, void *handle)
     removes a previously added hook More...
     
    +EVENT2_EXPORT_SYMBOL void evrpc_request_done (struct evrpc_req_generic *req)
     completes the server response to an rpc request
     
    +EVENT2_EXPORT_SYMBOL struct evrpc_pool * evrpc_request_get_pool (struct evrpc_request_wrapper *ctx)
     accessors for obscure and undocumented functionality
     
    +EVENT2_EXPORT_SYMBOL void evrpc_request_set_cb (struct evrpc_request_wrapper *ctx, void(*cb)(struct evrpc_status *, void *request, void *reply, void *arg), void *cb_arg)
     
    +EVENT2_EXPORT_SYMBOL void evrpc_request_set_pool (struct evrpc_request_wrapper *ctx, struct evrpc_pool *pool)
     
    EVENT2_EXPORT_SYMBOL int evrpc_resume_request (void *vbase, void *ctx, enum EVRPC_HOOK_RESULT res)
     resume a paused request More...
     
    EVENT2_EXPORT_SYMBOL int evrpc_send_request_generic (struct evrpc_pool *pool, void *request, void *reply, void(*cb)(struct evrpc_status *, void *, void *, void *), void *cb_arg, const char *rpcname, void(*req_marshal)(struct evbuffer *, void *), void(*rpl_clear)(void *), int(*rpl_unmarshal)(void *, struct evbuffer *))
     Function for sending a generic RPC request. More...
     
    +EVENT2_EXPORT_SYMBOL int evrpc_unregister_rpc (struct evrpc_base *base, const char *name)
     
    +

    Detailed Description

    +

    This header files provides basic support for an RPC server and client.

    +

    To support RPCs in a server, every supported RPC command needs to be defined and registered.

    +

    EVRPC_HEADER(SendCommand, Request, Reply);

    +

    SendCommand is the name of the RPC command. Request is the name of a structure generated by event_rpcgen.py. It contains all parameters relating to the SendCommand RPC. The server needs to fill in the Reply structure. Reply is the name of a structure generated by event_rpcgen.py. It contains the answer to the RPC.

    +

    To register an RPC with an HTTP server, you need to first create an RPC base with:

    +

    struct evrpc_base *base = evrpc_init(http);

    +

    A specific RPC can then be registered with

    +

    EVRPC_REGISTER(base, SendCommand, Request, Reply, FunctionCB, arg);

    +

    when the server receives an appropriately formatted RPC, the user callback is invoked. The callback needs to fill in the reply structure.

    +

    void FunctionCB(EVRPC_STRUCT(SendCommand)* rpc, void *arg);

    +

    To send the reply, call EVRPC_REQUEST_DONE(rpc);

    +

    See the regression test for an example.

    +

    Macro Definition Documentation

    + +

    ◆ EVRPC_GENERATE

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    #define EVRPC_GENERATE( rpcname,
     reqstruct,
     rplystruct 
    )
    +
    +Value:
    int evrpc_send_request_##rpcname(struct evrpc_pool *pool, \
    +
    struct reqstruct *request, struct rplystruct *reply, \
    +
    void (*cb)(struct evrpc_status *, \
    +
    struct reqstruct *, struct rplystruct *, void *cbarg), \
    +
    void *cbarg) { \
    +
    return evrpc_send_request_generic(pool, request, reply, \
    +
    (void (*)(struct evrpc_status *, void *, void *, void *))cb, \
    +
    cbarg, \
    +
    #rpcname, \
    +
    (void (*)(struct evbuffer *, void *))reqstruct##_marshal, \
    +
    (void (*)(void *))rplystruct##_clear, \
    +
    (int (*)(void *, struct evbuffer *))rplystruct##_unmarshal); \
    +
    }
    +
    +

    Generates the code for receiving and sending an RPC message.

    +

    EVRPC_GENERATE is used to create the code corresponding to sending and receiving a particular RPC message

    +
    Parameters
    + + + + +
    rpcnamethe name of the RPC
    reqstructthe name of the RPC request structure
    rplystructthe name of the RPC reply structure
    +
    +
    +
    See also
    EVRPC_HEADER()
    + +
    +
    + +

    ◆ EVRPC_HEADER

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    #define EVRPC_HEADER( rpcname,
     reqstruct,
     rplystruct 
    )
    +
    +Value:
    EVRPC_STRUCT(rpcname) { \
    +
    struct evrpc_hook_meta *hook_meta; \
    +
    struct reqstruct* request; \
    +
    struct rplystruct* reply; \
    +
    struct evrpc* rpc; \
    +
    struct evhttp_request* http_req; \
    +
    struct evbuffer* rpc_data; \
    +
    }; \
    +
    EVENT2_EXPORT_SYMBOL \
    +
    int evrpc_send_request_##rpcname(struct evrpc_pool *, \
    +
    struct reqstruct *, struct rplystruct *, \
    +
    void (*)(struct evrpc_status *, \
    +
    struct reqstruct *, struct rplystruct *, void *cbarg), \
    +
    void *);
    +
    +

    Creates the definitions and prototypes for an RPC.

    +

    You need to use EVRPC_HEADER to create structures and function prototypes needed by the server and client implementation. The structures have to be defined in an .rpc file and converted to source code via event_rpcgen.py

    +
    Parameters
    + + + + +
    rpcnamethe name of the RPC
    reqstructthe name of the RPC request structure
    rplystructthe name of the RPC reply structure
    +
    +
    +
    See also
    EVRPC_GENERATE()
    + +
    +
    + +

    ◆ EVRPC_MAKE_CTX

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    #define EVRPC_MAKE_CTX( rpcname,
     reqstruct,
     rplystruct,
     pool,
     request,
     reply,
     cb,
     cbarg 
    )
    +
    +Value:
    evrpc_make_request_ctx(pool, request, reply, \
    +
    #rpcname, \
    +
    (void (*)(struct evbuffer *, void *))reqstruct##_marshal, \
    +
    (void (*)(void *))rplystruct##_clear, \
    +
    (int (*)(void *, struct evbuffer *))rplystruct##_unmarshal, \
    +
    (void (*)(struct evrpc_status *, void *, void *, void *))cb, \
    +
    cbarg)
    +
    +

    Creates a context structure that contains rpc specific information.

    +

    EVRPC_MAKE_CTX is used to populate a RPC specific context that contains information about marshaling the RPC data types.

    +
    Parameters
    + + + + + + + + + +
    rpcnamethe name of the RPC
    reqstructthe name of the RPC request structure
    rplystructthe name of the RPC reply structure
    poolthe evrpc_pool over which to make the request
    requesta pointer to the RPC request structure object
    replya pointer to the RPC reply structure object
    cbthe callback function to call when the RPC has completed
    cbargthe argument to supply to the callback
    +
    +
    + +
    +
    + +

    ◆ EVRPC_MAKE_REQUEST

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    #define EVRPC_MAKE_REQUEST( name,
     pool,
     request,
     reply,
     cb,
     cbarg 
    )   evrpc_send_request_##name((pool), (request), (reply), (cb), (cbarg))
    +
    + +

    launches an RPC and sends it to the server

    +

    EVRPC_MAKE_REQUEST() is used by the client to send an RPC to the server.

    +
    Parameters
    + + + + + + + +
    namethe name of the RPC
    poolthe evrpc_pool that contains the connection objects over which the request should be sent.
    requesta pointer to the RPC request structure - it contains the data to be sent to the server.
    replya pointer to the RPC reply structure. It is going to be filled if the request was answered successfully
    cbthe callback to invoke when the RPC request has been answered
    cbargan additional argument to be passed to the client
    +
    +
    +
    Returns
    0 on success, -1 on failure
    + +
    +
    + +

    ◆ EVRPC_REGISTER

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    #define EVRPC_REGISTER( base,
     name,
     request,
     reply,
     callback,
     cbarg 
    )
    +
    +Value:
    evrpc_register_generic(base, #name, \
    +
    (void (*)(struct evrpc_req_generic *, void *))callback, cbarg, \
    +
    (void *(*)(void *))request##_new_with_arg, NULL, \
    +
    (void (*)(void *))request##_free, \
    +
    (int (*)(void *, struct evbuffer *))request##_unmarshal, \
    +
    (void *(*)(void *))reply##_new_with_arg, NULL, \
    +
    (void (*)(void *))reply##_free, \
    +
    (int (*)(void *))reply##_complete, \
    +
    (void (*)(struct evbuffer *, void *))reply##_marshal)
    +
    +

    register RPCs with the HTTP Server

    +

    registers a new RPC with the HTTP server, each RPC needs to have a unique name under which it can be identified.

    +
    Parameters
    + + + + + + + +
    basethe evrpc_base structure in which the RPC should be registered.
    namethe name of the RPC
    requestthe name of the RPC request structure
    replythe name of the RPC reply structure
    callbackthe callback that should be invoked when the RPC is received. The callback has the following prototype void (callback)(EVRPC_STRUCT(Message) rpc, void *arg)
    cbargan additional parameter that can be passed to the callback. The parameter can be used to carry around state.
    +
    +
    + +
    +
    + +

    ◆ EVRPC_REQUEST_DONE

    + +
    +
    + + + + + + + + +
    #define EVRPC_REQUEST_DONE( rpc_req)
    +
    +Value:
    do { \
    +
    struct evrpc_req_generic *req_ = (struct evrpc_req_generic *)(rpc_req); \
    +
    evrpc_request_done(req_); \
    +
    } while (0)
    +
    +

    Creates the reply to an RPC request.

    +

    EVRPC_REQUEST_DONE is used to answer a request; the reply is expected to have been filled in. The request and reply pointers become invalid after this call has finished.

    +
    Parameters
    + + +
    rpc_reqthe rpc request structure provided to the server callback
    +
    +
    + +
    +
    + +

    ◆ EVRPC_REQUEST_HTTP

    + +
    +
    + + + + + + + + +
    #define EVRPC_REQUEST_HTTP( rpc_req)   (rpc_req)->http_req
    +
    + +

    Provides access to the HTTP request object underlying an RPC.

    +

    Access to the underlying http object; can be used to look at headers or for getting the remote ip address

    +
    Parameters
    + + +
    rpc_reqthe rpc request structure provided to the server callback
    +
    +
    +
    Returns
    an struct evhttp_request object that can be inspected for HTTP headers or sender information.
    + +
    +
    + +

    ◆ EVRPC_STRUCT

    + +
    +
    + + + + + + + + +
    #define EVRPC_STRUCT( rpcname)   struct evrpc_req__##rpcname
    +
    + +

    The type of a specific RPC Message.

    +
    Parameters
    + + +
    rpcnamethe name of the RPC message
    +
    +
    + +
    +
    + +

    ◆ EVRPC_UNREGISTER

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    #define EVRPC_UNREGISTER( base,
     name 
    )   evrpc_unregister_rpc((base), #name)
    +
    + +

    Unregisters an already registered RPC.

    +
    Parameters
    + + + +
    basethe evrpc_base object from which to unregister an RPC
    namethe name of the rpc to unregister
    +
    +
    +
    Returns
    -1 on error or 0 when successful.
    +
    See also
    EVRPC_REGISTER()
    + +
    +
    + +

    ◆ EVTAG_ASSIGN

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    #define EVTAG_ASSIGN( msg,
     member,
     value 
    )   (*(msg)->base->member##_assign)((msg), (value))
    +
    + +

    Assigns a value to the member in the message.

    +
    Parameters
    + + + + +
    msgthe message to which to assign a value
    memberthe name of the member variable
    valuethe value to assign
    +
    +
    + +
    +
    + +

    ◆ EVTAG_ASSIGN_WITH_LEN

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    #define EVTAG_ASSIGN_WITH_LEN( msg,
     member,
     value,
     len 
    )   (*(msg)->base->member##_assign)((msg), (value), (len))
    +
    + +

    Assigns a value to the member in the message.

    +
    Parameters
    + + + + + +
    msgthe message to which to assign a value
    memberthe name of the member variable
    valuethe value to assign
    lenthe length of the value
    +
    +
    + +
    +
    + +

    ◆ EVTAG_GET

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    #define EVTAG_GET( msg,
     member,
     pvalue 
    )   (*(msg)->base->member##_get)((msg), (pvalue))
    +
    + +

    Returns the value for a member.

    +
    Parameters
    + + + + +
    msgthe message from which to get the value
    memberthe name of the member variable
    pvaluea pointer to the variable to hold the value
    +
    +
    +
    Returns
    0 on success, -1 otherwise.
    + +
    +
    + +

    ◆ EVTAG_GET_WITH_LEN

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    #define EVTAG_GET_WITH_LEN( msg,
     member,
     pvalue,
     plen 
    )   (*(msg)->base->member##_get)((msg), (pvalue), (plen))
    +
    + +

    Returns the value for a member.

    +
    Parameters
    + + + + + +
    msgthe message from which to get the value
    memberthe name of the member variable
    pvaluea pointer to the variable to hold the value
    plena pointer to the length of the value
    +
    +
    +
    Returns
    0 on success, -1 otherwise.
    + +
    +
    + +

    ◆ EVTAG_HAS

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    #define EVTAG_HAS( msg,
     member 
    )   ((msg)->member##_set == 1)
    +
    + +

    Determines if the member has been set in the message.

    +
    Parameters
    + + + +
    msgthe message to inspect
    memberthe member variable to test for presences
    +
    +
    +
    Returns
    1 if it's present or 0 otherwise.
    + +
    +
    + +

    ◆ INPUT

    + +
    +
    + + + + +
    #define INPUT   EVRPC_INPUT
    +
    + +

    Deprecated alias for EVRPC_INPUT.

    +

    Not available on windows, where it conflicts with platform headers.

    + +
    +
    + +

    ◆ OUTPUT

    + +
    +
    + + + + +
    #define OUTPUT   EVRPC_OUTPUT
    +
    + +

    Deprecated alias for EVRPC_OUTPUT.

    +

    Not available on windows, where it conflicts with platform headers.

    + +
    +
    +

    Enumeration Type Documentation

    + +

    ◆ EVRPC_HOOK_RESULT

    + +
    +
    + + + + +
    enum EVRPC_HOOK_RESULT
    +
    + +

    Return value from hook processing functions.

    + + + + +
    Enumerator
    EVRPC_TERMINATE 

    indicates the rpc should be terminated

    +
    EVRPC_CONTINUE 

    continue processing the rpc

    +
    EVRPC_PAUSE 

    pause processing request until resumed

    +
    + +
    +
    + +

    ◆ EVRPC_HOOK_TYPE

    + +
    +
    + + + + +
    enum EVRPC_HOOK_TYPE
    +
    + +

    Hooks for changing the input and output of RPCs; this can be used to implement compression, authentication, encryption, ...

    + + + +
    Enumerator
    EVRPC_INPUT 

    apply the function to an input hook

    +
    EVRPC_OUTPUT 

    apply the function to an output hook

    +
    + +
    +
    +

    Function Documentation

    + +

    ◆ evrpc_add_hook()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL void* evrpc_add_hook (void * vbase,
    enum EVRPC_HOOK_TYPE hook_type,
    int(*)(void *, struct evhttp_request *, struct evbuffer *, void *) cb,
    void * cb_arg 
    )
    +
    + +

    adds a processing hook to either an rpc base or rpc pool

    +

    If a hook returns TERMINATE, the processing is aborted. On CONTINUE, the request is immediately processed after the hook returns. If the hook returns PAUSE, request processing stops until evrpc_resume_request() has been called.

    +

    The add functions return handles that can be used for removing hooks.

    +
    Parameters
    + + + + + +
    vbasea pointer to either struct evrpc_base or struct evrpc_pool
    hook_typeeither INPUT or OUTPUT
    cbthe callback to call when the hook is activated
    cb_argan additional argument for the callback
    +
    +
    +
    Returns
    a handle to the hook so it can be removed later
    +
    See also
    evrpc_remove_hook()
    + +
    +
    + +

    ◆ evrpc_free()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL void evrpc_free (struct evrpc_base * base)
    +
    + +

    Frees the evrpc base.

    +

    For now, you are responsible for making sure that no rpcs are ongoing.

    +
    Parameters
    + + +
    basethe evrpc_base object to be freed
    +
    +
    +
    See also
    evrpc_init
    + +
    +
    + +

    ◆ evrpc_hook_add_meta()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evrpc_hook_add_meta (void * ctx,
    const char * key,
    const void * data,
    size_t data_size 
    )
    +
    + +

    adds meta data to request

    +

    evrpc_hook_add_meta() allows hooks to add meta data to a request. for a client request, the meta data can be inserted by an outgoing request hook and retrieved by the incoming request hook.

    +
    Parameters
    + + + + + +
    ctxthe context provided to the hook call
    keya NUL-terminated c-string
    datathe data to be associated with the key
    data_sizethe size of the data
    +
    +
    +
    Returns
    0 on success or -1 on failure (in case of memory allocation failures)
    + +
    +
    + +

    ◆ evrpc_hook_find_meta()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evrpc_hook_find_meta (void * ctx,
    const char * key,
    void ** data,
    size_t * data_size 
    )
    +
    + +

    retrieves meta data previously associated

    +

    evrpc_hook_find_meta() can be used to retrieve meta data associated to a request by a previous hook.

    Parameters
    + + + + + +
    ctxthe context provided to the hook call
    keya NUL-terminated c-string
    datapointer to a data pointer that will contain the retrieved data
    data_sizepointer to the size of the data
    +
    +
    +
    Returns
    0 on success or -1 on failure
    + +
    +
    + +

    ◆ evrpc_hook_get_connection()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL struct evhttp_connection* evrpc_hook_get_connection (void * ctx)
    +
    + +

    returns the connection object associated with the request

    +
    Parameters
    + + +
    ctxthe context provided to the hook call
    +
    +
    +
    Returns
    a pointer to the evhttp_connection object or NULL if an error occurred
    + +
    +
    + +

    ◆ evrpc_init()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL struct evrpc_base* evrpc_init (struct evhttp * server)
    +
    + +

    Creates a new rpc base from which RPC requests can be received.

    +
    Parameters
    + + +
    servera pointer to an existing HTTP server
    +
    +
    +
    Returns
    a newly allocated evrpc_base struct or NULL if an error occurred
    +
    See also
    evrpc_free()
    + +
    +
    + +

    ◆ evrpc_make_request()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evrpc_make_request (struct evrpc_request_wrapper * ctx)
    +
    + +

    Makes an RPC request based on the provided context.

    +

    This is a low-level function and should not be used directly unless a custom context object is provided. Use EVRPC_MAKE_REQUEST() instead.

    +
    Parameters
    + + +
    ctxa context from EVRPC_MAKE_CTX()
    +
    +
    +
    Returns
    0 on success, -1 otherwise.
    +
    See also
    EVRPC_MAKE_REQUEST(), EVRPC_MAKE_CTX()
    + +
    +
    + +

    ◆ evrpc_pool_add_connection()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL void evrpc_pool_add_connection (struct evrpc_pool * pool,
    struct evhttp_connection * evcon 
    )
    +
    + +

    Adds a connection over which rpc can be dispatched to the pool.

    +

    The connection object must have been newly created.

    +
    Parameters
    + + + +
    poolthe pool to which to add the connection
    evconthe connection to add to the pool.
    +
    +
    + +
    +
    + +

    ◆ evrpc_pool_free()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL void evrpc_pool_free (struct evrpc_pool * pool)
    +
    + +

    frees an rpc connection pool

    +
    Parameters
    + + +
    poola pointer to an evrpc_pool allocated via evrpc_pool_new()
    +
    +
    +
    See also
    evrpc_pool_new()
    + +
    +
    + +

    ◆ evrpc_pool_new()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL struct evrpc_pool* evrpc_pool_new (struct event_basebase)
    +
    + +

    creates an rpc connection pool

    +

    a pool has a number of connections associated with it. rpc requests are always made via a pool.

    +
    Parameters
    + + +
    basea pointer to an struct event_based object; can be left NULL in singled-threaded applications
    +
    +
    +
    Returns
    a newly allocated struct evrpc_pool object or NULL if an error occurred
    +
    See also
    evrpc_pool_free()
    + +
    +
    + +

    ◆ evrpc_pool_remove_connection()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL void evrpc_pool_remove_connection (struct evrpc_pool * pool,
    struct evhttp_connection * evcon 
    )
    +
    + +

    Removes a connection from the pool.

    +

    The connection object must have been newly created.

    +
    Parameters
    + + + +
    poolthe pool from which to remove the connection
    evconthe connection to remove from the pool.
    +
    +
    + +
    +
    + +

    ◆ evrpc_pool_set_timeout()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL void evrpc_pool_set_timeout (struct evrpc_pool * pool,
    int timeout_in_secs 
    )
    +
    + +

    Sets the timeout in secs after which a request has to complete.

    +

    The RPC is completely aborted if it does not complete by then. Setting the timeout to 0 means that it never timeouts and can be used to implement callback type RPCs.

    +

    Any connection already in the pool will be updated with the new timeout. Connections added to the pool after set_timeout has be called receive the pool timeout only if no timeout has been set for the connection itself.

    +
    Parameters
    + + + +
    poola pointer to a struct evrpc_pool object
    timeout_in_secsthe number of seconds after which a request should timeout and a failure be returned to the callback.
    +
    +
    + +
    +
    + +

    ◆ evrpc_register_generic()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evrpc_register_generic (struct evrpc_base * base,
    const char * name,
    void(*)(struct evrpc_req_generic *, void *) callback,
    void * cbarg,
    void *(*)(void *) req_new,
    void * req_new_arg,
    void(*)(void *) req_free,
    int(*)(void *, struct evbuffer *) req_unmarshal,
    void *(*)(void *) rpl_new,
    void * rpl_new_arg,
    void(*)(void *) rpl_free,
    int(*)(void *) rpl_complete,
    void(*)(struct evbuffer *, void *) rpl_marshal 
    )
    +
    + +

    Function for registering a generic RPC with the RPC base.

    +

    Do not call this function directly, use EVRPC_REGISTER() instead.

    +
    See also
    EVRPC_REGISTER()
    + +
    +
    + +

    ◆ evrpc_register_rpc()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evrpc_register_rpc (struct evrpc_base * ,
    struct evrpc * ,
    void(*)(struct evrpc_req_generic *, void *) ,
    void *  
    )
    +
    + +

    Low level function for registering an RPC with a server.

    +

    Use EVRPC_REGISTER() instead.

    +
    See also
    EVRPC_REGISTER()
    + +
    +
    + +

    ◆ evrpc_remove_hook()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evrpc_remove_hook (void * vbase,
    enum EVRPC_HOOK_TYPE hook_type,
    void * handle 
    )
    +
    + +

    removes a previously added hook

    +
    Parameters
    + + + + +
    vbasea pointer to either struct evrpc_base or struct evrpc_pool
    hook_typeeither INPUT or OUTPUT
    handlea handle returned by evrpc_add_hook()
    +
    +
    +
    Returns
    1 on success or 0 on failure
    +
    See also
    evrpc_add_hook()
    + +
    +
    + +

    ◆ evrpc_resume_request()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evrpc_resume_request (void * vbase,
    void * ctx,
    enum EVRPC_HOOK_RESULT res 
    )
    +
    + +

    resume a paused request

    +
    Parameters
    + + + +
    vbasea pointer to either struct evrpc_base or struct evrpc_pool
    ctxthe context pointer provided to the original hook call
    +
    +
    + +
    +
    + +

    ◆ evrpc_send_request_generic()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evrpc_send_request_generic (struct evrpc_pool * pool,
    void * request,
    void * reply,
    void(*)(struct evrpc_status *, void *, void *, void *) cb,
    void * cb_arg,
    const char * rpcname,
    void(*)(struct evbuffer *, void *) req_marshal,
    void(*)(void *) rpl_clear,
    int(*)(void *, struct evbuffer *) rpl_unmarshal 
    )
    +
    + +

    Function for sending a generic RPC request.

    +

    Do not call this function directly, use EVRPC_MAKE_REQUEST() instead.

    +
    See also
    EVRPC_MAKE_REQUEST()
    + +
    +
    +
    +
    EVENT2_EXPORT_SYMBOL struct evrpc_request_wrapper * evrpc_make_request_ctx(struct evrpc_pool *pool, void *request, void *reply, const char *rpcname, void(*req_marshal)(struct evbuffer *, void *), void(*rpl_clear)(void *), int(*rpl_unmarshal)(void *, struct evbuffer *), void(*cb)(struct evrpc_status *, void *, void *, void *), void *cbarg)
    use EVRPC_GENERATE instead
    +
    EVENT2_EXPORT_SYMBOL int evrpc_register_generic(struct evrpc_base *base, const char *name, void(*callback)(struct evrpc_req_generic *, void *), void *cbarg, void *(*req_new)(void *), void *req_new_arg, void(*req_free)(void *), int(*req_unmarshal)(void *, struct evbuffer *), void *(*rpl_new)(void *), void *rpl_new_arg, void(*rpl_free)(void *), int(*rpl_complete)(void *), void(*rpl_marshal)(struct evbuffer *, void *))
    Function for registering a generic RPC with the RPC base.
    +
    An evbuffer is an opaque data type for efficiently buffering data to be sent or received on the netwo...
    Definition: buffer.h:97
    +
    EVENT2_EXPORT_SYMBOL int evrpc_send_request_generic(struct evrpc_pool *pool, void *request, void *reply, void(*cb)(struct evrpc_status *, void *, void *, void *), void *cb_arg, const char *rpcname, void(*req_marshal)(struct evbuffer *, void *), void(*rpl_clear)(void *), int(*rpl_unmarshal)(void *, struct evbuffer *))
    Function for sending a generic RPC request.
    +
    #define EVRPC_STRUCT(rpcname)
    The type of a specific RPC Message.
    Definition: rpc.h:159
    + + + + diff --git a/rpc_8h_source.html b/rpc_8h_source.html new file mode 100644 index 0000000..12215ba --- /dev/null +++ b/rpc_8h_source.html @@ -0,0 +1,399 @@ + + + + + + + +libevent: event2/rpc.h Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    rpc.h
    +
    +
    +Go to the documentation of this file.
    1 /*
    +
    2  * Copyright (c) 2006-2007 Niels Provos <provos@citi.umich.edu>
    +
    3  * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson
    +
    4  *
    +
    5  * Redistribution and use in source and binary forms, with or without
    +
    6  * modification, are permitted provided that the following conditions
    +
    7  * are met:
    +
    8  * 1. Redistributions of source code must retain the above copyright
    +
    9  * notice, this list of conditions and the following disclaimer.
    +
    10  * 2. Redistributions in binary form must reproduce the above copyright
    +
    11  * notice, this list of conditions and the following disclaimer in the
    +
    12  * documentation and/or other materials provided with the distribution.
    +
    13  * 3. The name of the author may not be used to endorse or promote products
    +
    14  * derived from this software without specific prior written permission.
    +
    15  *
    +
    16  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
    +
    17  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
    +
    18  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
    +
    19  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
    +
    20  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
    +
    21  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
    +
    22  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
    +
    23  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
    +
    24  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
    +
    25  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
    +
    26  */
    +
    27 #ifndef EVENT2_RPC_H_INCLUDED_
    +
    28 #define EVENT2_RPC_H_INCLUDED_
    +
    29 
    +
    30 /* For int types. */
    +
    31 #include <event2/util.h>
    +
    32 #include <event2/visibility.h>
    +
    33 
    +
    34 #ifdef __cplusplus
    +
    35 extern "C" {
    +
    36 #endif
    +
    37 
    +
    80 #define EVTAG_HAS(msg, member) \
    +
    81  ((msg)->member##_set == 1)
    +
    82 
    +
    83 #ifndef EVENT2_RPC_COMPAT_H_INCLUDED_
    +
    84 
    +
    92 #define EVTAG_ASSIGN(msg, member, value) \
    +
    93  (*(msg)->base->member##_assign)((msg), (value))
    +
    94 
    +
    102 #define EVTAG_ASSIGN_WITH_LEN(msg, member, value, len) \
    +
    103  (*(msg)->base->member##_assign)((msg), (value), (len))
    +
    104 
    +
    112 #define EVTAG_GET(msg, member, pvalue) \
    +
    113  (*(msg)->base->member##_get)((msg), (pvalue))
    +
    114 
    +
    123 #define EVTAG_GET_WITH_LEN(msg, member, pvalue, plen) \
    +
    124  (*(msg)->base->member##_get)((msg), (pvalue), (plen))
    +
    125 
    +
    126 #endif /* EVENT2_RPC_COMPAT_H_INCLUDED_ */
    +
    127 
    +
    131 #define EVTAG_ARRAY_ADD_VALUE(msg, member, value) \
    +
    132  (*(msg)->base->member##_add)((msg), (value))
    +
    133 
    +
    136 #define EVTAG_ARRAY_ADD(msg, member) \
    +
    137  (*(msg)->base->member##_add)(msg)
    +
    138 
    +
    141 #define EVTAG_ARRAY_GET(msg, member, offset, pvalue) \
    +
    142  (*(msg)->base->member##_get)((msg), (offset), (pvalue))
    +
    143 
    +
    146 #define EVTAG_ARRAY_LEN(msg, member) ((msg)->member##_length)
    +
    147 
    +
    148 
    +
    149 struct evbuffer;
    +
    150 struct event_base;
    +
    151 struct evrpc_req_generic;
    +
    152 struct evrpc_request_wrapper;
    +
    153 struct evrpc;
    +
    154 
    +
    159 #define EVRPC_STRUCT(rpcname) struct evrpc_req__##rpcname
    +
    160 
    +
    161 struct evhttp_request;
    +
    162 struct evrpc_status;
    +
    163 struct evrpc_hook_meta;
    +
    164 
    +
    176 #define EVRPC_HEADER(rpcname, reqstruct, rplystruct) \
    +
    177 EVRPC_STRUCT(rpcname) { \
    +
    178  struct evrpc_hook_meta *hook_meta; \
    +
    179  struct reqstruct* request; \
    +
    180  struct rplystruct* reply; \
    +
    181  struct evrpc* rpc; \
    +
    182  struct evhttp_request* http_req; \
    +
    183  struct evbuffer* rpc_data; \
    +
    184 }; \
    +
    185 EVENT2_EXPORT_SYMBOL \
    +
    186 int evrpc_send_request_##rpcname(struct evrpc_pool *, \
    +
    187  struct reqstruct *, struct rplystruct *, \
    +
    188  void (*)(struct evrpc_status *, \
    +
    189  struct reqstruct *, struct rplystruct *, void *cbarg), \
    +
    190  void *);
    +
    191 
    +
    192 struct evrpc_pool;
    +
    193 
    +
    195 EVENT2_EXPORT_SYMBOL
    +
    196 struct evrpc_request_wrapper *evrpc_make_request_ctx(
    +
    197  struct evrpc_pool *pool, void *request, void *reply,
    +
    198  const char *rpcname,
    +
    199  void (*req_marshal)(struct evbuffer*, void *),
    +
    200  void (*rpl_clear)(void *),
    +
    201  int (*rpl_unmarshal)(void *, struct evbuffer *),
    +
    202  void (*cb)(struct evrpc_status *, void *, void *, void *),
    +
    203  void *cbarg);
    +
    204 
    +
    219 #define EVRPC_MAKE_CTX(rpcname, reqstruct, rplystruct, \
    +
    220  pool, request, reply, cb, cbarg) \
    +
    221  evrpc_make_request_ctx(pool, request, reply, \
    +
    222  #rpcname, \
    +
    223  (void (*)(struct evbuffer *, void *))reqstruct##_marshal, \
    +
    224  (void (*)(void *))rplystruct##_clear, \
    +
    225  (int (*)(void *, struct evbuffer *))rplystruct##_unmarshal, \
    +
    226  (void (*)(struct evrpc_status *, void *, void *, void *))cb, \
    +
    227  cbarg)
    +
    228 
    +
    239 #define EVRPC_GENERATE(rpcname, reqstruct, rplystruct) \
    +
    240  int evrpc_send_request_##rpcname(struct evrpc_pool *pool, \
    +
    241  struct reqstruct *request, struct rplystruct *reply, \
    +
    242  void (*cb)(struct evrpc_status *, \
    +
    243  struct reqstruct *, struct rplystruct *, void *cbarg), \
    +
    244  void *cbarg) { \
    +
    245  return evrpc_send_request_generic(pool, request, reply, \
    +
    246  (void (*)(struct evrpc_status *, void *, void *, void *))cb, \
    +
    247  cbarg, \
    +
    248  #rpcname, \
    +
    249  (void (*)(struct evbuffer *, void *))reqstruct##_marshal, \
    +
    250  (void (*)(void *))rplystruct##_clear, \
    +
    251  (int (*)(void *, struct evbuffer *))rplystruct##_unmarshal); \
    +
    252 }
    +
    253 
    +
    263 #define EVRPC_REQUEST_HTTP(rpc_req) (rpc_req)->http_req
    +
    264 
    +
    266 EVENT2_EXPORT_SYMBOL
    +
    267 void evrpc_request_done(struct evrpc_req_generic *req);
    +
    268 
    +
    270 EVENT2_EXPORT_SYMBOL
    +
    271 void *evrpc_get_request(struct evrpc_req_generic *req);
    +
    272 EVENT2_EXPORT_SYMBOL
    +
    273 void *evrpc_get_reply(struct evrpc_req_generic *req);
    +
    274 
    +
    283 #define EVRPC_REQUEST_DONE(rpc_req) do { \
    +
    284  struct evrpc_req_generic *req_ = (struct evrpc_req_generic *)(rpc_req); \
    +
    285  evrpc_request_done(req_); \
    +
    286 } while (0)
    +
    287 
    +
    288 
    +
    289 struct evrpc_base;
    +
    290 struct evhttp;
    +
    291 
    +
    292 /* functions to start up the rpc system */
    +
    293 
    +
    300 EVENT2_EXPORT_SYMBOL
    +
    301 struct evrpc_base *evrpc_init(struct evhttp *server);
    +
    302 
    +
    311 EVENT2_EXPORT_SYMBOL
    +
    312 void evrpc_free(struct evrpc_base *base);
    +
    313 
    +
    330 #define EVRPC_REGISTER(base, name, request, reply, callback, cbarg) \
    +
    331  evrpc_register_generic(base, #name, \
    +
    332  (void (*)(struct evrpc_req_generic *, void *))callback, cbarg, \
    +
    333  (void *(*)(void *))request##_new_with_arg, NULL, \
    +
    334  (void (*)(void *))request##_free, \
    +
    335  (int (*)(void *, struct evbuffer *))request##_unmarshal, \
    +
    336  (void *(*)(void *))reply##_new_with_arg, NULL, \
    +
    337  (void (*)(void *))reply##_free, \
    +
    338  (int (*)(void *))reply##_complete, \
    +
    339  (void (*)(struct evbuffer *, void *))reply##_marshal)
    +
    340 
    +
    348 EVENT2_EXPORT_SYMBOL
    +
    349 int evrpc_register_rpc(struct evrpc_base *, struct evrpc *,
    +
    350  void (*)(struct evrpc_req_generic*, void *), void *);
    +
    351 
    +
    360 #define EVRPC_UNREGISTER(base, name) evrpc_unregister_rpc((base), #name)
    +
    361 
    +
    362 EVENT2_EXPORT_SYMBOL
    +
    363 int evrpc_unregister_rpc(struct evrpc_base *base, const char *name);
    +
    364 
    +
    365 /*
    +
    366  * Client-side RPC support
    +
    367  */
    +
    368 
    +
    369 struct evhttp_connection;
    +
    370 struct evrpc_status;
    +
    371 
    +
    387 #define EVRPC_MAKE_REQUEST(name, pool, request, reply, cb, cbarg) \
    +
    388  evrpc_send_request_##name((pool), (request), (reply), (cb), (cbarg))
    +
    389 
    +
    401 EVENT2_EXPORT_SYMBOL
    +
    402 int evrpc_make_request(struct evrpc_request_wrapper *ctx);
    +
    403 
    +
    415 EVENT2_EXPORT_SYMBOL
    +
    416 struct evrpc_pool *evrpc_pool_new(struct event_base *base);
    +
    422 EVENT2_EXPORT_SYMBOL
    +
    423 void evrpc_pool_free(struct evrpc_pool *pool);
    +
    424 
    +
    433 EVENT2_EXPORT_SYMBOL
    +
    434 void evrpc_pool_add_connection(struct evrpc_pool *pool,
    +
    435  struct evhttp_connection *evcon);
    +
    436 
    +
    445 EVENT2_EXPORT_SYMBOL
    +
    446 void evrpc_pool_remove_connection(struct evrpc_pool *pool,
    +
    447  struct evhttp_connection *evcon);
    +
    448 
    +
    464 EVENT2_EXPORT_SYMBOL
    +
    465 void evrpc_pool_set_timeout(struct evrpc_pool *pool, int timeout_in_secs);
    +
    466 
    + + + +
    475 };
    +
    476 
    +
    477 #ifndef _WIN32
    +
    478 
    +
    480 #define INPUT EVRPC_INPUT
    +
    481 
    +
    483 #define OUTPUT EVRPC_OUTPUT
    +
    484 #endif
    +
    485 
    + + + + +
    494 };
    +
    495 
    +
    512 EVENT2_EXPORT_SYMBOL
    +
    513 void *evrpc_add_hook(void *vbase,
    +
    514  enum EVRPC_HOOK_TYPE hook_type,
    +
    515  int (*cb)(void *, struct evhttp_request *, struct evbuffer *, void *),
    +
    516  void *cb_arg);
    +
    517 
    +
    526 EVENT2_EXPORT_SYMBOL
    +
    527 int evrpc_remove_hook(void *vbase,
    +
    528  enum EVRPC_HOOK_TYPE hook_type,
    +
    529  void *handle);
    +
    530 
    +
    536 EVENT2_EXPORT_SYMBOL
    +
    537 int evrpc_resume_request(void *vbase, void *ctx, enum EVRPC_HOOK_RESULT res);
    +
    538 
    +
    551 EVENT2_EXPORT_SYMBOL
    +
    552 int evrpc_hook_add_meta(void *ctx, const char *key,
    +
    553  const void *data, size_t data_size);
    +
    554 
    +
    565 EVENT2_EXPORT_SYMBOL
    +
    566 int evrpc_hook_find_meta(void *ctx, const char *key,
    +
    567  void **data, size_t *data_size);
    +
    568 
    +
    576 EVENT2_EXPORT_SYMBOL
    +
    577 struct evhttp_connection *evrpc_hook_get_connection(void *ctx);
    +
    578 
    +
    586 EVENT2_EXPORT_SYMBOL
    +
    587 int evrpc_send_request_generic(struct evrpc_pool *pool,
    +
    588  void *request, void *reply,
    +
    589  void (*cb)(struct evrpc_status *, void *, void *, void *),
    +
    590  void *cb_arg,
    +
    591  const char *rpcname,
    +
    592  void (*req_marshal)(struct evbuffer *, void *),
    +
    593  void (*rpl_clear)(void *),
    +
    594  int (*rpl_unmarshal)(void *, struct evbuffer *));
    +
    595 
    +
    603 EVENT2_EXPORT_SYMBOL
    +
    604 int evrpc_register_generic(struct evrpc_base *base, const char *name,
    +
    605  void (*callback)(struct evrpc_req_generic *, void *), void *cbarg,
    +
    606  void *(*req_new)(void *), void *req_new_arg, void (*req_free)(void *),
    +
    607  int (*req_unmarshal)(void *, struct evbuffer *),
    +
    608  void *(*rpl_new)(void *), void *rpl_new_arg, void (*rpl_free)(void *),
    +
    609  int (*rpl_complete)(void *),
    +
    610  void (*rpl_marshal)(struct evbuffer *, void *));
    +
    611 
    +
    613 EVENT2_EXPORT_SYMBOL
    +
    614 struct evrpc_pool* evrpc_request_get_pool(struct evrpc_request_wrapper *ctx);
    +
    615 EVENT2_EXPORT_SYMBOL
    +
    616 void evrpc_request_set_pool(struct evrpc_request_wrapper *ctx,
    +
    617  struct evrpc_pool *pool);
    +
    618 EVENT2_EXPORT_SYMBOL
    +
    619 void evrpc_request_set_cb(struct evrpc_request_wrapper *ctx,
    +
    620  void (*cb)(struct evrpc_status*, void *request, void *reply, void *arg),
    +
    621  void *cb_arg);
    +
    622 
    +
    623 #ifdef __cplusplus
    +
    624 }
    +
    625 #endif
    +
    626 
    +
    627 #endif /* EVENT2_RPC_H_INCLUDED_ */
    +
    +
    @ EVRPC_TERMINATE
    indicates the rpc should be terminated
    Definition: rpc.h:491
    +
    EVENT2_EXPORT_SYMBOL void evrpc_request_done(struct evrpc_req_generic *req)
    completes the server response to an rpc request
    +
    EVENT2_EXPORT_SYMBOL void evrpc_pool_set_timeout(struct evrpc_pool *pool, int timeout_in_secs)
    Sets the timeout in secs after which a request has to complete.
    +
    @ EVRPC_INPUT
    apply the function to an input hook
    Definition: rpc.h:473
    +
    EVENT2_EXPORT_SYMBOL struct evrpc_request_wrapper * evrpc_make_request_ctx(struct evrpc_pool *pool, void *request, void *reply, const char *rpcname, void(*req_marshal)(struct evbuffer *, void *), void(*rpl_clear)(void *), int(*rpl_unmarshal)(void *, struct evbuffer *), void(*cb)(struct evrpc_status *, void *, void *, void *), void *cbarg)
    use EVRPC_GENERATE instead
    +
    Structure to hold information and state for a Libevent dispatch loop.
    Definition: event.h:219
    +
    EVENT2_EXPORT_SYMBOL int evrpc_hook_find_meta(void *ctx, const char *key, void **data, size_t *data_size)
    retrieves meta data previously associated
    +
    EVRPC_HOOK_RESULT
    Return value from hook processing functions.
    Definition: rpc.h:490
    +
    @ EVRPC_CONTINUE
    continue processing the rpc
    Definition: rpc.h:492
    +
    EVENT2_EXPORT_SYMBOL int evrpc_remove_hook(void *vbase, enum EVRPC_HOOK_TYPE hook_type, void *handle)
    removes a previously added hook
    +
    EVENT2_EXPORT_SYMBOL void evrpc_pool_remove_connection(struct evrpc_pool *pool, struct evhttp_connection *evcon)
    Removes a connection from the pool.
    +
    EVENT2_EXPORT_SYMBOL int evrpc_register_generic(struct evrpc_base *base, const char *name, void(*callback)(struct evrpc_req_generic *, void *), void *cbarg, void *(*req_new)(void *), void *req_new_arg, void(*req_free)(void *), int(*req_unmarshal)(void *, struct evbuffer *), void *(*rpl_new)(void *), void *rpl_new_arg, void(*rpl_free)(void *), int(*rpl_complete)(void *), void(*rpl_marshal)(struct evbuffer *, void *))
    Function for registering a generic RPC with the RPC base.
    +
    EVENT2_EXPORT_SYMBOL void * evrpc_add_hook(void *vbase, enum EVRPC_HOOK_TYPE hook_type, int(*cb)(void *, struct evhttp_request *, struct evbuffer *, void *), void *cb_arg)
    adds a processing hook to either an rpc base or rpc pool
    +
    EVENT2_EXPORT_SYMBOL void evrpc_pool_free(struct evrpc_pool *pool)
    frees an rpc connection pool
    +
    EVENT2_EXPORT_SYMBOL int evrpc_hook_add_meta(void *ctx, const char *key, const void *data, size_t data_size)
    adds meta data to request
    +
    An evbuffer is an opaque data type for efficiently buffering data to be sent or received on the netwo...
    Definition: buffer.h:97
    +
    EVENT2_EXPORT_SYMBOL struct evrpc_pool * evrpc_pool_new(struct event_base *base)
    creates an rpc connection pool
    +
    EVENT2_EXPORT_SYMBOL int evrpc_make_request(struct evrpc_request_wrapper *ctx)
    Makes an RPC request based on the provided context.
    +
    EVENT2_EXPORT_SYMBOL struct evrpc_pool * evrpc_request_get_pool(struct evrpc_request_wrapper *ctx)
    accessors for obscure and undocumented functionality
    +
    EVENT2_EXPORT_SYMBOL void evrpc_free(struct evrpc_base *base)
    Frees the evrpc base.
    +
    EVENT2_EXPORT_SYMBOL int evrpc_resume_request(void *vbase, void *ctx, enum EVRPC_HOOK_RESULT res)
    resume a paused request
    +
    @ EVRPC_OUTPUT
    apply the function to an output hook
    Definition: rpc.h:474
    +
    EVENT2_EXPORT_SYMBOL int evrpc_send_request_generic(struct evrpc_pool *pool, void *request, void *reply, void(*cb)(struct evrpc_status *, void *, void *, void *), void *cb_arg, const char *rpcname, void(*req_marshal)(struct evbuffer *, void *), void(*rpl_clear)(void *), int(*rpl_unmarshal)(void *, struct evbuffer *))
    Function for sending a generic RPC request.
    +
    @ EVRPC_PAUSE
    pause processing request until resumed
    Definition: rpc.h:493
    +
    EVENT2_EXPORT_SYMBOL struct evhttp_connection * evrpc_hook_get_connection(void *ctx)
    returns the connection object associated with the request
    +
    EVENT2_EXPORT_SYMBOL struct evrpc_base * evrpc_init(struct evhttp *server)
    Creates a new rpc base from which RPC requests can be received.
    +
    EVENT2_EXPORT_SYMBOL void evrpc_pool_add_connection(struct evrpc_pool *pool, struct evhttp_connection *evcon)
    Adds a connection over which rpc can be dispatched to the pool.
    +
    EVENT2_EXPORT_SYMBOL void * evrpc_get_request(struct evrpc_req_generic *req)
    accessors for request and reply
    +
    EVENT2_EXPORT_SYMBOL int evrpc_register_rpc(struct evrpc_base *, struct evrpc *, void(*)(struct evrpc_req_generic *, void *), void *)
    Low level function for registering an RPC with a server.
    +
    Common convenience functions for cross-platform portability and related socket manipulations.
    +
    EVRPC_HOOK_TYPE
    Hooks for changing the input and output of RPCs; this can be used to implement compression,...
    Definition: rpc.h:472
    + + + + diff --git a/rpc__compat_8h.html b/rpc__compat_8h.html new file mode 100644 index 0000000..9a2ada8 --- /dev/null +++ b/rpc__compat_8h.html @@ -0,0 +1,99 @@ + + + + + + + +libevent: event2/rpc_compat.h File Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    + +
    +
    rpc_compat.h File Reference
    +
    +
    + +

    Deprecated versions of the functions in rpc.h: provided only for backwards compatibility. +More...

    + +

    Go to the source code of this file.

    + + + + + +

    +Macros

    +#define EVTAG_LEN(msg, member)   ((msg)->member##_length)
     backwards compatible accessors that work only with gcc
     
    +

    Detailed Description

    +

    Deprecated versions of the functions in rpc.h: provided only for backwards compatibility.

    +
    + + + + diff --git a/rpc__compat_8h_source.html b/rpc__compat_8h_source.html new file mode 100644 index 0000000..f76cd0a --- /dev/null +++ b/rpc__compat_8h_source.html @@ -0,0 +1,135 @@ + + + + + + + +libevent: event2/rpc_compat.h Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    rpc_compat.h
    +
    +
    +Go to the documentation of this file.
    1 /*
    +
    2  * Copyright (c) 2006-2007 Niels Provos <provos@citi.umich.edu>
    +
    3  * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson
    +
    4  *
    +
    5  * Redistribution and use in source and binary forms, with or without
    +
    6  * modification, are permitted provided that the following conditions
    +
    7  * are met:
    +
    8  * 1. Redistributions of source code must retain the above copyright
    +
    9  * notice, this list of conditions and the following disclaimer.
    +
    10  * 2. Redistributions in binary form must reproduce the above copyright
    +
    11  * notice, this list of conditions and the following disclaimer in the
    +
    12  * documentation and/or other materials provided with the distribution.
    +
    13  * 3. The name of the author may not be used to endorse or promote products
    +
    14  * derived from this software without specific prior written permission.
    +
    15  *
    +
    16  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
    +
    17  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
    +
    18  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
    +
    19  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
    +
    20  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
    +
    21  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
    +
    22  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
    +
    23  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
    +
    24  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
    +
    25  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
    +
    26  */
    +
    27 #ifndef EVENT2_RPC_COMPAT_H_INCLUDED_
    +
    28 #define EVENT2_RPC_COMPAT_H_INCLUDED_
    +
    29 
    +
    37 #ifdef __cplusplus
    +
    38 extern "C" {
    +
    39 #endif
    +
    40 
    +
    42 #if defined(__GNUC__) && !defined(__STRICT_ANSI__)
    +
    43 
    +
    44 #undef EVTAG_ASSIGN
    +
    45 #undef EVTAG_GET
    +
    46 #undef EVTAG_ADD
    +
    47 
    +
    48 #define EVTAG_ASSIGN(msg, member, args...) \
    +
    49  (*(msg)->base->member##_assign)(msg, ## args)
    +
    50 #define EVTAG_GET(msg, member, args...) \
    +
    51  (*(msg)->base->member##_get)(msg, ## args)
    +
    52 #define EVTAG_ADD(msg, member, args...) \
    +
    53  (*(msg)->base->member##_add)(msg, ## args)
    +
    54 #endif
    +
    55 #define EVTAG_LEN(msg, member) ((msg)->member##_length)
    +
    56 
    +
    57 #ifdef __cplusplus
    +
    58 }
    +
    59 #endif
    +
    60 
    +
    61 #endif /* EVENT2_EVENT_COMPAT_H_INCLUDED_ */
    +
    + + + + diff --git a/search/all_0.html b/search/all_0.html new file mode 100644 index 0000000..26dd244 --- /dev/null +++ b/search/all_0.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_0.js b/search/all_0.js new file mode 100644 index 0000000..6ee2cf1 --- /dev/null +++ b/search/all_0.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['alloc_0',['alloc',['../structevthread__lock__callbacks.html#a640c2b86b8e914b411848dc72a472591',1,'evthread_lock_callbacks']]], + ['alloc_5fcondition_1',['alloc_condition',['../structevthread__condition__callbacks.html#a1112ef26fb2217351895c10ba347220c',1,'evthread_condition_callbacks']]] +]; diff --git a/search/all_1.html b/search/all_1.html new file mode 100644 index 0000000..8eb215b --- /dev/null +++ b/search/all_1.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_1.js b/search/all_1.js new file mode 100644 index 0000000..548697d --- /dev/null +++ b/search/all_1.js @@ -0,0 +1,106 @@ +var searchData= +[ + ['bev_5ferror_2',['BEV_ERROR',['../bufferevent_8h.html#a19e499f7bfa831b802fd3575d141b4e1a4e51550811d3dad92400c27d69277032',1,'bufferevent.h']]], + ['bev_5fevent_5fconnected_3',['BEV_EVENT_CONNECTED',['../bufferevent_8h.html#affb7a7e5e21e1541ba6f43f950d92993',1,'bufferevent.h']]], + ['bev_5fevent_5feof_4',['BEV_EVENT_EOF',['../bufferevent_8h.html#a4d7d8c93cf62e6f3d37c0cbac75aebcc',1,'bufferevent.h']]], + ['bev_5fevent_5ferror_5',['BEV_EVENT_ERROR',['../bufferevent_8h.html#a5f112d7a064258bdabf8d5182a3bf5e4',1,'bufferevent.h']]], + ['bev_5fevent_5freading_6',['BEV_EVENT_READING',['../bufferevent_8h.html#a504816ca8678e4f3d0bee2700fda524d',1,'bufferevent.h']]], + ['bev_5fevent_5ftimeout_7',['BEV_EVENT_TIMEOUT',['../bufferevent_8h.html#aa537428e3ac2c8d2dbb4ec041f09347f',1,'bufferevent.h']]], + ['bev_5fevent_5fwriting_8',['BEV_EVENT_WRITING',['../bufferevent_8h.html#a557afaa0ce75e6bbb71fdcd68c35d077',1,'bufferevent.h']]], + ['bev_5ffinished_9',['BEV_FINISHED',['../bufferevent_8h.html#ac35edc760057a2e48b4e8ba9ecf2ad25acb248a91854bbebd773061df7f4bbc94',1,'bufferevent.h']]], + ['bev_5fflush_10',['BEV_FLUSH',['../bufferevent_8h.html#ac35edc760057a2e48b4e8ba9ecf2ad25a77e7f15a95815dcaaef27fdabb0e6164',1,'bufferevent.h']]], + ['bev_5fneed_5fmore_11',['BEV_NEED_MORE',['../bufferevent_8h.html#a19e499f7bfa831b802fd3575d141b4e1a78c4f864aee50d333d74e3b46e12b8a4',1,'bufferevent.h']]], + ['bev_5fnormal_12',['BEV_NORMAL',['../bufferevent_8h.html#ac35edc760057a2e48b4e8ba9ecf2ad25a81903ce04ca68ac1680dd0b7a28a7fce',1,'bufferevent.h']]], + ['bev_5fok_13',['BEV_OK',['../bufferevent_8h.html#a19e499f7bfa831b802fd3575d141b4e1a794bf8211eaafdbeb382991dc5874e4d',1,'bufferevent.h']]], + ['bev_5fopt_5fclose_5fon_5ffree_14',['BEV_OPT_CLOSE_ON_FREE',['../bufferevent_8h.html#aa4919449c62c6483e2d135509190dc65a5dc89d74ef445da33295d00c8f6adc90',1,'bufferevent.h']]], + ['bev_5fopt_5fdefer_5fcallbacks_15',['BEV_OPT_DEFER_CALLBACKS',['../bufferevent_8h.html#aa4919449c62c6483e2d135509190dc65a2fbeb24d0156aa2492c23aaace73f1d3',1,'bufferevent.h']]], + ['bev_5fopt_5fthreadsafe_16',['BEV_OPT_THREADSAFE',['../bufferevent_8h.html#aa4919449c62c6483e2d135509190dc65adfb637881b739eff1441ad848a5e3a2d',1,'bufferevent.h']]], + ['bev_5fopt_5funlock_5fcallbacks_17',['BEV_OPT_UNLOCK_CALLBACKS',['../bufferevent_8h.html#aa4919449c62c6483e2d135509190dc65acb8ca6f6422fb8f9a748521cf8c4caf5',1,'bufferevent.h']]], + ['bev_5ftrig_5fdefer_5fcallbacks_18',['BEV_TRIG_DEFER_CALLBACKS',['../bufferevent_8h.html#a7837b6947fc855924466e2347a6faa8faef788894ba060effdd88553e59eb1330',1,'bufferevent.h']]], + ['bev_5ftrig_5fignore_5fwatermarks_19',['BEV_TRIG_IGNORE_WATERMARKS',['../bufferevent_8h.html#a7837b6947fc855924466e2347a6faa8fa02d5d43f86f75f0f1569ca2b16025bfc',1,'bufferevent.h']]], + ['buffer_2eh_20',['buffer.h',['../buffer_8h.html',1,'']]], + ['buffer_5fcompat_2eh_21',['buffer_compat.h',['../buffer__compat_8h.html',1,'']]], + ['bufferevent_22',['bufferevent',['../structbufferevent.html',1,'']]], + ['bufferevent_2eh_23',['bufferevent.h',['../bufferevent_8h.html',1,'']]], + ['bufferevent_5fadd_5fto_5frate_5flimit_5fgroup_24',['bufferevent_add_to_rate_limit_group',['../bufferevent_8h.html#a44ea6c9406f855dadf4afadadbbf47d8',1,'bufferevent.h']]], + ['bufferevent_5fbase_5fset_25',['bufferevent_base_set',['../bufferevent_8h.html#acb59fdb64642f73a96c84adeb97311cb',1,'bufferevent.h']]], + ['bufferevent_5fcompat_2eh_26',['bufferevent_compat.h',['../bufferevent__compat_8h.html',1,'']]], + ['bufferevent_5fdata_5fcb_27',['bufferevent_data_cb',['../bufferevent_8h.html#ad0b9fa4a6c8f03b2fe5a9929a7f2cd59',1,'bufferevent.h']]], + ['bufferevent_5fdecref_28',['bufferevent_decref',['../bufferevent_8h.html#a3427551c0806f78f1bdfd8d767974e27',1,'bufferevent.h']]], + ['bufferevent_5fdisable_29',['bufferevent_disable',['../bufferevent_8h.html#a4f3974def824e73a6861d94cff71e7c6',1,'bufferevent.h']]], + ['bufferevent_5fenable_30',['bufferevent_enable',['../bufferevent_8h.html#aa8a5dd2436494afd374213b99102265b',1,'bufferevent.h']]], + ['bufferevent_5fevent_5fcb_31',['bufferevent_event_cb',['../bufferevent_8h.html#a3b0191b460511796e5281474cd704ec4',1,'bufferevent.h']]], + ['bufferevent_5ffilter_5fcb_32',['bufferevent_filter_cb',['../bufferevent_8h.html#add4274f8e311afc47fb097d290dc54e8',1,'bufferevent.h']]], + ['bufferevent_5ffilter_5fnew_33',['bufferevent_filter_new',['../bufferevent_8h.html#a38bb612dac0112d8ceeb02d0a9a02451',1,'bufferevent.h']]], + ['bufferevent_5ffilter_5fresult_34',['bufferevent_filter_result',['../bufferevent_8h.html#a19e499f7bfa831b802fd3575d141b4e1',1,'bufferevent.h']]], + ['bufferevent_5fflush_35',['bufferevent_flush',['../bufferevent_8h.html#a4e7b46a3dd1518534a2120ee9c8dbe69',1,'bufferevent.h']]], + ['bufferevent_5fflush_5fmode_36',['bufferevent_flush_mode',['../bufferevent_8h.html#ac35edc760057a2e48b4e8ba9ecf2ad25',1,'bufferevent.h']]], + ['bufferevent_5ffree_37',['bufferevent_free',['../bufferevent_8h.html#a8baa699f526f237c0d33f618f073c1cc',1,'bufferevent.h']]], + ['bufferevent_5fget_5fbase_38',['bufferevent_get_base',['../bufferevent_8h.html#a16aa6baf1d489b14fd31cf5e18265186',1,'bufferevent.h']]], + ['bufferevent_5fget_5fenabled_39',['bufferevent_get_enabled',['../bufferevent_8h.html#ab78b8248210f0fadac8b5924dde5a3e7',1,'bufferevent.h']]], + ['bufferevent_5fget_5finput_40',['bufferevent_get_input',['../bufferevent_8h.html#a3ddbf50178b96b3f243ddc83d67e88b0',1,'bufferevent.h']]], + ['bufferevent_5fget_5fmax_5fsingle_5fread_41',['bufferevent_get_max_single_read',['../bufferevent_8h.html#a2fd3db28a9802573c07e5e0584b85465',1,'bufferevent.h']]], + ['bufferevent_5fget_5fmax_5fsingle_5fwrite_42',['bufferevent_get_max_single_write',['../bufferevent_8h.html#acb0bd0b3bb5c983c2b3680637af08617',1,'bufferevent.h']]], + ['bufferevent_5fget_5fmbedtls_5ferror_43',['bufferevent_get_mbedtls_error',['../bufferevent__ssl_8h.html#a9ff8a04e47b127f185911ea153cde862',1,'bufferevent_ssl.h']]], + ['bufferevent_5fget_5fopenssl_5ferror_44',['bufferevent_get_openssl_error',['../bufferevent__ssl_8h.html#a02d39dd2ed160e7564f62cf487bd0315',1,'bufferevent_ssl.h']]], + ['bufferevent_5fget_5foutput_45',['bufferevent_get_output',['../bufferevent_8h.html#ac6e45fa1fc577c4f0e6c4689e72c0a15',1,'bufferevent.h']]], + ['bufferevent_5fget_5fpriority_46',['bufferevent_get_priority',['../bufferevent_8h.html#a0091b3c386580cf2980039ad9a629b70',1,'bufferevent.h']]], + ['bufferevent_5fget_5funderlying_47',['bufferevent_get_underlying',['../bufferevent_8h.html#a3e0081196d2776b92994c6034eb00b2c',1,'bufferevent.h']]], + ['bufferevent_5fgetcb_48',['bufferevent_getcb',['../bufferevent_8h.html#ae58a293995d110362cc1fc695678a928',1,'bufferevent.h']]], + ['bufferevent_5fgetfd_49',['bufferevent_getfd',['../bufferevent_8h.html#a544e049e4a8cca27ab1a98b8339fe72a',1,'bufferevent.h']]], + ['bufferevent_5fgetwatermark_50',['bufferevent_getwatermark',['../bufferevent_8h.html#ae3dd6349d1e33b5238e110a3aba4d163',1,'bufferevent.h']]], + ['bufferevent_5fincref_51',['bufferevent_incref',['../bufferevent_8h.html#a27cabbe542fec7731049312e37e7ba95',1,'bufferevent.h']]], + ['bufferevent_5flock_52',['bufferevent_lock',['../bufferevent_8h.html#a8744a827bb440c1b62676ec35b56b5fc',1,'bufferevent.h']]], + ['bufferevent_5fmbedtls_5fdyncontext_5ffree_53',['bufferevent_mbedtls_dyncontext_free',['../bufferevent__ssl_8h.html#addce4bbddd3fe09b50f9042bd7d1435e',1,'bufferevent_ssl.h']]], + ['bufferevent_5fmbedtls_5fdyncontext_5fnew_54',['bufferevent_mbedtls_dyncontext_new',['../bufferevent__ssl_8h.html#a15ef9128f6f03c98d24032d74de6f0a8',1,'bufferevent_ssl.h']]], + ['bufferevent_5fmbedtls_5ffilter_5fnew_55',['bufferevent_mbedtls_filter_new',['../bufferevent__ssl_8h.html#ab70b27645fdd5a2f0294d53aa1743061',1,'bufferevent_ssl.h']]], + ['bufferevent_5fmbedtls_5fget_5fallow_5fdirty_5fshutdown_56',['bufferevent_mbedtls_get_allow_dirty_shutdown',['../bufferevent__ssl_8h.html#a4f8cc4d8ca0fc0c882659b0e7793e886',1,'bufferevent_ssl.h']]], + ['bufferevent_5fmbedtls_5fget_5fssl_57',['bufferevent_mbedtls_get_ssl',['../bufferevent__ssl_8h.html#afd907d76bb66d40b6633f611c0f01526',1,'bufferevent_ssl.h']]], + ['bufferevent_5fmbedtls_5frenegotiate_58',['bufferevent_mbedtls_renegotiate',['../bufferevent__ssl_8h.html#ad8a0aa57628113bd4fae0ad7dc796b34',1,'bufferevent_ssl.h']]], + ['bufferevent_5fmbedtls_5fset_5fallow_5fdirty_5fshutdown_59',['bufferevent_mbedtls_set_allow_dirty_shutdown',['../bufferevent__ssl_8h.html#a72794ad409cf280240988a104cc3a836',1,'bufferevent_ssl.h']]], + ['bufferevent_5fmbedtls_5fsocket_5fnew_60',['bufferevent_mbedtls_socket_new',['../bufferevent__ssl_8h.html#a941a2172b791789ef1791f2c3b28be75',1,'bufferevent_ssl.h']]], + ['bufferevent_5fnew_61',['bufferevent_new',['../bufferevent__compat_8h.html#a621af7017b3a7fe2ab1de902297ceb94',1,'bufferevent_compat.h']]], + ['bufferevent_5fopenssl_5ffilter_5fnew_62',['bufferevent_openssl_filter_new',['../bufferevent__ssl_8h.html#ac6d45c0c7988f83b0feb2b67497e33c9',1,'bufferevent_ssl.h']]], + ['bufferevent_5fopenssl_5fget_5fallow_5fdirty_5fshutdown_63',['bufferevent_openssl_get_allow_dirty_shutdown',['../bufferevent__ssl_8h.html#ab99fa44e01e56fbd4de25022be3ffbe4',1,'bufferevent_ssl.h']]], + ['bufferevent_5fopenssl_5fget_5fssl_64',['bufferevent_openssl_get_ssl',['../bufferevent__ssl_8h.html#a8e0f365c4daa5129c0cd311a3ee0149f',1,'bufferevent_ssl.h']]], + ['bufferevent_5fopenssl_5fset_5fallow_5fdirty_5fshutdown_65',['bufferevent_openssl_set_allow_dirty_shutdown',['../bufferevent__ssl_8h.html#aa12d88e848c0b8b43e2e7c60992ab870',1,'bufferevent_ssl.h']]], + ['bufferevent_5fopenssl_5fsocket_5fnew_66',['bufferevent_openssl_socket_new',['../bufferevent__ssl_8h.html#a7a3090b586bfc7fc02e81a3a2c2deea5',1,'bufferevent_ssl.h']]], + ['bufferevent_5foptions_67',['bufferevent_options',['../bufferevent_8h.html#aa4919449c62c6483e2d135509190dc65',1,'bufferevent.h']]], + ['bufferevent_5fpair_5fget_5fpartner_68',['bufferevent_pair_get_partner',['../bufferevent_8h.html#a32442df1f9b2252e00d9d9a64ea07854',1,'bufferevent.h']]], + ['bufferevent_5fpair_5fnew_69',['bufferevent_pair_new',['../bufferevent_8h.html#ac6271b7cc2126d3bc745cf00187672a5',1,'bufferevent.h']]], + ['bufferevent_5fpriority_5fset_70',['bufferevent_priority_set',['../bufferevent_8h.html#a2a0eaaf330e2fa46f84dd5ec3e1299c8',1,'bufferevent.h']]], + ['bufferevent_5frate_5flimit_5fgroup_5ffree_71',['bufferevent_rate_limit_group_free',['../bufferevent_8h.html#a5f4f37207371ed122bd5866a55769be1',1,'bufferevent.h']]], + ['bufferevent_5frate_5flimit_5fgroup_5fget_5ftotals_72',['bufferevent_rate_limit_group_get_totals',['../bufferevent_8h.html#ac94cfb31bf5542e1a424d2df3d73203f',1,'bufferevent.h']]], + ['bufferevent_5frate_5flimit_5fgroup_5fnew_73',['bufferevent_rate_limit_group_new',['../bufferevent_8h.html#afc5cd06cb7b574ec9746c8fb89b98491',1,'bufferevent.h']]], + ['bufferevent_5frate_5flimit_5fgroup_5freset_5ftotals_74',['bufferevent_rate_limit_group_reset_totals',['../bufferevent_8h.html#a0cb2748aa4dce6804d166a74383dd0cc',1,'bufferevent.h']]], + ['bufferevent_5frate_5flimit_5fgroup_5fset_5fcfg_75',['bufferevent_rate_limit_group_set_cfg',['../bufferevent_8h.html#a23bbafd1ee4e0a12cc2253b46458b06d',1,'bufferevent.h']]], + ['bufferevent_5frate_5flimit_5fgroup_5fset_5fmin_5fshare_76',['bufferevent_rate_limit_group_set_min_share',['../bufferevent_8h.html#a43c18046f0accddec559dba1a67d933d',1,'bufferevent.h']]], + ['bufferevent_5fread_77',['bufferevent_read',['../bufferevent_8h.html#a9e36c54f6b0ea02183998d5a604a00ef',1,'bufferevent.h']]], + ['bufferevent_5fread_5fbuffer_78',['bufferevent_read_buffer',['../bufferevent_8h.html#abcab28c476ef6bde1faf233bfd18285c',1,'bufferevent.h']]], + ['bufferevent_5fremove_5ffrom_5frate_5flimit_5fgroup_79',['bufferevent_remove_from_rate_limit_group',['../bufferevent_8h.html#a37762f5e89204ca8a8184b59414e6f46',1,'bufferevent.h']]], + ['bufferevent_5freplacefd_80',['bufferevent_replacefd',['../bufferevent_8h.html#a955c7d37679173c593ee6ed0a7adeeea',1,'bufferevent.h']]], + ['bufferevent_5fset_5fmax_5fsingle_5fread_81',['bufferevent_set_max_single_read',['../bufferevent_8h.html#ac450d06c482f354510d5d0abe4577278',1,'bufferevent.h']]], + ['bufferevent_5fset_5fmax_5fsingle_5fwrite_82',['bufferevent_set_max_single_write',['../bufferevent_8h.html#a8e5f4f727f9e0b74f8232c3d758b607e',1,'bufferevent.h']]], + ['bufferevent_5fset_5frate_5flimit_83',['bufferevent_set_rate_limit',['../bufferevent_8h.html#ad5381c899547a19ee6a93df63b064ad4',1,'bufferevent.h']]], + ['bufferevent_5fset_5ftimeouts_84',['bufferevent_set_timeouts',['../bufferevent_8h.html#aec0864607ef2bf9816cda06c1c4ab83f',1,'bufferevent.h']]], + ['bufferevent_5fsetcb_85',['bufferevent_setcb',['../bufferevent_8h.html#a031df52978c5237b70fb8ae7df572c97',1,'bufferevent.h']]], + ['bufferevent_5fsetfd_86',['bufferevent_setfd',['../bufferevent_8h.html#a66cdf9296b02676aacf98a6277a7e756',1,'bufferevent.h']]], + ['bufferevent_5fsettimeout_87',['bufferevent_settimeout',['../bufferevent__compat_8h.html#a5e48aa6b7217987a51cc02b56e0f7297',1,'bufferevent_compat.h']]], + ['bufferevent_5fsetwatermark_88',['bufferevent_setwatermark',['../bufferevent_8h.html#ae23c61cdaf3f74d0fea96d41aa6f7783',1,'bufferevent.h']]], + ['bufferevent_5fsocket_5fconnect_89',['bufferevent_socket_connect',['../bufferevent_8h.html#aefc782ac77411bdd712be30d6268af2e',1,'bufferevent.h']]], + ['bufferevent_5fsocket_5fconnect_5fhostname_90',['bufferevent_socket_connect_hostname',['../bufferevent_8h.html#a5c3c313f2ff0d79a1889e508b37d9dbe',1,'bufferevent.h']]], + ['bufferevent_5fsocket_5fconnect_5fhostname_5fhints_91',['bufferevent_socket_connect_hostname_hints',['../bufferevent_8h.html#afd80dc15fef6d1e7a88a0464e72e8acb',1,'bufferevent.h']]], + ['bufferevent_5fsocket_5fget_5fdns_5ferror_92',['bufferevent_socket_get_dns_error',['../bufferevent_8h.html#aa533016e5ffc2ed558a5d85f9fbe2fd5',1,'bufferevent.h']]], + ['bufferevent_5fsocket_5fnew_93',['bufferevent_socket_new',['../bufferevent_8h.html#a71181be5ab504e26f866dd3d91494854',1,'bufferevent.h']]], + ['bufferevent_5fssl_2eh_94',['bufferevent_ssl.h',['../bufferevent__ssl_8h.html',1,'']]], + ['bufferevent_5fssl_5fbatch_5fwrite_95',['BUFFEREVENT_SSL_BATCH_WRITE',['../bufferevent__ssl_8h.html#a34aeb5156538c8ca7f5353a77aa9059b',1,'bufferevent_ssl.h']]], + ['bufferevent_5fssl_5fdirty_5fshutdown_96',['BUFFEREVENT_SSL_DIRTY_SHUTDOWN',['../bufferevent__ssl_8h.html#af65fd99ef2fa0bc7df9622dc84dfa38b',1,'bufferevent_ssl.h']]], + ['bufferevent_5fssl_5frenegotiate_97',['bufferevent_ssl_renegotiate',['../bufferevent__ssl_8h.html#a3fd911cdaeaa3974bb4c17ad13f48503',1,'bufferevent_ssl.h']]], + ['bufferevent_5fssl_5fstate_98',['bufferevent_ssl_state',['../bufferevent__ssl_8h.html#a96964ed61294aff8a9d95d661f403ee4',1,'bufferevent_ssl.h']]], + ['bufferevent_5ftrigger_99',['bufferevent_trigger',['../bufferevent_8h.html#ae46282450083187370ba2ea42029d341',1,'bufferevent.h']]], + ['bufferevent_5ftrigger_5fevent_100',['bufferevent_trigger_event',['../bufferevent_8h.html#ae8574fb31c0dc88c158c5324110bcbac',1,'bufferevent.h']]], + ['bufferevent_5ftrigger_5foptions_101',['bufferevent_trigger_options',['../bufferevent_8h.html#a7837b6947fc855924466e2347a6faa8f',1,'bufferevent.h']]], + ['bufferevent_5funlock_102',['bufferevent_unlock',['../bufferevent_8h.html#a238f9ac0fcd75094f7b7611e7e6649f2',1,'bufferevent.h']]], + ['bufferevent_5fwrite_103',['bufferevent_write',['../bufferevent_8h.html#a7873bee379202ca1913ea365b92d2ed1',1,'bufferevent.h']]], + ['bufferevent_5fwrite_5fbuffer_104',['bufferevent_write_buffer',['../bufferevent_8h.html#ac9b0f97c37f116dcb579e4491dadda1d',1,'bufferevent.h']]] +]; diff --git a/search/all_2.html b/search/all_2.html new file mode 100644 index 0000000..b26d916 --- /dev/null +++ b/search/all_2.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_2.js b/search/all_2.js new file mode 100644 index 0000000..2a9e6bf --- /dev/null +++ b/search/all_2.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['condition_5fapi_5fversion_105',['condition_api_version',['../structevthread__condition__callbacks.html#a632a051711c8f7728e3464721d7c8084',1,'evthread_condition_callbacks']]] +]; diff --git a/search/all_3.html b/search/all_3.html new file mode 100644 index 0000000..b61b96f --- /dev/null +++ b/search/all_3.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_3.js b/search/all_3.js new file mode 100644 index 0000000..e1767a8 --- /dev/null +++ b/search/all_3.js @@ -0,0 +1,23 @@ +var searchData= +[ + ['deprecated_20list_106',['Deprecated List',['../deprecated.html',1,'']]], + ['dns_2eh_107',['dns.h',['../dns_8h.html',1,'']]], + ['dns_5fcname_5fcallback_108',['DNS_CNAME_CALLBACK',['../dns_8h.html#ae6bc56fee95d5e87a19e8660738b81d2',1,'dns.h']]], + ['dns_5fcompat_2eh_109',['dns_compat.h',['../dns__compat_8h.html',1,'']]], + ['dns_5ferr_5fcancel_110',['DNS_ERR_CANCEL',['../dns_8h.html#aa213c5179d5439b1ceb6b356cfa6670a',1,'dns.h']]], + ['dns_5ferr_5fformat_111',['DNS_ERR_FORMAT',['../dns_8h.html#af83b8dba06d732f95c5134a26189bf07',1,'dns.h']]], + ['dns_5ferr_5fnodata_112',['DNS_ERR_NODATA',['../dns_8h.html#a339623396788ff9271b5cc345b83a2e8',1,'dns.h']]], + ['dns_5ferr_5fnone_113',['DNS_ERR_NONE',['../dns_8h.html#a9ab3095d5fc6b9b476753f1dc43ca062',1,'dns.h']]], + ['dns_5ferr_5fnotexist_114',['DNS_ERR_NOTEXIST',['../dns_8h.html#a69a1417da1abb3ec925bac4bdc9dda00',1,'dns.h']]], + ['dns_5ferr_5fnotimpl_115',['DNS_ERR_NOTIMPL',['../dns_8h.html#ad4c885f89aab5bba9636bcab0b2bb46f',1,'dns.h']]], + ['dns_5ferr_5frefused_116',['DNS_ERR_REFUSED',['../dns_8h.html#ac2612a0b4f473b2e0d8353968cf958c8',1,'dns.h']]], + ['dns_5ferr_5fserverfailed_117',['DNS_ERR_SERVERFAILED',['../dns_8h.html#a288664d29454d839d3337c9f1a16287b',1,'dns.h']]], + ['dns_5ferr_5fshutdown_118',['DNS_ERR_SHUTDOWN',['../dns_8h.html#ad64cc74ddb454b815d42e23b4d24bf16',1,'dns.h']]], + ['dns_5ferr_5ftimeout_119',['DNS_ERR_TIMEOUT',['../dns_8h.html#acb501430c13d4432314859d36b21c59c',1,'dns.h']]], + ['dns_5ferr_5ftruncated_120',['DNS_ERR_TRUNCATED',['../dns_8h.html#ab133c94928a9ebe3d37ad5a5d3722fb8',1,'dns.h']]], + ['dns_5ferr_5funknown_121',['DNS_ERR_UNKNOWN',['../dns_8h.html#a09a9900444d399cb6d516e40a1629f79',1,'dns.h']]], + ['dns_5foptions_5fall_122',['DNS_OPTIONS_ALL',['../dns_8h.html#a417f74bbbbd887a84d911ed9dc7ce3ae',1,'dns.h']]], + ['dns_5fquery_5figntc_123',['DNS_QUERY_IGNTC',['../dns_8h.html#a9c15b7447c0ed1c0966ecce97317266c',1,'dns.h']]], + ['dns_5fquery_5fno_5fsearch_124',['DNS_QUERY_NO_SEARCH',['../dns_8h.html#af82856a398b08ac3a1bb2d540fa9c742',1,'dns.h']]], + ['dns_5fquery_5fusevc_125',['DNS_QUERY_USEVC',['../dns_8h.html#a14fa571999c82d15277b253806d2fbdc',1,'dns.h']]] +]; diff --git a/search/all_4.html b/search/all_4.html new file mode 100644 index 0000000..06de155 --- /dev/null +++ b/search/all_4.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_4.js b/search/all_4.js new file mode 100644 index 0000000..660efa3 --- /dev/null +++ b/search/all_4.js @@ -0,0 +1,523 @@ +var searchData= +[ + ['ev_5fclosed_126',['EV_CLOSED',['../event_8h.html#a98f643f9c9063a4cbf410f519eb61e55',1,'event.h']]], + ['ev_5fet_127',['EV_ET',['../event_8h.html#a01084abbcdd3a58b4068359548a3ea71',1,'event.h']]], + ['ev_5ffeature_5fearly_5fclose_128',['EV_FEATURE_EARLY_CLOSE',['../event_8h.html#ae7da61aef13e27a3047151b696b44c80af28b206cf4665dacc2c6bf09446e29b7',1,'event.h']]], + ['ev_5ffeature_5fet_129',['EV_FEATURE_ET',['../event_8h.html#ae7da61aef13e27a3047151b696b44c80ab407cae60af925dba44bd66e56e5f897',1,'event.h']]], + ['ev_5ffeature_5ffds_130',['EV_FEATURE_FDS',['../event_8h.html#ae7da61aef13e27a3047151b696b44c80a2e964e8a8f3033d26d52831fb8eec199',1,'event.h']]], + ['ev_5ffeature_5fo1_131',['EV_FEATURE_O1',['../event_8h.html#ae7da61aef13e27a3047151b696b44c80a7a6f2de86c09b92aa175f950190bf706',1,'event.h']]], + ['ev_5ffinalize_132',['EV_FINALIZE',['../event_8h.html#ac062d75b2bf9a961d893e3a71726bdff',1,'event.h']]], + ['ev_5fpersist_133',['EV_PERSIST',['../event_8h.html#a3c4947a60eb6d09327c61f89135f9f37',1,'event.h']]], + ['ev_5frate_5flimit_5fmax_134',['EV_RATE_LIMIT_MAX',['../bufferevent_8h.html#a78fc86349f408552be0fdf249db673ec',1,'bufferevent.h']]], + ['ev_5fread_135',['EV_READ',['../event_8h.html#a74bbaf2d529670cc0ab793497b41700f',1,'event.h']]], + ['ev_5fsignal_136',['EV_SIGNAL',['../event_8h.html#a59b7e95284ac1a197969d42ee9441ece',1,'event.h']]], + ['ev_5ftimeout_137',['EV_TIMEOUT',['../event_8h.html#a37ef4b6056484f5580f7d72fcf46fccf',1,'event.h']]], + ['ev_5ftoken_5fbucket_5fcfg_5ffree_138',['ev_token_bucket_cfg_free',['../bufferevent_8h.html#a7ac436abc86f4071a5c43b29c12dba16',1,'bufferevent.h']]], + ['ev_5ftoken_5fbucket_5fcfg_5fnew_139',['ev_token_bucket_cfg_new',['../bufferevent_8h.html#a2dc87d1bae8855f9efca12edea9e3b84',1,'bufferevent.h']]], + ['ev_5fwrite_140',['EV_WRITE',['../event_8h.html#a2a31813fa3b26bf2d150512cbbf893f7',1,'event.h']]], + ['evbuf_5ffs_5fclose_5fon_5ffree_141',['EVBUF_FS_CLOSE_ON_FREE',['../buffer_8h.html#a647759a5dec0745de7b17aefc928e3d6',1,'buffer.h']]], + ['evbuf_5ffs_5fdisable_5flocking_142',['EVBUF_FS_DISABLE_LOCKING',['../buffer_8h.html#ad9d19b50a501babad4cbe7f0f9a42691',1,'buffer.h']]], + ['evbuf_5ffs_5fdisable_5fmmap_143',['EVBUF_FS_DISABLE_MMAP',['../buffer_8h.html#a0749ba245d15e70bc99cee90a3d02ac9',1,'buffer.h']]], + ['evbuf_5ffs_5fdisable_5fsendfile_144',['EVBUF_FS_DISABLE_SENDFILE',['../buffer_8h.html#a553dd6c9a5cbbc112ffe32401cacd705',1,'buffer.h']]], + ['evbuffer_145',['evbuffer',['../structevbuffer.html',1,'']]], + ['evbuffer_5fadd_146',['evbuffer_add',['../buffer_8h.html#a8abedc30187fe00d86b7b1cc4d3ce643',1,'buffer.h']]], + ['evbuffer_5fadd_5fbuffer_147',['evbuffer_add_buffer',['../buffer_8h.html#af95837e510c03d5e5fcf9c05db019f14',1,'buffer.h']]], + ['evbuffer_5fadd_5fbuffer_5freference_148',['evbuffer_add_buffer_reference',['../buffer_8h.html#a60aa7eb8766fcbeadc17f722a095c624',1,'buffer.h']]], + ['evbuffer_5fadd_5fcb_149',['evbuffer_add_cb',['../buffer_8h.html#a3885fb5ca54eff0778916183f58a9c25',1,'buffer.h']]], + ['evbuffer_5fadd_5ffile_150',['evbuffer_add_file',['../buffer_8h.html#a601996b1fc1f5c165dc62b89acbd069e',1,'buffer.h']]], + ['evbuffer_5fadd_5ffile_5fsegment_151',['evbuffer_add_file_segment',['../buffer_8h.html#a300f9e6d1db3d6f834284c47fc77e1bc',1,'buffer.h']]], + ['evbuffer_5fadd_5fiovec_152',['evbuffer_add_iovec',['../buffer_8h.html#acd12f9e37353ed2b72d6a1cc2064f998',1,'buffer.h']]], + ['evbuffer_5fadd_5fprintf_153',['evbuffer_add_printf',['../buffer_8h.html#abd34b7bd9e698e15f868bf05fa6abc59',1,'buffer.h']]], + ['evbuffer_5fadd_5freference_154',['evbuffer_add_reference',['../buffer_8h.html#a35e99b5370b59b0c0b391ada3a59befe',1,'buffer.h']]], + ['evbuffer_5fadd_5freference_5fwith_5foffset_155',['evbuffer_add_reference_with_offset',['../buffer_8h.html#abf2b931577be86b72418252207ca221b',1,'buffer.h']]], + ['evbuffer_5fadd_5fvprintf_156',['evbuffer_add_vprintf',['../buffer_8h.html#abb5d7931c7be6b2bde597cbb9b6dc72d',1,'buffer.h']]], + ['evbuffer_5fcb_157',['evbuffer_cb',['../buffer__compat_8h.html#a6df4ae9e3d819c487ded545d2e1d41b0',1,'buffer_compat.h']]], + ['evbuffer_5fcb_5fclear_5fflags_158',['evbuffer_cb_clear_flags',['../buffer_8h.html#ae384dcadf478c364d005f57be899b21b',1,'buffer.h']]], + ['evbuffer_5fcb_5fenabled_159',['EVBUFFER_CB_ENABLED',['../buffer_8h.html#aeb635643a72f8e57d50d7dee37308148',1,'buffer.h']]], + ['evbuffer_5fcb_5ffunc_160',['evbuffer_cb_func',['../buffer_8h.html#a8f16422514b698553f34c0eba180f3fa',1,'buffer.h']]], + ['evbuffer_5fcb_5finfo_161',['evbuffer_cb_info',['../structevbuffer__cb__info.html',1,'']]], + ['evbuffer_5fcb_5fset_5fflags_162',['evbuffer_cb_set_flags',['../buffer_8h.html#af5fa49788238edd197d3f242878576f3',1,'buffer.h']]], + ['evbuffer_5fclear_5fflags_163',['evbuffer_clear_flags',['../buffer_8h.html#a256652150a256e8e09d9c1ca5ad24881',1,'buffer.h']]], + ['evbuffer_5fcommit_5fspace_164',['evbuffer_commit_space',['../buffer_8h.html#ab9cd3918d883d90acda2d9a9c530bf84',1,'buffer.h']]], + ['evbuffer_5fcopyout_165',['evbuffer_copyout',['../buffer_8h.html#afdc539f4c3dbae7c671a4a857833a3d5',1,'buffer.h']]], + ['evbuffer_5fcopyout_5ffrom_166',['evbuffer_copyout_from',['../buffer_8h.html#a3cf708e4e9384d70a5d2fd7158fd94cb',1,'buffer.h']]], + ['evbuffer_5fdata_167',['EVBUFFER_DATA',['../buffer__compat_8h.html#a1c57a451c56dc1483a1c8aaeb9b92cc6',1,'buffer_compat.h']]], + ['evbuffer_5fdefer_5fcallbacks_168',['evbuffer_defer_callbacks',['../buffer_8h.html#a97293fcb83dd9d073af4cf370b9d094d',1,'buffer.h']]], + ['evbuffer_5fdrain_169',['evbuffer_drain',['../buffer_8h.html#a08599d8165ea785b9b6a4ddf44ec24f7',1,'buffer.h']]], + ['evbuffer_5fenable_5flocking_170',['evbuffer_enable_locking',['../buffer_8h.html#af68e729ac81d8a1c02b716653af45ded',1,'buffer.h']]], + ['evbuffer_5feol_5fany_171',['EVBUFFER_EOL_ANY',['../buffer_8h.html#ad8daf54669a1d2094ce4251dbb502178ab7c6da1408b1b2ec3a6657e5a71a50c3',1,'buffer.h']]], + ['evbuffer_5feol_5fcrlf_172',['EVBUFFER_EOL_CRLF',['../buffer_8h.html#ad8daf54669a1d2094ce4251dbb502178a4aec5353e85fbb57ce3b1ee68f36f641',1,'buffer.h']]], + ['evbuffer_5feol_5fcrlf_5fstrict_173',['EVBUFFER_EOL_CRLF_STRICT',['../buffer_8h.html#ad8daf54669a1d2094ce4251dbb502178a814775b4a9773d34421e7e88ca8c58de',1,'buffer.h']]], + ['evbuffer_5feol_5flf_174',['EVBUFFER_EOL_LF',['../buffer_8h.html#ad8daf54669a1d2094ce4251dbb502178ac572ea90e5a96a7ceb878f2a8ef48993',1,'buffer.h']]], + ['evbuffer_5feol_5fnul_175',['EVBUFFER_EOL_NUL',['../buffer_8h.html#ad8daf54669a1d2094ce4251dbb502178a7b93c5a9f595c62c9d016562356159b7',1,'buffer.h']]], + ['evbuffer_5feol_5fstyle_176',['evbuffer_eol_style',['../buffer_8h.html#ad8daf54669a1d2094ce4251dbb502178',1,'buffer.h']]], + ['evbuffer_5fexpand_177',['evbuffer_expand',['../buffer_8h.html#a8d4919171c71fc41515c0373e8264527',1,'buffer.h']]], + ['evbuffer_5ffile_5fsegment_5fadd_5fcleanup_5fcb_178',['evbuffer_file_segment_add_cleanup_cb',['../buffer_8h.html#ab0767fa82fecc6255129928b02ecc1d6',1,'buffer.h']]], + ['evbuffer_5ffile_5fsegment_5fcleanup_5fcb_179',['evbuffer_file_segment_cleanup_cb',['../buffer_8h.html#aa0e56a17ff87cf097011902b80dd53bf',1,'buffer.h']]], + ['evbuffer_5ffile_5fsegment_5ffree_180',['evbuffer_file_segment_free',['../buffer_8h.html#a0b82a4d7dd6853882ed5a87559edbad1',1,'buffer.h']]], + ['evbuffer_5ffile_5fsegment_5fnew_181',['evbuffer_file_segment_new',['../buffer_8h.html#aa52264c1529ee486400bbad0bf9f4271',1,'buffer.h']]], + ['evbuffer_5ffind_182',['evbuffer_find',['../buffer__compat_8h.html#af44d0b893f624295a4eeb5da8bbca100',1,'buffer_compat.h']]], + ['evbuffer_5fflag_5fdrains_5fto_5ffd_183',['EVBUFFER_FLAG_DRAINS_TO_FD',['../buffer_8h.html#a0d9db8b232ebf8d63c660ec429981e91',1,'buffer.h']]], + ['evbuffer_5ffree_184',['evbuffer_free',['../buffer_8h.html#ab255015b91f7b43ba09d8f9da54ed865',1,'buffer.h']]], + ['evbuffer_5ffreeze_185',['evbuffer_freeze',['../buffer_8h.html#a2b32b99d60603aac9bbadb9e463a6bc1',1,'buffer.h']]], + ['evbuffer_5fget_5fcontiguous_5fspace_186',['evbuffer_get_contiguous_space',['../buffer_8h.html#a3f0b89841da394aebf6dfd620dd787d1',1,'buffer.h']]], + ['evbuffer_5fget_5flength_187',['evbuffer_get_length',['../buffer_8h.html#a808db707e84e20229b2aafdcaba6c708',1,'buffer.h']]], + ['evbuffer_5fget_5fmax_5fread_188',['evbuffer_get_max_read',['../buffer_8h.html#a94fa0f064f3a5d273a362762eb6b1410',1,'buffer.h']]], + ['evbuffer_5finput_189',['EVBUFFER_INPUT',['../bufferevent__compat_8h.html#a189bf30c83f32cffebdc0dcb65f41350',1,'bufferevent_compat.h']]], + ['evbuffer_5fiovec_190',['evbuffer_iovec',['../structevbuffer__iovec.html',1,'']]], + ['evbuffer_5flength_191',['EVBUFFER_LENGTH',['../buffer__compat_8h.html#ab8d9564980e380cf1887f2be70f687ad',1,'buffer_compat.h']]], + ['evbuffer_5flock_192',['evbuffer_lock',['../buffer_8h.html#afe1a938f5728ca0770419119cd90359d',1,'buffer.h']]], + ['evbuffer_5fnew_193',['evbuffer_new',['../buffer_8h.html#a7a853e8ebc063d32cd11f1554c77615d',1,'buffer.h']]], + ['evbuffer_5foutput_194',['EVBUFFER_OUTPUT',['../bufferevent__compat_8h.html#a6e7bfa5494417540589e9ae582a2bccd',1,'bufferevent_compat.h']]], + ['evbuffer_5fpeek_195',['evbuffer_peek',['../buffer_8h.html#aad7c208f2afca3e7e46a1a95fb79eec1',1,'buffer.h']]], + ['evbuffer_5fprepend_196',['evbuffer_prepend',['../buffer_8h.html#a1112b433d2554b8b80b814feb37fdc95',1,'buffer.h']]], + ['evbuffer_5fprepend_5fbuffer_197',['evbuffer_prepend_buffer',['../buffer_8h.html#a1d26aa5a48b549d702bc5175b0444d33',1,'buffer.h']]], + ['evbuffer_5fptr_198',['evbuffer_ptr',['../structevbuffer__ptr.html',1,'']]], + ['evbuffer_5fptr_5fadd_199',['EVBUFFER_PTR_ADD',['../buffer_8h.html#a13a9ee759900ce2964d16acd5f309014a0bce00d78b5fbc55c478ff362269f428',1,'buffer.h']]], + ['evbuffer_5fptr_5fhow_200',['evbuffer_ptr_how',['../buffer_8h.html#a13a9ee759900ce2964d16acd5f309014',1,'buffer.h']]], + ['evbuffer_5fptr_5fset_201',['EVBUFFER_PTR_SET',['../buffer_8h.html#a13a9ee759900ce2964d16acd5f309014a78a0ff3721ff5f1647f743dcfb2f13ee',1,'EVBUFFER_PTR_SET(): buffer.h'],['../buffer_8h.html#a22137a538067a8450d52af0e6601ca49',1,'evbuffer_ptr_set(struct evbuffer *buffer, struct evbuffer_ptr *ptr, size_t position, enum evbuffer_ptr_how how): buffer.h']]], + ['evbuffer_5fpullup_202',['evbuffer_pullup',['../buffer_8h.html#acd73ca99c3a793ea26c43307b9723bd6',1,'buffer.h']]], + ['evbuffer_5fread_203',['evbuffer_read',['../buffer_8h.html#a2664ab1d68d21acf3185a01c85cf29af',1,'buffer.h']]], + ['evbuffer_5freadline_204',['evbuffer_readline',['../buffer__compat_8h.html#a4fea308404ec34c5daeec61f5e05bc08',1,'buffer_compat.h']]], + ['evbuffer_5freadln_205',['evbuffer_readln',['../buffer_8h.html#a8bcc94903283574331994c9364be3d7b',1,'buffer.h']]], + ['evbuffer_5fref_5fcleanup_5fcb_206',['evbuffer_ref_cleanup_cb',['../buffer_8h.html#a66c442353fa5159e2acd808794fa92d6',1,'buffer.h']]], + ['evbuffer_5fremove_207',['evbuffer_remove',['../buffer_8h.html#aa53da314581de5e13bb0d92aa05e2301',1,'buffer.h']]], + ['evbuffer_5fremove_5fbuffer_208',['evbuffer_remove_buffer',['../buffer_8h.html#a863342bdbdb4f91d0415ae29ef25494b',1,'buffer.h']]], + ['evbuffer_5fremove_5fcb_209',['evbuffer_remove_cb',['../buffer_8h.html#abc4912118c60071766c6a9d343186137',1,'buffer.h']]], + ['evbuffer_5fremove_5fcb_5fentry_210',['evbuffer_remove_cb_entry',['../buffer_8h.html#ade150950a995af06cd3c6321f71eb3c1',1,'buffer.h']]], + ['evbuffer_5freserve_5fspace_211',['evbuffer_reserve_space',['../buffer_8h.html#a18e9703ca1a062669412684543f7f537',1,'buffer.h']]], + ['evbuffer_5fsearch_212',['evbuffer_search',['../buffer_8h.html#a06e9211319a369ffb072d4f4a83b48e7',1,'buffer.h']]], + ['evbuffer_5fsearch_5feol_213',['evbuffer_search_eol',['../buffer_8h.html#a28e2fa6852a5a49285933b1c95c7465f',1,'buffer.h']]], + ['evbuffer_5fsearch_5frange_214',['evbuffer_search_range',['../buffer_8h.html#a3b1e093af8bc1a86963729ec1290de8f',1,'buffer.h']]], + ['evbuffer_5fset_5fflags_215',['evbuffer_set_flags',['../buffer_8h.html#a8649a5edeb1fcf06490d4d35ac76c13a',1,'buffer.h']]], + ['evbuffer_5fset_5fmax_5fread_216',['evbuffer_set_max_read',['../buffer_8h.html#ac5441fc0ce576ad997bf1a869f8c4ba9',1,'buffer.h']]], + ['evbuffer_5fsetcb_217',['evbuffer_setcb',['../buffer__compat_8h.html#aaae25109e21cb9f7417922592ed495a4',1,'buffer_compat.h']]], + ['evbuffer_5funfreeze_218',['evbuffer_unfreeze',['../buffer_8h.html#af36bd50996e2db4445282e6a194328a2',1,'buffer.h']]], + ['evbuffer_5funlock_219',['evbuffer_unlock',['../buffer_8h.html#a25e8be33a5d5cb2684594b9b3cb6c7c9',1,'buffer.h']]], + ['evbuffer_5fwrite_220',['evbuffer_write',['../buffer_8h.html#a7d9605737ec9ba876f0ba49e937b9bd7',1,'buffer.h']]], + ['evbuffer_5fwrite_5fatmost_221',['evbuffer_write_atmost',['../buffer_8h.html#a69f9cbac8f6dbd2d8f3c2706fbbdc7cd',1,'buffer.h']]], + ['evconnlistener_5fdisable_222',['evconnlistener_disable',['../listener_8h.html#a1f772caf7e2f01276ec33641eb32418c',1,'listener.h']]], + ['evconnlistener_5fenable_223',['evconnlistener_enable',['../listener_8h.html#a890717d86a18e2bd82655fd342b1973f',1,'listener.h']]], + ['evconnlistener_5ferrorcb_224',['evconnlistener_errorcb',['../listener_8h.html#a925d682ff37636dc08b045aaeff6b538',1,'listener.h']]], + ['evconnlistener_5ffree_225',['evconnlistener_free',['../listener_8h.html#a0f7f3d276f08669c2a9b1817941aa68f',1,'listener.h']]], + ['evconnlistener_5fget_5fbase_226',['evconnlistener_get_base',['../listener_8h.html#ab3492fa1741d2b50e151505c0582334d',1,'listener.h']]], + ['evconnlistener_5fget_5ffd_227',['evconnlistener_get_fd',['../listener_8h.html#a56e8de702931f3960edd84617e6c2fb6',1,'listener.h']]], + ['evconnlistener_5fnew_228',['evconnlistener_new',['../listener_8h.html#aa07ae1878cf56d58579b025dd1620c91',1,'listener.h']]], + ['evconnlistener_5fnew_5fbind_229',['evconnlistener_new_bind',['../listener_8h.html#a29076ec56e051fb75aa48f30cf9111ee',1,'listener.h']]], + ['evconnlistener_5fset_5fcb_230',['evconnlistener_set_cb',['../listener_8h.html#abf8c1793319829ff9c6d8ce4fea6b342',1,'listener.h']]], + ['evconnlistener_5fset_5ferror_5fcb_231',['evconnlistener_set_error_cb',['../listener_8h.html#a328c8f6b2c2b3c87507ca6a4d5790da1',1,'listener.h']]], + ['evdns_5fadd_5fserver_5fport_232',['evdns_add_server_port',['../dns__compat_8h.html#a0def8fe56b2dee569e32ed685f4c22d8',1,'dns_compat.h']]], + ['evdns_5fadd_5fserver_5fport_5fwith_5fbase_233',['evdns_add_server_port_with_base',['../dns_8h.html#ad6a51e72173fcb3df380a49e8589635b',1,'dns.h']]], + ['evdns_5fadd_5fserver_5fport_5fwith_5flistener_234',['evdns_add_server_port_with_listener',['../dns_8h.html#ac44ddac0711712a5e3f7ec041c8d2478',1,'dns.h']]], + ['evdns_5fbase_5fclear_5fhost_5faddresses_235',['evdns_base_clear_host_addresses',['../dns_8h.html#a1875001046dd6cbff5f2139590221ddf',1,'dns.h']]], + ['evdns_5fbase_5fclear_5fnameservers_5fand_5fsuspend_236',['evdns_base_clear_nameservers_and_suspend',['../dns_8h.html#af942ce8b6a65052f4b6def91a3390a61',1,'dns.h']]], + ['evdns_5fbase_5fconfig_5fwindows_5fnameservers_237',['evdns_base_config_windows_nameservers',['../dns_8h.html#ac287c8b638a248719a00b0324579b728',1,'dns.h']]], + ['evdns_5fbase_5fcount_5fnameservers_238',['evdns_base_count_nameservers',['../dns_8h.html#a6811354521b4fe8df4c724d6cb9fb102',1,'dns.h']]], + ['evdns_5fbase_5fdisable_5fwhen_5finactive_239',['EVDNS_BASE_DISABLE_WHEN_INACTIVE',['../dns_8h.html#ad676c79dfd2107701961fe2b269dcfd8',1,'dns.h']]], + ['evdns_5fbase_5ffree_240',['evdns_base_free',['../dns_8h.html#ab221bbadb18451c9007e8dc98bc97786',1,'dns.h']]], + ['evdns_5fbase_5fget_5fnameserver_5faddr_241',['evdns_base_get_nameserver_addr',['../dns_8h.html#a1545f7930f228018a06476a7236bfe0e',1,'dns.h']]], + ['evdns_5fbase_5fget_5fnameserver_5ffd_242',['evdns_base_get_nameserver_fd',['../dns_8h.html#a954ffdf37038dba334543f6013d6a87f',1,'dns.h']]], + ['evdns_5fbase_5finitialize_5fnameservers_243',['EVDNS_BASE_INITIALIZE_NAMESERVERS',['../dns_8h.html#a1cbcfe6baf59913c34aa04e57637da3d',1,'dns.h']]], + ['evdns_5fbase_5fload_5fhosts_244',['evdns_base_load_hosts',['../dns_8h.html#a5092d38082851904e37d6b80c3475714',1,'dns.h']]], + ['evdns_5fbase_5fnameserver_5fadd_245',['evdns_base_nameserver_add',['../dns_8h.html#a53a242ec2ab15eef9e49e4286153d55a',1,'dns.h']]], + ['evdns_5fbase_5fnameserver_5fip_5fadd_246',['evdns_base_nameserver_ip_add',['../dns_8h.html#a0a5f8e71a80a41d10e386f8cac816238',1,'dns.h']]], + ['evdns_5fbase_5fnameserver_5fsockaddr_5fadd_247',['evdns_base_nameserver_sockaddr_add',['../dns_8h.html#ac8feac209d81aea2654809727ee7ada7',1,'dns.h']]], + ['evdns_5fbase_5fnameservers_5fno_5fdefault_248',['EVDNS_BASE_NAMESERVERS_NO_DEFAULT',['../dns_8h.html#a548a0e3529efb572b991408f7581a09b',1,'dns.h']]], + ['evdns_5fbase_5fnew_249',['evdns_base_new',['../dns_8h.html#afdcc359c412591d174f4d965afd18513',1,'dns.h']]], + ['evdns_5fbase_5fno_5fcache_250',['EVDNS_BASE_NO_CACHE',['../dns_8h.html#a865ae03fdd5198a182e6c4c322f56f8d',1,'dns.h']]], + ['evdns_5fbase_5fresolv_5fconf_5fparse_251',['evdns_base_resolv_conf_parse',['../dns_8h.html#a7e3a053e25ae7c045944a5db0947babb',1,'dns.h']]], + ['evdns_5fbase_5fresolve_5fipv4_252',['evdns_base_resolve_ipv4',['../dns_8h.html#a4f8b11705fa285dffa661c7f55f86693',1,'dns.h']]], + ['evdns_5fbase_5fresolve_5fipv6_253',['evdns_base_resolve_ipv6',['../dns_8h.html#a646ca1414b09b9fec7763bf8aca05e74',1,'dns.h']]], + ['evdns_5fbase_5fresolve_5freverse_254',['evdns_base_resolve_reverse',['../dns_8h.html#a1f9cbcd4c017180e7d302056b3d5bbd4',1,'dns.h']]], + ['evdns_5fbase_5fresolve_5freverse_5fipv6_255',['evdns_base_resolve_reverse_ipv6',['../dns_8h.html#a55843d1e90512bfbe8499d52642240cd',1,'dns.h']]], + ['evdns_5fbase_5fresume_256',['evdns_base_resume',['../dns_8h.html#a3ef3a20dd645e02d6dd5d3766ced9ce7',1,'dns.h']]], + ['evdns_5fbase_5fsearch_5fadd_257',['evdns_base_search_add',['../dns_8h.html#a8044de93700190d5ca6a6a0becdc4f6e',1,'dns.h']]], + ['evdns_5fbase_5fsearch_5fclear_258',['evdns_base_search_clear',['../dns_8h.html#a9211bdca966e8f4ce3270b29c1d72122',1,'dns.h']]], + ['evdns_5fbase_5fsearch_5fndots_5fset_259',['evdns_base_search_ndots_set',['../dns_8h.html#ae858583b1c9fdd1f7c99330bcdd68ba6',1,'dns.h']]], + ['evdns_5fbase_5fset_5foption_260',['evdns_base_set_option',['../dns_8h.html#a791b6fdc9f41bd62414574d85ae18cc8',1,'dns.h']]], + ['evdns_5fcache_5flookup_261',['evdns_cache_lookup',['../dns_8h.html#abdb3c829da1d539ecdf92ae47f8f1c03',1,'dns.h']]], + ['evdns_5fcache_5fwrite_262',['evdns_cache_write',['../dns_8h.html#ac969fd31d17e59ad072be79a591d5224',1,'dns.h']]], + ['evdns_5fcallback_5ftype_263',['evdns_callback_type',['../dns_8h.html#a43018959c4be1a9b16e4143c5e3ff556',1,'dns.h']]], + ['evdns_5fcancel_5frequest_264',['evdns_cancel_request',['../dns_8h.html#a062bdd01f7243b3c8509d93c45a802ef',1,'dns.h']]], + ['evdns_5fclear_5fnameservers_5fand_5fsuspend_265',['evdns_clear_nameservers_and_suspend',['../dns__compat_8h.html#a6c7b5be4d918882465ef75f4a1478124',1,'dns_compat.h']]], + ['evdns_5fclose_5fserver_5fport_266',['evdns_close_server_port',['../dns_8h.html#abbd56ab78c400f46498515330343c66a',1,'dns.h']]], + ['evdns_5fcount_5fnameservers_267',['evdns_count_nameservers',['../dns__compat_8h.html#a1d07cab0ca89d14da595552f05338e0b',1,'dns_compat.h']]], + ['evdns_5fdebug_5flog_5ffn_5ftype_268',['evdns_debug_log_fn_type',['../dns_8h.html#a850904a1dbd8c8a087dc2be7617e21c8',1,'dns.h']]], + ['evdns_5ferr_5fto_5fstring_269',['evdns_err_to_string',['../dns_8h.html#a24bb4cf48915f73e4e9c6d4b6216466b',1,'dns.h']]], + ['evdns_5fget_5fglobal_5fbase_270',['evdns_get_global_base',['../dns__compat_8h.html#ae54990e958bb398b120a90d47796a2d8',1,'dns_compat.h']]], + ['evdns_5fgetaddrinfo_271',['evdns_getaddrinfo',['../dns_8h.html#a28a4c5e6e22bcf92f8c229461023f914',1,'dns.h']]], + ['evdns_5fgetaddrinfo_5fcb_272',['evdns_getaddrinfo_cb',['../dns_8h.html#a0d1464f191ef7678be0d4caf3644a8f4',1,'dns.h']]], + ['evdns_5finit_273',['evdns_init',['../dns__compat_8h.html#ad1b7dd2a9e58135f17a383331233b207',1,'dns_compat.h']]], + ['evdns_5fnameserver_5fadd_274',['evdns_nameserver_add',['../dns__compat_8h.html#ae50b63ae4a40a756bc51c0aebe2ac23e',1,'dns_compat.h']]], + ['evdns_5fnameserver_5fip_5fadd_275',['evdns_nameserver_ip_add',['../dns__compat_8h.html#aa40d812a3dc909b8728cc3647ef1247a',1,'dns_compat.h']]], + ['evdns_5frequest_5fcallback_5ffn_5ftype_276',['evdns_request_callback_fn_type',['../dns_8h.html#a052802966f4c9d482279a05197dff005',1,'dns.h']]], + ['evdns_5fresolv_5fconf_5fparse_277',['evdns_resolv_conf_parse',['../dns__compat_8h.html#a4dd30bf34468410eb96757007523eb34',1,'dns_compat.h']]], + ['evdns_5fresolve_5fipv4_278',['evdns_resolve_ipv4',['../dns__compat_8h.html#a438a9e699ff81b4a22cc072ad3c8e1c2',1,'dns_compat.h']]], + ['evdns_5fresolve_5fipv6_279',['evdns_resolve_ipv6',['../dns__compat_8h.html#a295f72a34e9744a7026261c078c03f13',1,'dns_compat.h']]], + ['evdns_5fresolve_5freverse_280',['evdns_resolve_reverse',['../dns__compat_8h.html#a30c78f62647609846c2bb3222ebce87e',1,'dns_compat.h']]], + ['evdns_5fresolve_5freverse_5fipv6_281',['evdns_resolve_reverse_ipv6',['../dns__compat_8h.html#a45bf87a8a77c7fba752836aab6a5a9cb',1,'dns_compat.h']]], + ['evdns_5fresume_282',['evdns_resume',['../dns__compat_8h.html#aa34fd9ec83c05361a23d484aa0debe7a',1,'dns_compat.h']]], + ['evdns_5fsearch_5fadd_283',['evdns_search_add',['../dns__compat_8h.html#ad43d4dab51d417dfd21299b615e64e71',1,'dns_compat.h']]], + ['evdns_5fsearch_5fclear_284',['evdns_search_clear',['../dns__compat_8h.html#a717e59ca40403c0cd86091748bee5405',1,'dns_compat.h']]], + ['evdns_5fsearch_5fndots_5fset_285',['evdns_search_ndots_set',['../dns__compat_8h.html#a0b9532165f3d175cd9bfa3cc64c397c2',1,'dns_compat.h']]], + ['evdns_5fserver_5foption_286',['evdns_server_option',['../dns_8h.html#a626139345ff6cb6c871e2950872e8473',1,'dns.h']]], + ['evdns_5fserver_5fport_5fset_5foption_287',['evdns_server_port_set_option',['../dns_8h.html#afdb5e0e7000a17810e762d40ecb8eda2',1,'dns.h']]], + ['evdns_5fserver_5frequest_5fdrop_288',['evdns_server_request_drop',['../dns_8h.html#a1291ec11bf79809c4ae1b113bb0160e9',1,'dns.h']]], + ['evdns_5fserver_5frequest_5fget_5frequesting_5faddr_289',['evdns_server_request_get_requesting_addr',['../dns_8h.html#a078ce45f71d886514ece8688e19ead19',1,'dns.h']]], + ['evdns_5fserver_5frequest_5frespond_290',['evdns_server_request_respond',['../dns_8h.html#a606b067e5cd3fee40b527b3cb4ec2d72',1,'dns.h']]], + ['evdns_5fserver_5frequest_5fset_5fflags_291',['evdns_server_request_set_flags',['../dns_8h.html#a849622fc8fee97302a6a0a34e7e6feb8',1,'dns.h']]], + ['evdns_5fset_5flog_5ffn_292',['evdns_set_log_fn',['../dns_8h.html#af2ba90756cecdc246711879462a20b51',1,'dns.h']]], + ['evdns_5fset_5foption_293',['evdns_set_option',['../dns__compat_8h.html#a2c7b199ba05d398d9901fed62c9467e5',1,'dns_compat.h']]], + ['evdns_5fshutdown_294',['evdns_shutdown',['../dns__compat_8h.html#a4b3aece85850a3963493ddba2d778451',1,'dns_compat.h']]], + ['evdns_5fsopt_5ftcp_5fidle_5ftimeout_295',['EVDNS_SOPT_TCP_IDLE_TIMEOUT',['../dns_8h.html#a626139345ff6cb6c871e2950872e8473a6363f0c18c4efaff4d00b27ced12e92b',1,'dns.h']]], + ['evdns_5fsopt_5ftcp_5fmax_5fclients_296',['EVDNS_SOPT_TCP_MAX_CLIENTS',['../dns_8h.html#a626139345ff6cb6c871e2950872e8473a8943e341547a0479f14a9c4de889217d',1,'dns.h']]], + ['event_297',['event',['../structevent.html',1,'']]], + ['event_2eh_298',['event.h',['../event_8h.html',1,'']]], + ['event_5factive_299',['event_active',['../event_8h.html#a31d9440cf2b7010e32a05a2142a91525',1,'event.h']]], + ['event_5fadd_300',['event_add',['../event_8h.html#ab0c85ebe9cf057be1aa17724c701b0c8',1,'event.h']]], + ['event_5fassign_301',['event_assign',['../event_8h.html#a3e49a8172e00ae82959dfe64684eda11',1,'event.h']]], + ['event_5fbase_302',['event_base',['../structevent__base.html',1,'']]], + ['event_5fbase_5factive_5fby_5ffd_303',['event_base_active_by_fd',['../event_8h.html#a092013616b4636c74e889b0b015cb75e',1,'event.h']]], + ['event_5fbase_5factive_5fby_5fsignal_304',['event_base_active_by_signal',['../event_8h.html#a4bca4d24a15bef084bf066faca8a43d2',1,'event.h']]], + ['event_5fbase_5fconfig_5fflag_305',['event_base_config_flag',['../event_8h.html#acfef69af45abee54725f40f7f29986c5',1,'event.h']]], + ['event_5fbase_5fcount_5factive_306',['EVENT_BASE_COUNT_ACTIVE',['../event_8h.html#aa3786406bc592990f0583ac211110fa3',1,'event.h']]], + ['event_5fbase_5fcount_5fadded_307',['EVENT_BASE_COUNT_ADDED',['../event_8h.html#a36205e544778da7d91ec8555b962851a',1,'event.h']]], + ['event_5fbase_5fcount_5fvirtual_308',['EVENT_BASE_COUNT_VIRTUAL',['../event_8h.html#aac4e49b51ffe924451c9048c5061a224',1,'event.h']]], + ['event_5fbase_5fdispatch_309',['event_base_dispatch',['../event_8h.html#a19d60cb72a1af398247f40e92cf07056',1,'event.h']]], + ['event_5fbase_5fdump_5fevents_310',['event_base_dump_events',['../event_8h.html#ae3ed8b33f9e0d797615c2f86ff30f5fb',1,'event.h']]], + ['event_5fbase_5fflag_5fepoll_5fdisallow_5ftimerfd_311',['EVENT_BASE_FLAG_EPOLL_DISALLOW_TIMERFD',['../event_8h.html#acfef69af45abee54725f40f7f29986c5a9eaa69643a73f5fb5959db017c9050a5',1,'event.h']]], + ['event_5fbase_5fflag_5fepoll_5fuse_5fchangelist_312',['EVENT_BASE_FLAG_EPOLL_USE_CHANGELIST',['../event_8h.html#acfef69af45abee54725f40f7f29986c5acceb45f3098787247044929f92f4296e',1,'event.h']]], + ['event_5fbase_5fflag_5fignore_5fenv_313',['EVENT_BASE_FLAG_IGNORE_ENV',['../event_8h.html#acfef69af45abee54725f40f7f29986c5a230574947412d83f2dd19fe8c7d286e7',1,'event.h']]], + ['event_5fbase_5fflag_5fno_5fcache_5ftime_314',['EVENT_BASE_FLAG_NO_CACHE_TIME',['../event_8h.html#acfef69af45abee54725f40f7f29986c5a057dff1977c48174f0a0f0c43ef92ec5',1,'event.h']]], + ['event_5fbase_5fflag_5fnolock_315',['EVENT_BASE_FLAG_NOLOCK',['../event_8h.html#acfef69af45abee54725f40f7f29986c5ac1302f72251168137258335e945e2ae5',1,'event.h']]], + ['event_5fbase_5fflag_5fprecise_5ftimer_316',['EVENT_BASE_FLAG_PRECISE_TIMER',['../event_8h.html#acfef69af45abee54725f40f7f29986c5af6080f1d7c5067868cbc749d1cfe56e9',1,'event.h']]], + ['event_5fbase_5fflag_5fstartup_5fiocp_317',['EVENT_BASE_FLAG_STARTUP_IOCP',['../event_8h.html#acfef69af45abee54725f40f7f29986c5a4ffb2510ab533d7156f412ee4f0c08ea',1,'event.h']]], + ['event_5fbase_5fflag_5fuse_5fsignalfd_318',['EVENT_BASE_FLAG_USE_SIGNALFD',['../event_8h.html#acfef69af45abee54725f40f7f29986c5a86d9f5574e29964187bafe245b211447',1,'event.h']]], + ['event_5fbase_5fforeach_5fevent_319',['event_base_foreach_event',['../event_8h.html#a7d5c38711c6a72545b939cc375468f79',1,'event.h']]], + ['event_5fbase_5fforeach_5fevent_5fcb_320',['event_base_foreach_event_cb',['../event_8h.html#a61f656b17425f17ed857b96d45fc6268',1,'event.h']]], + ['event_5fbase_5ffree_321',['event_base_free',['../event_8h.html#a91f9deb12c37f2ff586e65e8b9a46641',1,'event.h']]], + ['event_5fbase_5ffree_5fnofinalize_322',['event_base_free_nofinalize',['../event_8h.html#a385fb6f81ab73f9c95d77b7179f780e0',1,'event.h']]], + ['event_5fbase_5fget_5ffeatures_323',['event_base_get_features',['../event_8h.html#aced890aa77dac1669325f74a27584f03',1,'event.h']]], + ['event_5fbase_5fget_5fmax_5fevents_324',['event_base_get_max_events',['../event_8h.html#a9cf1a991dcad465adf4330a79576b148',1,'event.h']]], + ['event_5fbase_5fget_5fmethod_325',['event_base_get_method',['../event_8h.html#ae0910900c306cef32e2623272c7b7cb0',1,'event.h']]], + ['event_5fbase_5fget_5fnpriorities_326',['event_base_get_npriorities',['../event_8h.html#a3c91bec6e27bf2e26e8ecbb286787cc5',1,'event.h']]], + ['event_5fbase_5fget_5fnum_5fevents_327',['event_base_get_num_events',['../event_8h.html#a3dd8aaea50a18e1b300ae6a138132743',1,'event.h']]], + ['event_5fbase_5fget_5frunning_5fevent_328',['event_base_get_running_event',['../event_8h.html#a23276914af0b2527951cc7c47b46f00b',1,'event.h']]], + ['event_5fbase_5fget_5fsignal_5fmethod_329',['event_base_get_signal_method',['../event_8h.html#a138b72aa85ec5c344714867204ed3d3d',1,'event.h']]], + ['event_5fbase_5fgettimeofday_5fcached_330',['event_base_gettimeofday_cached',['../event_8h.html#a0fbd35d624f1c865329a2a388afba3fd',1,'event.h']]], + ['event_5fbase_5fgot_5fbreak_331',['event_base_got_break',['../event_8h.html#ae3853087c016ff8e877d914b1bda8f90',1,'event.h']]], + ['event_5fbase_5fgot_5fexit_332',['event_base_got_exit',['../event_8h.html#a654b3b2c5923a9c0620907701383f6dd',1,'event.h']]], + ['event_5fbase_5finit_5fcommon_5ftimeout_333',['event_base_init_common_timeout',['../event_8h.html#a46b388babfda66dcb897c9e4dbd233b1',1,'event.h']]], + ['event_5fbase_5floop_334',['event_base_loop',['../event_8h.html#acd7da32086d1e37008e7c76c9ea54fc4',1,'event.h']]], + ['event_5fbase_5floopbreak_335',['event_base_loopbreak',['../event_8h.html#a28e0be91488e8a0ed57a582f3343eaf6',1,'event.h']]], + ['event_5fbase_5floopcontinue_336',['event_base_loopcontinue',['../event_8h.html#a34ce349afe4a37119e1ac50710642ccb',1,'event.h']]], + ['event_5fbase_5floopexit_337',['event_base_loopexit',['../event_8h.html#a67ba4db4b6e7467b3412219530603e60',1,'event.h']]], + ['event_5fbase_5fnew_338',['event_base_new',['../event_8h.html#af34c025430d445427a2a5661082405c3',1,'event.h']]], + ['event_5fbase_5fnew_5fwith_5fconfig_339',['event_base_new_with_config',['../event_8h.html#a864798e5b3c6aa8d2f9e9c5035a3e6da',1,'event.h']]], + ['event_5fbase_5fonce_340',['event_base_once',['../event_8h.html#ae4d40e572ad8310897ce06f9fe0f9062',1,'event.h']]], + ['event_5fbase_5fpriority_5finit_341',['event_base_priority_init',['../event_8h.html#a289e44ce22c816060bf7b7bfe38720b9',1,'event.h']]], + ['event_5fbase_5fset_342',['event_base_set',['../event_8h.html#a20fb823ec65b17519ec07aee1a0a22ba',1,'event.h']]], + ['event_5fbase_5fupdate_5fcache_5ftime_343',['event_base_update_cache_time',['../event_8h.html#ae920425b48421c3cb7cb5e0802e4af9d',1,'event.h']]], + ['event_5fcallback_5ffn_344',['event_callback_fn',['../event_8h.html#aed2307f3d9b38e07cc10c2607322d758',1,'event.h']]], + ['event_5fcompat_2eh_345',['event_compat.h',['../event__compat_8h.html',1,'']]], + ['event_5fconfig_346',['event_config',['../structevent__config.html',1,'']]], + ['event_5fconfig_5favoid_5fmethod_347',['event_config_avoid_method',['../event_8h.html#ac5328011d251a7af085fdc19deb748bc',1,'event.h']]], + ['event_5fconfig_5ffree_348',['event_config_free',['../event_8h.html#ad7917192d1f78884de03a8777013fd1c',1,'event.h']]], + ['event_5fconfig_5fnew_349',['event_config_new',['../event_8h.html#a76f3b4191e43c8b4758b99da761c858e',1,'event.h']]], + ['event_5fconfig_5frequire_5ffeatures_350',['event_config_require_features',['../event_8h.html#ab76526f5bcd7b05d63f38fca439d7492',1,'event.h']]], + ['event_5fconfig_5fset_5fflag_351',['event_config_set_flag',['../event_8h.html#ae9e42b61a7e8465b7c897432c4ddcabd',1,'event.h']]], + ['event_5fconfig_5fset_5fmax_5fdispatch_5finterval_352',['event_config_set_max_dispatch_interval',['../event_8h.html#aeb08f9ff880ff8a07eb623124f48f979',1,'event.h']]], + ['event_5fconfig_5fset_5fnum_5fcpus_5fhint_353',['event_config_set_num_cpus_hint',['../event_8h.html#a472425045a342e48429e408eaeb81d18',1,'event.h']]], + ['event_5fdebug_5funassign_354',['event_debug_unassign',['../event_8h.html#a1347923dccea548c036ccc7614c5b595',1,'event.h']]], + ['event_5fdel_355',['event_del',['../event_8h.html#a2ffc10a652c67bea16b0a71f7d5a44dc',1,'event.h']]], + ['event_5fdel_5fblock_356',['event_del_block',['../event_8h.html#a8236f5e7e9d845cd127e768b2747df9c',1,'event.h']]], + ['event_5fdel_5fnoblock_357',['event_del_noblock',['../event_8h.html#a54ae25b313b15e6038b5dd87c740e39e',1,'event.h']]], + ['event_5fdispatch_358',['event_dispatch',['../event__compat_8h.html#af4db42ebbe9e6ee92128e99523e5987f',1,'event_compat.h']]], + ['event_5fenable_5fdebug_5flogging_359',['event_enable_debug_logging',['../event_8h.html#abce01eafdfef974a80fdf9a507f5eca9',1,'event.h']]], + ['event_5fenable_5fdebug_5fmode_360',['event_enable_debug_mode',['../event_8h.html#a37441a3defac55b5d2513521964b2af5',1,'event.h']]], + ['event_5ffatal_5fcb_361',['event_fatal_cb',['../event_8h.html#abb799b636f0d3aab6ca17426d88473cf',1,'event.h']]], + ['event_5ffinalize_5fcallback_5ffn_362',['event_finalize_callback_fn',['../event_8h.html#a6f62afb6e295ee487ad947e4eec18332',1,'event.h']]], + ['event_5ffree_363',['event_free',['../event_8h.html#a1f326019b65d319b2221b7e57d56c273',1,'event.h']]], + ['event_5fget_5fassignment_364',['event_get_assignment',['../event_8h.html#a6ddcda6db7bd3fc1e0f635d60e145a03',1,'event.h']]], + ['event_5fget_5fbase_365',['event_get_base',['../event_8h.html#ab90af034dd2638511f483bd25effdc77',1,'event.h']]], + ['event_5fget_5fcallback_366',['event_get_callback',['../event_8h.html#a6e325a315660638135385dc3b608bf85',1,'event.h']]], + ['event_5fget_5fcallback_5farg_367',['event_get_callback_arg',['../event_8h.html#ad868b16c4dc7450e49ba277b9ee7b467',1,'event.h']]], + ['event_5fget_5fevents_368',['event_get_events',['../event_8h.html#a70989121937ecb71358a2d76be772d51',1,'event.h']]], + ['event_5fget_5ffd_369',['event_get_fd',['../event_8h.html#a4f63589ebe3e0d4c9e20447f96d343b2',1,'event.h']]], + ['event_5fget_5fmethod_370',['event_get_method',['../event__compat_8h.html#a756cb3d9a3671a5a03387a2f18ff83e8',1,'event_compat.h']]], + ['event_5fget_5fpriority_371',['event_get_priority',['../event_8h.html#abbc9ca70c2b59b3c1b5767b7675920c3',1,'event.h']]], + ['event_5fget_5fsignal_372',['event_get_signal',['../event_8h.html#a69cc368a9137187726ef371a06f9cc9f',1,'event.h']]], + ['event_5fget_5fstruct_5fevent_5fsize_373',['event_get_struct_event_size',['../event_8h.html#a0f93db0db7e74f9ae173e1766415dd56',1,'event.h']]], + ['event_5fget_5fsupported_5fmethods_374',['event_get_supported_methods',['../event_8h.html#a7abb8da4e334086319949997fd51c799',1,'event.h']]], + ['event_5fget_5fversion_375',['event_get_version',['../event_8h.html#a328e99de6281ce1645935835e44341b6',1,'event.h']]], + ['event_5fget_5fversion_5fnumber_376',['event_get_version_number',['../event_8h.html#a578ddddcc39d197630e7909b7da443e3',1,'event.h']]], + ['event_5fgettime_5fmonotonic_377',['event_gettime_monotonic',['../event_8h.html#a0c624a8830f69b32ee11faabc8ebb99a',1,'event.h']]], + ['event_5finit_378',['event_init',['../event__compat_8h.html#aa72d84e78eb6f08dc580e6245c087cb6',1,'event_compat.h']]], + ['event_5finitialized_379',['event_initialized',['../event_8h.html#a85b94b111b8aa7fb480fc2f9da7f8e18',1,'event.h']]], + ['event_5flog_5fcb_380',['event_log_cb',['../event_8h.html#a185f44c610d7ee21ecba720561b2e09c',1,'event.h']]], + ['event_5floop_381',['event_loop',['../event__compat_8h.html#a3d6542d4518f6873ef9d308e3ee525e1',1,'event_compat.h']]], + ['event_5floopbreak_382',['event_loopbreak',['../event__compat_8h.html#a497e5e360112dcbdc8409ecb45c2c565',1,'event_compat.h']]], + ['event_5floopexit_383',['event_loopexit',['../event__compat_8h.html#a88b7e5bb1e7bd5e617167ed6192fdd66',1,'event_compat.h']]], + ['event_5fmax_5fpriorities_384',['EVENT_MAX_PRIORITIES',['../event_8h.html#ad74f7bf73ff985bfaf61c462cbba022f',1,'event.h']]], + ['event_5fmethod_5ffeature_385',['event_method_feature',['../event_8h.html#ae7da61aef13e27a3047151b696b44c80',1,'event.h']]], + ['event_5fnew_386',['event_new',['../event_8h.html#a6cd300e5cd15601c5e4570b221b20397',1,'event.h']]], + ['event_5fonce_387',['event_once',['../event__compat_8h.html#aa7139d18495e80b2e31961c1c553d45e',1,'event_compat.h']]], + ['event_5fpending_388',['event_pending',['../event_8h.html#a9b1687396305898af018c74e63486eb5',1,'event.h']]], + ['event_5fpriority_5finit_389',['event_priority_init',['../event__compat_8h.html#ade115d1b3302c33a6308c50964b6304e',1,'event_compat.h']]], + ['event_5fpriority_5fset_390',['event_priority_set',['../event_8h.html#a11a800dce1fe61de5e2506aaf603c47f',1,'event.h']]], + ['event_5freinit_391',['event_reinit',['../event_8h.html#a7f05aabb4fbcd2ba676bb6ba92f21630',1,'event.h']]], + ['event_5fremove_5ftimer_392',['event_remove_timer',['../event_8h.html#a6d3aae1a8b2c0002e5744fb54ba4fe64',1,'event.h']]], + ['event_5fself_5fcbarg_393',['event_self_cbarg',['../event_8h.html#aaf0b6ecbbc95137d7a6621f46670acad',1,'event.h']]], + ['event_5fset_394',['event_set',['../event__compat_8h.html#af06653a20ca79b6229adf89630d20916',1,'event_compat.h']]], + ['event_5fset_5ffatal_5fcallback_395',['event_set_fatal_callback',['../event_8h.html#a1d0efefe738406049a7bd71e2e59ccfb',1,'event.h']]], + ['event_5fset_5flog_5fcallback_396',['event_set_log_callback',['../event_8h.html#a2ec6be5aff4af06b22da20d5ad747ff2',1,'event.h']]], + ['event_5fset_5fmem_5ffunctions_397',['event_set_mem_functions',['../event_8h.html#a9bb71feea97288bc15d2fba3dccd46bf',1,'event.h']]], + ['event_5fset_5fmem_5ffunctions_5fimplemented_398',['EVENT_SET_MEM_FUNCTIONS_IMPLEMENTED',['../event_8h.html#ade387a9a39bbbdf40ff20b4d977ec6ae',1,'event.h']]], + ['evhttp_5faccept_5fsocket_399',['evhttp_accept_socket',['../http_8h.html#ae8599595a7617e5e3c213e45c10d22a0',1,'http.h']]], + ['evhttp_5faccept_5fsocket_5fwith_5fhandle_400',['evhttp_accept_socket_with_handle',['../http_8h.html#a68381a3b8dbab796bdcf44ef64a45a73',1,'http.h']]], + ['evhttp_5fadd_5fheader_401',['evhttp_add_header',['../http_8h.html#a04d806174bb259be406b32669a4ed9cc',1,'http.h']]], + ['evhttp_5fadd_5fserver_5falias_402',['evhttp_add_server_alias',['../http_8h.html#afa5936add0f808199f617be4aa42bbd7',1,'http.h']]], + ['evhttp_5fadd_5fvirtual_5fhost_403',['evhttp_add_virtual_host',['../http_8h.html#ad89bdd6053de1ff73fab1b2bb3c3182f',1,'http.h']]], + ['evhttp_5fbind_5flistener_404',['evhttp_bind_listener',['../http_8h.html#a18d321f8f459b7d6e1826b3e8c53c921',1,'http.h']]], + ['evhttp_5fbind_5fsocket_405',['evhttp_bind_socket',['../http_8h.html#a3431520b3bd31e957e93e519b2fe56a5',1,'http.h']]], + ['evhttp_5fbind_5fsocket_5fwith_5fhandle_406',['evhttp_bind_socket_with_handle',['../http_8h.html#a5cb57564c8af123b17e8330d2f104a1d',1,'http.h']]], + ['evhttp_5fbound_5fsocket_5fget_5ffd_407',['evhttp_bound_socket_get_fd',['../http_8h.html#a586eeb946ec397fec8094c25b7d1d9e4',1,'http.h']]], + ['evhttp_5fbound_5fsocket_5fget_5flistener_408',['evhttp_bound_socket_get_listener',['../http_8h.html#a4216e1d29237ab9511eaf55433293e8b',1,'http.h']]], + ['evhttp_5fcancel_5frequest_409',['evhttp_cancel_request',['../http_8h.html#a7758d5808bd2e062d2aa3912ca19d2fd',1,'http.h']]], + ['evhttp_5fclear_5fheaders_410',['evhttp_clear_headers',['../http_8h.html#ad2399662cdf2e300251d4330c649ac77',1,'http.h']]], + ['evhttp_5fcmd_5ftype_411',['evhttp_cmd_type',['../http_8h.html#ac858319d667267f9fc848c2bb6931aa3',1,'http.h']]], + ['evhttp_5fconnection_5fbase_5fbufferevent_5fnew_412',['evhttp_connection_base_bufferevent_new',['../http_8h.html#ab6a2f82ff7323986705ead089a2d3f58',1,'http.h']]], + ['evhttp_5fconnection_5fbase_5fbufferevent_5funix_5fnew_413',['evhttp_connection_base_bufferevent_unix_new',['../http_8h.html#aab47f88b970a6a49c0297cd7314f154b',1,'http.h']]], + ['evhttp_5fconnection_5fbase_5fnew_414',['evhttp_connection_base_new',['../http_8h.html#ae91224cfece07d01a029eb67e9053819',1,'http.h']]], + ['evhttp_5fconnection_5ffree_415',['evhttp_connection_free',['../http_8h.html#aaf15e06932005ac0bc890b6fe72b19e3',1,'http.h']]], + ['evhttp_5fconnection_5ffree_5fon_5fcompletion_416',['evhttp_connection_free_on_completion',['../http_8h.html#af33ddcfb93380ab98ac0f75426480824',1,'http.h']]], + ['evhttp_5fconnection_5fget_5faddr_417',['evhttp_connection_get_addr',['../http_8h.html#ae0097ea31d96c509962b3d3df5ca6958',1,'http.h']]], + ['evhttp_5fconnection_5fget_5fbase_418',['evhttp_connection_get_base',['../http_8h.html#a605b42ad45d6e804e1a21204b33a2e42',1,'http.h']]], + ['evhttp_5fconnection_5fget_5fbufferevent_419',['evhttp_connection_get_bufferevent',['../http_8h.html#a04ae09d5ca4ced488a0feb4b5145e95c',1,'http.h']]], + ['evhttp_5fconnection_5fget_5fpeer_420',['evhttp_connection_get_peer',['../http_8h.html#a8d21ffce46e0207d97d31cfac295e079',1,'http.h']]], + ['evhttp_5fconnection_5fget_5fserver_421',['evhttp_connection_get_server',['../http_8h.html#a4ab7ae144cf7aac8a512deb0dbaf9ac8',1,'http.h']]], + ['evhttp_5fconnection_5fnew_422',['evhttp_connection_new',['../http__compat_8h.html#a2e1ca8b7e6d1cc4ed0e0a2e864496e92',1,'http_compat.h']]], + ['evhttp_5fconnection_5fset_5fbase_423',['evhttp_connection_set_base',['../http__compat_8h.html#a005fff08e18b6ca6689c1226dd9d00fb',1,'http_compat.h']]], + ['evhttp_5fconnection_5fset_5fclosecb_424',['evhttp_connection_set_closecb',['../http_8h.html#afac5a00d6baf28ecb5c7d52dee757bd1',1,'http.h']]], + ['evhttp_5fconnection_5fset_5fconnect_5ftimeout_5ftv_425',['evhttp_connection_set_connect_timeout_tv',['../http_8h.html#a3070128a12534b199f5dd24673fad4c4',1,'http.h']]], + ['evhttp_5fconnection_5fset_5fext_5fmethod_5fcmp_426',['evhttp_connection_set_ext_method_cmp',['../http_8h.html#a8b60b73ced5441bd9a2a4fe114db7db0',1,'http.h']]], + ['evhttp_5fconnection_5fset_5ffamily_427',['evhttp_connection_set_family',['../http_8h.html#a33eb3d75bb0ae4b4d19678f8f7d97636',1,'http.h']]], + ['evhttp_5fconnection_5fset_5fflags_428',['evhttp_connection_set_flags',['../http_8h.html#a081b1b41e26d62c5690bdd79109cdcfd',1,'http.h']]], + ['evhttp_5fconnection_5fset_5finitial_5fretry_5ftv_429',['evhttp_connection_set_initial_retry_tv',['../http_8h.html#a8b33510923ba80494353419fd769729c',1,'http.h']]], + ['evhttp_5fconnection_5fset_5flocal_5faddress_430',['evhttp_connection_set_local_address',['../http_8h.html#a1125aa44cce8ee1faf9c0bdfc6e815c8',1,'http.h']]], + ['evhttp_5fconnection_5fset_5flocal_5fport_431',['evhttp_connection_set_local_port',['../http_8h.html#a881ace0b082a725cbd7156e8d701db7a',1,'http.h']]], + ['evhttp_5fconnection_5fset_5fread_5ftimeout_5ftv_432',['evhttp_connection_set_read_timeout_tv',['../http_8h.html#a8ce5c2c1090309215004e8490014d7a8',1,'http.h']]], + ['evhttp_5fconnection_5fset_5fretries_433',['evhttp_connection_set_retries',['../http_8h.html#a2d1ec8afb0b84b591e40daa8d25594b9',1,'http.h']]], + ['evhttp_5fconnection_5fset_5ftimeout_434',['evhttp_connection_set_timeout',['../http_8h.html#af74808e97c298ae690b29d45e8cf2f7b',1,'http.h']]], + ['evhttp_5fconnection_5fset_5ftimeout_5ftv_435',['evhttp_connection_set_timeout_tv',['../http_8h.html#ab8d3d92102ff797ea2375db5235ebe49',1,'http.h']]], + ['evhttp_5fconnection_5fset_5fwrite_5ftimeout_5ftv_436',['evhttp_connection_set_write_timeout_tv',['../http_8h.html#a29110fb60e660f33f2d20a964dcb2d37',1,'http.h']]], + ['evhttp_5fdecode_5furi_437',['evhttp_decode_uri',['../http_8h.html#a6ac6bc2748f226d50367245989e7acd1',1,'http.h']]], + ['evhttp_5fdel_5faccept_5fsocket_438',['evhttp_del_accept_socket',['../http_8h.html#a565c02c3469c28c1c043cb4a1e3b242c',1,'http.h']]], + ['evhttp_5fdel_5fcb_439',['evhttp_del_cb',['../http_8h.html#ad7afbe5f5ce3dd8aa00496c859847947',1,'http.h']]], + ['evhttp_5fencode_5furi_440',['evhttp_encode_uri',['../http_8h.html#a8742ce04eb4951e7af8cb200bc9669ef',1,'http.h']]], + ['evhttp_5fext_5fmethod_441',['evhttp_ext_method',['../structevhttp__ext__method.html',1,'']]], + ['evhttp_5ffind_5fheader_442',['evhttp_find_header',['../http_8h.html#a54b0a309df8639541cfb552ab152e9bd',1,'http.h']]], + ['evhttp_5fforeach_5fbound_5fsocket_443',['evhttp_foreach_bound_socket',['../http_8h.html#ad15b347cd339ce5b03c806c0f7adaecf',1,'http.h']]], + ['evhttp_5ffree_444',['evhttp_free',['../http_8h.html#a12b2e61a0088e3707198876ae1e61f3f',1,'http.h']]], + ['evhttp_5fget_5fconnection_5fcount_445',['evhttp_get_connection_count',['../http_8h.html#acdc4276e80df2a99d64944598fc946ee',1,'http.h']]], + ['evhttp_5fhtmlescape_446',['evhttp_htmlescape',['../http_8h.html#a28fb801171a5f4a71057629e15c70fb5',1,'http.h']]], + ['evhttp_5fmake_5frequest_447',['evhttp_make_request',['../http_8h.html#a88c4f63045dc6567f8220d6d37426924',1,'http.h']]], + ['evhttp_5fnew_448',['evhttp_new',['../http_8h.html#a5baa37a340f5be4b2c6062327e0a84e1',1,'http.h']]], + ['evhttp_5fparse_5fquery_449',['evhttp_parse_query',['../http_8h.html#ad9b32eed2eb6693eef5694052f2223a8',1,'http.h']]], + ['evhttp_5fparse_5fquery_5fstr_450',['evhttp_parse_query_str',['../http_8h.html#a9a61f2b2ae4b7b733871f64e89360d75',1,'http.h']]], + ['evhttp_5fparse_5fquery_5fstr_5fflags_451',['evhttp_parse_query_str_flags',['../http_8h.html#a1a9d2efb83e6599e7e6aa2130018fedc',1,'http.h']]], + ['evhttp_5fremove_5fheader_452',['evhttp_remove_header',['../http_8h.html#acbdce3871fffa5c0c97c0680eb1ea668',1,'http.h']]], + ['evhttp_5fremove_5fserver_5falias_453',['evhttp_remove_server_alias',['../http_8h.html#a6b2b581793f361f68fd21cff110aa262',1,'http.h']]], + ['evhttp_5fremove_5fvirtual_5fhost_454',['evhttp_remove_virtual_host',['../http_8h.html#a68ec9dd6e33b7505a1ccde9e3d55b18a',1,'http.h']]], + ['evhttp_5frequest_5ferror_455',['evhttp_request_error',['../http_8h.html#a01f921a909d1504f873222b1d29c2b4a',1,'http.h']]], + ['evhttp_5frequest_5ffree_456',['evhttp_request_free',['../http_8h.html#a740defd3a36e3d609a362cee96508402',1,'http.h']]], + ['evhttp_5frequest_5fget_5fcommand_457',['evhttp_request_get_command',['../http_8h.html#aaef4dc4d2dfd468b5f3497853d6c0486',1,'http.h']]], + ['evhttp_5frequest_5fget_5fconnection_458',['evhttp_request_get_connection',['../http_8h.html#a2d816772ec078f8cf0367b4be63095b3',1,'http.h']]], + ['evhttp_5frequest_5fget_5fevhttp_5furi_459',['evhttp_request_get_evhttp_uri',['../http_8h.html#af528a5c6a3a6212cefadf21f751a9718',1,'http.h']]], + ['evhttp_5frequest_5fget_5fhost_460',['evhttp_request_get_host',['../http_8h.html#afded43caaf7dc2d0532f50b4a463f7d1',1,'http.h']]], + ['evhttp_5frequest_5fget_5finput_5fbuffer_461',['evhttp_request_get_input_buffer',['../http_8h.html#a5a7df0b7b7a10bda540ba24cd1021c80',1,'http.h']]], + ['evhttp_5frequest_5fget_5finput_5fheaders_462',['evhttp_request_get_input_headers',['../http_8h.html#a3ab43473b2830c8d0f3b8ec14c6f9fdf',1,'http.h']]], + ['evhttp_5frequest_5fget_5foutput_5fbuffer_463',['evhttp_request_get_output_buffer',['../http_8h.html#ae4c4774bbd23cd887ceda30c3e7ea094',1,'http.h']]], + ['evhttp_5frequest_5fget_5foutput_5fheaders_464',['evhttp_request_get_output_headers',['../http_8h.html#ad12a28805401f4f498964987385ed1e3',1,'http.h']]], + ['evhttp_5frequest_5fget_5furi_465',['evhttp_request_get_uri',['../http_8h.html#aa02d664574b2aefbb671f8534e5c476a',1,'http.h']]], + ['evhttp_5frequest_5fis_5fowned_466',['evhttp_request_is_owned',['../http_8h.html#a980ad5b5a00bef46201b1683ef0e2ee1',1,'http.h']]], + ['evhttp_5frequest_5fkind_467',['evhttp_request_kind',['../http_8h.html#a47ca41a942899d019bf59cf32301ae4f',1,'http.h']]], + ['evhttp_5frequest_5fnew_468',['evhttp_request_new',['../http_8h.html#a66ffd177b52ffc59163c708d9b2f7275',1,'http.h']]], + ['evhttp_5frequest_5fown_469',['evhttp_request_own',['../http_8h.html#aa1bd475e8be9f389586a6be9fbb242d4',1,'http.h']]], + ['evhttp_5frequest_5fset_5fchunked_5fcb_470',['evhttp_request_set_chunked_cb',['../http_8h.html#ace8a70a82c88bfc3856a1b2ae1c9a40b',1,'http.h']]], + ['evhttp_5frequest_5fset_5ferror_5fcb_471',['evhttp_request_set_error_cb',['../http_8h.html#a90bf87f4fdaea3ccf414bf8572b0228a',1,'http.h']]], + ['evhttp_5frequest_5fset_5fheader_5fcb_472',['evhttp_request_set_header_cb',['../http_8h.html#a3d812da94907b41165dfa2efc09bd329',1,'http.h']]], + ['evhttp_5frequest_5fset_5fon_5fcomplete_5fcb_473',['evhttp_request_set_on_complete_cb',['../http_8h.html#a83469b1ba147fc46a98d4f94cbd99a45',1,'http.h']]], + ['evhttp_5frequest_5furi_474',['evhttp_request_uri',['../http__compat_8h.html#aae95ca15c179b4b0b8c7bbb7b1da342a',1,'http_compat.h']]], + ['evhttp_5fsend_5ferror_475',['evhttp_send_error',['../http_8h.html#a47d90ffdd80edc13ab4197e2c21a1403',1,'http.h']]], + ['evhttp_5fsend_5freply_476',['evhttp_send_reply',['../http_8h.html#a0a77d07263e20733a7562dcd576ad721',1,'http.h']]], + ['evhttp_5fsend_5freply_5fchunk_477',['evhttp_send_reply_chunk',['../http_8h.html#a380c78fba2c4d5efe22191673c4ed1a7',1,'http.h']]], + ['evhttp_5fsend_5freply_5fchunk_5fwith_5fcb_478',['evhttp_send_reply_chunk_with_cb',['../http_8h.html#a694a80962c9dd37014b4bd61f6a04275',1,'http.h']]], + ['evhttp_5fsend_5freply_5fend_479',['evhttp_send_reply_end',['../http_8h.html#a014b3c0c4f85a2c7bc7f4092aaf19884',1,'http.h']]], + ['evhttp_5fsend_5freply_5fstart_480',['evhttp_send_reply_start',['../http_8h.html#a730f35086068b559b2bd324d07591283',1,'http.h']]], + ['evhttp_5fset_5fallowed_5fmethods_481',['evhttp_set_allowed_methods',['../http_8h.html#a5682dc2fe3f18dcbffd9a55bcebac9a0',1,'http.h']]], + ['evhttp_5fset_5fbevcb_482',['evhttp_set_bevcb',['../http_8h.html#ae4accb83b76a63db8b6fe5e765df1411',1,'http.h']]], + ['evhttp_5fset_5fcb_483',['evhttp_set_cb',['../http_8h.html#af1b22fdf5ea2c6335ccbc96fb930774e',1,'http.h']]], + ['evhttp_5fset_5fdefault_5fcontent_5ftype_484',['evhttp_set_default_content_type',['../http_8h.html#a53cbc32c73ae066cf6140698a2fca532',1,'http.h']]], + ['evhttp_5fset_5ferrorcb_485',['evhttp_set_errorcb',['../http_8h.html#a7ff8d8b085885abf2037f0b4d0cc8c39',1,'http.h']]], + ['evhttp_5fset_5fext_5fmethod_5fcmp_486',['evhttp_set_ext_method_cmp',['../http_8h.html#a171f175f66ceb0bd7ca93b32229a54c5',1,'http.h']]], + ['evhttp_5fset_5fflags_487',['evhttp_set_flags',['../http_8h.html#ab531e7d4962724efa3401d11edea1150',1,'http.h']]], + ['evhttp_5fset_5fgencb_488',['evhttp_set_gencb',['../http_8h.html#a52e68315974c684709c373fe7c46bec8',1,'http.h']]], + ['evhttp_5fset_5fmax_5fbody_5fsize_489',['evhttp_set_max_body_size',['../http_8h.html#a4ba3aa63bccc4f2ec3c18d4eb26be851',1,'http.h']]], + ['evhttp_5fset_5fmax_5fconnections_490',['evhttp_set_max_connections',['../http_8h.html#a9ee088f799a4f8ade368f0e18817d432',1,'http.h']]], + ['evhttp_5fset_5fmax_5fheaders_5fsize_491',['evhttp_set_max_headers_size',['../http_8h.html#a1d118ec9cf879e60df5e800a53fa7be5',1,'http.h']]], + ['evhttp_5fset_5fnewreqcb_492',['evhttp_set_newreqcb',['../http_8h.html#a5d57616424673f65eee38f0dc8293373',1,'http.h']]], + ['evhttp_5fset_5fread_5ftimeout_5ftv_493',['evhttp_set_read_timeout_tv',['../http_8h.html#ae4efab329925d632a9e94a3065b8d17f',1,'http.h']]], + ['evhttp_5fset_5ftimeout_494',['evhttp_set_timeout',['../http_8h.html#a5b4a6022933fb806d621a398ceec8eb2',1,'http.h']]], + ['evhttp_5fset_5ftimeout_5ftv_495',['evhttp_set_timeout_tv',['../http_8h.html#a3ea68d1a73ae1a09c6398e264b357407',1,'http.h']]], + ['evhttp_5fset_5fwrite_5ftimeout_5ftv_496',['evhttp_set_write_timeout_tv',['../http_8h.html#ae0916087937baf9c4e99e19301ae59f8',1,'http.h']]], + ['evhttp_5fstart_497',['evhttp_start',['../http__compat_8h.html#ae6e4bd50d3da5bdac6457ffc03f4db06',1,'http_compat.h']]], + ['evhttp_5furi_5ffree_498',['evhttp_uri_free',['../http_8h.html#a656211357bacf7fae9d09d2d23f7f4b0',1,'http.h']]], + ['evhttp_5furi_5fget_5ffragment_499',['evhttp_uri_get_fragment',['../http_8h.html#af2d03ee60bd21072b67ec7b89d476226',1,'http.h']]], + ['evhttp_5furi_5fget_5fhost_500',['evhttp_uri_get_host',['../http_8h.html#aaa22a9dc787b32f5133e81a7f5e96d25',1,'http.h']]], + ['evhttp_5furi_5fget_5fpath_501',['evhttp_uri_get_path',['../http_8h.html#a8264b614f23012200c559e25f37f8a4c',1,'http.h']]], + ['evhttp_5furi_5fget_5fport_502',['evhttp_uri_get_port',['../http_8h.html#a1ee1f098fa176ae0b33729308a35136d',1,'http.h']]], + ['evhttp_5furi_5fget_5fquery_503',['evhttp_uri_get_query',['../http_8h.html#a02a52f21c3c169729110efb289835b55',1,'http.h']]], + ['evhttp_5furi_5fget_5fscheme_504',['evhttp_uri_get_scheme',['../http_8h.html#a2b19501e4d1ae89df696304e9b18fbe0',1,'http.h']]], + ['evhttp_5furi_5fget_5funixsocket_505',['evhttp_uri_get_unixsocket',['../http_8h.html#a56fd87a6f536bb28a66dbbfda1eaf328',1,'http.h']]], + ['evhttp_5furi_5fget_5fuserinfo_506',['evhttp_uri_get_userinfo',['../http_8h.html#aab0d0c0b1a761ab88a9c105330170f10',1,'http.h']]], + ['evhttp_5furi_5fhost_5fstrip_5fbrackets_507',['EVHTTP_URI_HOST_STRIP_BRACKETS',['../http_8h.html#a8260a82157dadb3a659cb1ba783bb304',1,'http.h']]], + ['evhttp_5furi_5fjoin_508',['evhttp_uri_join',['../http_8h.html#a8eb220c9f81c70ccd3f69fb692cffbda',1,'http.h']]], + ['evhttp_5furi_5fnew_509',['evhttp_uri_new',['../http_8h.html#a4447fa5bf7323b98a74fc660bcd892d8',1,'http.h']]], + ['evhttp_5furi_5fnonconformant_510',['EVHTTP_URI_NONCONFORMANT',['../http_8h.html#ace576911d436a163584f4942907270a5',1,'http.h']]], + ['evhttp_5furi_5fparse_511',['evhttp_uri_parse',['../http_8h.html#abdae107e1eba62a9a015892fb761f074',1,'http.h']]], + ['evhttp_5furi_5fparse_5fwith_5fflags_512',['evhttp_uri_parse_with_flags',['../http_8h.html#ac6cc995d43fb39f838d2ff866057673c',1,'http.h']]], + ['evhttp_5furi_5fquery_5flast_5fval_513',['EVHTTP_URI_QUERY_LAST_VAL',['../http_8h.html#a12b8b97844f5d13e2f7b6d5c9f8ce0b6',1,'http.h']]], + ['evhttp_5furi_5fquery_5fnonconformant_514',['EVHTTP_URI_QUERY_NONCONFORMANT',['../http_8h.html#a64c9b77846e83a6f3d45f4be4b7150de',1,'http.h']]], + ['evhttp_5furi_5fset_5fflags_515',['evhttp_uri_set_flags',['../http_8h.html#aa18f3bc6e899f80ba047a683d245245b',1,'http.h']]], + ['evhttp_5furi_5fset_5ffragment_516',['evhttp_uri_set_fragment',['../http_8h.html#a6ffbf72e6974650339f89b23a8d8fc30',1,'http.h']]], + ['evhttp_5furi_5fset_5fhost_517',['evhttp_uri_set_host',['../http_8h.html#a71b70977e40970863c611dc9f8c66f0f',1,'http.h']]], + ['evhttp_5furi_5fset_5fpath_518',['evhttp_uri_set_path',['../http_8h.html#a55ae372c7045ed54e9193a061e440b59',1,'http.h']]], + ['evhttp_5furi_5fset_5fport_519',['evhttp_uri_set_port',['../http_8h.html#a44aebcf9b67a66025af7d002df0ecde1',1,'http.h']]], + ['evhttp_5furi_5fset_5fquery_520',['evhttp_uri_set_query',['../http_8h.html#aa1de728d898f2ec5deab6299d885d286',1,'http.h']]], + ['evhttp_5furi_5fset_5fscheme_521',['evhttp_uri_set_scheme',['../http_8h.html#a45fcdbd2ca2683418f3745cbb8745256',1,'http.h']]], + ['evhttp_5furi_5fset_5funixsocket_522',['evhttp_uri_set_unixsocket',['../http_8h.html#ac7259917dbf5cac8ff0e3d00b8574cbe',1,'http.h']]], + ['evhttp_5furi_5fset_5fuserinfo_523',['evhttp_uri_set_userinfo',['../http_8h.html#a12083a9ed157ed7d0d980973613e7f18',1,'http.h']]], + ['evhttp_5furi_5funix_5fsocket_524',['EVHTTP_URI_UNIX_SOCKET',['../http_8h.html#a3e2dab6e699d45bb208299312e73b2aa',1,'http.h']]], + ['evhttp_5furidecode_525',['evhttp_uridecode',['../http_8h.html#a837276600c9c2f0521c44879c8d371b7',1,'http.h']]], + ['evhttp_5furiencode_526',['evhttp_uriencode',['../http_8h.html#ad9259be209e6afbf15987922d1841e70',1,'http.h']]], + ['evloop_5fno_5fexit_5fon_5fempty_527',['EVLOOP_NO_EXIT_ON_EMPTY',['../event_8h.html#a6751a7d5867ff8e7807400a93ffd5b08',1,'event.h']]], + ['evloop_5fnonblock_528',['EVLOOP_NONBLOCK',['../event_8h.html#a10b9c102337d0ece8607c9c01bc4f7c8',1,'event.h']]], + ['evloop_5fonce_529',['EVLOOP_ONCE',['../event_8h.html#afab575b1e867dde13a2c7f2f967e0e4e',1,'event.h']]], + ['evreq_5fhttp_5fbuffer_5ferror_530',['EVREQ_HTTP_BUFFER_ERROR',['../http_8h.html#a01f921a909d1504f873222b1d29c2b4aa3bd6cb0d713a8ae9eaa3cf667a3edc9b',1,'http.h']]], + ['evreq_5fhttp_5fdata_5ftoo_5flong_531',['EVREQ_HTTP_DATA_TOO_LONG',['../http_8h.html#a01f921a909d1504f873222b1d29c2b4aac26adda43a54b9011756e83e93b9b26b',1,'http.h']]], + ['evreq_5fhttp_5feof_532',['EVREQ_HTTP_EOF',['../http_8h.html#a01f921a909d1504f873222b1d29c2b4aac2922c6ca9cd576a7e722f18876676a8',1,'http.h']]], + ['evreq_5fhttp_5finvalid_5fheader_533',['EVREQ_HTTP_INVALID_HEADER',['../http_8h.html#a01f921a909d1504f873222b1d29c2b4aad755cf3b1ab25bdfede358b137e7d1e4',1,'http.h']]], + ['evreq_5fhttp_5frequest_5fcancel_534',['EVREQ_HTTP_REQUEST_CANCEL',['../http_8h.html#a01f921a909d1504f873222b1d29c2b4aaa07ee0241ac812c0e8bc1eabc5ac810d',1,'http.h']]], + ['evreq_5fhttp_5ftimeout_535',['EVREQ_HTTP_TIMEOUT',['../http_8h.html#a01f921a909d1504f873222b1d29c2b4aa52bd0bcf036c6577b3ea55c7c086880d',1,'http.h']]], + ['evrpc_5fadd_5fhook_536',['evrpc_add_hook',['../rpc_8h.html#a5d82ac478904ddadeba9af7e695b254d',1,'rpc.h']]], + ['evrpc_5fcontinue_537',['EVRPC_CONTINUE',['../rpc_8h.html#a9c37f133ebc96b2bd66c472079b1338ba4f92aee79d3413c4940eeb578ee33643',1,'rpc.h']]], + ['evrpc_5ffree_538',['evrpc_free',['../rpc_8h.html#aefeb82c78c1a6e2338d32cfcb02297c6',1,'rpc.h']]], + ['evrpc_5fgenerate_539',['EVRPC_GENERATE',['../rpc_8h.html#af7abcafae087e3c4dce6a4cd85346114',1,'rpc.h']]], + ['evrpc_5fget_5frequest_540',['evrpc_get_request',['../rpc_8h.html#abb47f45ebbc9c6322f3d57dc0bc9dd0d',1,'rpc.h']]], + ['evrpc_5fheader_541',['EVRPC_HEADER',['../rpc_8h.html#aa526799df545537b2dc67358b0dfaa15',1,'rpc.h']]], + ['evrpc_5fhook_5fadd_5fmeta_542',['evrpc_hook_add_meta',['../rpc_8h.html#afddaba85bd35b7a99ff69daa73b9a98d',1,'rpc.h']]], + ['evrpc_5fhook_5ffind_5fmeta_543',['evrpc_hook_find_meta',['../rpc_8h.html#a5e6215f4f22ab5bc5d72159143cefcea',1,'rpc.h']]], + ['evrpc_5fhook_5fget_5fconnection_544',['evrpc_hook_get_connection',['../rpc_8h.html#afb04e638c158bd3fe3a0e73000e39f10',1,'rpc.h']]], + ['evrpc_5fhook_5fresult_545',['EVRPC_HOOK_RESULT',['../rpc_8h.html#a9c37f133ebc96b2bd66c472079b1338b',1,'rpc.h']]], + ['evrpc_5fhook_5ftype_546',['EVRPC_HOOK_TYPE',['../rpc_8h.html#a66eff7ea6bdd17e53fde6c4d9dc1835b',1,'rpc.h']]], + ['evrpc_5finit_547',['evrpc_init',['../rpc_8h.html#ac86c02abb0baa97c82efe94a72ae8178',1,'rpc.h']]], + ['evrpc_5finput_548',['EVRPC_INPUT',['../rpc_8h.html#a66eff7ea6bdd17e53fde6c4d9dc1835ba2a62d2e1147edb5b460c1abb17be9734',1,'rpc.h']]], + ['evrpc_5fmake_5fctx_549',['EVRPC_MAKE_CTX',['../rpc_8h.html#ad7694fa8f1b5995a9d43bef1da170fad',1,'rpc.h']]], + ['evrpc_5fmake_5frequest_550',['EVRPC_MAKE_REQUEST',['../rpc_8h.html#aff0efcd7cb8b966256b5127960bd2c81',1,'EVRPC_MAKE_REQUEST(): rpc.h'],['../rpc_8h.html#a1e45aa64f32b7a0a780b914b4a7b83c5',1,'evrpc_make_request(struct evrpc_request_wrapper *ctx): rpc.h']]], + ['evrpc_5fmake_5frequest_5fctx_551',['evrpc_make_request_ctx',['../rpc_8h.html#a6a8bc24b989e67a6739fc11118ba0b3f',1,'rpc.h']]], + ['evrpc_5foutput_552',['EVRPC_OUTPUT',['../rpc_8h.html#a66eff7ea6bdd17e53fde6c4d9dc1835bad63587ff3a66808e422f1ca48c9db85e',1,'rpc.h']]], + ['evrpc_5fpause_553',['EVRPC_PAUSE',['../rpc_8h.html#a9c37f133ebc96b2bd66c472079b1338baff86ced7cf446eec75868ba64d956b9c',1,'rpc.h']]], + ['evrpc_5fpool_5fadd_5fconnection_554',['evrpc_pool_add_connection',['../rpc_8h.html#a9e3bedffaef59f2ccc1c0003ce05da8c',1,'rpc.h']]], + ['evrpc_5fpool_5ffree_555',['evrpc_pool_free',['../rpc_8h.html#ab8579f465aee520bb8ac1b208d1d8d95',1,'rpc.h']]], + ['evrpc_5fpool_5fnew_556',['evrpc_pool_new',['../rpc_8h.html#a3098d4fd0966fe525d86f0f717771389',1,'rpc.h']]], + ['evrpc_5fpool_5fremove_5fconnection_557',['evrpc_pool_remove_connection',['../rpc_8h.html#a6272b6b974e4abe27ccb1273ba37b100',1,'rpc.h']]], + ['evrpc_5fpool_5fset_5ftimeout_558',['evrpc_pool_set_timeout',['../rpc_8h.html#a0164fb784c8b8907e30861f2fee89c44',1,'rpc.h']]], + ['evrpc_5fregister_559',['EVRPC_REGISTER',['../rpc_8h.html#abb204281e2555a1e91ff3885747d0533',1,'rpc.h']]], + ['evrpc_5fregister_5fgeneric_560',['evrpc_register_generic',['../rpc_8h.html#aad265540d04241d80f60847718db5913',1,'rpc.h']]], + ['evrpc_5fregister_5frpc_561',['evrpc_register_rpc',['../rpc_8h.html#ab8687528c294762984a097ecf4575713',1,'rpc.h']]], + ['evrpc_5fremove_5fhook_562',['evrpc_remove_hook',['../rpc_8h.html#ab77b039cae7b4f94bfff18382bef981f',1,'rpc.h']]], + ['evrpc_5frequest_5fdone_563',['evrpc_request_done',['../rpc_8h.html#a7c74b9d6cd83891ed8f03435892a0e5d',1,'evrpc_request_done(struct evrpc_req_generic *req): rpc.h'],['../rpc_8h.html#a36d6ba276baf3c95df69db35a2ef1527',1,'EVRPC_REQUEST_DONE(): rpc.h']]], + ['evrpc_5frequest_5fget_5fpool_564',['evrpc_request_get_pool',['../rpc_8h.html#af6dd0d42ecc04297df768300e5f24b31',1,'rpc.h']]], + ['evrpc_5frequest_5fhttp_565',['EVRPC_REQUEST_HTTP',['../rpc_8h.html#af78e1869994ee9597a9a0785d25fbf0b',1,'rpc.h']]], + ['evrpc_5fresume_5frequest_566',['evrpc_resume_request',['../rpc_8h.html#a8e7a8aabcd4e216d1e32254bfba33472',1,'rpc.h']]], + ['evrpc_5fsend_5frequest_5fgeneric_567',['evrpc_send_request_generic',['../rpc_8h.html#a99dc1ab2f6775a743dac96cdf2d5ace0',1,'rpc.h']]], + ['evrpc_5fstruct_568',['EVRPC_STRUCT',['../rpc_8h.html#ae9eff66229e154543551a936c59dd8fa',1,'rpc.h']]], + ['evrpc_5fterminate_569',['EVRPC_TERMINATE',['../rpc_8h.html#a9c37f133ebc96b2bd66c472079b1338ba61de2cad490f408aa9ecc3427cfb6233',1,'rpc.h']]], + ['evrpc_5funregister_570',['EVRPC_UNREGISTER',['../rpc_8h.html#ab646cdf50e026accddcd9fe23b35837b',1,'rpc.h']]], + ['evtag_5farray_5fadd_571',['EVTAG_ARRAY_ADD',['../rpc_8h.html#a8bd4b0f338823bffee3ead3885ea6791',1,'rpc.h']]], + ['evtag_5farray_5fadd_5fvalue_572',['EVTAG_ARRAY_ADD_VALUE',['../rpc_8h.html#a796d8c44ee666b13ecbae36b0897820b',1,'rpc.h']]], + ['evtag_5farray_5fget_573',['EVTAG_ARRAY_GET',['../rpc_8h.html#a1b955ffe442d49fdfe17c76a6e758880',1,'rpc.h']]], + ['evtag_5farray_5flen_574',['EVTAG_ARRAY_LEN',['../rpc_8h.html#ab4a0a6a9f8fbe20ced71eaebd297168b',1,'rpc.h']]], + ['evtag_5fassign_575',['EVTAG_ASSIGN',['../rpc_8h.html#a8063c9f0927da79cc9e53600a77eecc6',1,'rpc.h']]], + ['evtag_5fassign_5fwith_5flen_576',['EVTAG_ASSIGN_WITH_LEN',['../rpc_8h.html#af420133e56a545bef6cba6f878d403d7',1,'rpc.h']]], + ['evtag_5fencode_5fint_577',['evtag_encode_int',['../tag_8h.html#a22ef611a14b919e939fdade0af8b692c',1,'tag.h']]], + ['evtag_5fget_578',['EVTAG_GET',['../rpc_8h.html#aef6e54053208c090c43d05c9b2259fb9',1,'rpc.h']]], + ['evtag_5fget_5fwith_5flen_579',['EVTAG_GET_WITH_LEN',['../rpc_8h.html#ae0b73ea41cb7f06976fd69a8f1be6219',1,'rpc.h']]], + ['evtag_5fhas_580',['EVTAG_HAS',['../rpc_8h.html#a1a924e89c7a0c5eddc63cf9bf569fae6',1,'rpc.h']]], + ['evtag_5flen_581',['EVTAG_LEN',['../rpc__compat_8h.html#a9eb90639aa8aab13d3dc932353828e7b',1,'rpc_compat.h']]], + ['evtag_5funmarshal_5fheader_582',['evtag_unmarshal_header',['../tag_8h.html#a57431aea9815331fbbea6cca413a85af',1,'tag.h']]], + ['evthread_5fcondition_5fcallbacks_583',['evthread_condition_callbacks',['../structevthread__condition__callbacks.html',1,'']]], + ['evthread_5fenable_5flock_5fdebugging_584',['evthread_enable_lock_debugging',['../thread_8h.html#a4b9ec0970d762320451fafc8f7cb2087',1,'thread.h']]], + ['evthread_5flock_5fcallbacks_585',['evthread_lock_callbacks',['../structevthread__lock__callbacks.html',1,'']]], + ['evthread_5flocktype_5frecursive_586',['EVTHREAD_LOCKTYPE_RECURSIVE',['../thread_8h.html#a8fbf4020f11c3b98459fd8d4d427513c',1,'thread.h']]], + ['evthread_5fmake_5fbase_5fnotifiable_587',['evthread_make_base_notifiable',['../thread_8h.html#ac0c39231d48295aff378fd9f65b2569a',1,'thread.h']]], + ['evthread_5fread_588',['EVTHREAD_READ',['../thread_8h.html#a8c7a3fb4b1f521b4a262e5043f3fa14c',1,'thread.h']]], + ['evthread_5fset_5fcondition_5fcallbacks_589',['evthread_set_condition_callbacks',['../thread_8h.html#a15c0f69030cfec09cc34bf8afd151bac',1,'thread.h']]], + ['evthread_5fset_5fid_5fcallback_590',['evthread_set_id_callback',['../thread_8h.html#a79ec78eb62ee5082a33cfb0c14df9772',1,'thread.h']]], + ['evthread_5fset_5flock_5fcallbacks_591',['evthread_set_lock_callbacks',['../thread_8h.html#ae5fa5c777ca30576db8355a9140c533b',1,'thread.h']]], + ['evthread_5ftry_592',['EVTHREAD_TRY',['../thread_8h.html#a746e63692bf5bd5b4ee5d929df1592e2',1,'thread.h']]], + ['evthread_5fuse_5fpthreads_593',['evthread_use_pthreads',['../thread_8h.html#acc0cc708c566c14f4659331ec12f8a5b',1,'thread.h']]], + ['evthread_5fuse_5fpthreads_5fimplemented_594',['EVTHREAD_USE_PTHREADS_IMPLEMENTED',['../thread_8h.html#a8906b609d6c2bb4af5c7653c4f0f355d',1,'thread.h']]], + ['evthread_5fuse_5fpthreads_5fwith_5fflags_595',['evthread_use_pthreads_with_flags',['../thread_8h.html#a2cef140279d8452e69dc73cc15ca697c',1,'thread.h']]], + ['evthread_5fuse_5fwindows_5fthreads_596',['evthread_use_windows_threads',['../thread_8h.html#a1b0fe36dcb033da2c679d39ce8a190e2',1,'thread.h']]], + ['evthread_5fuse_5fwindows_5fthreads_5fimplemented_597',['EVTHREAD_USE_WINDOWS_THREADS_IMPLEMENTED',['../thread_8h.html#a05306512f3074b45be6eba702440f1f1',1,'thread.h']]], + ['evthread_5fwrite_598',['EVTHREAD_WRITE',['../thread_8h.html#aa9fb1861f3b09a03c5986561dd00db0d',1,'thread.h']]], + ['evutil_5faddrinfo_599',['evutil_addrinfo',['../structevutil__addrinfo.html',1,'']]], + ['evutil_5fascii_5fstrcasecmp_600',['evutil_ascii_strcasecmp',['../util_8h.html#aae46d8f8407906b79216f9be88803126',1,'util.h']]], + ['evutil_5fascii_5fstrncasecmp_601',['evutil_ascii_strncasecmp',['../util_8h.html#a03b44d66883df5bfed32c9ac6df93aac',1,'util.h']]], + ['evutil_5fclosesocket_602',['evutil_closesocket',['../util_8h.html#a5cfa6c13c62d17570a7d5f6d3541ff5b',1,'util.h']]], + ['evutil_5fconfigure_5fmonotonic_5ftime_603',['evutil_configure_monotonic_time',['../util_8h.html#ab486d1e10fd1e3102b4e53beed8d9baa',1,'util.h']]], + ['evutil_5fdate_5frfc1123_604',['evutil_date_rfc1123',['../util_8h.html#a9d2f7f9996a6ff28db2aeb8ac8a58187',1,'util.h']]], + ['evutil_5ffreeaddrinfo_605',['evutil_freeaddrinfo',['../util_8h.html#a58a472b3afc5cef1e6b1c9912604381b',1,'util.h']]], + ['evutil_5fgetaddrinfo_606',['evutil_getaddrinfo',['../util_8h.html#a0f36c2fc48c644a4f56347a25c585cc9',1,'util.h']]], + ['evutil_5fgettime_5fmonotonic_607',['evutil_gettime_monotonic',['../util_8h.html#abe94df86960981b69411f20c0c5235dc',1,'util.h']]], + ['evutil_5finet_5fntop_608',['evutil_inet_ntop',['../util_8h.html#afa98d48bdd6ad06c1fd013a44621d567',1,'util.h']]], + ['evutil_5finet_5fpton_609',['evutil_inet_pton',['../util_8h.html#a4065af1c9c995010ef7df66154c313b2',1,'util.h']]], + ['evutil_5finet_5fpton_5fscope_610',['evutil_inet_pton_scope',['../util_8h.html#ad586fc57f596616d810a8b5fe4f8c111',1,'util.h']]], + ['evutil_5fmake_5flisten_5fsocket_5fipv6only_611',['evutil_make_listen_socket_ipv6only',['../util_8h.html#ad361aa5727c88f05633a9032ad8c850f',1,'util.h']]], + ['evutil_5fmake_5flisten_5fsocket_5fnot_5fipv6only_612',['evutil_make_listen_socket_not_ipv6only',['../util_8h.html#a031699658b52069610d660919d0c2b9d',1,'util.h']]], + ['evutil_5fmake_5flisten_5fsocket_5freuseable_613',['evutil_make_listen_socket_reuseable',['../util_8h.html#a7a8e18b7861ed856bde592257f6b6e11',1,'util.h']]], + ['evutil_5fmake_5flisten_5fsocket_5freuseable_5fport_614',['evutil_make_listen_socket_reuseable_port',['../util_8h.html#a9e4e68f77ce876ceecc6fb65f2dbe506',1,'util.h']]], + ['evutil_5fmake_5fsocket_5fcloseonexec_615',['evutil_make_socket_closeonexec',['../util_8h.html#a7edc3874139e863f61edf6c705030430',1,'util.h']]], + ['evutil_5fmake_5fsocket_5fnonblocking_616',['evutil_make_socket_nonblocking',['../util_8h.html#a4f8f2384311baf5d7308c7ab079f9b84',1,'util.h']]], + ['evutil_5fmake_5ftcp_5flisten_5fsocket_5fdeferred_617',['evutil_make_tcp_listen_socket_deferred',['../util_8h.html#a988b1fc98edeac63efc8b13c4f822a0d',1,'util.h']]], + ['evutil_5fmonotonic_5ftimer_618',['evutil_monotonic_timer',['../structevutil__monotonic__timer.html',1,'']]], + ['evutil_5fmonotonic_5ftimer_5ffree_619',['evutil_monotonic_timer_free',['../util_8h.html#a2874062ff988293cd4e40b220933e209',1,'util.h']]], + ['evutil_5fmonotonic_5ftimer_5fnew_620',['evutil_monotonic_timer_new',['../util_8h.html#a87b00e2754d908ba05c5aa8e9c8e4f28',1,'util.h']]], + ['evutil_5foffsetof_621',['evutil_offsetof',['../util_8h.html#a4c296955d33624c18bd4811730caa417',1,'util.h']]], + ['evutil_5fparse_5fsockaddr_5fport_622',['evutil_parse_sockaddr_port',['../util_8h.html#a97d4f315d5c40c4f604f6c9ae694a684',1,'util.h']]], + ['evutil_5fsecure_5frng_5fadd_5fbytes_623',['evutil_secure_rng_add_bytes',['../util_8h.html#a3b5b7d22b368ffdd6ed77838bf4fcea6',1,'util.h']]], + ['evutil_5fsecure_5frng_5fget_5fbytes_624',['evutil_secure_rng_get_bytes',['../util_8h.html#a0836ed5d00ccab1957419a07b7acbb56',1,'util.h']]], + ['evutil_5fsecure_5frng_5finit_625',['evutil_secure_rng_init',['../util_8h.html#a49ffe53dcbe32ad55f1582a0da358ac0',1,'util.h']]], + ['evutil_5fsecure_5frng_5fset_5furandom_5fdevice_5ffile_626',['evutil_secure_rng_set_urandom_device_file',['../util_8h.html#a4544ddceb4e20c8c52985641ca829b7e',1,'util.h']]], + ['evutil_5fset_5fsocket_5ferror_627',['EVUTIL_SET_SOCKET_ERROR',['../util_8h.html#ae8b4fae7790599f7b58e8c269f6b29d8',1,'util.h']]], + ['evutil_5fset_5ftcp_5fkeepalive_628',['evutil_set_tcp_keepalive',['../util_8h.html#a96f11bb3a6bf772201a0a2010689a250',1,'util.h']]], + ['evutil_5fsnprintf_629',['evutil_snprintf',['../util_8h.html#a198e8db3626746515792e28b1380be67',1,'util.h']]], + ['evutil_5fsockaddr_5fcmp_630',['evutil_sockaddr_cmp',['../util_8h.html#a7b5ad1074f1effe2dbfa18b3f44b589f',1,'util.h']]], + ['evutil_5fsocket_5ferror_631',['EVUTIL_SOCKET_ERROR',['../util_8h.html#a9a94a2e72982e708333486cf72aab941',1,'util.h']]], + ['evutil_5fsocket_5ferror_5fto_5fstring_632',['evutil_socket_error_to_string',['../util_8h.html#ad5ea5ef81ddcfb299e4867d362ad8654',1,'util.h']]], + ['evutil_5fsocket_5fgeterror_633',['evutil_socket_geterror',['../util_8h.html#a28f952fb0f16b057d931fd38ee9bdf5e',1,'util.h']]], + ['evutil_5fsocket_5ft_634',['evutil_socket_t',['../util_8h.html#a7ef0023565082a65020f6e56be59fd0b',1,'util.h']]], + ['evutil_5fsocketpair_635',['evutil_socketpair',['../util_8h.html#a050a74274e08eb89a53cb8cb1d617939',1,'util.h']]], + ['evutil_5fstrtoll_636',['evutil_strtoll',['../util_8h.html#a9175e63729c256eb2646e11e8211f4f7',1,'util.h']]], + ['evutil_5ftimercmp_637',['evutil_timercmp',['../util_8h.html#a1a42f43db6aaf6e99736329b6611175d',1,'util.h']]], + ['evutil_5fvsnprintf_638',['evutil_vsnprintf',['../util_8h.html#a30bbdc509d150e5dfac1f74dd4e4c212',1,'util.h']]], + ['evwatch_5fbase_639',['evwatch_base',['../watch_8h.html#a12f916b5846e7925939abbaca49b4521',1,'watch.h']]], + ['evwatch_5fcheck_5fcb_640',['evwatch_check_cb',['../watch_8h.html#a552db1e01295811adc2191580a48f3f7',1,'watch.h']]], + ['evwatch_5fcheck_5fnew_641',['evwatch_check_new',['../watch_8h.html#acfeaa9fc345062e41c7f807d6c5d511f',1,'watch.h']]], + ['evwatch_5ffree_642',['evwatch_free',['../watch_8h.html#aadf0c377890835ae40612b19f9029032',1,'watch.h']]], + ['evwatch_5fprepare_5fcb_643',['evwatch_prepare_cb',['../watch_8h.html#ab49b34b1552c9cc5e6a736cfc435c766',1,'watch.h']]], + ['evwatch_5fprepare_5fget_5ftimeout_644',['evwatch_prepare_get_timeout',['../watch_8h.html#a5f7837d8af2b00c9ec401e00b4f33781',1,'watch.h']]], + ['evwatch_5fprepare_5fnew_645',['evwatch_prepare_new',['../watch_8h.html#ad446340d54b8de7125cae9d5fed9c61e',1,'watch.h']]] +]; diff --git a/search/all_5.html b/search/all_5.html new file mode 100644 index 0000000..2544c4e --- /dev/null +++ b/search/all_5.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_5.js b/search/all_5.js new file mode 100644 index 0000000..dae27f6 --- /dev/null +++ b/search/all_5.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['free_646',['free',['../structevthread__lock__callbacks.html#afdab536528e27486ae7acb783ccad07a',1,'evthread_lock_callbacks']]], + ['free_5fcondition_647',['free_condition',['../structevthread__condition__callbacks.html#af20b2614116b6ac43f3e25012a792575',1,'evthread_condition_callbacks']]] +]; diff --git a/search/all_6.html b/search/all_6.html new file mode 100644 index 0000000..43f14ea --- /dev/null +++ b/search/all_6.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_6.js b/search/all_6.js new file mode 100644 index 0000000..947bc5d --- /dev/null +++ b/search/all_6.js @@ -0,0 +1,29 @@ +var searchData= +[ + ['http_2eh_648',['http.h',['../http_8h.html',1,'']]], + ['http_5faccepted_649',['HTTP_ACCEPTED',['../http_8h.html#ad53204f337b45ad77e9a746e434d1817',1,'http.h']]], + ['http_5fbadgateway_650',['HTTP_BADGATEWAY',['../http_8h.html#a746f663029189ec16d55d0d9546ac89d',1,'http.h']]], + ['http_5fbadmethod_651',['HTTP_BADMETHOD',['../http_8h.html#a8d93bc2b08ddc194c213682c4726b0e6',1,'http.h']]], + ['http_5fbadrequest_652',['HTTP_BADREQUEST',['../http_8h.html#af9f070802de32cd2f820059fc42cbf39',1,'http.h']]], + ['http_5fcompat_2eh_653',['http_compat.h',['../http__compat_8h.html',1,'']]], + ['http_5fcontinue_654',['HTTP_CONTINUE',['../http_8h.html#a3c520c5e65c710a1c7bbb1fa79fd3a9d',1,'http.h']]], + ['http_5fcreated_655',['HTTP_CREATED',['../http_8h.html#ac19a79fb4cf575d20efd0633c1669ed9',1,'http.h']]], + ['http_5fearlyhints_656',['HTTP_EARLYHINTS',['../http_8h.html#acebc611f41e394b875f6283a4840d9d9',1,'http.h']]], + ['http_5fentitytoolarge_657',['HTTP_ENTITYTOOLARGE',['../http_8h.html#a64236d9bad703199d84a08bee90e00f0',1,'http.h']]], + ['http_5fexpectationfailed_658',['HTTP_EXPECTATIONFAILED',['../http_8h.html#a4eac9f52d3d8de9b3deadaec6ad0bee9',1,'http.h']]], + ['http_5fforbidden_659',['HTTP_FORBIDDEN',['../http_8h.html#a92646f876056a1e5013e0050496dc04d',1,'http.h']]], + ['http_5finternal_660',['HTTP_INTERNAL',['../http_8h.html#a15eac402986428a8125d364b7ae569b1',1,'http.h']]], + ['http_5fmoveperm_661',['HTTP_MOVEPERM',['../http_8h.html#ac6ffbb7b69889f1eee0d413576c609a9',1,'http.h']]], + ['http_5fmovetemp_662',['HTTP_MOVETEMP',['../http_8h.html#a7d2a7341ba2af15babe8c25df67e563f',1,'http.h']]], + ['http_5fnocontent_663',['HTTP_NOCONTENT',['../http_8h.html#ac5e3a483119375a05d199c30709f2b8e',1,'http.h']]], + ['http_5fnonauthoritative_664',['HTTP_NONAUTHORITATIVE',['../http_8h.html#ab9789b35d84095b35f7ab1d9913fff4e',1,'http.h']]], + ['http_5fnotfound_665',['HTTP_NOTFOUND',['../http_8h.html#a1f5b9c02b018640c890e5f27207fa6c0',1,'http.h']]], + ['http_5fnotimplemented_666',['HTTP_NOTIMPLEMENTED',['../http_8h.html#a9759dd4ad026a688142afb7b4e4542cc',1,'http.h']]], + ['http_5fnotmodified_667',['HTTP_NOTMODIFIED',['../http_8h.html#a3112d58297965db46a04fe288bf1d0da',1,'http.h']]], + ['http_5fok_668',['HTTP_OK',['../http_8h.html#a02e6d59009dee759528ec81fc9a8eeff',1,'http.h']]], + ['http_5fpaymentrequired_669',['HTTP_PAYMENTREQUIRED',['../http_8h.html#aaae52dca74d8f240798a3daf8396bfe5',1,'http.h']]], + ['http_5fprocessing_670',['HTTP_PROCESSING',['../http_8h.html#aad76b47755281ea8ba65edc6683be8f9',1,'http.h']]], + ['http_5fservunavail_671',['HTTP_SERVUNAVAIL',['../http_8h.html#a5fd6829fe2bb38dd13288f11dcb2025f',1,'http.h']]], + ['http_5fswitch_5fprotocols_672',['HTTP_SWITCH_PROTOCOLS',['../http_8h.html#aa0a6a40f95575cb08438f396f0711017',1,'http.h']]], + ['http_5funauthorized_673',['HTTP_UNAUTHORIZED',['../http_8h.html#ac4cfa4b7a737abff1264ddba3752a2ad',1,'http.h']]] +]; diff --git a/search/all_7.html b/search/all_7.html new file mode 100644 index 0000000..af52f82 --- /dev/null +++ b/search/all_7.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_7.js b/search/all_7.js new file mode 100644 index 0000000..7e04ea0 --- /dev/null +++ b/search/all_7.js @@ -0,0 +1,6 @@ +var searchData= +[ + ['input_674',['INPUT',['../rpc_8h.html#a1bb283bd7893b9855e2f23013891fc82',1,'rpc.h']]], + ['iov_5fbase_675',['iov_base',['../structevbuffer__iovec.html#a1ce384c93f7554ab94f5dccdab8b4e13',1,'evbuffer_iovec']]], + ['iov_5flen_676',['iov_len',['../structevbuffer__iovec.html#a0b1981aa931c720e63238022d74c0ac1',1,'evbuffer_iovec']]] +]; diff --git a/search/all_8.html b/search/all_8.html new file mode 100644 index 0000000..cf2b5df --- /dev/null +++ b/search/all_8.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_8.js b/search/all_8.js new file mode 100644 index 0000000..f7bb417 --- /dev/null +++ b/search/all_8.js @@ -0,0 +1,19 @@ +var searchData= +[ + ['lev_5fopt_5fbind_5fipv4_5fand_5fipv6_677',['LEV_OPT_BIND_IPV4_AND_IPV6',['../listener_8h.html#afc396525343a6848149d6c0f7cd11ed5',1,'listener.h']]], + ['lev_5fopt_5fbind_5fipv6only_678',['LEV_OPT_BIND_IPV6ONLY',['../listener_8h.html#a3a54f81b44cec176dffe72a1aa22d8e6',1,'listener.h']]], + ['lev_5fopt_5fclose_5fon_5fexec_679',['LEV_OPT_CLOSE_ON_EXEC',['../listener_8h.html#af6f307bd279abe88586fb56672fcf6c8',1,'listener.h']]], + ['lev_5fopt_5fclose_5fon_5ffree_680',['LEV_OPT_CLOSE_ON_FREE',['../listener_8h.html#a4b2de09b129675a41696a89e5c58de53',1,'listener.h']]], + ['lev_5fopt_5fdeferred_5faccept_681',['LEV_OPT_DEFERRED_ACCEPT',['../listener_8h.html#a5b1903214eb069f47ae9119793307b89',1,'listener.h']]], + ['lev_5fopt_5fdisabled_682',['LEV_OPT_DISABLED',['../listener_8h.html#ad96f043f9d9b2f028536fe832061daf6',1,'listener.h']]], + ['lev_5fopt_5fleave_5fsockets_5fblocking_683',['LEV_OPT_LEAVE_SOCKETS_BLOCKING',['../listener_8h.html#ac19549ba5b3746557d5fd8be8a9c5eb3',1,'listener.h']]], + ['lev_5fopt_5freuseable_684',['LEV_OPT_REUSEABLE',['../listener_8h.html#a15337d63b237ec11b0781656aad90662',1,'listener.h']]], + ['lev_5fopt_5freuseable_5fport_685',['LEV_OPT_REUSEABLE_PORT',['../listener_8h.html#af417f499a89518d16eb3be4098e504c7',1,'listener.h']]], + ['lev_5fopt_5fthreadsafe_686',['LEV_OPT_THREADSAFE',['../listener_8h.html#a7bcc41438093090d28a7c98b899db9ba',1,'listener.h']]], + ['libevent_5fglobal_5fshutdown_687',['libevent_global_shutdown',['../event_8h.html#aaed24b9ff1f5b137ea2e2cc6a2bf8d1f',1,'event.h']]], + ['libevent_5fversion_688',['LIBEVENT_VERSION',['../event_8h.html#aad00c7d4ddbd6b590c15861a2e767182',1,'event.h']]], + ['libevent_5fversion_5fnumber_689',['LIBEVENT_VERSION_NUMBER',['../event_8h.html#a8a9c8021651a2d8d7946083281279586',1,'event.h']]], + ['listener_2eh_690',['listener.h',['../listener_8h.html',1,'']]], + ['lock_691',['lock',['../structevthread__lock__callbacks.html#a1eb04c0bb0cf9dba264d1b5ed7c9e025',1,'evthread_lock_callbacks']]], + ['lock_5fapi_5fversion_692',['lock_api_version',['../structevthread__lock__callbacks.html#afe0e286cfffd238f4891bdb431c79eb9',1,'evthread_lock_callbacks']]] +]; diff --git a/search/all_9.html b/search/all_9.html new file mode 100644 index 0000000..690785a --- /dev/null +++ b/search/all_9.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_9.js b/search/all_9.js new file mode 100644 index 0000000..de84b7e --- /dev/null +++ b/search/all_9.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['n_5fadded_693',['n_added',['../structevbuffer__cb__info.html#a8191bbc06e291543359428daace6bae6',1,'evbuffer_cb_info']]], + ['n_5fdeleted_694',['n_deleted',['../structevbuffer__cb__info.html#a7d1a674e020d2eee72538b0221dc32a4',1,'evbuffer_cb_info']]] +]; diff --git a/search/all_a.html b/search/all_a.html new file mode 100644 index 0000000..f2f3d3a --- /dev/null +++ b/search/all_a.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_a.js b/search/all_a.js new file mode 100644 index 0000000..0a8514f --- /dev/null +++ b/search/all_a.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['orig_5fsize_695',['orig_size',['../structevbuffer__cb__info.html#a18e973448576100923328e4de05ddef5',1,'evbuffer_cb_info']]], + ['output_696',['OUTPUT',['../rpc_8h.html#a61a3c9a18380aafb6e430e79bf596557',1,'rpc.h']]] +]; diff --git a/search/all_b.html b/search/all_b.html new file mode 100644 index 0000000..14f3403 --- /dev/null +++ b/search/all_b.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_b.js b/search/all_b.js new file mode 100644 index 0000000..883f7dc --- /dev/null +++ b/search/all_b.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['rpc_2eh_697',['rpc.h',['../rpc_8h.html',1,'']]], + ['rpc_5fcompat_2eh_698',['rpc_compat.h',['../rpc__compat_8h.html',1,'']]] +]; diff --git a/search/all_c.html b/search/all_c.html new file mode 100644 index 0000000..da60ab8 --- /dev/null +++ b/search/all_c.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_c.js b/search/all_c.js new file mode 100644 index 0000000..3e36c3c --- /dev/null +++ b/search/all_c.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['signal_5fcondition_699',['signal_condition',['../structevthread__condition__callbacks.html#a453762d49a8fbcbe0f36b34dae478e8e',1,'evthread_condition_callbacks']]], + ['supported_5flocktypes_700',['supported_locktypes',['../structevthread__lock__callbacks.html#afebbd92f9fc12e5852b0c008b423f948',1,'evthread_lock_callbacks']]] +]; diff --git a/search/all_d.html b/search/all_d.html new file mode 100644 index 0000000..bc376fe --- /dev/null +++ b/search/all_d.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_d.js b/search/all_d.js new file mode 100644 index 0000000..e676856 --- /dev/null +++ b/search/all_d.js @@ -0,0 +1,6 @@ +var searchData= +[ + ['tag_2eh_701',['tag.h',['../tag_8h.html',1,'']]], + ['tag_5fcompat_2eh_702',['tag_compat.h',['../tag__compat_8h.html',1,'']]], + ['thread_2eh_703',['thread.h',['../thread_8h.html',1,'']]] +]; diff --git a/search/all_e.html b/search/all_e.html new file mode 100644 index 0000000..2e3c74d --- /dev/null +++ b/search/all_e.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_e.js b/search/all_e.js new file mode 100644 index 0000000..678f1cd --- /dev/null +++ b/search/all_e.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['unlock_704',['unlock',['../structevthread__lock__callbacks.html#ae896047fcd1b4c5095d2b05a58e0a35d',1,'evthread_lock_callbacks']]], + ['util_2eh_705',['util.h',['../util_8h.html',1,'']]] +]; diff --git a/search/all_f.html b/search/all_f.html new file mode 100644 index 0000000..246f8ab --- /dev/null +++ b/search/all_f.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_f.js b/search/all_f.js new file mode 100644 index 0000000..648f0ff --- /dev/null +++ b/search/all_f.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['wait_5fcondition_706',['wait_condition',['../structevthread__condition__callbacks.html#aa7963135768612f74dfa80f15b6c7260',1,'evthread_condition_callbacks']]], + ['watch_2eh_707',['watch.h',['../watch_8h.html',1,'']]] +]; diff --git a/search/classes_0.html b/search/classes_0.html new file mode 100644 index 0000000..f7e4c14 --- /dev/null +++ b/search/classes_0.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/classes_0.js b/search/classes_0.js new file mode 100644 index 0000000..c1579e8 --- /dev/null +++ b/search/classes_0.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['bufferevent_708',['bufferevent',['../structbufferevent.html',1,'']]] +]; diff --git a/search/classes_1.html b/search/classes_1.html new file mode 100644 index 0000000..c7ff4b3 --- /dev/null +++ b/search/classes_1.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/classes_1.js b/search/classes_1.js new file mode 100644 index 0000000..7c6a4ba --- /dev/null +++ b/search/classes_1.js @@ -0,0 +1,15 @@ +var searchData= +[ + ['evbuffer_709',['evbuffer',['../structevbuffer.html',1,'']]], + ['evbuffer_5fcb_5finfo_710',['evbuffer_cb_info',['../structevbuffer__cb__info.html',1,'']]], + ['evbuffer_5fiovec_711',['evbuffer_iovec',['../structevbuffer__iovec.html',1,'']]], + ['evbuffer_5fptr_712',['evbuffer_ptr',['../structevbuffer__ptr.html',1,'']]], + ['event_713',['event',['../structevent.html',1,'']]], + ['event_5fbase_714',['event_base',['../structevent__base.html',1,'']]], + ['event_5fconfig_715',['event_config',['../structevent__config.html',1,'']]], + ['evhttp_5fext_5fmethod_716',['evhttp_ext_method',['../structevhttp__ext__method.html',1,'']]], + ['evthread_5fcondition_5fcallbacks_717',['evthread_condition_callbacks',['../structevthread__condition__callbacks.html',1,'']]], + ['evthread_5flock_5fcallbacks_718',['evthread_lock_callbacks',['../structevthread__lock__callbacks.html',1,'']]], + ['evutil_5faddrinfo_719',['evutil_addrinfo',['../structevutil__addrinfo.html',1,'']]], + ['evutil_5fmonotonic_5ftimer_720',['evutil_monotonic_timer',['../structevutil__monotonic__timer.html',1,'']]] +]; diff --git a/search/close.png b/search/close.png new file mode 100644 index 0000000..9342d3d Binary files /dev/null and b/search/close.png differ diff --git a/search/defines_0.html b/search/defines_0.html new file mode 100644 index 0000000..2deb369 --- /dev/null +++ b/search/defines_0.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/defines_0.js b/search/defines_0.js new file mode 100644 index 0000000..7d0733f --- /dev/null +++ b/search/defines_0.js @@ -0,0 +1,11 @@ +var searchData= +[ + ['bev_5fevent_5fconnected_1285',['BEV_EVENT_CONNECTED',['../bufferevent_8h.html#affb7a7e5e21e1541ba6f43f950d92993',1,'bufferevent.h']]], + ['bev_5fevent_5feof_1286',['BEV_EVENT_EOF',['../bufferevent_8h.html#a4d7d8c93cf62e6f3d37c0cbac75aebcc',1,'bufferevent.h']]], + ['bev_5fevent_5ferror_1287',['BEV_EVENT_ERROR',['../bufferevent_8h.html#a5f112d7a064258bdabf8d5182a3bf5e4',1,'bufferevent.h']]], + ['bev_5fevent_5freading_1288',['BEV_EVENT_READING',['../bufferevent_8h.html#a504816ca8678e4f3d0bee2700fda524d',1,'bufferevent.h']]], + ['bev_5fevent_5ftimeout_1289',['BEV_EVENT_TIMEOUT',['../bufferevent_8h.html#aa537428e3ac2c8d2dbb4ec041f09347f',1,'bufferevent.h']]], + ['bev_5fevent_5fwriting_1290',['BEV_EVENT_WRITING',['../bufferevent_8h.html#a557afaa0ce75e6bbb71fdcd68c35d077',1,'bufferevent.h']]], + ['bufferevent_5fssl_5fbatch_5fwrite_1291',['BUFFEREVENT_SSL_BATCH_WRITE',['../bufferevent__ssl_8h.html#a34aeb5156538c8ca7f5353a77aa9059b',1,'bufferevent_ssl.h']]], + ['bufferevent_5fssl_5fdirty_5fshutdown_1292',['BUFFEREVENT_SSL_DIRTY_SHUTDOWN',['../bufferevent__ssl_8h.html#af65fd99ef2fa0bc7df9622dc84dfa38b',1,'bufferevent_ssl.h']]] +]; diff --git a/search/defines_1.html b/search/defines_1.html new file mode 100644 index 0000000..e0d0b6d --- /dev/null +++ b/search/defines_1.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/defines_1.js b/search/defines_1.js new file mode 100644 index 0000000..73f0b08 --- /dev/null +++ b/search/defines_1.js @@ -0,0 +1,20 @@ +var searchData= +[ + ['dns_5fcname_5fcallback_1293',['DNS_CNAME_CALLBACK',['../dns_8h.html#ae6bc56fee95d5e87a19e8660738b81d2',1,'dns.h']]], + ['dns_5ferr_5fcancel_1294',['DNS_ERR_CANCEL',['../dns_8h.html#aa213c5179d5439b1ceb6b356cfa6670a',1,'dns.h']]], + ['dns_5ferr_5fformat_1295',['DNS_ERR_FORMAT',['../dns_8h.html#af83b8dba06d732f95c5134a26189bf07',1,'dns.h']]], + ['dns_5ferr_5fnodata_1296',['DNS_ERR_NODATA',['../dns_8h.html#a339623396788ff9271b5cc345b83a2e8',1,'dns.h']]], + ['dns_5ferr_5fnone_1297',['DNS_ERR_NONE',['../dns_8h.html#a9ab3095d5fc6b9b476753f1dc43ca062',1,'dns.h']]], + ['dns_5ferr_5fnotexist_1298',['DNS_ERR_NOTEXIST',['../dns_8h.html#a69a1417da1abb3ec925bac4bdc9dda00',1,'dns.h']]], + ['dns_5ferr_5fnotimpl_1299',['DNS_ERR_NOTIMPL',['../dns_8h.html#ad4c885f89aab5bba9636bcab0b2bb46f',1,'dns.h']]], + ['dns_5ferr_5frefused_1300',['DNS_ERR_REFUSED',['../dns_8h.html#ac2612a0b4f473b2e0d8353968cf958c8',1,'dns.h']]], + ['dns_5ferr_5fserverfailed_1301',['DNS_ERR_SERVERFAILED',['../dns_8h.html#a288664d29454d839d3337c9f1a16287b',1,'dns.h']]], + ['dns_5ferr_5fshutdown_1302',['DNS_ERR_SHUTDOWN',['../dns_8h.html#ad64cc74ddb454b815d42e23b4d24bf16',1,'dns.h']]], + ['dns_5ferr_5ftimeout_1303',['DNS_ERR_TIMEOUT',['../dns_8h.html#acb501430c13d4432314859d36b21c59c',1,'dns.h']]], + ['dns_5ferr_5ftruncated_1304',['DNS_ERR_TRUNCATED',['../dns_8h.html#ab133c94928a9ebe3d37ad5a5d3722fb8',1,'dns.h']]], + ['dns_5ferr_5funknown_1305',['DNS_ERR_UNKNOWN',['../dns_8h.html#a09a9900444d399cb6d516e40a1629f79',1,'dns.h']]], + ['dns_5foptions_5fall_1306',['DNS_OPTIONS_ALL',['../dns_8h.html#a417f74bbbbd887a84d911ed9dc7ce3ae',1,'dns.h']]], + ['dns_5fquery_5figntc_1307',['DNS_QUERY_IGNTC',['../dns_8h.html#a9c15b7447c0ed1c0966ecce97317266c',1,'dns.h']]], + ['dns_5fquery_5fno_5fsearch_1308',['DNS_QUERY_NO_SEARCH',['../dns_8h.html#af82856a398b08ac3a1bb2d540fa9c742',1,'dns.h']]], + ['dns_5fquery_5fusevc_1309',['DNS_QUERY_USEVC',['../dns_8h.html#a14fa571999c82d15277b253806d2fbdc',1,'dns.h']]] +]; diff --git a/search/defines_2.html b/search/defines_2.html new file mode 100644 index 0000000..707f942 --- /dev/null +++ b/search/defines_2.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/defines_2.js b/search/defines_2.js new file mode 100644 index 0000000..b2e4690 --- /dev/null +++ b/search/defines_2.js @@ -0,0 +1,73 @@ +var searchData= +[ + ['ev_5fclosed_1310',['EV_CLOSED',['../event_8h.html#a98f643f9c9063a4cbf410f519eb61e55',1,'event.h']]], + ['ev_5fet_1311',['EV_ET',['../event_8h.html#a01084abbcdd3a58b4068359548a3ea71',1,'event.h']]], + ['ev_5ffinalize_1312',['EV_FINALIZE',['../event_8h.html#ac062d75b2bf9a961d893e3a71726bdff',1,'event.h']]], + ['ev_5fpersist_1313',['EV_PERSIST',['../event_8h.html#a3c4947a60eb6d09327c61f89135f9f37',1,'event.h']]], + ['ev_5frate_5flimit_5fmax_1314',['EV_RATE_LIMIT_MAX',['../bufferevent_8h.html#a78fc86349f408552be0fdf249db673ec',1,'bufferevent.h']]], + ['ev_5fread_1315',['EV_READ',['../event_8h.html#a74bbaf2d529670cc0ab793497b41700f',1,'event.h']]], + ['ev_5fsignal_1316',['EV_SIGNAL',['../event_8h.html#a59b7e95284ac1a197969d42ee9441ece',1,'event.h']]], + ['ev_5ftimeout_1317',['EV_TIMEOUT',['../event_8h.html#a37ef4b6056484f5580f7d72fcf46fccf',1,'event.h']]], + ['ev_5fwrite_1318',['EV_WRITE',['../event_8h.html#a2a31813fa3b26bf2d150512cbbf893f7',1,'event.h']]], + ['evbuf_5ffs_5fclose_5fon_5ffree_1319',['EVBUF_FS_CLOSE_ON_FREE',['../buffer_8h.html#a647759a5dec0745de7b17aefc928e3d6',1,'buffer.h']]], + ['evbuf_5ffs_5fdisable_5flocking_1320',['EVBUF_FS_DISABLE_LOCKING',['../buffer_8h.html#ad9d19b50a501babad4cbe7f0f9a42691',1,'buffer.h']]], + ['evbuf_5ffs_5fdisable_5fmmap_1321',['EVBUF_FS_DISABLE_MMAP',['../buffer_8h.html#a0749ba245d15e70bc99cee90a3d02ac9',1,'buffer.h']]], + ['evbuf_5ffs_5fdisable_5fsendfile_1322',['EVBUF_FS_DISABLE_SENDFILE',['../buffer_8h.html#a553dd6c9a5cbbc112ffe32401cacd705',1,'buffer.h']]], + ['evbuffer_5fcb_5fenabled_1323',['EVBUFFER_CB_ENABLED',['../buffer_8h.html#aeb635643a72f8e57d50d7dee37308148',1,'buffer.h']]], + ['evbuffer_5fdata_1324',['EVBUFFER_DATA',['../buffer__compat_8h.html#a1c57a451c56dc1483a1c8aaeb9b92cc6',1,'buffer_compat.h']]], + ['evbuffer_5fflag_5fdrains_5fto_5ffd_1325',['EVBUFFER_FLAG_DRAINS_TO_FD',['../buffer_8h.html#a0d9db8b232ebf8d63c660ec429981e91',1,'buffer.h']]], + ['evbuffer_5finput_1326',['EVBUFFER_INPUT',['../bufferevent__compat_8h.html#a189bf30c83f32cffebdc0dcb65f41350',1,'bufferevent_compat.h']]], + ['evbuffer_5flength_1327',['EVBUFFER_LENGTH',['../buffer__compat_8h.html#ab8d9564980e380cf1887f2be70f687ad',1,'buffer_compat.h']]], + ['evbuffer_5foutput_1328',['EVBUFFER_OUTPUT',['../bufferevent__compat_8h.html#a6e7bfa5494417540589e9ae582a2bccd',1,'bufferevent_compat.h']]], + ['evdns_5fbase_5fdisable_5fwhen_5finactive_1329',['EVDNS_BASE_DISABLE_WHEN_INACTIVE',['../dns_8h.html#ad676c79dfd2107701961fe2b269dcfd8',1,'dns.h']]], + ['evdns_5fbase_5finitialize_5fnameservers_1330',['EVDNS_BASE_INITIALIZE_NAMESERVERS',['../dns_8h.html#a1cbcfe6baf59913c34aa04e57637da3d',1,'dns.h']]], + ['evdns_5fbase_5fnameservers_5fno_5fdefault_1331',['EVDNS_BASE_NAMESERVERS_NO_DEFAULT',['../dns_8h.html#a548a0e3529efb572b991408f7581a09b',1,'dns.h']]], + ['evdns_5fbase_5fno_5fcache_1332',['EVDNS_BASE_NO_CACHE',['../dns_8h.html#a865ae03fdd5198a182e6c4c322f56f8d',1,'dns.h']]], + ['event_5fbase_5fcount_5factive_1333',['EVENT_BASE_COUNT_ACTIVE',['../event_8h.html#aa3786406bc592990f0583ac211110fa3',1,'event.h']]], + ['event_5fbase_5fcount_5fadded_1334',['EVENT_BASE_COUNT_ADDED',['../event_8h.html#a36205e544778da7d91ec8555b962851a',1,'event.h']]], + ['event_5fbase_5fcount_5fvirtual_1335',['EVENT_BASE_COUNT_VIRTUAL',['../event_8h.html#aac4e49b51ffe924451c9048c5061a224',1,'event.h']]], + ['event_5fget_5fsignal_1336',['event_get_signal',['../event_8h.html#a69cc368a9137187726ef371a06f9cc9f',1,'event.h']]], + ['event_5fmax_5fpriorities_1337',['EVENT_MAX_PRIORITIES',['../event_8h.html#ad74f7bf73ff985bfaf61c462cbba022f',1,'event.h']]], + ['event_5fset_5fmem_5ffunctions_5fimplemented_1338',['EVENT_SET_MEM_FUNCTIONS_IMPLEMENTED',['../event_8h.html#ade387a9a39bbbdf40ff20b4d977ec6ae',1,'event.h']]], + ['evhttp_5frequest_5furi_1339',['evhttp_request_uri',['../http__compat_8h.html#aae95ca15c179b4b0b8c7bbb7b1da342a',1,'http_compat.h']]], + ['evhttp_5furi_5fhost_5fstrip_5fbrackets_1340',['EVHTTP_URI_HOST_STRIP_BRACKETS',['../http_8h.html#a8260a82157dadb3a659cb1ba783bb304',1,'http.h']]], + ['evhttp_5furi_5fnonconformant_1341',['EVHTTP_URI_NONCONFORMANT',['../http_8h.html#ace576911d436a163584f4942907270a5',1,'http.h']]], + ['evhttp_5furi_5fquery_5flast_5fval_1342',['EVHTTP_URI_QUERY_LAST_VAL',['../http_8h.html#a12b8b97844f5d13e2f7b6d5c9f8ce0b6',1,'http.h']]], + ['evhttp_5furi_5fquery_5fnonconformant_1343',['EVHTTP_URI_QUERY_NONCONFORMANT',['../http_8h.html#a64c9b77846e83a6f3d45f4be4b7150de',1,'http.h']]], + ['evhttp_5furi_5funix_5fsocket_1344',['EVHTTP_URI_UNIX_SOCKET',['../http_8h.html#a3e2dab6e699d45bb208299312e73b2aa',1,'http.h']]], + ['evloop_5fno_5fexit_5fon_5fempty_1345',['EVLOOP_NO_EXIT_ON_EMPTY',['../event_8h.html#a6751a7d5867ff8e7807400a93ffd5b08',1,'event.h']]], + ['evloop_5fnonblock_1346',['EVLOOP_NONBLOCK',['../event_8h.html#a10b9c102337d0ece8607c9c01bc4f7c8',1,'event.h']]], + ['evloop_5fonce_1347',['EVLOOP_ONCE',['../event_8h.html#afab575b1e867dde13a2c7f2f967e0e4e',1,'event.h']]], + ['evrpc_5fgenerate_1348',['EVRPC_GENERATE',['../rpc_8h.html#af7abcafae087e3c4dce6a4cd85346114',1,'rpc.h']]], + ['evrpc_5fheader_1349',['EVRPC_HEADER',['../rpc_8h.html#aa526799df545537b2dc67358b0dfaa15',1,'rpc.h']]], + ['evrpc_5fmake_5fctx_1350',['EVRPC_MAKE_CTX',['../rpc_8h.html#ad7694fa8f1b5995a9d43bef1da170fad',1,'rpc.h']]], + ['evrpc_5fmake_5frequest_1351',['EVRPC_MAKE_REQUEST',['../rpc_8h.html#aff0efcd7cb8b966256b5127960bd2c81',1,'rpc.h']]], + ['evrpc_5fregister_1352',['EVRPC_REGISTER',['../rpc_8h.html#abb204281e2555a1e91ff3885747d0533',1,'rpc.h']]], + ['evrpc_5frequest_5fdone_1353',['EVRPC_REQUEST_DONE',['../rpc_8h.html#a36d6ba276baf3c95df69db35a2ef1527',1,'rpc.h']]], + ['evrpc_5frequest_5fhttp_1354',['EVRPC_REQUEST_HTTP',['../rpc_8h.html#af78e1869994ee9597a9a0785d25fbf0b',1,'rpc.h']]], + ['evrpc_5fstruct_1355',['EVRPC_STRUCT',['../rpc_8h.html#ae9eff66229e154543551a936c59dd8fa',1,'rpc.h']]], + ['evrpc_5funregister_1356',['EVRPC_UNREGISTER',['../rpc_8h.html#ab646cdf50e026accddcd9fe23b35837b',1,'rpc.h']]], + ['evtag_5farray_5fadd_1357',['EVTAG_ARRAY_ADD',['../rpc_8h.html#a8bd4b0f338823bffee3ead3885ea6791',1,'rpc.h']]], + ['evtag_5farray_5fadd_5fvalue_1358',['EVTAG_ARRAY_ADD_VALUE',['../rpc_8h.html#a796d8c44ee666b13ecbae36b0897820b',1,'rpc.h']]], + ['evtag_5farray_5fget_1359',['EVTAG_ARRAY_GET',['../rpc_8h.html#a1b955ffe442d49fdfe17c76a6e758880',1,'rpc.h']]], + ['evtag_5farray_5flen_1360',['EVTAG_ARRAY_LEN',['../rpc_8h.html#ab4a0a6a9f8fbe20ced71eaebd297168b',1,'rpc.h']]], + ['evtag_5fassign_1361',['EVTAG_ASSIGN',['../rpc_8h.html#a8063c9f0927da79cc9e53600a77eecc6',1,'rpc.h']]], + ['evtag_5fassign_5fwith_5flen_1362',['EVTAG_ASSIGN_WITH_LEN',['../rpc_8h.html#af420133e56a545bef6cba6f878d403d7',1,'rpc.h']]], + ['evtag_5fget_1363',['EVTAG_GET',['../rpc_8h.html#aef6e54053208c090c43d05c9b2259fb9',1,'rpc.h']]], + ['evtag_5fget_5fwith_5flen_1364',['EVTAG_GET_WITH_LEN',['../rpc_8h.html#ae0b73ea41cb7f06976fd69a8f1be6219',1,'rpc.h']]], + ['evtag_5fhas_1365',['EVTAG_HAS',['../rpc_8h.html#a1a924e89c7a0c5eddc63cf9bf569fae6',1,'rpc.h']]], + ['evtag_5flen_1366',['EVTAG_LEN',['../rpc__compat_8h.html#a9eb90639aa8aab13d3dc932353828e7b',1,'rpc_compat.h']]], + ['evthread_5flocktype_5frecursive_1367',['EVTHREAD_LOCKTYPE_RECURSIVE',['../thread_8h.html#a8fbf4020f11c3b98459fd8d4d427513c',1,'thread.h']]], + ['evthread_5fread_1368',['EVTHREAD_READ',['../thread_8h.html#a8c7a3fb4b1f521b4a262e5043f3fa14c',1,'thread.h']]], + ['evthread_5ftry_1369',['EVTHREAD_TRY',['../thread_8h.html#a746e63692bf5bd5b4ee5d929df1592e2',1,'thread.h']]], + ['evthread_5fuse_5fpthreads_5fimplemented_1370',['EVTHREAD_USE_PTHREADS_IMPLEMENTED',['../thread_8h.html#a8906b609d6c2bb4af5c7653c4f0f355d',1,'thread.h']]], + ['evthread_5fuse_5fwindows_5fthreads_5fimplemented_1371',['EVTHREAD_USE_WINDOWS_THREADS_IMPLEMENTED',['../thread_8h.html#a05306512f3074b45be6eba702440f1f1',1,'thread.h']]], + ['evthread_5fwrite_1372',['EVTHREAD_WRITE',['../thread_8h.html#aa9fb1861f3b09a03c5986561dd00db0d',1,'thread.h']]], + ['evutil_5foffsetof_1373',['evutil_offsetof',['../util_8h.html#a4c296955d33624c18bd4811730caa417',1,'util.h']]], + ['evutil_5fset_5fsocket_5ferror_1374',['EVUTIL_SET_SOCKET_ERROR',['../util_8h.html#ae8b4fae7790599f7b58e8c269f6b29d8',1,'util.h']]], + ['evutil_5fsocket_5ferror_1375',['EVUTIL_SOCKET_ERROR',['../util_8h.html#a9a94a2e72982e708333486cf72aab941',1,'util.h']]], + ['evutil_5fsocket_5ferror_5fto_5fstring_1376',['evutil_socket_error_to_string',['../util_8h.html#ad5ea5ef81ddcfb299e4867d362ad8654',1,'util.h']]], + ['evutil_5fsocket_5fgeterror_1377',['evutil_socket_geterror',['../util_8h.html#a28f952fb0f16b057d931fd38ee9bdf5e',1,'util.h']]], + ['evutil_5fsocket_5ft_1378',['evutil_socket_t',['../util_8h.html#a7ef0023565082a65020f6e56be59fd0b',1,'util.h']]], + ['evutil_5ftimercmp_1379',['evutil_timercmp',['../util_8h.html#a1a42f43db6aaf6e99736329b6611175d',1,'util.h']]] +]; diff --git a/search/defines_3.html b/search/defines_3.html new file mode 100644 index 0000000..f30be10 --- /dev/null +++ b/search/defines_3.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/defines_3.js b/search/defines_3.js new file mode 100644 index 0000000..3d3b58e --- /dev/null +++ b/search/defines_3.js @@ -0,0 +1,27 @@ +var searchData= +[ + ['http_5faccepted_1380',['HTTP_ACCEPTED',['../http_8h.html#ad53204f337b45ad77e9a746e434d1817',1,'http.h']]], + ['http_5fbadgateway_1381',['HTTP_BADGATEWAY',['../http_8h.html#a746f663029189ec16d55d0d9546ac89d',1,'http.h']]], + ['http_5fbadmethod_1382',['HTTP_BADMETHOD',['../http_8h.html#a8d93bc2b08ddc194c213682c4726b0e6',1,'http.h']]], + ['http_5fbadrequest_1383',['HTTP_BADREQUEST',['../http_8h.html#af9f070802de32cd2f820059fc42cbf39',1,'http.h']]], + ['http_5fcontinue_1384',['HTTP_CONTINUE',['../http_8h.html#a3c520c5e65c710a1c7bbb1fa79fd3a9d',1,'http.h']]], + ['http_5fcreated_1385',['HTTP_CREATED',['../http_8h.html#ac19a79fb4cf575d20efd0633c1669ed9',1,'http.h']]], + ['http_5fearlyhints_1386',['HTTP_EARLYHINTS',['../http_8h.html#acebc611f41e394b875f6283a4840d9d9',1,'http.h']]], + ['http_5fentitytoolarge_1387',['HTTP_ENTITYTOOLARGE',['../http_8h.html#a64236d9bad703199d84a08bee90e00f0',1,'http.h']]], + ['http_5fexpectationfailed_1388',['HTTP_EXPECTATIONFAILED',['../http_8h.html#a4eac9f52d3d8de9b3deadaec6ad0bee9',1,'http.h']]], + ['http_5fforbidden_1389',['HTTP_FORBIDDEN',['../http_8h.html#a92646f876056a1e5013e0050496dc04d',1,'http.h']]], + ['http_5finternal_1390',['HTTP_INTERNAL',['../http_8h.html#a15eac402986428a8125d364b7ae569b1',1,'http.h']]], + ['http_5fmoveperm_1391',['HTTP_MOVEPERM',['../http_8h.html#ac6ffbb7b69889f1eee0d413576c609a9',1,'http.h']]], + ['http_5fmovetemp_1392',['HTTP_MOVETEMP',['../http_8h.html#a7d2a7341ba2af15babe8c25df67e563f',1,'http.h']]], + ['http_5fnocontent_1393',['HTTP_NOCONTENT',['../http_8h.html#ac5e3a483119375a05d199c30709f2b8e',1,'http.h']]], + ['http_5fnonauthoritative_1394',['HTTP_NONAUTHORITATIVE',['../http_8h.html#ab9789b35d84095b35f7ab1d9913fff4e',1,'http.h']]], + ['http_5fnotfound_1395',['HTTP_NOTFOUND',['../http_8h.html#a1f5b9c02b018640c890e5f27207fa6c0',1,'http.h']]], + ['http_5fnotimplemented_1396',['HTTP_NOTIMPLEMENTED',['../http_8h.html#a9759dd4ad026a688142afb7b4e4542cc',1,'http.h']]], + ['http_5fnotmodified_1397',['HTTP_NOTMODIFIED',['../http_8h.html#a3112d58297965db46a04fe288bf1d0da',1,'http.h']]], + ['http_5fok_1398',['HTTP_OK',['../http_8h.html#a02e6d59009dee759528ec81fc9a8eeff',1,'http.h']]], + ['http_5fpaymentrequired_1399',['HTTP_PAYMENTREQUIRED',['../http_8h.html#aaae52dca74d8f240798a3daf8396bfe5',1,'http.h']]], + ['http_5fprocessing_1400',['HTTP_PROCESSING',['../http_8h.html#aad76b47755281ea8ba65edc6683be8f9',1,'http.h']]], + ['http_5fservunavail_1401',['HTTP_SERVUNAVAIL',['../http_8h.html#a5fd6829fe2bb38dd13288f11dcb2025f',1,'http.h']]], + ['http_5fswitch_5fprotocols_1402',['HTTP_SWITCH_PROTOCOLS',['../http_8h.html#aa0a6a40f95575cb08438f396f0711017',1,'http.h']]], + ['http_5funauthorized_1403',['HTTP_UNAUTHORIZED',['../http_8h.html#ac4cfa4b7a737abff1264ddba3752a2ad',1,'http.h']]] +]; diff --git a/search/defines_4.html b/search/defines_4.html new file mode 100644 index 0000000..046ad4a --- /dev/null +++ b/search/defines_4.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/defines_4.js b/search/defines_4.js new file mode 100644 index 0000000..760eb03 --- /dev/null +++ b/search/defines_4.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['input_1404',['INPUT',['../rpc_8h.html#a1bb283bd7893b9855e2f23013891fc82',1,'rpc.h']]] +]; diff --git a/search/defines_5.html b/search/defines_5.html new file mode 100644 index 0000000..61ce555 --- /dev/null +++ b/search/defines_5.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/defines_5.js b/search/defines_5.js new file mode 100644 index 0000000..a86715b --- /dev/null +++ b/search/defines_5.js @@ -0,0 +1,15 @@ +var searchData= +[ + ['lev_5fopt_5fbind_5fipv4_5fand_5fipv6_1405',['LEV_OPT_BIND_IPV4_AND_IPV6',['../listener_8h.html#afc396525343a6848149d6c0f7cd11ed5',1,'listener.h']]], + ['lev_5fopt_5fbind_5fipv6only_1406',['LEV_OPT_BIND_IPV6ONLY',['../listener_8h.html#a3a54f81b44cec176dffe72a1aa22d8e6',1,'listener.h']]], + ['lev_5fopt_5fclose_5fon_5fexec_1407',['LEV_OPT_CLOSE_ON_EXEC',['../listener_8h.html#af6f307bd279abe88586fb56672fcf6c8',1,'listener.h']]], + ['lev_5fopt_5fclose_5fon_5ffree_1408',['LEV_OPT_CLOSE_ON_FREE',['../listener_8h.html#a4b2de09b129675a41696a89e5c58de53',1,'listener.h']]], + ['lev_5fopt_5fdeferred_5faccept_1409',['LEV_OPT_DEFERRED_ACCEPT',['../listener_8h.html#a5b1903214eb069f47ae9119793307b89',1,'listener.h']]], + ['lev_5fopt_5fdisabled_1410',['LEV_OPT_DISABLED',['../listener_8h.html#ad96f043f9d9b2f028536fe832061daf6',1,'listener.h']]], + ['lev_5fopt_5fleave_5fsockets_5fblocking_1411',['LEV_OPT_LEAVE_SOCKETS_BLOCKING',['../listener_8h.html#ac19549ba5b3746557d5fd8be8a9c5eb3',1,'listener.h']]], + ['lev_5fopt_5freuseable_1412',['LEV_OPT_REUSEABLE',['../listener_8h.html#a15337d63b237ec11b0781656aad90662',1,'listener.h']]], + ['lev_5fopt_5freuseable_5fport_1413',['LEV_OPT_REUSEABLE_PORT',['../listener_8h.html#af417f499a89518d16eb3be4098e504c7',1,'listener.h']]], + ['lev_5fopt_5fthreadsafe_1414',['LEV_OPT_THREADSAFE',['../listener_8h.html#a7bcc41438093090d28a7c98b899db9ba',1,'listener.h']]], + ['libevent_5fversion_1415',['LIBEVENT_VERSION',['../event_8h.html#aad00c7d4ddbd6b590c15861a2e767182',1,'event.h']]], + ['libevent_5fversion_5fnumber_1416',['LIBEVENT_VERSION_NUMBER',['../event_8h.html#a8a9c8021651a2d8d7946083281279586',1,'event.h']]] +]; diff --git a/search/defines_6.html b/search/defines_6.html new file mode 100644 index 0000000..7496307 --- /dev/null +++ b/search/defines_6.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/defines_6.js b/search/defines_6.js new file mode 100644 index 0000000..3400f27 --- /dev/null +++ b/search/defines_6.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['output_1417',['OUTPUT',['../rpc_8h.html#a61a3c9a18380aafb6e430e79bf596557',1,'rpc.h']]] +]; diff --git a/search/enums_0.html b/search/enums_0.html new file mode 100644 index 0000000..9669700 --- /dev/null +++ b/search/enums_0.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/enums_0.js b/search/enums_0.js new file mode 100644 index 0000000..0c988a6 --- /dev/null +++ b/search/enums_0.js @@ -0,0 +1,8 @@ +var searchData= +[ + ['bufferevent_5ffilter_5fresult_1226',['bufferevent_filter_result',['../bufferevent_8h.html#a19e499f7bfa831b802fd3575d141b4e1',1,'bufferevent.h']]], + ['bufferevent_5fflush_5fmode_1227',['bufferevent_flush_mode',['../bufferevent_8h.html#ac35edc760057a2e48b4e8ba9ecf2ad25',1,'bufferevent.h']]], + ['bufferevent_5foptions_1228',['bufferevent_options',['../bufferevent_8h.html#aa4919449c62c6483e2d135509190dc65',1,'bufferevent.h']]], + ['bufferevent_5fssl_5fstate_1229',['bufferevent_ssl_state',['../bufferevent__ssl_8h.html#a96964ed61294aff8a9d95d661f403ee4',1,'bufferevent_ssl.h']]], + ['bufferevent_5ftrigger_5foptions_1230',['bufferevent_trigger_options',['../bufferevent_8h.html#a7837b6947fc855924466e2347a6faa8f',1,'bufferevent.h']]] +]; diff --git a/search/enums_1.html b/search/enums_1.html new file mode 100644 index 0000000..dfec174 --- /dev/null +++ b/search/enums_1.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/enums_1.js b/search/enums_1.js new file mode 100644 index 0000000..4d749c2 --- /dev/null +++ b/search/enums_1.js @@ -0,0 +1,13 @@ +var searchData= +[ + ['evbuffer_5feol_5fstyle_1231',['evbuffer_eol_style',['../buffer_8h.html#ad8daf54669a1d2094ce4251dbb502178',1,'buffer.h']]], + ['evbuffer_5fptr_5fhow_1232',['evbuffer_ptr_how',['../buffer_8h.html#a13a9ee759900ce2964d16acd5f309014',1,'buffer.h']]], + ['evdns_5fserver_5foption_1233',['evdns_server_option',['../dns_8h.html#a626139345ff6cb6c871e2950872e8473',1,'dns.h']]], + ['event_5fbase_5fconfig_5fflag_1234',['event_base_config_flag',['../event_8h.html#acfef69af45abee54725f40f7f29986c5',1,'event.h']]], + ['event_5fmethod_5ffeature_1235',['event_method_feature',['../event_8h.html#ae7da61aef13e27a3047151b696b44c80',1,'event.h']]], + ['evhttp_5fcmd_5ftype_1236',['evhttp_cmd_type',['../http_8h.html#ac858319d667267f9fc848c2bb6931aa3',1,'http.h']]], + ['evhttp_5frequest_5ferror_1237',['evhttp_request_error',['../http_8h.html#a01f921a909d1504f873222b1d29c2b4a',1,'http.h']]], + ['evhttp_5frequest_5fkind_1238',['evhttp_request_kind',['../http_8h.html#a47ca41a942899d019bf59cf32301ae4f',1,'http.h']]], + ['evrpc_5fhook_5fresult_1239',['EVRPC_HOOK_RESULT',['../rpc_8h.html#a9c37f133ebc96b2bd66c472079b1338b',1,'rpc.h']]], + ['evrpc_5fhook_5ftype_1240',['EVRPC_HOOK_TYPE',['../rpc_8h.html#a66eff7ea6bdd17e53fde6c4d9dc1835b',1,'rpc.h']]] +]; diff --git a/search/enumvalues_0.html b/search/enumvalues_0.html new file mode 100644 index 0000000..9286248 --- /dev/null +++ b/search/enumvalues_0.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/enumvalues_0.js b/search/enumvalues_0.js new file mode 100644 index 0000000..cb01bc2 --- /dev/null +++ b/search/enumvalues_0.js @@ -0,0 +1,15 @@ +var searchData= +[ + ['bev_5ferror_1241',['BEV_ERROR',['../bufferevent_8h.html#a19e499f7bfa831b802fd3575d141b4e1a4e51550811d3dad92400c27d69277032',1,'bufferevent.h']]], + ['bev_5ffinished_1242',['BEV_FINISHED',['../bufferevent_8h.html#ac35edc760057a2e48b4e8ba9ecf2ad25acb248a91854bbebd773061df7f4bbc94',1,'bufferevent.h']]], + ['bev_5fflush_1243',['BEV_FLUSH',['../bufferevent_8h.html#ac35edc760057a2e48b4e8ba9ecf2ad25a77e7f15a95815dcaaef27fdabb0e6164',1,'bufferevent.h']]], + ['bev_5fneed_5fmore_1244',['BEV_NEED_MORE',['../bufferevent_8h.html#a19e499f7bfa831b802fd3575d141b4e1a78c4f864aee50d333d74e3b46e12b8a4',1,'bufferevent.h']]], + ['bev_5fnormal_1245',['BEV_NORMAL',['../bufferevent_8h.html#ac35edc760057a2e48b4e8ba9ecf2ad25a81903ce04ca68ac1680dd0b7a28a7fce',1,'bufferevent.h']]], + ['bev_5fok_1246',['BEV_OK',['../bufferevent_8h.html#a19e499f7bfa831b802fd3575d141b4e1a794bf8211eaafdbeb382991dc5874e4d',1,'bufferevent.h']]], + ['bev_5fopt_5fclose_5fon_5ffree_1247',['BEV_OPT_CLOSE_ON_FREE',['../bufferevent_8h.html#aa4919449c62c6483e2d135509190dc65a5dc89d74ef445da33295d00c8f6adc90',1,'bufferevent.h']]], + ['bev_5fopt_5fdefer_5fcallbacks_1248',['BEV_OPT_DEFER_CALLBACKS',['../bufferevent_8h.html#aa4919449c62c6483e2d135509190dc65a2fbeb24d0156aa2492c23aaace73f1d3',1,'bufferevent.h']]], + ['bev_5fopt_5fthreadsafe_1249',['BEV_OPT_THREADSAFE',['../bufferevent_8h.html#aa4919449c62c6483e2d135509190dc65adfb637881b739eff1441ad848a5e3a2d',1,'bufferevent.h']]], + ['bev_5fopt_5funlock_5fcallbacks_1250',['BEV_OPT_UNLOCK_CALLBACKS',['../bufferevent_8h.html#aa4919449c62c6483e2d135509190dc65acb8ca6f6422fb8f9a748521cf8c4caf5',1,'bufferevent.h']]], + ['bev_5ftrig_5fdefer_5fcallbacks_1251',['BEV_TRIG_DEFER_CALLBACKS',['../bufferevent_8h.html#a7837b6947fc855924466e2347a6faa8faef788894ba060effdd88553e59eb1330',1,'bufferevent.h']]], + ['bev_5ftrig_5fignore_5fwatermarks_1252',['BEV_TRIG_IGNORE_WATERMARKS',['../bufferevent_8h.html#a7837b6947fc855924466e2347a6faa8fa02d5d43f86f75f0f1569ca2b16025bfc',1,'bufferevent.h']]] +]; diff --git a/search/enumvalues_1.html b/search/enumvalues_1.html new file mode 100644 index 0000000..e22a79f --- /dev/null +++ b/search/enumvalues_1.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/enumvalues_1.js b/search/enumvalues_1.js new file mode 100644 index 0000000..eb9574f --- /dev/null +++ b/search/enumvalues_1.js @@ -0,0 +1,35 @@ +var searchData= +[ + ['ev_5ffeature_5fearly_5fclose_1253',['EV_FEATURE_EARLY_CLOSE',['../event_8h.html#ae7da61aef13e27a3047151b696b44c80af28b206cf4665dacc2c6bf09446e29b7',1,'event.h']]], + ['ev_5ffeature_5fet_1254',['EV_FEATURE_ET',['../event_8h.html#ae7da61aef13e27a3047151b696b44c80ab407cae60af925dba44bd66e56e5f897',1,'event.h']]], + ['ev_5ffeature_5ffds_1255',['EV_FEATURE_FDS',['../event_8h.html#ae7da61aef13e27a3047151b696b44c80a2e964e8a8f3033d26d52831fb8eec199',1,'event.h']]], + ['ev_5ffeature_5fo1_1256',['EV_FEATURE_O1',['../event_8h.html#ae7da61aef13e27a3047151b696b44c80a7a6f2de86c09b92aa175f950190bf706',1,'event.h']]], + ['evbuffer_5feol_5fany_1257',['EVBUFFER_EOL_ANY',['../buffer_8h.html#ad8daf54669a1d2094ce4251dbb502178ab7c6da1408b1b2ec3a6657e5a71a50c3',1,'buffer.h']]], + ['evbuffer_5feol_5fcrlf_1258',['EVBUFFER_EOL_CRLF',['../buffer_8h.html#ad8daf54669a1d2094ce4251dbb502178a4aec5353e85fbb57ce3b1ee68f36f641',1,'buffer.h']]], + ['evbuffer_5feol_5fcrlf_5fstrict_1259',['EVBUFFER_EOL_CRLF_STRICT',['../buffer_8h.html#ad8daf54669a1d2094ce4251dbb502178a814775b4a9773d34421e7e88ca8c58de',1,'buffer.h']]], + ['evbuffer_5feol_5flf_1260',['EVBUFFER_EOL_LF',['../buffer_8h.html#ad8daf54669a1d2094ce4251dbb502178ac572ea90e5a96a7ceb878f2a8ef48993',1,'buffer.h']]], + ['evbuffer_5feol_5fnul_1261',['EVBUFFER_EOL_NUL',['../buffer_8h.html#ad8daf54669a1d2094ce4251dbb502178a7b93c5a9f595c62c9d016562356159b7',1,'buffer.h']]], + ['evbuffer_5fptr_5fadd_1262',['EVBUFFER_PTR_ADD',['../buffer_8h.html#a13a9ee759900ce2964d16acd5f309014a0bce00d78b5fbc55c478ff362269f428',1,'buffer.h']]], + ['evbuffer_5fptr_5fset_1263',['EVBUFFER_PTR_SET',['../buffer_8h.html#a13a9ee759900ce2964d16acd5f309014a78a0ff3721ff5f1647f743dcfb2f13ee',1,'buffer.h']]], + ['evdns_5fsopt_5ftcp_5fidle_5ftimeout_1264',['EVDNS_SOPT_TCP_IDLE_TIMEOUT',['../dns_8h.html#a626139345ff6cb6c871e2950872e8473a6363f0c18c4efaff4d00b27ced12e92b',1,'dns.h']]], + ['evdns_5fsopt_5ftcp_5fmax_5fclients_1265',['EVDNS_SOPT_TCP_MAX_CLIENTS',['../dns_8h.html#a626139345ff6cb6c871e2950872e8473a8943e341547a0479f14a9c4de889217d',1,'dns.h']]], + ['event_5fbase_5fflag_5fepoll_5fdisallow_5ftimerfd_1266',['EVENT_BASE_FLAG_EPOLL_DISALLOW_TIMERFD',['../event_8h.html#acfef69af45abee54725f40f7f29986c5a9eaa69643a73f5fb5959db017c9050a5',1,'event.h']]], + ['event_5fbase_5fflag_5fepoll_5fuse_5fchangelist_1267',['EVENT_BASE_FLAG_EPOLL_USE_CHANGELIST',['../event_8h.html#acfef69af45abee54725f40f7f29986c5acceb45f3098787247044929f92f4296e',1,'event.h']]], + ['event_5fbase_5fflag_5fignore_5fenv_1268',['EVENT_BASE_FLAG_IGNORE_ENV',['../event_8h.html#acfef69af45abee54725f40f7f29986c5a230574947412d83f2dd19fe8c7d286e7',1,'event.h']]], + ['event_5fbase_5fflag_5fno_5fcache_5ftime_1269',['EVENT_BASE_FLAG_NO_CACHE_TIME',['../event_8h.html#acfef69af45abee54725f40f7f29986c5a057dff1977c48174f0a0f0c43ef92ec5',1,'event.h']]], + ['event_5fbase_5fflag_5fnolock_1270',['EVENT_BASE_FLAG_NOLOCK',['../event_8h.html#acfef69af45abee54725f40f7f29986c5ac1302f72251168137258335e945e2ae5',1,'event.h']]], + ['event_5fbase_5fflag_5fprecise_5ftimer_1271',['EVENT_BASE_FLAG_PRECISE_TIMER',['../event_8h.html#acfef69af45abee54725f40f7f29986c5af6080f1d7c5067868cbc749d1cfe56e9',1,'event.h']]], + ['event_5fbase_5fflag_5fstartup_5fiocp_1272',['EVENT_BASE_FLAG_STARTUP_IOCP',['../event_8h.html#acfef69af45abee54725f40f7f29986c5a4ffb2510ab533d7156f412ee4f0c08ea',1,'event.h']]], + ['event_5fbase_5fflag_5fuse_5fsignalfd_1273',['EVENT_BASE_FLAG_USE_SIGNALFD',['../event_8h.html#acfef69af45abee54725f40f7f29986c5a86d9f5574e29964187bafe245b211447',1,'event.h']]], + ['evreq_5fhttp_5fbuffer_5ferror_1274',['EVREQ_HTTP_BUFFER_ERROR',['../http_8h.html#a01f921a909d1504f873222b1d29c2b4aa3bd6cb0d713a8ae9eaa3cf667a3edc9b',1,'http.h']]], + ['evreq_5fhttp_5fdata_5ftoo_5flong_1275',['EVREQ_HTTP_DATA_TOO_LONG',['../http_8h.html#a01f921a909d1504f873222b1d29c2b4aac26adda43a54b9011756e83e93b9b26b',1,'http.h']]], + ['evreq_5fhttp_5feof_1276',['EVREQ_HTTP_EOF',['../http_8h.html#a01f921a909d1504f873222b1d29c2b4aac2922c6ca9cd576a7e722f18876676a8',1,'http.h']]], + ['evreq_5fhttp_5finvalid_5fheader_1277',['EVREQ_HTTP_INVALID_HEADER',['../http_8h.html#a01f921a909d1504f873222b1d29c2b4aad755cf3b1ab25bdfede358b137e7d1e4',1,'http.h']]], + ['evreq_5fhttp_5frequest_5fcancel_1278',['EVREQ_HTTP_REQUEST_CANCEL',['../http_8h.html#a01f921a909d1504f873222b1d29c2b4aaa07ee0241ac812c0e8bc1eabc5ac810d',1,'http.h']]], + ['evreq_5fhttp_5ftimeout_1279',['EVREQ_HTTP_TIMEOUT',['../http_8h.html#a01f921a909d1504f873222b1d29c2b4aa52bd0bcf036c6577b3ea55c7c086880d',1,'http.h']]], + ['evrpc_5fcontinue_1280',['EVRPC_CONTINUE',['../rpc_8h.html#a9c37f133ebc96b2bd66c472079b1338ba4f92aee79d3413c4940eeb578ee33643',1,'rpc.h']]], + ['evrpc_5finput_1281',['EVRPC_INPUT',['../rpc_8h.html#a66eff7ea6bdd17e53fde6c4d9dc1835ba2a62d2e1147edb5b460c1abb17be9734',1,'rpc.h']]], + ['evrpc_5foutput_1282',['EVRPC_OUTPUT',['../rpc_8h.html#a66eff7ea6bdd17e53fde6c4d9dc1835bad63587ff3a66808e422f1ca48c9db85e',1,'rpc.h']]], + ['evrpc_5fpause_1283',['EVRPC_PAUSE',['../rpc_8h.html#a9c37f133ebc96b2bd66c472079b1338baff86ced7cf446eec75868ba64d956b9c',1,'rpc.h']]], + ['evrpc_5fterminate_1284',['EVRPC_TERMINATE',['../rpc_8h.html#a9c37f133ebc96b2bd66c472079b1338ba61de2cad490f408aa9ecc3427cfb6233',1,'rpc.h']]] +]; diff --git a/search/files_0.html b/search/files_0.html new file mode 100644 index 0000000..737608e --- /dev/null +++ b/search/files_0.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/files_0.js b/search/files_0.js new file mode 100644 index 0000000..7d59590 --- /dev/null +++ b/search/files_0.js @@ -0,0 +1,8 @@ +var searchData= +[ + ['buffer_2eh_721',['buffer.h',['../buffer_8h.html',1,'']]], + ['buffer_5fcompat_2eh_722',['buffer_compat.h',['../buffer__compat_8h.html',1,'']]], + ['bufferevent_2eh_723',['bufferevent.h',['../bufferevent_8h.html',1,'']]], + ['bufferevent_5fcompat_2eh_724',['bufferevent_compat.h',['../bufferevent__compat_8h.html',1,'']]], + ['bufferevent_5fssl_2eh_725',['bufferevent_ssl.h',['../bufferevent__ssl_8h.html',1,'']]] +]; diff --git a/search/files_1.html b/search/files_1.html new file mode 100644 index 0000000..f27a62d --- /dev/null +++ b/search/files_1.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/files_1.js b/search/files_1.js new file mode 100644 index 0000000..0a26048 --- /dev/null +++ b/search/files_1.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['dns_2eh_726',['dns.h',['../dns_8h.html',1,'']]], + ['dns_5fcompat_2eh_727',['dns_compat.h',['../dns__compat_8h.html',1,'']]] +]; diff --git a/search/files_2.html b/search/files_2.html new file mode 100644 index 0000000..a45066e --- /dev/null +++ b/search/files_2.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/files_2.js b/search/files_2.js new file mode 100644 index 0000000..0541d8f --- /dev/null +++ b/search/files_2.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['event_2eh_728',['event.h',['../event_8h.html',1,'']]], + ['event_5fcompat_2eh_729',['event_compat.h',['../event__compat_8h.html',1,'']]] +]; diff --git a/search/files_3.html b/search/files_3.html new file mode 100644 index 0000000..1076bc5 --- /dev/null +++ b/search/files_3.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/files_3.js b/search/files_3.js new file mode 100644 index 0000000..df7238e --- /dev/null +++ b/search/files_3.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['http_2eh_730',['http.h',['../http_8h.html',1,'']]], + ['http_5fcompat_2eh_731',['http_compat.h',['../http__compat_8h.html',1,'']]] +]; diff --git a/search/files_4.html b/search/files_4.html new file mode 100644 index 0000000..e5cd7f4 --- /dev/null +++ b/search/files_4.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/files_4.js b/search/files_4.js new file mode 100644 index 0000000..3224438 --- /dev/null +++ b/search/files_4.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['listener_2eh_732',['listener.h',['../listener_8h.html',1,'']]] +]; diff --git a/search/files_5.html b/search/files_5.html new file mode 100644 index 0000000..2cc480f --- /dev/null +++ b/search/files_5.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/files_5.js b/search/files_5.js new file mode 100644 index 0000000..1429147 --- /dev/null +++ b/search/files_5.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['rpc_2eh_733',['rpc.h',['../rpc_8h.html',1,'']]], + ['rpc_5fcompat_2eh_734',['rpc_compat.h',['../rpc__compat_8h.html',1,'']]] +]; diff --git a/search/files_6.html b/search/files_6.html new file mode 100644 index 0000000..6510245 --- /dev/null +++ b/search/files_6.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/files_6.js b/search/files_6.js new file mode 100644 index 0000000..7e3772c --- /dev/null +++ b/search/files_6.js @@ -0,0 +1,6 @@ +var searchData= +[ + ['tag_2eh_735',['tag.h',['../tag_8h.html',1,'']]], + ['tag_5fcompat_2eh_736',['tag_compat.h',['../tag__compat_8h.html',1,'']]], + ['thread_2eh_737',['thread.h',['../thread_8h.html',1,'']]] +]; diff --git a/search/files_7.html b/search/files_7.html new file mode 100644 index 0000000..819f7b8 --- /dev/null +++ b/search/files_7.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/files_7.js b/search/files_7.js new file mode 100644 index 0000000..edd9c8e --- /dev/null +++ b/search/files_7.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['util_2eh_738',['util.h',['../util_8h.html',1,'']]] +]; diff --git a/search/files_8.html b/search/files_8.html new file mode 100644 index 0000000..fa1a27f --- /dev/null +++ b/search/files_8.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/files_8.js b/search/files_8.js new file mode 100644 index 0000000..63c2117 --- /dev/null +++ b/search/files_8.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['watch_2eh_739',['watch.h',['../watch_8h.html',1,'']]] +]; diff --git a/search/functions_0.html b/search/functions_0.html new file mode 100644 index 0000000..e17c711 --- /dev/null +++ b/search/functions_0.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/functions_0.js b/search/functions_0.js new file mode 100644 index 0000000..a37f63c --- /dev/null +++ b/search/functions_0.js @@ -0,0 +1,72 @@ +var searchData= +[ + ['bufferevent_5fadd_5fto_5frate_5flimit_5fgroup_740',['bufferevent_add_to_rate_limit_group',['../bufferevent_8h.html#a44ea6c9406f855dadf4afadadbbf47d8',1,'bufferevent.h']]], + ['bufferevent_5fbase_5fset_741',['bufferevent_base_set',['../bufferevent_8h.html#acb59fdb64642f73a96c84adeb97311cb',1,'bufferevent.h']]], + ['bufferevent_5fdecref_742',['bufferevent_decref',['../bufferevent_8h.html#a3427551c0806f78f1bdfd8d767974e27',1,'bufferevent.h']]], + ['bufferevent_5fdisable_743',['bufferevent_disable',['../bufferevent_8h.html#a4f3974def824e73a6861d94cff71e7c6',1,'bufferevent.h']]], + ['bufferevent_5fenable_744',['bufferevent_enable',['../bufferevent_8h.html#aa8a5dd2436494afd374213b99102265b',1,'bufferevent.h']]], + ['bufferevent_5ffilter_5fnew_745',['bufferevent_filter_new',['../bufferevent_8h.html#a38bb612dac0112d8ceeb02d0a9a02451',1,'bufferevent.h']]], + ['bufferevent_5fflush_746',['bufferevent_flush',['../bufferevent_8h.html#a4e7b46a3dd1518534a2120ee9c8dbe69',1,'bufferevent.h']]], + ['bufferevent_5ffree_747',['bufferevent_free',['../bufferevent_8h.html#a8baa699f526f237c0d33f618f073c1cc',1,'bufferevent.h']]], + ['bufferevent_5fget_5fbase_748',['bufferevent_get_base',['../bufferevent_8h.html#a16aa6baf1d489b14fd31cf5e18265186',1,'bufferevent.h']]], + ['bufferevent_5fget_5fenabled_749',['bufferevent_get_enabled',['../bufferevent_8h.html#ab78b8248210f0fadac8b5924dde5a3e7',1,'bufferevent.h']]], + ['bufferevent_5fget_5finput_750',['bufferevent_get_input',['../bufferevent_8h.html#a3ddbf50178b96b3f243ddc83d67e88b0',1,'bufferevent.h']]], + ['bufferevent_5fget_5fmax_5fsingle_5fread_751',['bufferevent_get_max_single_read',['../bufferevent_8h.html#a2fd3db28a9802573c07e5e0584b85465',1,'bufferevent.h']]], + ['bufferevent_5fget_5fmax_5fsingle_5fwrite_752',['bufferevent_get_max_single_write',['../bufferevent_8h.html#acb0bd0b3bb5c983c2b3680637af08617',1,'bufferevent.h']]], + ['bufferevent_5fget_5fmbedtls_5ferror_753',['bufferevent_get_mbedtls_error',['../bufferevent__ssl_8h.html#a9ff8a04e47b127f185911ea153cde862',1,'bufferevent_ssl.h']]], + ['bufferevent_5fget_5fopenssl_5ferror_754',['bufferevent_get_openssl_error',['../bufferevent__ssl_8h.html#a02d39dd2ed160e7564f62cf487bd0315',1,'bufferevent_ssl.h']]], + ['bufferevent_5fget_5foutput_755',['bufferevent_get_output',['../bufferevent_8h.html#ac6e45fa1fc577c4f0e6c4689e72c0a15',1,'bufferevent.h']]], + ['bufferevent_5fget_5fpriority_756',['bufferevent_get_priority',['../bufferevent_8h.html#a0091b3c386580cf2980039ad9a629b70',1,'bufferevent.h']]], + ['bufferevent_5fget_5funderlying_757',['bufferevent_get_underlying',['../bufferevent_8h.html#a3e0081196d2776b92994c6034eb00b2c',1,'bufferevent.h']]], + ['bufferevent_5fgetcb_758',['bufferevent_getcb',['../bufferevent_8h.html#ae58a293995d110362cc1fc695678a928',1,'bufferevent.h']]], + ['bufferevent_5fgetfd_759',['bufferevent_getfd',['../bufferevent_8h.html#a544e049e4a8cca27ab1a98b8339fe72a',1,'bufferevent.h']]], + ['bufferevent_5fgetwatermark_760',['bufferevent_getwatermark',['../bufferevent_8h.html#ae3dd6349d1e33b5238e110a3aba4d163',1,'bufferevent.h']]], + ['bufferevent_5fincref_761',['bufferevent_incref',['../bufferevent_8h.html#a27cabbe542fec7731049312e37e7ba95',1,'bufferevent.h']]], + ['bufferevent_5flock_762',['bufferevent_lock',['../bufferevent_8h.html#a8744a827bb440c1b62676ec35b56b5fc',1,'bufferevent.h']]], + ['bufferevent_5fmbedtls_5fdyncontext_5ffree_763',['bufferevent_mbedtls_dyncontext_free',['../bufferevent__ssl_8h.html#addce4bbddd3fe09b50f9042bd7d1435e',1,'bufferevent_ssl.h']]], + ['bufferevent_5fmbedtls_5fdyncontext_5fnew_764',['bufferevent_mbedtls_dyncontext_new',['../bufferevent__ssl_8h.html#a15ef9128f6f03c98d24032d74de6f0a8',1,'bufferevent_ssl.h']]], + ['bufferevent_5fmbedtls_5ffilter_5fnew_765',['bufferevent_mbedtls_filter_new',['../bufferevent__ssl_8h.html#ab70b27645fdd5a2f0294d53aa1743061',1,'bufferevent_ssl.h']]], + ['bufferevent_5fmbedtls_5fget_5fallow_5fdirty_5fshutdown_766',['bufferevent_mbedtls_get_allow_dirty_shutdown',['../bufferevent__ssl_8h.html#a4f8cc4d8ca0fc0c882659b0e7793e886',1,'bufferevent_ssl.h']]], + ['bufferevent_5fmbedtls_5fget_5fssl_767',['bufferevent_mbedtls_get_ssl',['../bufferevent__ssl_8h.html#afd907d76bb66d40b6633f611c0f01526',1,'bufferevent_ssl.h']]], + ['bufferevent_5fmbedtls_5frenegotiate_768',['bufferevent_mbedtls_renegotiate',['../bufferevent__ssl_8h.html#ad8a0aa57628113bd4fae0ad7dc796b34',1,'bufferevent_ssl.h']]], + ['bufferevent_5fmbedtls_5fset_5fallow_5fdirty_5fshutdown_769',['bufferevent_mbedtls_set_allow_dirty_shutdown',['../bufferevent__ssl_8h.html#a72794ad409cf280240988a104cc3a836',1,'bufferevent_ssl.h']]], + ['bufferevent_5fmbedtls_5fsocket_5fnew_770',['bufferevent_mbedtls_socket_new',['../bufferevent__ssl_8h.html#a941a2172b791789ef1791f2c3b28be75',1,'bufferevent_ssl.h']]], + ['bufferevent_5fnew_771',['bufferevent_new',['../bufferevent__compat_8h.html#a621af7017b3a7fe2ab1de902297ceb94',1,'bufferevent_compat.h']]], + ['bufferevent_5fopenssl_5ffilter_5fnew_772',['bufferevent_openssl_filter_new',['../bufferevent__ssl_8h.html#ac6d45c0c7988f83b0feb2b67497e33c9',1,'bufferevent_ssl.h']]], + ['bufferevent_5fopenssl_5fget_5fallow_5fdirty_5fshutdown_773',['bufferevent_openssl_get_allow_dirty_shutdown',['../bufferevent__ssl_8h.html#ab99fa44e01e56fbd4de25022be3ffbe4',1,'bufferevent_ssl.h']]], + ['bufferevent_5fopenssl_5fget_5fssl_774',['bufferevent_openssl_get_ssl',['../bufferevent__ssl_8h.html#a8e0f365c4daa5129c0cd311a3ee0149f',1,'bufferevent_ssl.h']]], + ['bufferevent_5fopenssl_5fset_5fallow_5fdirty_5fshutdown_775',['bufferevent_openssl_set_allow_dirty_shutdown',['../bufferevent__ssl_8h.html#aa12d88e848c0b8b43e2e7c60992ab870',1,'bufferevent_ssl.h']]], + ['bufferevent_5fopenssl_5fsocket_5fnew_776',['bufferevent_openssl_socket_new',['../bufferevent__ssl_8h.html#a7a3090b586bfc7fc02e81a3a2c2deea5',1,'bufferevent_ssl.h']]], + ['bufferevent_5fpair_5fget_5fpartner_777',['bufferevent_pair_get_partner',['../bufferevent_8h.html#a32442df1f9b2252e00d9d9a64ea07854',1,'bufferevent.h']]], + ['bufferevent_5fpair_5fnew_778',['bufferevent_pair_new',['../bufferevent_8h.html#ac6271b7cc2126d3bc745cf00187672a5',1,'bufferevent.h']]], + ['bufferevent_5fpriority_5fset_779',['bufferevent_priority_set',['../bufferevent_8h.html#a2a0eaaf330e2fa46f84dd5ec3e1299c8',1,'bufferevent.h']]], + ['bufferevent_5frate_5flimit_5fgroup_5ffree_780',['bufferevent_rate_limit_group_free',['../bufferevent_8h.html#a5f4f37207371ed122bd5866a55769be1',1,'bufferevent.h']]], + ['bufferevent_5frate_5flimit_5fgroup_5fget_5ftotals_781',['bufferevent_rate_limit_group_get_totals',['../bufferevent_8h.html#ac94cfb31bf5542e1a424d2df3d73203f',1,'bufferevent.h']]], + ['bufferevent_5frate_5flimit_5fgroup_5fnew_782',['bufferevent_rate_limit_group_new',['../bufferevent_8h.html#afc5cd06cb7b574ec9746c8fb89b98491',1,'bufferevent.h']]], + ['bufferevent_5frate_5flimit_5fgroup_5freset_5ftotals_783',['bufferevent_rate_limit_group_reset_totals',['../bufferevent_8h.html#a0cb2748aa4dce6804d166a74383dd0cc',1,'bufferevent.h']]], + ['bufferevent_5frate_5flimit_5fgroup_5fset_5fcfg_784',['bufferevent_rate_limit_group_set_cfg',['../bufferevent_8h.html#a23bbafd1ee4e0a12cc2253b46458b06d',1,'bufferevent.h']]], + ['bufferevent_5frate_5flimit_5fgroup_5fset_5fmin_5fshare_785',['bufferevent_rate_limit_group_set_min_share',['../bufferevent_8h.html#a43c18046f0accddec559dba1a67d933d',1,'bufferevent.h']]], + ['bufferevent_5fread_786',['bufferevent_read',['../bufferevent_8h.html#a9e36c54f6b0ea02183998d5a604a00ef',1,'bufferevent.h']]], + ['bufferevent_5fread_5fbuffer_787',['bufferevent_read_buffer',['../bufferevent_8h.html#abcab28c476ef6bde1faf233bfd18285c',1,'bufferevent.h']]], + ['bufferevent_5fremove_5ffrom_5frate_5flimit_5fgroup_788',['bufferevent_remove_from_rate_limit_group',['../bufferevent_8h.html#a37762f5e89204ca8a8184b59414e6f46',1,'bufferevent.h']]], + ['bufferevent_5freplacefd_789',['bufferevent_replacefd',['../bufferevent_8h.html#a955c7d37679173c593ee6ed0a7adeeea',1,'bufferevent.h']]], + ['bufferevent_5fset_5fmax_5fsingle_5fread_790',['bufferevent_set_max_single_read',['../bufferevent_8h.html#ac450d06c482f354510d5d0abe4577278',1,'bufferevent.h']]], + ['bufferevent_5fset_5fmax_5fsingle_5fwrite_791',['bufferevent_set_max_single_write',['../bufferevent_8h.html#a8e5f4f727f9e0b74f8232c3d758b607e',1,'bufferevent.h']]], + ['bufferevent_5fset_5frate_5flimit_792',['bufferevent_set_rate_limit',['../bufferevent_8h.html#ad5381c899547a19ee6a93df63b064ad4',1,'bufferevent.h']]], + ['bufferevent_5fset_5ftimeouts_793',['bufferevent_set_timeouts',['../bufferevent_8h.html#aec0864607ef2bf9816cda06c1c4ab83f',1,'bufferevent.h']]], + ['bufferevent_5fsetcb_794',['bufferevent_setcb',['../bufferevent_8h.html#a031df52978c5237b70fb8ae7df572c97',1,'bufferevent.h']]], + ['bufferevent_5fsetfd_795',['bufferevent_setfd',['../bufferevent_8h.html#a66cdf9296b02676aacf98a6277a7e756',1,'bufferevent.h']]], + ['bufferevent_5fsettimeout_796',['bufferevent_settimeout',['../bufferevent__compat_8h.html#a5e48aa6b7217987a51cc02b56e0f7297',1,'bufferevent_compat.h']]], + ['bufferevent_5fsetwatermark_797',['bufferevent_setwatermark',['../bufferevent_8h.html#ae23c61cdaf3f74d0fea96d41aa6f7783',1,'bufferevent.h']]], + ['bufferevent_5fsocket_5fconnect_798',['bufferevent_socket_connect',['../bufferevent_8h.html#aefc782ac77411bdd712be30d6268af2e',1,'bufferevent.h']]], + ['bufferevent_5fsocket_5fconnect_5fhostname_799',['bufferevent_socket_connect_hostname',['../bufferevent_8h.html#a5c3c313f2ff0d79a1889e508b37d9dbe',1,'bufferevent.h']]], + ['bufferevent_5fsocket_5fconnect_5fhostname_5fhints_800',['bufferevent_socket_connect_hostname_hints',['../bufferevent_8h.html#afd80dc15fef6d1e7a88a0464e72e8acb',1,'bufferevent.h']]], + ['bufferevent_5fsocket_5fget_5fdns_5ferror_801',['bufferevent_socket_get_dns_error',['../bufferevent_8h.html#aa533016e5ffc2ed558a5d85f9fbe2fd5',1,'bufferevent.h']]], + ['bufferevent_5fsocket_5fnew_802',['bufferevent_socket_new',['../bufferevent_8h.html#a71181be5ab504e26f866dd3d91494854',1,'bufferevent.h']]], + ['bufferevent_5fssl_5frenegotiate_803',['bufferevent_ssl_renegotiate',['../bufferevent__ssl_8h.html#a3fd911cdaeaa3974bb4c17ad13f48503',1,'bufferevent_ssl.h']]], + ['bufferevent_5ftrigger_804',['bufferevent_trigger',['../bufferevent_8h.html#ae46282450083187370ba2ea42029d341',1,'bufferevent.h']]], + ['bufferevent_5ftrigger_5fevent_805',['bufferevent_trigger_event',['../bufferevent_8h.html#ae8574fb31c0dc88c158c5324110bcbac',1,'bufferevent.h']]], + ['bufferevent_5funlock_806',['bufferevent_unlock',['../bufferevent_8h.html#a238f9ac0fcd75094f7b7611e7e6649f2',1,'bufferevent.h']]], + ['bufferevent_5fwrite_807',['bufferevent_write',['../bufferevent_8h.html#a7873bee379202ca1913ea365b92d2ed1',1,'bufferevent.h']]], + ['bufferevent_5fwrite_5fbuffer_808',['bufferevent_write_buffer',['../bufferevent_8h.html#ac9b0f97c37f116dcb579e4491dadda1d',1,'bufferevent.h']]] +]; diff --git a/search/functions_1.html b/search/functions_1.html new file mode 100644 index 0000000..0ddac0a --- /dev/null +++ b/search/functions_1.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/functions_1.js b/search/functions_1.js new file mode 100644 index 0000000..d23a94c --- /dev/null +++ b/search/functions_1.js @@ -0,0 +1,384 @@ +var searchData= +[ + ['ev_5ftoken_5fbucket_5fcfg_5ffree_809',['ev_token_bucket_cfg_free',['../bufferevent_8h.html#a7ac436abc86f4071a5c43b29c12dba16',1,'bufferevent.h']]], + ['ev_5ftoken_5fbucket_5fcfg_5fnew_810',['ev_token_bucket_cfg_new',['../bufferevent_8h.html#a2dc87d1bae8855f9efca12edea9e3b84',1,'bufferevent.h']]], + ['evbuffer_5fadd_811',['evbuffer_add',['../buffer_8h.html#a8abedc30187fe00d86b7b1cc4d3ce643',1,'buffer.h']]], + ['evbuffer_5fadd_5fbuffer_812',['evbuffer_add_buffer',['../buffer_8h.html#af95837e510c03d5e5fcf9c05db019f14',1,'buffer.h']]], + ['evbuffer_5fadd_5fbuffer_5freference_813',['evbuffer_add_buffer_reference',['../buffer_8h.html#a60aa7eb8766fcbeadc17f722a095c624',1,'buffer.h']]], + ['evbuffer_5fadd_5fcb_814',['evbuffer_add_cb',['../buffer_8h.html#a3885fb5ca54eff0778916183f58a9c25',1,'buffer.h']]], + ['evbuffer_5fadd_5ffile_815',['evbuffer_add_file',['../buffer_8h.html#a601996b1fc1f5c165dc62b89acbd069e',1,'buffer.h']]], + ['evbuffer_5fadd_5ffile_5fsegment_816',['evbuffer_add_file_segment',['../buffer_8h.html#a300f9e6d1db3d6f834284c47fc77e1bc',1,'buffer.h']]], + ['evbuffer_5fadd_5fiovec_817',['evbuffer_add_iovec',['../buffer_8h.html#acd12f9e37353ed2b72d6a1cc2064f998',1,'buffer.h']]], + ['evbuffer_5fadd_5fprintf_818',['evbuffer_add_printf',['../buffer_8h.html#abd34b7bd9e698e15f868bf05fa6abc59',1,'buffer.h']]], + ['evbuffer_5fadd_5freference_819',['evbuffer_add_reference',['../buffer_8h.html#a35e99b5370b59b0c0b391ada3a59befe',1,'buffer.h']]], + ['evbuffer_5fadd_5freference_5fwith_5foffset_820',['evbuffer_add_reference_with_offset',['../buffer_8h.html#abf2b931577be86b72418252207ca221b',1,'buffer.h']]], + ['evbuffer_5fadd_5fvprintf_821',['evbuffer_add_vprintf',['../buffer_8h.html#abb5d7931c7be6b2bde597cbb9b6dc72d',1,'buffer.h']]], + ['evbuffer_5fcb_5fclear_5fflags_822',['evbuffer_cb_clear_flags',['../buffer_8h.html#ae384dcadf478c364d005f57be899b21b',1,'buffer.h']]], + ['evbuffer_5fcb_5fset_5fflags_823',['evbuffer_cb_set_flags',['../buffer_8h.html#af5fa49788238edd197d3f242878576f3',1,'buffer.h']]], + ['evbuffer_5fclear_5fflags_824',['evbuffer_clear_flags',['../buffer_8h.html#a256652150a256e8e09d9c1ca5ad24881',1,'buffer.h']]], + ['evbuffer_5fcommit_5fspace_825',['evbuffer_commit_space',['../buffer_8h.html#ab9cd3918d883d90acda2d9a9c530bf84',1,'buffer.h']]], + ['evbuffer_5fcopyout_826',['evbuffer_copyout',['../buffer_8h.html#afdc539f4c3dbae7c671a4a857833a3d5',1,'buffer.h']]], + ['evbuffer_5fcopyout_5ffrom_827',['evbuffer_copyout_from',['../buffer_8h.html#a3cf708e4e9384d70a5d2fd7158fd94cb',1,'buffer.h']]], + ['evbuffer_5fdefer_5fcallbacks_828',['evbuffer_defer_callbacks',['../buffer_8h.html#a97293fcb83dd9d073af4cf370b9d094d',1,'buffer.h']]], + ['evbuffer_5fdrain_829',['evbuffer_drain',['../buffer_8h.html#a08599d8165ea785b9b6a4ddf44ec24f7',1,'buffer.h']]], + ['evbuffer_5fenable_5flocking_830',['evbuffer_enable_locking',['../buffer_8h.html#af68e729ac81d8a1c02b716653af45ded',1,'buffer.h']]], + ['evbuffer_5fexpand_831',['evbuffer_expand',['../buffer_8h.html#a8d4919171c71fc41515c0373e8264527',1,'buffer.h']]], + ['evbuffer_5ffile_5fsegment_5fadd_5fcleanup_5fcb_832',['evbuffer_file_segment_add_cleanup_cb',['../buffer_8h.html#ab0767fa82fecc6255129928b02ecc1d6',1,'buffer.h']]], + ['evbuffer_5ffile_5fsegment_5ffree_833',['evbuffer_file_segment_free',['../buffer_8h.html#a0b82a4d7dd6853882ed5a87559edbad1',1,'buffer.h']]], + ['evbuffer_5ffile_5fsegment_5fnew_834',['evbuffer_file_segment_new',['../buffer_8h.html#aa52264c1529ee486400bbad0bf9f4271',1,'buffer.h']]], + ['evbuffer_5ffind_835',['evbuffer_find',['../buffer__compat_8h.html#af44d0b893f624295a4eeb5da8bbca100',1,'buffer_compat.h']]], + ['evbuffer_5ffree_836',['evbuffer_free',['../buffer_8h.html#ab255015b91f7b43ba09d8f9da54ed865',1,'buffer.h']]], + ['evbuffer_5ffreeze_837',['evbuffer_freeze',['../buffer_8h.html#a2b32b99d60603aac9bbadb9e463a6bc1',1,'buffer.h']]], + ['evbuffer_5fget_5fcontiguous_5fspace_838',['evbuffer_get_contiguous_space',['../buffer_8h.html#a3f0b89841da394aebf6dfd620dd787d1',1,'buffer.h']]], + ['evbuffer_5fget_5flength_839',['evbuffer_get_length',['../buffer_8h.html#a808db707e84e20229b2aafdcaba6c708',1,'buffer.h']]], + ['evbuffer_5fget_5fmax_5fread_840',['evbuffer_get_max_read',['../buffer_8h.html#a94fa0f064f3a5d273a362762eb6b1410',1,'buffer.h']]], + ['evbuffer_5flock_841',['evbuffer_lock',['../buffer_8h.html#afe1a938f5728ca0770419119cd90359d',1,'buffer.h']]], + ['evbuffer_5fnew_842',['evbuffer_new',['../buffer_8h.html#a7a853e8ebc063d32cd11f1554c77615d',1,'buffer.h']]], + ['evbuffer_5fpeek_843',['evbuffer_peek',['../buffer_8h.html#aad7c208f2afca3e7e46a1a95fb79eec1',1,'buffer.h']]], + ['evbuffer_5fprepend_844',['evbuffer_prepend',['../buffer_8h.html#a1112b433d2554b8b80b814feb37fdc95',1,'buffer.h']]], + ['evbuffer_5fprepend_5fbuffer_845',['evbuffer_prepend_buffer',['../buffer_8h.html#a1d26aa5a48b549d702bc5175b0444d33',1,'buffer.h']]], + ['evbuffer_5fptr_5fset_846',['evbuffer_ptr_set',['../buffer_8h.html#a22137a538067a8450d52af0e6601ca49',1,'buffer.h']]], + ['evbuffer_5fpullup_847',['evbuffer_pullup',['../buffer_8h.html#acd73ca99c3a793ea26c43307b9723bd6',1,'buffer.h']]], + ['evbuffer_5fread_848',['evbuffer_read',['../buffer_8h.html#a2664ab1d68d21acf3185a01c85cf29af',1,'buffer.h']]], + ['evbuffer_5freadline_849',['evbuffer_readline',['../buffer__compat_8h.html#a4fea308404ec34c5daeec61f5e05bc08',1,'buffer_compat.h']]], + ['evbuffer_5freadln_850',['evbuffer_readln',['../buffer_8h.html#a8bcc94903283574331994c9364be3d7b',1,'buffer.h']]], + ['evbuffer_5fremove_851',['evbuffer_remove',['../buffer_8h.html#aa53da314581de5e13bb0d92aa05e2301',1,'buffer.h']]], + ['evbuffer_5fremove_5fbuffer_852',['evbuffer_remove_buffer',['../buffer_8h.html#a863342bdbdb4f91d0415ae29ef25494b',1,'buffer.h']]], + ['evbuffer_5fremove_5fcb_853',['evbuffer_remove_cb',['../buffer_8h.html#abc4912118c60071766c6a9d343186137',1,'buffer.h']]], + ['evbuffer_5fremove_5fcb_5fentry_854',['evbuffer_remove_cb_entry',['../buffer_8h.html#ade150950a995af06cd3c6321f71eb3c1',1,'buffer.h']]], + ['evbuffer_5freserve_5fspace_855',['evbuffer_reserve_space',['../buffer_8h.html#a18e9703ca1a062669412684543f7f537',1,'buffer.h']]], + ['evbuffer_5fsearch_856',['evbuffer_search',['../buffer_8h.html#a06e9211319a369ffb072d4f4a83b48e7',1,'buffer.h']]], + ['evbuffer_5fsearch_5feol_857',['evbuffer_search_eol',['../buffer_8h.html#a28e2fa6852a5a49285933b1c95c7465f',1,'buffer.h']]], + ['evbuffer_5fsearch_5frange_858',['evbuffer_search_range',['../buffer_8h.html#a3b1e093af8bc1a86963729ec1290de8f',1,'buffer.h']]], + ['evbuffer_5fset_5fflags_859',['evbuffer_set_flags',['../buffer_8h.html#a8649a5edeb1fcf06490d4d35ac76c13a',1,'buffer.h']]], + ['evbuffer_5fset_5fmax_5fread_860',['evbuffer_set_max_read',['../buffer_8h.html#ac5441fc0ce576ad997bf1a869f8c4ba9',1,'buffer.h']]], + ['evbuffer_5fsetcb_861',['evbuffer_setcb',['../buffer__compat_8h.html#aaae25109e21cb9f7417922592ed495a4',1,'buffer_compat.h']]], + ['evbuffer_5funfreeze_862',['evbuffer_unfreeze',['../buffer_8h.html#af36bd50996e2db4445282e6a194328a2',1,'buffer.h']]], + ['evbuffer_5funlock_863',['evbuffer_unlock',['../buffer_8h.html#a25e8be33a5d5cb2684594b9b3cb6c7c9',1,'buffer.h']]], + ['evbuffer_5fwrite_864',['evbuffer_write',['../buffer_8h.html#a7d9605737ec9ba876f0ba49e937b9bd7',1,'buffer.h']]], + ['evbuffer_5fwrite_5fatmost_865',['evbuffer_write_atmost',['../buffer_8h.html#a69f9cbac8f6dbd2d8f3c2706fbbdc7cd',1,'buffer.h']]], + ['evconnlistener_5fdisable_866',['evconnlistener_disable',['../listener_8h.html#a1f772caf7e2f01276ec33641eb32418c',1,'listener.h']]], + ['evconnlistener_5fenable_867',['evconnlistener_enable',['../listener_8h.html#a890717d86a18e2bd82655fd342b1973f',1,'listener.h']]], + ['evconnlistener_5ffree_868',['evconnlistener_free',['../listener_8h.html#a0f7f3d276f08669c2a9b1817941aa68f',1,'listener.h']]], + ['evconnlistener_5fget_5fbase_869',['evconnlistener_get_base',['../listener_8h.html#ab3492fa1741d2b50e151505c0582334d',1,'listener.h']]], + ['evconnlistener_5fget_5ffd_870',['evconnlistener_get_fd',['../listener_8h.html#a56e8de702931f3960edd84617e6c2fb6',1,'listener.h']]], + ['evconnlistener_5fnew_871',['evconnlistener_new',['../listener_8h.html#aa07ae1878cf56d58579b025dd1620c91',1,'listener.h']]], + ['evconnlistener_5fnew_5fbind_872',['evconnlistener_new_bind',['../listener_8h.html#a29076ec56e051fb75aa48f30cf9111ee',1,'listener.h']]], + ['evconnlistener_5fset_5fcb_873',['evconnlistener_set_cb',['../listener_8h.html#abf8c1793319829ff9c6d8ce4fea6b342',1,'listener.h']]], + ['evconnlistener_5fset_5ferror_5fcb_874',['evconnlistener_set_error_cb',['../listener_8h.html#a328c8f6b2c2b3c87507ca6a4d5790da1',1,'listener.h']]], + ['evdns_5fadd_5fserver_5fport_875',['evdns_add_server_port',['../dns__compat_8h.html#a0def8fe56b2dee569e32ed685f4c22d8',1,'dns_compat.h']]], + ['evdns_5fadd_5fserver_5fport_5fwith_5fbase_876',['evdns_add_server_port_with_base',['../dns_8h.html#ad6a51e72173fcb3df380a49e8589635b',1,'dns.h']]], + ['evdns_5fadd_5fserver_5fport_5fwith_5flistener_877',['evdns_add_server_port_with_listener',['../dns_8h.html#ac44ddac0711712a5e3f7ec041c8d2478',1,'dns.h']]], + ['evdns_5fbase_5fclear_5fhost_5faddresses_878',['evdns_base_clear_host_addresses',['../dns_8h.html#a1875001046dd6cbff5f2139590221ddf',1,'dns.h']]], + ['evdns_5fbase_5fclear_5fnameservers_5fand_5fsuspend_879',['evdns_base_clear_nameservers_and_suspend',['../dns_8h.html#af942ce8b6a65052f4b6def91a3390a61',1,'dns.h']]], + ['evdns_5fbase_5fconfig_5fwindows_5fnameservers_880',['evdns_base_config_windows_nameservers',['../dns_8h.html#ac287c8b638a248719a00b0324579b728',1,'dns.h']]], + ['evdns_5fbase_5fcount_5fnameservers_881',['evdns_base_count_nameservers',['../dns_8h.html#a6811354521b4fe8df4c724d6cb9fb102',1,'dns.h']]], + ['evdns_5fbase_5ffree_882',['evdns_base_free',['../dns_8h.html#ab221bbadb18451c9007e8dc98bc97786',1,'dns.h']]], + ['evdns_5fbase_5fget_5fnameserver_5faddr_883',['evdns_base_get_nameserver_addr',['../dns_8h.html#a1545f7930f228018a06476a7236bfe0e',1,'dns.h']]], + ['evdns_5fbase_5fget_5fnameserver_5ffd_884',['evdns_base_get_nameserver_fd',['../dns_8h.html#a954ffdf37038dba334543f6013d6a87f',1,'dns.h']]], + ['evdns_5fbase_5fload_5fhosts_885',['evdns_base_load_hosts',['../dns_8h.html#a5092d38082851904e37d6b80c3475714',1,'dns.h']]], + ['evdns_5fbase_5fnameserver_5fadd_886',['evdns_base_nameserver_add',['../dns_8h.html#a53a242ec2ab15eef9e49e4286153d55a',1,'dns.h']]], + ['evdns_5fbase_5fnameserver_5fip_5fadd_887',['evdns_base_nameserver_ip_add',['../dns_8h.html#a0a5f8e71a80a41d10e386f8cac816238',1,'dns.h']]], + ['evdns_5fbase_5fnameserver_5fsockaddr_5fadd_888',['evdns_base_nameserver_sockaddr_add',['../dns_8h.html#ac8feac209d81aea2654809727ee7ada7',1,'dns.h']]], + ['evdns_5fbase_5fnew_889',['evdns_base_new',['../dns_8h.html#afdcc359c412591d174f4d965afd18513',1,'dns.h']]], + ['evdns_5fbase_5fresolv_5fconf_5fparse_890',['evdns_base_resolv_conf_parse',['../dns_8h.html#a7e3a053e25ae7c045944a5db0947babb',1,'dns.h']]], + ['evdns_5fbase_5fresolve_5fipv4_891',['evdns_base_resolve_ipv4',['../dns_8h.html#a4f8b11705fa285dffa661c7f55f86693',1,'dns.h']]], + ['evdns_5fbase_5fresolve_5fipv6_892',['evdns_base_resolve_ipv6',['../dns_8h.html#a646ca1414b09b9fec7763bf8aca05e74',1,'dns.h']]], + ['evdns_5fbase_5fresolve_5freverse_893',['evdns_base_resolve_reverse',['../dns_8h.html#a1f9cbcd4c017180e7d302056b3d5bbd4',1,'dns.h']]], + ['evdns_5fbase_5fresolve_5freverse_5fipv6_894',['evdns_base_resolve_reverse_ipv6',['../dns_8h.html#a55843d1e90512bfbe8499d52642240cd',1,'dns.h']]], + ['evdns_5fbase_5fresume_895',['evdns_base_resume',['../dns_8h.html#a3ef3a20dd645e02d6dd5d3766ced9ce7',1,'dns.h']]], + ['evdns_5fbase_5fsearch_5fadd_896',['evdns_base_search_add',['../dns_8h.html#a8044de93700190d5ca6a6a0becdc4f6e',1,'dns.h']]], + ['evdns_5fbase_5fsearch_5fclear_897',['evdns_base_search_clear',['../dns_8h.html#a9211bdca966e8f4ce3270b29c1d72122',1,'dns.h']]], + ['evdns_5fbase_5fsearch_5fndots_5fset_898',['evdns_base_search_ndots_set',['../dns_8h.html#ae858583b1c9fdd1f7c99330bcdd68ba6',1,'dns.h']]], + ['evdns_5fbase_5fset_5foption_899',['evdns_base_set_option',['../dns_8h.html#a791b6fdc9f41bd62414574d85ae18cc8',1,'dns.h']]], + ['evdns_5fcache_5flookup_900',['evdns_cache_lookup',['../dns_8h.html#abdb3c829da1d539ecdf92ae47f8f1c03',1,'dns.h']]], + ['evdns_5fcache_5fwrite_901',['evdns_cache_write',['../dns_8h.html#ac969fd31d17e59ad072be79a591d5224',1,'dns.h']]], + ['evdns_5fcancel_5frequest_902',['evdns_cancel_request',['../dns_8h.html#a062bdd01f7243b3c8509d93c45a802ef',1,'dns.h']]], + ['evdns_5fclear_5fnameservers_5fand_5fsuspend_903',['evdns_clear_nameservers_and_suspend',['../dns__compat_8h.html#a6c7b5be4d918882465ef75f4a1478124',1,'dns_compat.h']]], + ['evdns_5fclose_5fserver_5fport_904',['evdns_close_server_port',['../dns_8h.html#abbd56ab78c400f46498515330343c66a',1,'dns.h']]], + ['evdns_5fcount_5fnameservers_905',['evdns_count_nameservers',['../dns__compat_8h.html#a1d07cab0ca89d14da595552f05338e0b',1,'dns_compat.h']]], + ['evdns_5ferr_5fto_5fstring_906',['evdns_err_to_string',['../dns_8h.html#a24bb4cf48915f73e4e9c6d4b6216466b',1,'dns.h']]], + ['evdns_5fget_5fglobal_5fbase_907',['evdns_get_global_base',['../dns__compat_8h.html#ae54990e958bb398b120a90d47796a2d8',1,'dns_compat.h']]], + ['evdns_5fgetaddrinfo_908',['evdns_getaddrinfo',['../dns_8h.html#a28a4c5e6e22bcf92f8c229461023f914',1,'dns.h']]], + ['evdns_5finit_909',['evdns_init',['../dns__compat_8h.html#ad1b7dd2a9e58135f17a383331233b207',1,'dns_compat.h']]], + ['evdns_5fnameserver_5fadd_910',['evdns_nameserver_add',['../dns__compat_8h.html#ae50b63ae4a40a756bc51c0aebe2ac23e',1,'dns_compat.h']]], + ['evdns_5fnameserver_5fip_5fadd_911',['evdns_nameserver_ip_add',['../dns__compat_8h.html#aa40d812a3dc909b8728cc3647ef1247a',1,'dns_compat.h']]], + ['evdns_5fresolv_5fconf_5fparse_912',['evdns_resolv_conf_parse',['../dns__compat_8h.html#a4dd30bf34468410eb96757007523eb34',1,'dns_compat.h']]], + ['evdns_5fresolve_5fipv4_913',['evdns_resolve_ipv4',['../dns__compat_8h.html#a438a9e699ff81b4a22cc072ad3c8e1c2',1,'dns_compat.h']]], + ['evdns_5fresolve_5fipv6_914',['evdns_resolve_ipv6',['../dns__compat_8h.html#a295f72a34e9744a7026261c078c03f13',1,'dns_compat.h']]], + ['evdns_5fresolve_5freverse_915',['evdns_resolve_reverse',['../dns__compat_8h.html#a30c78f62647609846c2bb3222ebce87e',1,'dns_compat.h']]], + ['evdns_5fresolve_5freverse_5fipv6_916',['evdns_resolve_reverse_ipv6',['../dns__compat_8h.html#a45bf87a8a77c7fba752836aab6a5a9cb',1,'dns_compat.h']]], + ['evdns_5fresume_917',['evdns_resume',['../dns__compat_8h.html#aa34fd9ec83c05361a23d484aa0debe7a',1,'dns_compat.h']]], + ['evdns_5fsearch_5fadd_918',['evdns_search_add',['../dns__compat_8h.html#ad43d4dab51d417dfd21299b615e64e71',1,'dns_compat.h']]], + ['evdns_5fsearch_5fclear_919',['evdns_search_clear',['../dns__compat_8h.html#a717e59ca40403c0cd86091748bee5405',1,'dns_compat.h']]], + ['evdns_5fsearch_5fndots_5fset_920',['evdns_search_ndots_set',['../dns__compat_8h.html#a0b9532165f3d175cd9bfa3cc64c397c2',1,'dns_compat.h']]], + ['evdns_5fserver_5fport_5fset_5foption_921',['evdns_server_port_set_option',['../dns_8h.html#afdb5e0e7000a17810e762d40ecb8eda2',1,'dns.h']]], + ['evdns_5fserver_5frequest_5fdrop_922',['evdns_server_request_drop',['../dns_8h.html#a1291ec11bf79809c4ae1b113bb0160e9',1,'dns.h']]], + ['evdns_5fserver_5frequest_5fget_5frequesting_5faddr_923',['evdns_server_request_get_requesting_addr',['../dns_8h.html#a078ce45f71d886514ece8688e19ead19',1,'dns.h']]], + ['evdns_5fserver_5frequest_5frespond_924',['evdns_server_request_respond',['../dns_8h.html#a606b067e5cd3fee40b527b3cb4ec2d72',1,'dns.h']]], + ['evdns_5fserver_5frequest_5fset_5fflags_925',['evdns_server_request_set_flags',['../dns_8h.html#a849622fc8fee97302a6a0a34e7e6feb8',1,'dns.h']]], + ['evdns_5fset_5flog_5ffn_926',['evdns_set_log_fn',['../dns_8h.html#af2ba90756cecdc246711879462a20b51',1,'dns.h']]], + ['evdns_5fset_5foption_927',['evdns_set_option',['../dns__compat_8h.html#a2c7b199ba05d398d9901fed62c9467e5',1,'dns_compat.h']]], + ['evdns_5fshutdown_928',['evdns_shutdown',['../dns__compat_8h.html#a4b3aece85850a3963493ddba2d778451',1,'dns_compat.h']]], + ['event_5factive_929',['event_active',['../event_8h.html#a31d9440cf2b7010e32a05a2142a91525',1,'event.h']]], + ['event_5fadd_930',['event_add',['../event_8h.html#ab0c85ebe9cf057be1aa17724c701b0c8',1,'event.h']]], + ['event_5fassign_931',['event_assign',['../event_8h.html#a3e49a8172e00ae82959dfe64684eda11',1,'event.h']]], + ['event_5fbase_5factive_5fby_5ffd_932',['event_base_active_by_fd',['../event_8h.html#a092013616b4636c74e889b0b015cb75e',1,'event.h']]], + ['event_5fbase_5factive_5fby_5fsignal_933',['event_base_active_by_signal',['../event_8h.html#a4bca4d24a15bef084bf066faca8a43d2',1,'event.h']]], + ['event_5fbase_5fdispatch_934',['event_base_dispatch',['../event_8h.html#a19d60cb72a1af398247f40e92cf07056',1,'event.h']]], + ['event_5fbase_5fdump_5fevents_935',['event_base_dump_events',['../event_8h.html#ae3ed8b33f9e0d797615c2f86ff30f5fb',1,'event.h']]], + ['event_5fbase_5fforeach_5fevent_936',['event_base_foreach_event',['../event_8h.html#a7d5c38711c6a72545b939cc375468f79',1,'event.h']]], + ['event_5fbase_5ffree_937',['event_base_free',['../event_8h.html#a91f9deb12c37f2ff586e65e8b9a46641',1,'event.h']]], + ['event_5fbase_5ffree_5fnofinalize_938',['event_base_free_nofinalize',['../event_8h.html#a385fb6f81ab73f9c95d77b7179f780e0',1,'event.h']]], + ['event_5fbase_5fget_5ffeatures_939',['event_base_get_features',['../event_8h.html#aced890aa77dac1669325f74a27584f03',1,'event.h']]], + ['event_5fbase_5fget_5fmax_5fevents_940',['event_base_get_max_events',['../event_8h.html#a9cf1a991dcad465adf4330a79576b148',1,'event.h']]], + ['event_5fbase_5fget_5fmethod_941',['event_base_get_method',['../event_8h.html#ae0910900c306cef32e2623272c7b7cb0',1,'event.h']]], + ['event_5fbase_5fget_5fnpriorities_942',['event_base_get_npriorities',['../event_8h.html#a3c91bec6e27bf2e26e8ecbb286787cc5',1,'event.h']]], + ['event_5fbase_5fget_5fnum_5fevents_943',['event_base_get_num_events',['../event_8h.html#a3dd8aaea50a18e1b300ae6a138132743',1,'event.h']]], + ['event_5fbase_5fget_5frunning_5fevent_944',['event_base_get_running_event',['../event_8h.html#a23276914af0b2527951cc7c47b46f00b',1,'event.h']]], + ['event_5fbase_5fget_5fsignal_5fmethod_945',['event_base_get_signal_method',['../event_8h.html#a138b72aa85ec5c344714867204ed3d3d',1,'event.h']]], + ['event_5fbase_5fgettimeofday_5fcached_946',['event_base_gettimeofday_cached',['../event_8h.html#a0fbd35d624f1c865329a2a388afba3fd',1,'event.h']]], + ['event_5fbase_5fgot_5fbreak_947',['event_base_got_break',['../event_8h.html#ae3853087c016ff8e877d914b1bda8f90',1,'event.h']]], + ['event_5fbase_5fgot_5fexit_948',['event_base_got_exit',['../event_8h.html#a654b3b2c5923a9c0620907701383f6dd',1,'event.h']]], + ['event_5fbase_5finit_5fcommon_5ftimeout_949',['event_base_init_common_timeout',['../event_8h.html#a46b388babfda66dcb897c9e4dbd233b1',1,'event.h']]], + ['event_5fbase_5floop_950',['event_base_loop',['../event_8h.html#acd7da32086d1e37008e7c76c9ea54fc4',1,'event.h']]], + ['event_5fbase_5floopbreak_951',['event_base_loopbreak',['../event_8h.html#a28e0be91488e8a0ed57a582f3343eaf6',1,'event.h']]], + ['event_5fbase_5floopcontinue_952',['event_base_loopcontinue',['../event_8h.html#a34ce349afe4a37119e1ac50710642ccb',1,'event.h']]], + ['event_5fbase_5floopexit_953',['event_base_loopexit',['../event_8h.html#a67ba4db4b6e7467b3412219530603e60',1,'event.h']]], + ['event_5fbase_5fnew_954',['event_base_new',['../event_8h.html#af34c025430d445427a2a5661082405c3',1,'event.h']]], + ['event_5fbase_5fnew_5fwith_5fconfig_955',['event_base_new_with_config',['../event_8h.html#a864798e5b3c6aa8d2f9e9c5035a3e6da',1,'event.h']]], + ['event_5fbase_5fonce_956',['event_base_once',['../event_8h.html#ae4d40e572ad8310897ce06f9fe0f9062',1,'event.h']]], + ['event_5fbase_5fpriority_5finit_957',['event_base_priority_init',['../event_8h.html#a289e44ce22c816060bf7b7bfe38720b9',1,'event.h']]], + ['event_5fbase_5fset_958',['event_base_set',['../event_8h.html#a20fb823ec65b17519ec07aee1a0a22ba',1,'event.h']]], + ['event_5fbase_5fupdate_5fcache_5ftime_959',['event_base_update_cache_time',['../event_8h.html#ae920425b48421c3cb7cb5e0802e4af9d',1,'event.h']]], + ['event_5fconfig_5favoid_5fmethod_960',['event_config_avoid_method',['../event_8h.html#ac5328011d251a7af085fdc19deb748bc',1,'event.h']]], + ['event_5fconfig_5ffree_961',['event_config_free',['../event_8h.html#ad7917192d1f78884de03a8777013fd1c',1,'event.h']]], + ['event_5fconfig_5fnew_962',['event_config_new',['../event_8h.html#a76f3b4191e43c8b4758b99da761c858e',1,'event.h']]], + ['event_5fconfig_5frequire_5ffeatures_963',['event_config_require_features',['../event_8h.html#ab76526f5bcd7b05d63f38fca439d7492',1,'event.h']]], + ['event_5fconfig_5fset_5fflag_964',['event_config_set_flag',['../event_8h.html#ae9e42b61a7e8465b7c897432c4ddcabd',1,'event.h']]], + ['event_5fconfig_5fset_5fmax_5fdispatch_5finterval_965',['event_config_set_max_dispatch_interval',['../event_8h.html#aeb08f9ff880ff8a07eb623124f48f979',1,'event.h']]], + ['event_5fconfig_5fset_5fnum_5fcpus_5fhint_966',['event_config_set_num_cpus_hint',['../event_8h.html#a472425045a342e48429e408eaeb81d18',1,'event.h']]], + ['event_5fdebug_5funassign_967',['event_debug_unassign',['../event_8h.html#a1347923dccea548c036ccc7614c5b595',1,'event.h']]], + ['event_5fdel_968',['event_del',['../event_8h.html#a2ffc10a652c67bea16b0a71f7d5a44dc',1,'event.h']]], + ['event_5fdel_5fblock_969',['event_del_block',['../event_8h.html#a8236f5e7e9d845cd127e768b2747df9c',1,'event.h']]], + ['event_5fdel_5fnoblock_970',['event_del_noblock',['../event_8h.html#a54ae25b313b15e6038b5dd87c740e39e',1,'event.h']]], + ['event_5fdispatch_971',['event_dispatch',['../event__compat_8h.html#af4db42ebbe9e6ee92128e99523e5987f',1,'event_compat.h']]], + ['event_5fenable_5fdebug_5flogging_972',['event_enable_debug_logging',['../event_8h.html#abce01eafdfef974a80fdf9a507f5eca9',1,'event.h']]], + ['event_5fenable_5fdebug_5fmode_973',['event_enable_debug_mode',['../event_8h.html#a37441a3defac55b5d2513521964b2af5',1,'event.h']]], + ['event_5ffree_974',['event_free',['../event_8h.html#a1f326019b65d319b2221b7e57d56c273',1,'event.h']]], + ['event_5fget_5fassignment_975',['event_get_assignment',['../event_8h.html#a6ddcda6db7bd3fc1e0f635d60e145a03',1,'event.h']]], + ['event_5fget_5fbase_976',['event_get_base',['../event_8h.html#ab90af034dd2638511f483bd25effdc77',1,'event.h']]], + ['event_5fget_5fcallback_977',['event_get_callback',['../event_8h.html#a6e325a315660638135385dc3b608bf85',1,'event.h']]], + ['event_5fget_5fcallback_5farg_978',['event_get_callback_arg',['../event_8h.html#ad868b16c4dc7450e49ba277b9ee7b467',1,'event.h']]], + ['event_5fget_5fevents_979',['event_get_events',['../event_8h.html#a70989121937ecb71358a2d76be772d51',1,'event.h']]], + ['event_5fget_5ffd_980',['event_get_fd',['../event_8h.html#a4f63589ebe3e0d4c9e20447f96d343b2',1,'event.h']]], + ['event_5fget_5fmethod_981',['event_get_method',['../event__compat_8h.html#a756cb3d9a3671a5a03387a2f18ff83e8',1,'event_compat.h']]], + ['event_5fget_5fpriority_982',['event_get_priority',['../event_8h.html#abbc9ca70c2b59b3c1b5767b7675920c3',1,'event.h']]], + ['event_5fget_5fstruct_5fevent_5fsize_983',['event_get_struct_event_size',['../event_8h.html#a0f93db0db7e74f9ae173e1766415dd56',1,'event.h']]], + ['event_5fget_5fsupported_5fmethods_984',['event_get_supported_methods',['../event_8h.html#a7abb8da4e334086319949997fd51c799',1,'event.h']]], + ['event_5fget_5fversion_985',['event_get_version',['../event_8h.html#a328e99de6281ce1645935835e44341b6',1,'event.h']]], + ['event_5fget_5fversion_5fnumber_986',['event_get_version_number',['../event_8h.html#a578ddddcc39d197630e7909b7da443e3',1,'event.h']]], + ['event_5fgettime_5fmonotonic_987',['event_gettime_monotonic',['../event_8h.html#a0c624a8830f69b32ee11faabc8ebb99a',1,'event.h']]], + ['event_5finit_988',['event_init',['../event__compat_8h.html#aa72d84e78eb6f08dc580e6245c087cb6',1,'event_compat.h']]], + ['event_5finitialized_989',['event_initialized',['../event_8h.html#a85b94b111b8aa7fb480fc2f9da7f8e18',1,'event.h']]], + ['event_5floop_990',['event_loop',['../event__compat_8h.html#a3d6542d4518f6873ef9d308e3ee525e1',1,'event_compat.h']]], + ['event_5floopbreak_991',['event_loopbreak',['../event__compat_8h.html#a497e5e360112dcbdc8409ecb45c2c565',1,'event_compat.h']]], + ['event_5floopexit_992',['event_loopexit',['../event__compat_8h.html#a88b7e5bb1e7bd5e617167ed6192fdd66',1,'event_compat.h']]], + ['event_5fnew_993',['event_new',['../event_8h.html#a6cd300e5cd15601c5e4570b221b20397',1,'event.h']]], + ['event_5fonce_994',['event_once',['../event__compat_8h.html#aa7139d18495e80b2e31961c1c553d45e',1,'event_compat.h']]], + ['event_5fpending_995',['event_pending',['../event_8h.html#a9b1687396305898af018c74e63486eb5',1,'event.h']]], + ['event_5fpriority_5finit_996',['event_priority_init',['../event__compat_8h.html#ade115d1b3302c33a6308c50964b6304e',1,'event_compat.h']]], + ['event_5fpriority_5fset_997',['event_priority_set',['../event_8h.html#a11a800dce1fe61de5e2506aaf603c47f',1,'event.h']]], + ['event_5freinit_998',['event_reinit',['../event_8h.html#a7f05aabb4fbcd2ba676bb6ba92f21630',1,'event.h']]], + ['event_5fremove_5ftimer_999',['event_remove_timer',['../event_8h.html#a6d3aae1a8b2c0002e5744fb54ba4fe64',1,'event.h']]], + ['event_5fself_5fcbarg_1000',['event_self_cbarg',['../event_8h.html#aaf0b6ecbbc95137d7a6621f46670acad',1,'event.h']]], + ['event_5fset_1001',['event_set',['../event__compat_8h.html#af06653a20ca79b6229adf89630d20916',1,'event_compat.h']]], + ['event_5fset_5ffatal_5fcallback_1002',['event_set_fatal_callback',['../event_8h.html#a1d0efefe738406049a7bd71e2e59ccfb',1,'event.h']]], + ['event_5fset_5flog_5fcallback_1003',['event_set_log_callback',['../event_8h.html#a2ec6be5aff4af06b22da20d5ad747ff2',1,'event.h']]], + ['event_5fset_5fmem_5ffunctions_1004',['event_set_mem_functions',['../event_8h.html#a9bb71feea97288bc15d2fba3dccd46bf',1,'event.h']]], + ['evhttp_5faccept_5fsocket_1005',['evhttp_accept_socket',['../http_8h.html#ae8599595a7617e5e3c213e45c10d22a0',1,'http.h']]], + ['evhttp_5faccept_5fsocket_5fwith_5fhandle_1006',['evhttp_accept_socket_with_handle',['../http_8h.html#a68381a3b8dbab796bdcf44ef64a45a73',1,'http.h']]], + ['evhttp_5fadd_5fheader_1007',['evhttp_add_header',['../http_8h.html#a04d806174bb259be406b32669a4ed9cc',1,'http.h']]], + ['evhttp_5fadd_5fserver_5falias_1008',['evhttp_add_server_alias',['../http_8h.html#afa5936add0f808199f617be4aa42bbd7',1,'http.h']]], + ['evhttp_5fadd_5fvirtual_5fhost_1009',['evhttp_add_virtual_host',['../http_8h.html#ad89bdd6053de1ff73fab1b2bb3c3182f',1,'http.h']]], + ['evhttp_5fbind_5flistener_1010',['evhttp_bind_listener',['../http_8h.html#a18d321f8f459b7d6e1826b3e8c53c921',1,'http.h']]], + ['evhttp_5fbind_5fsocket_1011',['evhttp_bind_socket',['../http_8h.html#a3431520b3bd31e957e93e519b2fe56a5',1,'http.h']]], + ['evhttp_5fbind_5fsocket_5fwith_5fhandle_1012',['evhttp_bind_socket_with_handle',['../http_8h.html#a5cb57564c8af123b17e8330d2f104a1d',1,'http.h']]], + ['evhttp_5fbound_5fsocket_5fget_5ffd_1013',['evhttp_bound_socket_get_fd',['../http_8h.html#a586eeb946ec397fec8094c25b7d1d9e4',1,'http.h']]], + ['evhttp_5fbound_5fsocket_5fget_5flistener_1014',['evhttp_bound_socket_get_listener',['../http_8h.html#a4216e1d29237ab9511eaf55433293e8b',1,'http.h']]], + ['evhttp_5fcancel_5frequest_1015',['evhttp_cancel_request',['../http_8h.html#a7758d5808bd2e062d2aa3912ca19d2fd',1,'http.h']]], + ['evhttp_5fclear_5fheaders_1016',['evhttp_clear_headers',['../http_8h.html#ad2399662cdf2e300251d4330c649ac77',1,'http.h']]], + ['evhttp_5fconnection_5fbase_5fbufferevent_5fnew_1017',['evhttp_connection_base_bufferevent_new',['../http_8h.html#ab6a2f82ff7323986705ead089a2d3f58',1,'http.h']]], + ['evhttp_5fconnection_5fbase_5fbufferevent_5funix_5fnew_1018',['evhttp_connection_base_bufferevent_unix_new',['../http_8h.html#aab47f88b970a6a49c0297cd7314f154b',1,'http.h']]], + ['evhttp_5fconnection_5fbase_5fnew_1019',['evhttp_connection_base_new',['../http_8h.html#ae91224cfece07d01a029eb67e9053819',1,'http.h']]], + ['evhttp_5fconnection_5ffree_1020',['evhttp_connection_free',['../http_8h.html#aaf15e06932005ac0bc890b6fe72b19e3',1,'http.h']]], + ['evhttp_5fconnection_5ffree_5fon_5fcompletion_1021',['evhttp_connection_free_on_completion',['../http_8h.html#af33ddcfb93380ab98ac0f75426480824',1,'http.h']]], + ['evhttp_5fconnection_5fget_5faddr_1022',['evhttp_connection_get_addr',['../http_8h.html#ae0097ea31d96c509962b3d3df5ca6958',1,'http.h']]], + ['evhttp_5fconnection_5fget_5fbase_1023',['evhttp_connection_get_base',['../http_8h.html#a605b42ad45d6e804e1a21204b33a2e42',1,'http.h']]], + ['evhttp_5fconnection_5fget_5fbufferevent_1024',['evhttp_connection_get_bufferevent',['../http_8h.html#a04ae09d5ca4ced488a0feb4b5145e95c',1,'http.h']]], + ['evhttp_5fconnection_5fget_5fpeer_1025',['evhttp_connection_get_peer',['../http_8h.html#a8d21ffce46e0207d97d31cfac295e079',1,'http.h']]], + ['evhttp_5fconnection_5fget_5fserver_1026',['evhttp_connection_get_server',['../http_8h.html#a4ab7ae144cf7aac8a512deb0dbaf9ac8',1,'http.h']]], + ['evhttp_5fconnection_5fnew_1027',['evhttp_connection_new',['../http__compat_8h.html#a2e1ca8b7e6d1cc4ed0e0a2e864496e92',1,'http_compat.h']]], + ['evhttp_5fconnection_5fset_5fbase_1028',['evhttp_connection_set_base',['../http__compat_8h.html#a005fff08e18b6ca6689c1226dd9d00fb',1,'http_compat.h']]], + ['evhttp_5fconnection_5fset_5fclosecb_1029',['evhttp_connection_set_closecb',['../http_8h.html#afac5a00d6baf28ecb5c7d52dee757bd1',1,'http.h']]], + ['evhttp_5fconnection_5fset_5fconnect_5ftimeout_5ftv_1030',['evhttp_connection_set_connect_timeout_tv',['../http_8h.html#a3070128a12534b199f5dd24673fad4c4',1,'http.h']]], + ['evhttp_5fconnection_5fset_5fext_5fmethod_5fcmp_1031',['evhttp_connection_set_ext_method_cmp',['../http_8h.html#a8b60b73ced5441bd9a2a4fe114db7db0',1,'http.h']]], + ['evhttp_5fconnection_5fset_5ffamily_1032',['evhttp_connection_set_family',['../http_8h.html#a33eb3d75bb0ae4b4d19678f8f7d97636',1,'http.h']]], + ['evhttp_5fconnection_5fset_5fflags_1033',['evhttp_connection_set_flags',['../http_8h.html#a081b1b41e26d62c5690bdd79109cdcfd',1,'http.h']]], + ['evhttp_5fconnection_5fset_5finitial_5fretry_5ftv_1034',['evhttp_connection_set_initial_retry_tv',['../http_8h.html#a8b33510923ba80494353419fd769729c',1,'http.h']]], + ['evhttp_5fconnection_5fset_5flocal_5faddress_1035',['evhttp_connection_set_local_address',['../http_8h.html#a1125aa44cce8ee1faf9c0bdfc6e815c8',1,'http.h']]], + ['evhttp_5fconnection_5fset_5flocal_5fport_1036',['evhttp_connection_set_local_port',['../http_8h.html#a881ace0b082a725cbd7156e8d701db7a',1,'http.h']]], + ['evhttp_5fconnection_5fset_5fread_5ftimeout_5ftv_1037',['evhttp_connection_set_read_timeout_tv',['../http_8h.html#a8ce5c2c1090309215004e8490014d7a8',1,'http.h']]], + ['evhttp_5fconnection_5fset_5fretries_1038',['evhttp_connection_set_retries',['../http_8h.html#a2d1ec8afb0b84b591e40daa8d25594b9',1,'http.h']]], + ['evhttp_5fconnection_5fset_5ftimeout_1039',['evhttp_connection_set_timeout',['../http_8h.html#af74808e97c298ae690b29d45e8cf2f7b',1,'http.h']]], + ['evhttp_5fconnection_5fset_5ftimeout_5ftv_1040',['evhttp_connection_set_timeout_tv',['../http_8h.html#ab8d3d92102ff797ea2375db5235ebe49',1,'http.h']]], + ['evhttp_5fconnection_5fset_5fwrite_5ftimeout_5ftv_1041',['evhttp_connection_set_write_timeout_tv',['../http_8h.html#a29110fb60e660f33f2d20a964dcb2d37',1,'http.h']]], + ['evhttp_5fdecode_5furi_1042',['evhttp_decode_uri',['../http_8h.html#a6ac6bc2748f226d50367245989e7acd1',1,'http.h']]], + ['evhttp_5fdel_5faccept_5fsocket_1043',['evhttp_del_accept_socket',['../http_8h.html#a565c02c3469c28c1c043cb4a1e3b242c',1,'http.h']]], + ['evhttp_5fdel_5fcb_1044',['evhttp_del_cb',['../http_8h.html#ad7afbe5f5ce3dd8aa00496c859847947',1,'http.h']]], + ['evhttp_5fencode_5furi_1045',['evhttp_encode_uri',['../http_8h.html#a8742ce04eb4951e7af8cb200bc9669ef',1,'http.h']]], + ['evhttp_5ffind_5fheader_1046',['evhttp_find_header',['../http_8h.html#a54b0a309df8639541cfb552ab152e9bd',1,'http.h']]], + ['evhttp_5fforeach_5fbound_5fsocket_1047',['evhttp_foreach_bound_socket',['../http_8h.html#ad15b347cd339ce5b03c806c0f7adaecf',1,'http.h']]], + ['evhttp_5ffree_1048',['evhttp_free',['../http_8h.html#a12b2e61a0088e3707198876ae1e61f3f',1,'http.h']]], + ['evhttp_5fget_5fconnection_5fcount_1049',['evhttp_get_connection_count',['../http_8h.html#acdc4276e80df2a99d64944598fc946ee',1,'http.h']]], + ['evhttp_5fhtmlescape_1050',['evhttp_htmlescape',['../http_8h.html#a28fb801171a5f4a71057629e15c70fb5',1,'http.h']]], + ['evhttp_5fmake_5frequest_1051',['evhttp_make_request',['../http_8h.html#a88c4f63045dc6567f8220d6d37426924',1,'http.h']]], + ['evhttp_5fnew_1052',['evhttp_new',['../http_8h.html#a5baa37a340f5be4b2c6062327e0a84e1',1,'http.h']]], + ['evhttp_5fparse_5fquery_1053',['evhttp_parse_query',['../http_8h.html#ad9b32eed2eb6693eef5694052f2223a8',1,'http.h']]], + ['evhttp_5fparse_5fquery_5fstr_1054',['evhttp_parse_query_str',['../http_8h.html#a9a61f2b2ae4b7b733871f64e89360d75',1,'http.h']]], + ['evhttp_5fparse_5fquery_5fstr_5fflags_1055',['evhttp_parse_query_str_flags',['../http_8h.html#a1a9d2efb83e6599e7e6aa2130018fedc',1,'http.h']]], + ['evhttp_5fremove_5fheader_1056',['evhttp_remove_header',['../http_8h.html#acbdce3871fffa5c0c97c0680eb1ea668',1,'http.h']]], + ['evhttp_5fremove_5fserver_5falias_1057',['evhttp_remove_server_alias',['../http_8h.html#a6b2b581793f361f68fd21cff110aa262',1,'http.h']]], + ['evhttp_5fremove_5fvirtual_5fhost_1058',['evhttp_remove_virtual_host',['../http_8h.html#a68ec9dd6e33b7505a1ccde9e3d55b18a',1,'http.h']]], + ['evhttp_5frequest_5ffree_1059',['evhttp_request_free',['../http_8h.html#a740defd3a36e3d609a362cee96508402',1,'http.h']]], + ['evhttp_5frequest_5fget_5fcommand_1060',['evhttp_request_get_command',['../http_8h.html#aaef4dc4d2dfd468b5f3497853d6c0486',1,'http.h']]], + ['evhttp_5frequest_5fget_5fconnection_1061',['evhttp_request_get_connection',['../http_8h.html#a2d816772ec078f8cf0367b4be63095b3',1,'http.h']]], + ['evhttp_5frequest_5fget_5fevhttp_5furi_1062',['evhttp_request_get_evhttp_uri',['../http_8h.html#af528a5c6a3a6212cefadf21f751a9718',1,'http.h']]], + ['evhttp_5frequest_5fget_5fhost_1063',['evhttp_request_get_host',['../http_8h.html#afded43caaf7dc2d0532f50b4a463f7d1',1,'http.h']]], + ['evhttp_5frequest_5fget_5finput_5fbuffer_1064',['evhttp_request_get_input_buffer',['../http_8h.html#a5a7df0b7b7a10bda540ba24cd1021c80',1,'http.h']]], + ['evhttp_5frequest_5fget_5finput_5fheaders_1065',['evhttp_request_get_input_headers',['../http_8h.html#a3ab43473b2830c8d0f3b8ec14c6f9fdf',1,'http.h']]], + ['evhttp_5frequest_5fget_5foutput_5fbuffer_1066',['evhttp_request_get_output_buffer',['../http_8h.html#ae4c4774bbd23cd887ceda30c3e7ea094',1,'http.h']]], + ['evhttp_5frequest_5fget_5foutput_5fheaders_1067',['evhttp_request_get_output_headers',['../http_8h.html#ad12a28805401f4f498964987385ed1e3',1,'http.h']]], + ['evhttp_5frequest_5fget_5furi_1068',['evhttp_request_get_uri',['../http_8h.html#aa02d664574b2aefbb671f8534e5c476a',1,'http.h']]], + ['evhttp_5frequest_5fis_5fowned_1069',['evhttp_request_is_owned',['../http_8h.html#a980ad5b5a00bef46201b1683ef0e2ee1',1,'http.h']]], + ['evhttp_5frequest_5fnew_1070',['evhttp_request_new',['../http_8h.html#a66ffd177b52ffc59163c708d9b2f7275',1,'http.h']]], + ['evhttp_5frequest_5fown_1071',['evhttp_request_own',['../http_8h.html#aa1bd475e8be9f389586a6be9fbb242d4',1,'http.h']]], + ['evhttp_5frequest_5fset_5fchunked_5fcb_1072',['evhttp_request_set_chunked_cb',['../http_8h.html#ace8a70a82c88bfc3856a1b2ae1c9a40b',1,'http.h']]], + ['evhttp_5frequest_5fset_5ferror_5fcb_1073',['evhttp_request_set_error_cb',['../http_8h.html#a90bf87f4fdaea3ccf414bf8572b0228a',1,'http.h']]], + ['evhttp_5frequest_5fset_5fheader_5fcb_1074',['evhttp_request_set_header_cb',['../http_8h.html#a3d812da94907b41165dfa2efc09bd329',1,'http.h']]], + ['evhttp_5frequest_5fset_5fon_5fcomplete_5fcb_1075',['evhttp_request_set_on_complete_cb',['../http_8h.html#a83469b1ba147fc46a98d4f94cbd99a45',1,'http.h']]], + ['evhttp_5fsend_5ferror_1076',['evhttp_send_error',['../http_8h.html#a47d90ffdd80edc13ab4197e2c21a1403',1,'http.h']]], + ['evhttp_5fsend_5freply_1077',['evhttp_send_reply',['../http_8h.html#a0a77d07263e20733a7562dcd576ad721',1,'http.h']]], + ['evhttp_5fsend_5freply_5fchunk_1078',['evhttp_send_reply_chunk',['../http_8h.html#a380c78fba2c4d5efe22191673c4ed1a7',1,'http.h']]], + ['evhttp_5fsend_5freply_5fchunk_5fwith_5fcb_1079',['evhttp_send_reply_chunk_with_cb',['../http_8h.html#a694a80962c9dd37014b4bd61f6a04275',1,'http.h']]], + ['evhttp_5fsend_5freply_5fend_1080',['evhttp_send_reply_end',['../http_8h.html#a014b3c0c4f85a2c7bc7f4092aaf19884',1,'http.h']]], + ['evhttp_5fsend_5freply_5fstart_1081',['evhttp_send_reply_start',['../http_8h.html#a730f35086068b559b2bd324d07591283',1,'http.h']]], + ['evhttp_5fset_5fallowed_5fmethods_1082',['evhttp_set_allowed_methods',['../http_8h.html#a5682dc2fe3f18dcbffd9a55bcebac9a0',1,'http.h']]], + ['evhttp_5fset_5fbevcb_1083',['evhttp_set_bevcb',['../http_8h.html#ae4accb83b76a63db8b6fe5e765df1411',1,'http.h']]], + ['evhttp_5fset_5fcb_1084',['evhttp_set_cb',['../http_8h.html#af1b22fdf5ea2c6335ccbc96fb930774e',1,'http.h']]], + ['evhttp_5fset_5fdefault_5fcontent_5ftype_1085',['evhttp_set_default_content_type',['../http_8h.html#a53cbc32c73ae066cf6140698a2fca532',1,'http.h']]], + ['evhttp_5fset_5ferrorcb_1086',['evhttp_set_errorcb',['../http_8h.html#a7ff8d8b085885abf2037f0b4d0cc8c39',1,'http.h']]], + ['evhttp_5fset_5fext_5fmethod_5fcmp_1087',['evhttp_set_ext_method_cmp',['../http_8h.html#a171f175f66ceb0bd7ca93b32229a54c5',1,'http.h']]], + ['evhttp_5fset_5fflags_1088',['evhttp_set_flags',['../http_8h.html#ab531e7d4962724efa3401d11edea1150',1,'http.h']]], + ['evhttp_5fset_5fgencb_1089',['evhttp_set_gencb',['../http_8h.html#a52e68315974c684709c373fe7c46bec8',1,'http.h']]], + ['evhttp_5fset_5fmax_5fbody_5fsize_1090',['evhttp_set_max_body_size',['../http_8h.html#a4ba3aa63bccc4f2ec3c18d4eb26be851',1,'http.h']]], + ['evhttp_5fset_5fmax_5fconnections_1091',['evhttp_set_max_connections',['../http_8h.html#a9ee088f799a4f8ade368f0e18817d432',1,'http.h']]], + ['evhttp_5fset_5fmax_5fheaders_5fsize_1092',['evhttp_set_max_headers_size',['../http_8h.html#a1d118ec9cf879e60df5e800a53fa7be5',1,'http.h']]], + ['evhttp_5fset_5fnewreqcb_1093',['evhttp_set_newreqcb',['../http_8h.html#a5d57616424673f65eee38f0dc8293373',1,'http.h']]], + ['evhttp_5fset_5fread_5ftimeout_5ftv_1094',['evhttp_set_read_timeout_tv',['../http_8h.html#ae4efab329925d632a9e94a3065b8d17f',1,'http.h']]], + ['evhttp_5fset_5ftimeout_1095',['evhttp_set_timeout',['../http_8h.html#a5b4a6022933fb806d621a398ceec8eb2',1,'http.h']]], + ['evhttp_5fset_5ftimeout_5ftv_1096',['evhttp_set_timeout_tv',['../http_8h.html#a3ea68d1a73ae1a09c6398e264b357407',1,'http.h']]], + ['evhttp_5fset_5fwrite_5ftimeout_5ftv_1097',['evhttp_set_write_timeout_tv',['../http_8h.html#ae0916087937baf9c4e99e19301ae59f8',1,'http.h']]], + ['evhttp_5fstart_1098',['evhttp_start',['../http__compat_8h.html#ae6e4bd50d3da5bdac6457ffc03f4db06',1,'http_compat.h']]], + ['evhttp_5furi_5ffree_1099',['evhttp_uri_free',['../http_8h.html#a656211357bacf7fae9d09d2d23f7f4b0',1,'http.h']]], + ['evhttp_5furi_5fget_5ffragment_1100',['evhttp_uri_get_fragment',['../http_8h.html#af2d03ee60bd21072b67ec7b89d476226',1,'http.h']]], + ['evhttp_5furi_5fget_5fhost_1101',['evhttp_uri_get_host',['../http_8h.html#aaa22a9dc787b32f5133e81a7f5e96d25',1,'http.h']]], + ['evhttp_5furi_5fget_5fpath_1102',['evhttp_uri_get_path',['../http_8h.html#a8264b614f23012200c559e25f37f8a4c',1,'http.h']]], + ['evhttp_5furi_5fget_5fport_1103',['evhttp_uri_get_port',['../http_8h.html#a1ee1f098fa176ae0b33729308a35136d',1,'http.h']]], + ['evhttp_5furi_5fget_5fquery_1104',['evhttp_uri_get_query',['../http_8h.html#a02a52f21c3c169729110efb289835b55',1,'http.h']]], + ['evhttp_5furi_5fget_5fscheme_1105',['evhttp_uri_get_scheme',['../http_8h.html#a2b19501e4d1ae89df696304e9b18fbe0',1,'http.h']]], + ['evhttp_5furi_5fget_5funixsocket_1106',['evhttp_uri_get_unixsocket',['../http_8h.html#a56fd87a6f536bb28a66dbbfda1eaf328',1,'http.h']]], + ['evhttp_5furi_5fget_5fuserinfo_1107',['evhttp_uri_get_userinfo',['../http_8h.html#aab0d0c0b1a761ab88a9c105330170f10',1,'http.h']]], + ['evhttp_5furi_5fjoin_1108',['evhttp_uri_join',['../http_8h.html#a8eb220c9f81c70ccd3f69fb692cffbda',1,'http.h']]], + ['evhttp_5furi_5fnew_1109',['evhttp_uri_new',['../http_8h.html#a4447fa5bf7323b98a74fc660bcd892d8',1,'http.h']]], + ['evhttp_5furi_5fparse_1110',['evhttp_uri_parse',['../http_8h.html#abdae107e1eba62a9a015892fb761f074',1,'http.h']]], + ['evhttp_5furi_5fparse_5fwith_5fflags_1111',['evhttp_uri_parse_with_flags',['../http_8h.html#ac6cc995d43fb39f838d2ff866057673c',1,'http.h']]], + ['evhttp_5furi_5fset_5fflags_1112',['evhttp_uri_set_flags',['../http_8h.html#aa18f3bc6e899f80ba047a683d245245b',1,'http.h']]], + ['evhttp_5furi_5fset_5ffragment_1113',['evhttp_uri_set_fragment',['../http_8h.html#a6ffbf72e6974650339f89b23a8d8fc30',1,'http.h']]], + ['evhttp_5furi_5fset_5fhost_1114',['evhttp_uri_set_host',['../http_8h.html#a71b70977e40970863c611dc9f8c66f0f',1,'http.h']]], + ['evhttp_5furi_5fset_5fpath_1115',['evhttp_uri_set_path',['../http_8h.html#a55ae372c7045ed54e9193a061e440b59',1,'http.h']]], + ['evhttp_5furi_5fset_5fport_1116',['evhttp_uri_set_port',['../http_8h.html#a44aebcf9b67a66025af7d002df0ecde1',1,'http.h']]], + ['evhttp_5furi_5fset_5fquery_1117',['evhttp_uri_set_query',['../http_8h.html#aa1de728d898f2ec5deab6299d885d286',1,'http.h']]], + ['evhttp_5furi_5fset_5fscheme_1118',['evhttp_uri_set_scheme',['../http_8h.html#a45fcdbd2ca2683418f3745cbb8745256',1,'http.h']]], + ['evhttp_5furi_5fset_5funixsocket_1119',['evhttp_uri_set_unixsocket',['../http_8h.html#ac7259917dbf5cac8ff0e3d00b8574cbe',1,'http.h']]], + ['evhttp_5furi_5fset_5fuserinfo_1120',['evhttp_uri_set_userinfo',['../http_8h.html#a12083a9ed157ed7d0d980973613e7f18',1,'http.h']]], + ['evhttp_5furidecode_1121',['evhttp_uridecode',['../http_8h.html#a837276600c9c2f0521c44879c8d371b7',1,'http.h']]], + ['evhttp_5furiencode_1122',['evhttp_uriencode',['../http_8h.html#ad9259be209e6afbf15987922d1841e70',1,'http.h']]], + ['evrpc_5fadd_5fhook_1123',['evrpc_add_hook',['../rpc_8h.html#a5d82ac478904ddadeba9af7e695b254d',1,'rpc.h']]], + ['evrpc_5ffree_1124',['evrpc_free',['../rpc_8h.html#aefeb82c78c1a6e2338d32cfcb02297c6',1,'rpc.h']]], + ['evrpc_5fget_5frequest_1125',['evrpc_get_request',['../rpc_8h.html#abb47f45ebbc9c6322f3d57dc0bc9dd0d',1,'rpc.h']]], + ['evrpc_5fhook_5fadd_5fmeta_1126',['evrpc_hook_add_meta',['../rpc_8h.html#afddaba85bd35b7a99ff69daa73b9a98d',1,'rpc.h']]], + ['evrpc_5fhook_5ffind_5fmeta_1127',['evrpc_hook_find_meta',['../rpc_8h.html#a5e6215f4f22ab5bc5d72159143cefcea',1,'rpc.h']]], + ['evrpc_5fhook_5fget_5fconnection_1128',['evrpc_hook_get_connection',['../rpc_8h.html#afb04e638c158bd3fe3a0e73000e39f10',1,'rpc.h']]], + ['evrpc_5finit_1129',['evrpc_init',['../rpc_8h.html#ac86c02abb0baa97c82efe94a72ae8178',1,'rpc.h']]], + ['evrpc_5fmake_5frequest_1130',['evrpc_make_request',['../rpc_8h.html#a1e45aa64f32b7a0a780b914b4a7b83c5',1,'rpc.h']]], + ['evrpc_5fmake_5frequest_5fctx_1131',['evrpc_make_request_ctx',['../rpc_8h.html#a6a8bc24b989e67a6739fc11118ba0b3f',1,'rpc.h']]], + ['evrpc_5fpool_5fadd_5fconnection_1132',['evrpc_pool_add_connection',['../rpc_8h.html#a9e3bedffaef59f2ccc1c0003ce05da8c',1,'rpc.h']]], + ['evrpc_5fpool_5ffree_1133',['evrpc_pool_free',['../rpc_8h.html#ab8579f465aee520bb8ac1b208d1d8d95',1,'rpc.h']]], + ['evrpc_5fpool_5fnew_1134',['evrpc_pool_new',['../rpc_8h.html#a3098d4fd0966fe525d86f0f717771389',1,'rpc.h']]], + ['evrpc_5fpool_5fremove_5fconnection_1135',['evrpc_pool_remove_connection',['../rpc_8h.html#a6272b6b974e4abe27ccb1273ba37b100',1,'rpc.h']]], + ['evrpc_5fpool_5fset_5ftimeout_1136',['evrpc_pool_set_timeout',['../rpc_8h.html#a0164fb784c8b8907e30861f2fee89c44',1,'rpc.h']]], + ['evrpc_5fregister_5fgeneric_1137',['evrpc_register_generic',['../rpc_8h.html#aad265540d04241d80f60847718db5913',1,'rpc.h']]], + ['evrpc_5fregister_5frpc_1138',['evrpc_register_rpc',['../rpc_8h.html#ab8687528c294762984a097ecf4575713',1,'rpc.h']]], + ['evrpc_5fremove_5fhook_1139',['evrpc_remove_hook',['../rpc_8h.html#ab77b039cae7b4f94bfff18382bef981f',1,'rpc.h']]], + ['evrpc_5frequest_5fdone_1140',['evrpc_request_done',['../rpc_8h.html#a7c74b9d6cd83891ed8f03435892a0e5d',1,'rpc.h']]], + ['evrpc_5frequest_5fget_5fpool_1141',['evrpc_request_get_pool',['../rpc_8h.html#af6dd0d42ecc04297df768300e5f24b31',1,'rpc.h']]], + ['evrpc_5fresume_5frequest_1142',['evrpc_resume_request',['../rpc_8h.html#a8e7a8aabcd4e216d1e32254bfba33472',1,'rpc.h']]], + ['evrpc_5fsend_5frequest_5fgeneric_1143',['evrpc_send_request_generic',['../rpc_8h.html#a99dc1ab2f6775a743dac96cdf2d5ace0',1,'rpc.h']]], + ['evtag_5fencode_5fint_1144',['evtag_encode_int',['../tag_8h.html#a22ef611a14b919e939fdade0af8b692c',1,'tag.h']]], + ['evtag_5funmarshal_5fheader_1145',['evtag_unmarshal_header',['../tag_8h.html#a57431aea9815331fbbea6cca413a85af',1,'tag.h']]], + ['evthread_5fenable_5flock_5fdebugging_1146',['evthread_enable_lock_debugging',['../thread_8h.html#a4b9ec0970d762320451fafc8f7cb2087',1,'thread.h']]], + ['evthread_5fmake_5fbase_5fnotifiable_1147',['evthread_make_base_notifiable',['../thread_8h.html#ac0c39231d48295aff378fd9f65b2569a',1,'thread.h']]], + ['evthread_5fset_5fcondition_5fcallbacks_1148',['evthread_set_condition_callbacks',['../thread_8h.html#a15c0f69030cfec09cc34bf8afd151bac',1,'thread.h']]], + ['evthread_5fset_5fid_5fcallback_1149',['evthread_set_id_callback',['../thread_8h.html#a79ec78eb62ee5082a33cfb0c14df9772',1,'thread.h']]], + ['evthread_5fset_5flock_5fcallbacks_1150',['evthread_set_lock_callbacks',['../thread_8h.html#ae5fa5c777ca30576db8355a9140c533b',1,'thread.h']]], + ['evthread_5fuse_5fpthreads_1151',['evthread_use_pthreads',['../thread_8h.html#acc0cc708c566c14f4659331ec12f8a5b',1,'thread.h']]], + ['evthread_5fuse_5fpthreads_5fwith_5fflags_1152',['evthread_use_pthreads_with_flags',['../thread_8h.html#a2cef140279d8452e69dc73cc15ca697c',1,'thread.h']]], + ['evthread_5fuse_5fwindows_5fthreads_1153',['evthread_use_windows_threads',['../thread_8h.html#a1b0fe36dcb033da2c679d39ce8a190e2',1,'thread.h']]], + ['evutil_5fascii_5fstrcasecmp_1154',['evutil_ascii_strcasecmp',['../util_8h.html#aae46d8f8407906b79216f9be88803126',1,'util.h']]], + ['evutil_5fascii_5fstrncasecmp_1155',['evutil_ascii_strncasecmp',['../util_8h.html#a03b44d66883df5bfed32c9ac6df93aac',1,'util.h']]], + ['evutil_5fclosesocket_1156',['evutil_closesocket',['../util_8h.html#a5cfa6c13c62d17570a7d5f6d3541ff5b',1,'util.h']]], + ['evutil_5fconfigure_5fmonotonic_5ftime_1157',['evutil_configure_monotonic_time',['../util_8h.html#ab486d1e10fd1e3102b4e53beed8d9baa',1,'util.h']]], + ['evutil_5fdate_5frfc1123_1158',['evutil_date_rfc1123',['../util_8h.html#a9d2f7f9996a6ff28db2aeb8ac8a58187',1,'util.h']]], + ['evutil_5ffreeaddrinfo_1159',['evutil_freeaddrinfo',['../util_8h.html#a58a472b3afc5cef1e6b1c9912604381b',1,'util.h']]], + ['evutil_5fgetaddrinfo_1160',['evutil_getaddrinfo',['../util_8h.html#a0f36c2fc48c644a4f56347a25c585cc9',1,'util.h']]], + ['evutil_5fgettime_5fmonotonic_1161',['evutil_gettime_monotonic',['../util_8h.html#abe94df86960981b69411f20c0c5235dc',1,'util.h']]], + ['evutil_5finet_5fntop_1162',['evutil_inet_ntop',['../util_8h.html#afa98d48bdd6ad06c1fd013a44621d567',1,'util.h']]], + ['evutil_5finet_5fpton_1163',['evutil_inet_pton',['../util_8h.html#a4065af1c9c995010ef7df66154c313b2',1,'util.h']]], + ['evutil_5finet_5fpton_5fscope_1164',['evutil_inet_pton_scope',['../util_8h.html#ad586fc57f596616d810a8b5fe4f8c111',1,'util.h']]], + ['evutil_5fmake_5flisten_5fsocket_5fipv6only_1165',['evutil_make_listen_socket_ipv6only',['../util_8h.html#ad361aa5727c88f05633a9032ad8c850f',1,'util.h']]], + ['evutil_5fmake_5flisten_5fsocket_5fnot_5fipv6only_1166',['evutil_make_listen_socket_not_ipv6only',['../util_8h.html#a031699658b52069610d660919d0c2b9d',1,'util.h']]], + ['evutil_5fmake_5flisten_5fsocket_5freuseable_1167',['evutil_make_listen_socket_reuseable',['../util_8h.html#a7a8e18b7861ed856bde592257f6b6e11',1,'util.h']]], + ['evutil_5fmake_5flisten_5fsocket_5freuseable_5fport_1168',['evutil_make_listen_socket_reuseable_port',['../util_8h.html#a9e4e68f77ce876ceecc6fb65f2dbe506',1,'util.h']]], + ['evutil_5fmake_5fsocket_5fcloseonexec_1169',['evutil_make_socket_closeonexec',['../util_8h.html#a7edc3874139e863f61edf6c705030430',1,'util.h']]], + ['evutil_5fmake_5fsocket_5fnonblocking_1170',['evutil_make_socket_nonblocking',['../util_8h.html#a4f8f2384311baf5d7308c7ab079f9b84',1,'util.h']]], + ['evutil_5fmake_5ftcp_5flisten_5fsocket_5fdeferred_1171',['evutil_make_tcp_listen_socket_deferred',['../util_8h.html#a988b1fc98edeac63efc8b13c4f822a0d',1,'util.h']]], + ['evutil_5fmonotonic_5ftimer_5ffree_1172',['evutil_monotonic_timer_free',['../util_8h.html#a2874062ff988293cd4e40b220933e209',1,'util.h']]], + ['evutil_5fmonotonic_5ftimer_5fnew_1173',['evutil_monotonic_timer_new',['../util_8h.html#a87b00e2754d908ba05c5aa8e9c8e4f28',1,'util.h']]], + ['evutil_5fparse_5fsockaddr_5fport_1174',['evutil_parse_sockaddr_port',['../util_8h.html#a97d4f315d5c40c4f604f6c9ae694a684',1,'util.h']]], + ['evutil_5fsecure_5frng_5fadd_5fbytes_1175',['evutil_secure_rng_add_bytes',['../util_8h.html#a3b5b7d22b368ffdd6ed77838bf4fcea6',1,'util.h']]], + ['evutil_5fsecure_5frng_5fget_5fbytes_1176',['evutil_secure_rng_get_bytes',['../util_8h.html#a0836ed5d00ccab1957419a07b7acbb56',1,'util.h']]], + ['evutil_5fsecure_5frng_5finit_1177',['evutil_secure_rng_init',['../util_8h.html#a49ffe53dcbe32ad55f1582a0da358ac0',1,'util.h']]], + ['evutil_5fsecure_5frng_5fset_5furandom_5fdevice_5ffile_1178',['evutil_secure_rng_set_urandom_device_file',['../util_8h.html#a4544ddceb4e20c8c52985641ca829b7e',1,'util.h']]], + ['evutil_5fset_5ftcp_5fkeepalive_1179',['evutil_set_tcp_keepalive',['../util_8h.html#a96f11bb3a6bf772201a0a2010689a250',1,'util.h']]], + ['evutil_5fsnprintf_1180',['evutil_snprintf',['../util_8h.html#a198e8db3626746515792e28b1380be67',1,'util.h']]], + ['evutil_5fsockaddr_5fcmp_1181',['evutil_sockaddr_cmp',['../util_8h.html#a7b5ad1074f1effe2dbfa18b3f44b589f',1,'util.h']]], + ['evutil_5fsocketpair_1182',['evutil_socketpair',['../util_8h.html#a050a74274e08eb89a53cb8cb1d617939',1,'util.h']]], + ['evutil_5fstrtoll_1183',['evutil_strtoll',['../util_8h.html#a9175e63729c256eb2646e11e8211f4f7',1,'util.h']]], + ['evutil_5fvsnprintf_1184',['evutil_vsnprintf',['../util_8h.html#a30bbdc509d150e5dfac1f74dd4e4c212',1,'util.h']]], + ['evwatch_5fbase_1185',['evwatch_base',['../watch_8h.html#a12f916b5846e7925939abbaca49b4521',1,'watch.h']]], + ['evwatch_5fcheck_5fnew_1186',['evwatch_check_new',['../watch_8h.html#acfeaa9fc345062e41c7f807d6c5d511f',1,'watch.h']]], + ['evwatch_5ffree_1187',['evwatch_free',['../watch_8h.html#aadf0c377890835ae40612b19f9029032',1,'watch.h']]], + ['evwatch_5fprepare_5fget_5ftimeout_1188',['evwatch_prepare_get_timeout',['../watch_8h.html#a5f7837d8af2b00c9ec401e00b4f33781',1,'watch.h']]], + ['evwatch_5fprepare_5fnew_1189',['evwatch_prepare_new',['../watch_8h.html#ad446340d54b8de7125cae9d5fed9c61e',1,'watch.h']]] +]; diff --git a/search/functions_2.html b/search/functions_2.html new file mode 100644 index 0000000..2737c5a --- /dev/null +++ b/search/functions_2.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/functions_2.js b/search/functions_2.js new file mode 100644 index 0000000..ca67821 --- /dev/null +++ b/search/functions_2.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['libevent_5fglobal_5fshutdown_1190',['libevent_global_shutdown',['../event_8h.html#aaed24b9ff1f5b137ea2e2cc6a2bf8d1f',1,'event.h']]] +]; diff --git a/search/mag_sel.png b/search/mag_sel.png new file mode 100644 index 0000000..39c0ed5 Binary files /dev/null and b/search/mag_sel.png differ diff --git a/search/nomatches.html b/search/nomatches.html new file mode 100644 index 0000000..4377320 --- /dev/null +++ b/search/nomatches.html @@ -0,0 +1,12 @@ + + + + + + + +
    +
    No Matches
    +
    + + diff --git a/search/pages_0.html b/search/pages_0.html new file mode 100644 index 0000000..9a6a29a --- /dev/null +++ b/search/pages_0.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/pages_0.js b/search/pages_0.js new file mode 100644 index 0000000..af20832 --- /dev/null +++ b/search/pages_0.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['deprecated_20list_1418',['Deprecated List',['../deprecated.html',1,'']]] +]; diff --git a/search/search.css b/search/search.css new file mode 100644 index 0000000..3cf9df9 --- /dev/null +++ b/search/search.css @@ -0,0 +1,271 @@ +/*---------------- Search Box */ + +#FSearchBox { + float: left; +} + +#MSearchBox { + white-space : nowrap; + float: none; + margin-top: 8px; + right: 0px; + width: 170px; + height: 24px; + z-index: 102; +} + +#MSearchBox .left +{ + display:block; + position:absolute; + left:10px; + width:20px; + height:19px; + background:url('search_l.png') no-repeat; + background-position:right; +} + +#MSearchSelect { + display:block; + position:absolute; + width:20px; + height:19px; +} + +.left #MSearchSelect { + left:4px; +} + +.right #MSearchSelect { + right:5px; +} + +#MSearchField { + display:block; + position:absolute; + height:19px; + background:url('search_m.png') repeat-x; + border:none; + width:115px; + margin-left:20px; + padding-left:4px; + color: #909090; + outline: none; + font: 9pt Arial, Verdana, sans-serif; + -webkit-border-radius: 0px; +} + +#FSearchBox #MSearchField { + margin-left:15px; +} + +#MSearchBox .right { + display:block; + position:absolute; + right:10px; + top:8px; + width:20px; + height:19px; + background:url('search_r.png') no-repeat; + background-position:left; +} + +#MSearchClose { + display: none; + position: absolute; + top: 4px; + background : none; + border: none; + margin: 0px 4px 0px 0px; + padding: 0px 0px; + outline: none; +} + +.left #MSearchClose { + left: 6px; +} + +.right #MSearchClose { + right: 2px; +} + +.MSearchBoxActive #MSearchField { + color: #000000; +} + +/*---------------- Search filter selection */ + +#MSearchSelectWindow { + display: none; + position: absolute; + left: 0; top: 0; + border: 1px solid #90A5CE; + background-color: #F9FAFC; + z-index: 10001; + padding-top: 4px; + padding-bottom: 4px; + -moz-border-radius: 4px; + -webkit-border-top-left-radius: 4px; + -webkit-border-top-right-radius: 4px; + -webkit-border-bottom-left-radius: 4px; + -webkit-border-bottom-right-radius: 4px; + -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); +} + +.SelectItem { + font: 8pt Arial, Verdana, sans-serif; + padding-left: 2px; + padding-right: 12px; + border: 0px; +} + +span.SelectionMark { + margin-right: 4px; + font-family: monospace; + outline-style: none; + text-decoration: none; +} + +a.SelectItem { + display: block; + outline-style: none; + color: #000000; + text-decoration: none; + padding-left: 6px; + padding-right: 12px; +} + +a.SelectItem:focus, +a.SelectItem:active { + color: #000000; + outline-style: none; + text-decoration: none; +} + +a.SelectItem:hover { + color: #FFFFFF; + background-color: #3D578C; + outline-style: none; + text-decoration: none; + cursor: pointer; + display: block; +} + +/*---------------- Search results window */ + +iframe#MSearchResults { + width: 60ex; + height: 15em; +} + +#MSearchResultsWindow { + display: none; + position: absolute; + left: 0; top: 0; + border: 1px solid #000; + background-color: #EEF1F7; + z-index:10000; +} + +/* ----------------------------------- */ + + +#SRIndex { + clear:both; + padding-bottom: 15px; +} + +.SREntry { + font-size: 10pt; + padding-left: 1ex; +} + +.SRPage .SREntry { + font-size: 8pt; + padding: 1px 5px; +} + +body.SRPage { + margin: 5px 2px; +} + +.SRChildren { + padding-left: 3ex; padding-bottom: .5em +} + +.SRPage .SRChildren { + display: none; +} + +.SRSymbol { + font-weight: bold; + color: #425E97; + font-family: Arial, Verdana, sans-serif; + text-decoration: none; + outline: none; +} + +a.SRScope { + display: block; + color: #425E97; + font-family: Arial, Verdana, sans-serif; + text-decoration: none; + outline: none; +} + +a.SRSymbol:focus, a.SRSymbol:active, +a.SRScope:focus, a.SRScope:active { + text-decoration: underline; +} + +span.SRScope { + padding-left: 4px; +} + +.SRPage .SRStatus { + padding: 2px 5px; + font-size: 8pt; + font-style: italic; +} + +.SRResult { + display: none; +} + +DIV.searchresults { + margin-left: 10px; + margin-right: 10px; +} + +/*---------------- External search page results */ + +.searchresult { + background-color: #F0F3F8; +} + +.pages b { + color: white; + padding: 5px 5px 3px 5px; + background-image: url("../tab_a.png"); + background-repeat: repeat-x; + text-shadow: 0 1px 1px #000000; +} + +.pages { + line-height: 17px; + margin-left: 4px; + text-decoration: none; +} + +.hl { + font-weight: bold; +} + +#searchresults { + margin-bottom: 20px; +} + +.searchpages { + margin-top: 10px; +} + diff --git a/search/search.js b/search/search.js new file mode 100644 index 0000000..a554ab9 --- /dev/null +++ b/search/search.js @@ -0,0 +1,814 @@ +/* + @licstart The following is the entire license notice for the + JavaScript code in this file. + + Copyright (C) 1997-2017 by Dimitri van Heesch + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + + @licend The above is the entire license notice + for the JavaScript code in this file + */ +function convertToId(search) +{ + var result = ''; + for (i=0;i do a search + { + this.Search(); + } + } + + this.OnSearchSelectKey = function(evt) + { + var e = (evt) ? evt : window.event; // for IE + if (e.keyCode==40 && this.searchIndex0) // Up + { + this.searchIndex--; + this.OnSelectItem(this.searchIndex); + } + else if (e.keyCode==13 || e.keyCode==27) + { + this.OnSelectItem(this.searchIndex); + this.CloseSelectionWindow(); + this.DOMSearchField().focus(); + } + return false; + } + + // --------- Actions + + // Closes the results window. + this.CloseResultsWindow = function() + { + this.DOMPopupSearchResultsWindow().style.display = 'none'; + this.DOMSearchClose().style.display = 'none'; + this.Activate(false); + } + + this.CloseSelectionWindow = function() + { + this.DOMSearchSelectWindow().style.display = 'none'; + } + + // Performs a search. + this.Search = function() + { + this.keyTimeout = 0; + + // strip leading whitespace + var searchValue = this.DOMSearchField().value.replace(/^ +/, ""); + + var code = searchValue.toLowerCase().charCodeAt(0); + var idxChar = searchValue.substr(0, 1).toLowerCase(); + if ( 0xD800 <= code && code <= 0xDBFF && searchValue > 1) // surrogate pair + { + idxChar = searchValue.substr(0, 2); + } + + var resultsPage; + var resultsPageWithSearch; + var hasResultsPage; + + var idx = indexSectionsWithContent[this.searchIndex].indexOf(idxChar); + if (idx!=-1) + { + var hexCode=idx.toString(16); + resultsPage = this.resultsPath + '/' + indexSectionNames[this.searchIndex] + '_' + hexCode + '.html'; + resultsPageWithSearch = resultsPage+'?'+escape(searchValue); + hasResultsPage = true; + } + else // nothing available for this search term + { + resultsPage = this.resultsPath + '/nomatches.html'; + resultsPageWithSearch = resultsPage; + hasResultsPage = false; + } + + window.frames.MSearchResults.location = resultsPageWithSearch; + var domPopupSearchResultsWindow = this.DOMPopupSearchResultsWindow(); + + if (domPopupSearchResultsWindow.style.display!='block') + { + var domSearchBox = this.DOMSearchBox(); + this.DOMSearchClose().style.display = 'inline'; + if (this.insideFrame) + { + var domPopupSearchResults = this.DOMPopupSearchResults(); + domPopupSearchResultsWindow.style.position = 'relative'; + domPopupSearchResultsWindow.style.display = 'block'; + var width = document.body.clientWidth - 8; // the -8 is for IE :-( + domPopupSearchResultsWindow.style.width = width + 'px'; + domPopupSearchResults.style.width = width + 'px'; + } + else + { + var domPopupSearchResults = this.DOMPopupSearchResults(); + var left = getXPos(domSearchBox) + 150; // domSearchBox.offsetWidth; + var top = getYPos(domSearchBox) + 20; // domSearchBox.offsetHeight + 1; + domPopupSearchResultsWindow.style.display = 'block'; + left -= domPopupSearchResults.offsetWidth; + domPopupSearchResultsWindow.style.top = top + 'px'; + domPopupSearchResultsWindow.style.left = left + 'px'; + } + } + + this.lastSearchValue = searchValue; + this.lastResultsPage = resultsPage; + } + + // -------- Activation Functions + + // Activates or deactivates the search panel, resetting things to + // their default values if necessary. + this.Activate = function(isActive) + { + if (isActive || // open it + this.DOMPopupSearchResultsWindow().style.display == 'block' + ) + { + this.DOMSearchBox().className = 'MSearchBoxActive'; + + var searchField = this.DOMSearchField(); + + if (searchField.value == this.searchLabel) // clear "Search" term upon entry + { + searchField.value = ''; + this.searchActive = true; + } + } + else if (!isActive) // directly remove the panel + { + this.DOMSearchBox().className = 'MSearchBoxInactive'; + this.DOMSearchField().value = this.searchLabel; + this.searchActive = false; + this.lastSearchValue = '' + this.lastResultsPage = ''; + } + } +} + +// ----------------------------------------------------------------------- + +// The class that handles everything on the search results page. +function SearchResults(name) +{ + // The number of matches from the last run of . + this.lastMatchCount = 0; + this.lastKey = 0; + this.repeatOn = false; + + // Toggles the visibility of the passed element ID. + this.FindChildElement = function(id) + { + var parentElement = document.getElementById(id); + var element = parentElement.firstChild; + + while (element && element!=parentElement) + { + if (element.nodeName == 'DIV' && element.className == 'SRChildren') + { + return element; + } + + if (element.nodeName == 'DIV' && element.hasChildNodes()) + { + element = element.firstChild; + } + else if (element.nextSibling) + { + element = element.nextSibling; + } + else + { + do + { + element = element.parentNode; + } + while (element && element!=parentElement && !element.nextSibling); + + if (element && element!=parentElement) + { + element = element.nextSibling; + } + } + } + } + + this.Toggle = function(id) + { + var element = this.FindChildElement(id); + if (element) + { + if (element.style.display == 'block') + { + element.style.display = 'none'; + } + else + { + element.style.display = 'block'; + } + } + } + + // Searches for the passed string. If there is no parameter, + // it takes it from the URL query. + // + // Always returns true, since other documents may try to call it + // and that may or may not be possible. + this.Search = function(search) + { + if (!search) // get search word from URL + { + search = window.location.search; + search = search.substring(1); // Remove the leading '?' + search = unescape(search); + } + + search = search.replace(/^ +/, ""); // strip leading spaces + search = search.replace(/ +$/, ""); // strip trailing spaces + search = search.toLowerCase(); + search = convertToId(search); + + var resultRows = document.getElementsByTagName("div"); + var matches = 0; + + var i = 0; + while (i < resultRows.length) + { + var row = resultRows.item(i); + if (row.className == "SRResult") + { + var rowMatchName = row.id.toLowerCase(); + rowMatchName = rowMatchName.replace(/^sr\d*_/, ''); // strip 'sr123_' + + if (search.length<=rowMatchName.length && + rowMatchName.substr(0, search.length)==search) + { + row.style.display = 'block'; + matches++; + } + else + { + row.style.display = 'none'; + } + } + i++; + } + document.getElementById("Searching").style.display='none'; + if (matches == 0) // no results + { + document.getElementById("NoMatches").style.display='block'; + } + else // at least one result + { + document.getElementById("NoMatches").style.display='none'; + } + this.lastMatchCount = matches; + return true; + } + + // return the first item with index index or higher that is visible + this.NavNext = function(index) + { + var focusItem; + while (1) + { + var focusName = 'Item'+index; + focusItem = document.getElementById(focusName); + if (focusItem && focusItem.parentNode.parentNode.style.display=='block') + { + break; + } + else if (!focusItem) // last element + { + break; + } + focusItem=null; + index++; + } + return focusItem; + } + + this.NavPrev = function(index) + { + var focusItem; + while (1) + { + var focusName = 'Item'+index; + focusItem = document.getElementById(focusName); + if (focusItem && focusItem.parentNode.parentNode.style.display=='block') + { + break; + } + else if (!focusItem) // last element + { + break; + } + focusItem=null; + index--; + } + return focusItem; + } + + this.ProcessKeys = function(e) + { + if (e.type == "keydown") + { + this.repeatOn = false; + this.lastKey = e.keyCode; + } + else if (e.type == "keypress") + { + if (!this.repeatOn) + { + if (this.lastKey) this.repeatOn = true; + return false; // ignore first keypress after keydown + } + } + else if (e.type == "keyup") + { + this.lastKey = 0; + this.repeatOn = false; + } + return this.lastKey!=0; + } + + this.Nav = function(evt,itemIndex) + { + var e = (evt) ? evt : window.event; // for IE + if (e.keyCode==13) return true; + if (!this.ProcessKeys(e)) return false; + + if (this.lastKey==38) // Up + { + var newIndex = itemIndex-1; + var focusItem = this.NavPrev(newIndex); + if (focusItem) + { + var child = this.FindChildElement(focusItem.parentNode.parentNode.id); + if (child && child.style.display == 'block') // children visible + { + var n=0; + var tmpElem; + while (1) // search for last child + { + tmpElem = document.getElementById('Item'+newIndex+'_c'+n); + if (tmpElem) + { + focusItem = tmpElem; + } + else // found it! + { + break; + } + n++; + } + } + } + if (focusItem) + { + focusItem.focus(); + } + else // return focus to search field + { + parent.document.getElementById("MSearchField").focus(); + } + } + else if (this.lastKey==40) // Down + { + var newIndex = itemIndex+1; + var focusItem; + var item = document.getElementById('Item'+itemIndex); + var elem = this.FindChildElement(item.parentNode.parentNode.id); + if (elem && elem.style.display == 'block') // children visible + { + focusItem = document.getElementById('Item'+itemIndex+'_c0'); + } + if (!focusItem) focusItem = this.NavNext(newIndex); + if (focusItem) focusItem.focus(); + } + else if (this.lastKey==39) // Right + { + var item = document.getElementById('Item'+itemIndex); + var elem = this.FindChildElement(item.parentNode.parentNode.id); + if (elem) elem.style.display = 'block'; + } + else if (this.lastKey==37) // Left + { + var item = document.getElementById('Item'+itemIndex); + var elem = this.FindChildElement(item.parentNode.parentNode.id); + if (elem) elem.style.display = 'none'; + } + else if (this.lastKey==27) // Escape + { + parent.searchBox.CloseResultsWindow(); + parent.document.getElementById("MSearchField").focus(); + } + else if (this.lastKey==13) // Enter + { + return true; + } + return false; + } + + this.NavChild = function(evt,itemIndex,childIndex) + { + var e = (evt) ? evt : window.event; // for IE + if (e.keyCode==13) return true; + if (!this.ProcessKeys(e)) return false; + + if (this.lastKey==38) // Up + { + if (childIndex>0) + { + var newIndex = childIndex-1; + document.getElementById('Item'+itemIndex+'_c'+newIndex).focus(); + } + else // already at first child, jump to parent + { + document.getElementById('Item'+itemIndex).focus(); + } + } + else if (this.lastKey==40) // Down + { + var newIndex = childIndex+1; + var elem = document.getElementById('Item'+itemIndex+'_c'+newIndex); + if (!elem) // last child, jump to parent next parent + { + elem = this.NavNext(itemIndex+1); + } + if (elem) + { + elem.focus(); + } + } + else if (this.lastKey==27) // Escape + { + parent.searchBox.CloseResultsWindow(); + parent.document.getElementById("MSearchField").focus(); + } + else if (this.lastKey==13) // Enter + { + return true; + } + return false; + } +} + +function setKeyActions(elem,action) +{ + elem.setAttribute('onkeydown',action); + elem.setAttribute('onkeypress',action); + elem.setAttribute('onkeyup',action); +} + +function setClassAttr(elem,attr) +{ + elem.setAttribute('class',attr); + elem.setAttribute('className',attr); +} + +function createResults() +{ + var results = document.getElementById("SRResults"); + for (var e=0; e + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/typedefs_0.js b/search/typedefs_0.js new file mode 100644 index 0000000..f2af24e --- /dev/null +++ b/search/typedefs_0.js @@ -0,0 +1,6 @@ +var searchData= +[ + ['bufferevent_5fdata_5fcb_1207',['bufferevent_data_cb',['../bufferevent_8h.html#ad0b9fa4a6c8f03b2fe5a9929a7f2cd59',1,'bufferevent.h']]], + ['bufferevent_5fevent_5fcb_1208',['bufferevent_event_cb',['../bufferevent_8h.html#a3b0191b460511796e5281474cd704ec4',1,'bufferevent.h']]], + ['bufferevent_5ffilter_5fcb_1209',['bufferevent_filter_cb',['../bufferevent_8h.html#add4274f8e311afc47fb097d290dc54e8',1,'bufferevent.h']]] +]; diff --git a/search/typedefs_1.html b/search/typedefs_1.html new file mode 100644 index 0000000..9b8bf72 --- /dev/null +++ b/search/typedefs_1.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/typedefs_1.js b/search/typedefs_1.js new file mode 100644 index 0000000..c8614e9 --- /dev/null +++ b/search/typedefs_1.js @@ -0,0 +1,19 @@ +var searchData= +[ + ['evbuffer_5fcb_1210',['evbuffer_cb',['../buffer__compat_8h.html#a6df4ae9e3d819c487ded545d2e1d41b0',1,'buffer_compat.h']]], + ['evbuffer_5fcb_5ffunc_1211',['evbuffer_cb_func',['../buffer_8h.html#a8f16422514b698553f34c0eba180f3fa',1,'buffer.h']]], + ['evbuffer_5ffile_5fsegment_5fcleanup_5fcb_1212',['evbuffer_file_segment_cleanup_cb',['../buffer_8h.html#aa0e56a17ff87cf097011902b80dd53bf',1,'buffer.h']]], + ['evbuffer_5fref_5fcleanup_5fcb_1213',['evbuffer_ref_cleanup_cb',['../buffer_8h.html#a66c442353fa5159e2acd808794fa92d6',1,'buffer.h']]], + ['evconnlistener_5ferrorcb_1214',['evconnlistener_errorcb',['../listener_8h.html#a925d682ff37636dc08b045aaeff6b538',1,'listener.h']]], + ['evdns_5fcallback_5ftype_1215',['evdns_callback_type',['../dns_8h.html#a43018959c4be1a9b16e4143c5e3ff556',1,'dns.h']]], + ['evdns_5fdebug_5flog_5ffn_5ftype_1216',['evdns_debug_log_fn_type',['../dns_8h.html#a850904a1dbd8c8a087dc2be7617e21c8',1,'dns.h']]], + ['evdns_5fgetaddrinfo_5fcb_1217',['evdns_getaddrinfo_cb',['../dns_8h.html#a0d1464f191ef7678be0d4caf3644a8f4',1,'dns.h']]], + ['evdns_5frequest_5fcallback_5ffn_5ftype_1218',['evdns_request_callback_fn_type',['../dns_8h.html#a052802966f4c9d482279a05197dff005',1,'dns.h']]], + ['event_5fbase_5fforeach_5fevent_5fcb_1219',['event_base_foreach_event_cb',['../event_8h.html#a61f656b17425f17ed857b96d45fc6268',1,'event.h']]], + ['event_5fcallback_5ffn_1220',['event_callback_fn',['../event_8h.html#aed2307f3d9b38e07cc10c2607322d758',1,'event.h']]], + ['event_5ffatal_5fcb_1221',['event_fatal_cb',['../event_8h.html#abb799b636f0d3aab6ca17426d88473cf',1,'event.h']]], + ['event_5ffinalize_5fcallback_5ffn_1222',['event_finalize_callback_fn',['../event_8h.html#a6f62afb6e295ee487ad947e4eec18332',1,'event.h']]], + ['event_5flog_5fcb_1223',['event_log_cb',['../event_8h.html#a185f44c610d7ee21ecba720561b2e09c',1,'event.h']]], + ['evwatch_5fcheck_5fcb_1224',['evwatch_check_cb',['../watch_8h.html#a552db1e01295811adc2191580a48f3f7',1,'watch.h']]], + ['evwatch_5fprepare_5fcb_1225',['evwatch_prepare_cb',['../watch_8h.html#ab49b34b1552c9cc5e6a736cfc435c766',1,'watch.h']]] +]; diff --git a/search/variables_0.html b/search/variables_0.html new file mode 100644 index 0000000..bf3eba5 --- /dev/null +++ b/search/variables_0.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/variables_0.js b/search/variables_0.js new file mode 100644 index 0000000..573902f --- /dev/null +++ b/search/variables_0.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['alloc_1191',['alloc',['../structevthread__lock__callbacks.html#a640c2b86b8e914b411848dc72a472591',1,'evthread_lock_callbacks']]], + ['alloc_5fcondition_1192',['alloc_condition',['../structevthread__condition__callbacks.html#a1112ef26fb2217351895c10ba347220c',1,'evthread_condition_callbacks']]] +]; diff --git a/search/variables_1.html b/search/variables_1.html new file mode 100644 index 0000000..49fe59a --- /dev/null +++ b/search/variables_1.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/variables_1.js b/search/variables_1.js new file mode 100644 index 0000000..38ce829 --- /dev/null +++ b/search/variables_1.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['condition_5fapi_5fversion_1193',['condition_api_version',['../structevthread__condition__callbacks.html#a632a051711c8f7728e3464721d7c8084',1,'evthread_condition_callbacks']]] +]; diff --git a/search/variables_2.html b/search/variables_2.html new file mode 100644 index 0000000..0c8a18c --- /dev/null +++ b/search/variables_2.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/variables_2.js b/search/variables_2.js new file mode 100644 index 0000000..9792868 --- /dev/null +++ b/search/variables_2.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['free_1194',['free',['../structevthread__lock__callbacks.html#afdab536528e27486ae7acb783ccad07a',1,'evthread_lock_callbacks']]], + ['free_5fcondition_1195',['free_condition',['../structevthread__condition__callbacks.html#af20b2614116b6ac43f3e25012a792575',1,'evthread_condition_callbacks']]] +]; diff --git a/search/variables_3.html b/search/variables_3.html new file mode 100644 index 0000000..19a31fc --- /dev/null +++ b/search/variables_3.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/variables_3.js b/search/variables_3.js new file mode 100644 index 0000000..bbde013 --- /dev/null +++ b/search/variables_3.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['iov_5fbase_1196',['iov_base',['../structevbuffer__iovec.html#a1ce384c93f7554ab94f5dccdab8b4e13',1,'evbuffer_iovec']]], + ['iov_5flen_1197',['iov_len',['../structevbuffer__iovec.html#a0b1981aa931c720e63238022d74c0ac1',1,'evbuffer_iovec']]] +]; diff --git a/search/variables_4.html b/search/variables_4.html new file mode 100644 index 0000000..bdc37be --- /dev/null +++ b/search/variables_4.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/variables_4.js b/search/variables_4.js new file mode 100644 index 0000000..140d5a9 --- /dev/null +++ b/search/variables_4.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['lock_1198',['lock',['../structevthread__lock__callbacks.html#a1eb04c0bb0cf9dba264d1b5ed7c9e025',1,'evthread_lock_callbacks']]], + ['lock_5fapi_5fversion_1199',['lock_api_version',['../structevthread__lock__callbacks.html#afe0e286cfffd238f4891bdb431c79eb9',1,'evthread_lock_callbacks']]] +]; diff --git a/search/variables_5.html b/search/variables_5.html new file mode 100644 index 0000000..6aa2249 --- /dev/null +++ b/search/variables_5.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/variables_5.js b/search/variables_5.js new file mode 100644 index 0000000..fd3be7c --- /dev/null +++ b/search/variables_5.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['n_5fadded_1200',['n_added',['../structevbuffer__cb__info.html#a8191bbc06e291543359428daace6bae6',1,'evbuffer_cb_info']]], + ['n_5fdeleted_1201',['n_deleted',['../structevbuffer__cb__info.html#a7d1a674e020d2eee72538b0221dc32a4',1,'evbuffer_cb_info']]] +]; diff --git a/search/variables_6.html b/search/variables_6.html new file mode 100644 index 0000000..ce4a906 --- /dev/null +++ b/search/variables_6.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/variables_6.js b/search/variables_6.js new file mode 100644 index 0000000..5cacc71 --- /dev/null +++ b/search/variables_6.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['orig_5fsize_1202',['orig_size',['../structevbuffer__cb__info.html#a18e973448576100923328e4de05ddef5',1,'evbuffer_cb_info']]] +]; diff --git a/search/variables_7.html b/search/variables_7.html new file mode 100644 index 0000000..39ffd47 --- /dev/null +++ b/search/variables_7.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/variables_7.js b/search/variables_7.js new file mode 100644 index 0000000..a6a0fa3 --- /dev/null +++ b/search/variables_7.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['signal_5fcondition_1203',['signal_condition',['../structevthread__condition__callbacks.html#a453762d49a8fbcbe0f36b34dae478e8e',1,'evthread_condition_callbacks']]], + ['supported_5flocktypes_1204',['supported_locktypes',['../structevthread__lock__callbacks.html#afebbd92f9fc12e5852b0c008b423f948',1,'evthread_lock_callbacks']]] +]; diff --git a/search/variables_8.html b/search/variables_8.html new file mode 100644 index 0000000..37a2edd --- /dev/null +++ b/search/variables_8.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/variables_8.js b/search/variables_8.js new file mode 100644 index 0000000..d12602c --- /dev/null +++ b/search/variables_8.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['unlock_1205',['unlock',['../structevthread__lock__callbacks.html#ae896047fcd1b4c5095d2b05a58e0a35d',1,'evthread_lock_callbacks']]] +]; diff --git a/search/variables_9.html b/search/variables_9.html new file mode 100644 index 0000000..21e5a4f --- /dev/null +++ b/search/variables_9.html @@ -0,0 +1,30 @@ + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/variables_9.js b/search/variables_9.js new file mode 100644 index 0000000..5f30739 --- /dev/null +++ b/search/variables_9.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['wait_5fcondition_1206',['wait_condition',['../structevthread__condition__callbacks.html#aa7963135768612f74dfa80f15b6c7260',1,'evthread_condition_callbacks']]] +]; diff --git a/splitbar.png b/splitbar.png new file mode 100644 index 0000000..fe895f2 Binary files /dev/null and b/splitbar.png differ diff --git a/structbufferevent.html b/structbufferevent.html new file mode 100644 index 0000000..73fda5b --- /dev/null +++ b/structbufferevent.html @@ -0,0 +1,89 @@ + + + + + + + +libevent: bufferevent Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    +
    +
    bufferevent Struct Reference
    +
    +
    + +

    An opaque type for handling buffered IO. + More...

    + +

    #include <bufferevent.h>

    +

    Detailed Description

    +

    An opaque type for handling buffered IO.

    +
    See also
    event2/bufferevent.h
    +

    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structevbuffer.html b/structevbuffer.html new file mode 100644 index 0000000..93c6c3d --- /dev/null +++ b/structevbuffer.html @@ -0,0 +1,89 @@ + + + + + + + +libevent: evbuffer Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    +
    +
    evbuffer Struct Reference
    +
    +
    + +

    An evbuffer is an opaque data type for efficiently buffering data to be sent or received on the network. + More...

    + +

    #include <buffer.h>

    +

    Detailed Description

    +

    An evbuffer is an opaque data type for efficiently buffering data to be sent or received on the network.

    +
    See also
    event2/event.h for more information
    +

    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structevbuffer__cb__info.html b/structevbuffer__cb__info.html new file mode 100644 index 0000000..26610c9 --- /dev/null +++ b/structevbuffer__cb__info.html @@ -0,0 +1,107 @@ + + + + + + + +libevent: evbuffer_cb_info Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    evbuffer_cb_info Struct Reference
    +
    +
    + +

    Structure passed to an evbuffer_cb_func evbuffer callback. + More...

    + +

    #include <buffer.h>

    + + + + + + + + + + + +

    +Data Fields

    +size_t n_added
     The number of bytes added since callbacks were last invoked.
     
    +size_t n_deleted
     The number of bytes removed since callbacks were last invoked.
     
    +size_t orig_size
     The number of bytes in this evbuffer when callbacks were last invoked.
     
    +

    Detailed Description

    +

    Structure passed to an evbuffer_cb_func evbuffer callback.

    +
    See also
    evbuffer_cb_func, evbuffer_add_cb()
    +

    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structevbuffer__iovec.html b/structevbuffer__iovec.html new file mode 100644 index 0000000..34eda95 --- /dev/null +++ b/structevbuffer__iovec.html @@ -0,0 +1,104 @@ + + + + + + + +libevent: evbuffer_iovec Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    evbuffer_iovec Struct Reference
    +
    +
    + +

    Describes a single extent of memory inside an evbuffer. + More...

    + +

    #include <buffer.h>

    + + + + + + + + +

    +Data Fields

    +void * iov_base
     The start of the extent of memory.
     
    +size_t iov_len
     The length of the extent of memory.
     
    +

    Detailed Description

    +

    Describes a single extent of memory inside an evbuffer.

    +

    Used for direct-access functions.

    +
    See also
    evbuffer_reserve_space, evbuffer_commit_space, evbuffer_peek
    +

    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structevbuffer__ptr.html b/structevbuffer__ptr.html new file mode 100644 index 0000000..0c64d74 --- /dev/null +++ b/structevbuffer__ptr.html @@ -0,0 +1,110 @@ + + + + + + + +libevent: evbuffer_ptr Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    evbuffer_ptr Struct Reference
    +
    +
    + +

    Pointer to a position within an evbuffer. + More...

    + +

    #include <buffer.h>

    + + + + + + + + + + + +

    +Data Fields

    +struct {
    +   void *   chain
     
    +   size_t   pos_in_chain
     
    internal_
     
    +ev_ssize_t pos
     
    +

    Detailed Description

    +

    Pointer to a position within an evbuffer.

    +

    Used when repeatedly searching through a buffer. Calling any function that modifies or re-packs the buffer contents may invalidate all evbuffer_ptrs for that buffer. Do not modify or construct these values except with evbuffer_ptr_set.

    +

    An evbuffer_ptr can represent any position from the start of a buffer up to a position immediately after the end of a buffer.

    +
    See also
    evbuffer_ptr_set()
    +

    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structevent.html b/structevent.html new file mode 100644 index 0000000..85ca7c0 --- /dev/null +++ b/structevent.html @@ -0,0 +1,98 @@ + + + + + + + +libevent: event Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    +
    +
    event Struct Reference
    +
    +
    + +

    Structure to represent a single event. + More...

    + +

    #include <event.h>

    +

    Detailed Description

    +

    Structure to represent a single event.

    +

    An event can have some underlying condition it represents: a socket becoming readable or writeable (or both), or a signal becoming raised. (An event that represents no underlying condition is still useful: you can use one to implement a timer, or to communicate between threads.)

    +

    Generally, you can create events with event_new(), then make them pending with event_add(). As your event_base runs, it will run the callbacks of an events whose conditions are triggered. When you no longer want the event, free it with event_free().

    +

    In more depth:

    +

    An event may be "pending" (one whose condition we are watching), "active" (one whose condition has triggered and whose callback is about to run), neither, or both. Events come into existence via event_assign() or event_new(), and are then neither active nor pending.

    +

    To make an event pending, pass it to event_add(). When doing so, you can also set a timeout for the event.

    +

    Events become active during an event_base_loop() call when either their condition has triggered, or when their timeout has elapsed. You can also activate an event manually using event_active(). The even_base loop will run the callbacks of active events; after it has done so, it marks them as no longer active.

    +

    You can make an event non-pending by passing it to event_del(). This also makes the event non-active.

    +

    Events can be "persistent" or "non-persistent". A non-persistent event becomes non-pending as soon as it is triggered: thus, it only runs at most once per call to event_add(). A persistent event remains pending even when it becomes active: you'll need to event_del() it manually in order to make it non-pending. When a persistent event with a timeout becomes active, its timeout is reset: this means you can use persistent events to implement periodic timeouts.

    +

    This should be treated as an opaque structure; you should never read or write any of its fields directly. For backward compatibility with old code, it is defined in the event2/event_struct.h header; including this header may make your code incompatible with other versions of Libevent.

    +
    See also
    event_new(), event_free(), event_assign(), event_get_assignment(), event_add(), event_del(), event_active(), event_pending(), event_get_fd(), event_get_base(), event_get_events(), event_get_callback(), event_get_callback_arg(), event_priority_set()
    +

    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structevent__base.html b/structevent__base.html new file mode 100644 index 0000000..fe19301 --- /dev/null +++ b/structevent__base.html @@ -0,0 +1,91 @@ + + + + + + + +libevent: event_base Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    +
    +
    event_base Struct Reference
    +
    +
    + +

    Structure to hold information and state for a Libevent dispatch loop. + More...

    + +

    #include <event.h>

    +

    Detailed Description

    +

    Structure to hold information and state for a Libevent dispatch loop.

    +

    The event_base lies at the center of Libevent; every application will have one. It keeps track of all pending and active events, and notifies your application of the active ones.

    +

    This is an opaque structure; you can allocate one using event_base_new() or event_base_new_with_config().

    +
    See also
    event_base_new(), event_base_free(), event_base_loop(), event_base_new_with_config()
    +

    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structevent__config.html b/structevent__config.html new file mode 100644 index 0000000..4f52e5f --- /dev/null +++ b/structevent__config.html @@ -0,0 +1,90 @@ + + + + + + + +libevent: event_config Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    +
    +
    event_config Struct Reference
    +
    +
    + +

    Configuration for an event_base. + More...

    + +

    #include <event.h>

    +

    Detailed Description

    +

    Configuration for an event_base.

    +

    There are many options that can be used to alter the behavior and implementation of an event_base. To avoid having to pass them all in a complex many-argument constructor, we provide an abstract data type where you set up configuration information before passing it to event_base_new_with_config().

    +
    See also
    event_config_new(), event_config_free(), event_base_new_with_config(), event_config_avoid_method(), event_config_require_features(), event_config_set_flag(), event_config_set_num_cpus_hint()
    +

    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structevhttp__ext__method.html b/structevhttp__ext__method.html new file mode 100644 index 0000000..efb2c9e --- /dev/null +++ b/structevhttp__ext__method.html @@ -0,0 +1,106 @@ + + + + + + + +libevent: evhttp_ext_method Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    evhttp_ext_method Struct Reference
    +
    +
    + +

    structure that is passed to (and modified by) the extended method callback function + More...

    + +

    #include <http.h>

    + + + + + + + + +

    +Data Fields

    +ev_uint16_t flags
     
    +const char * method
     
    +ev_uint32_t type
     
    +

    Detailed Description

    +

    structure that is passed to (and modified by) the extended method callback function

    +
    See also
    evhttp_set_ext_method_cmp
    +
    +evhttp_connection_set_ext_method_cmp
    +

    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structevthread__condition__callbacks.html b/structevthread__condition__callbacks.html new file mode 100644 index 0000000..3aef31e --- /dev/null +++ b/structevthread__condition__callbacks.html @@ -0,0 +1,181 @@ + + + + + + + +libevent: evthread_condition_callbacks Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    evthread_condition_callbacks Struct Reference
    +
    +
    + +

    This structure describes the interface a threading library uses for condition variables. + More...

    + +

    #include <thread.h>

    + + + + + + + + + + + + + + + + + +

    +Data Fields

    void *(* alloc_condition )(unsigned condtype)
     Function to allocate and initialize a new condition variable. More...
     
    int condition_api_version
     The current version of the conditions API. More...
     
    +void(* free_condition )(void *cond)
     Function to free a condition variable.
     
    int(* signal_condition )(void *cond, int broadcast)
     Function to signal a condition variable. More...
     
    int(* wait_condition )(void *cond, void *lock, const struct timeval *timeout)
     Function to wait for a condition variable. More...
     
    +

    Detailed Description

    +

    This structure describes the interface a threading library uses for condition variables.

    +

    It's used to tell evthread_set_condition_callbacks how to use locking on this platform.

    +

    Field Documentation

    + +

    ◆ alloc_condition

    + +
    +
    + + + + +
    void*(* evthread_condition_callbacks::alloc_condition) (unsigned condtype)
    +
    + +

    Function to allocate and initialize a new condition variable.

    +

    Returns the condition variable on success, and NULL on failure. The 'condtype' argument will be 0 with this API version.

    + +
    +
    + +

    ◆ condition_api_version

    + +
    +
    + + + + +
    int evthread_condition_callbacks::condition_api_version
    +
    + +

    The current version of the conditions API.

    +

    Set this to EVTHREAD_CONDITION_API_VERSION

    + +
    +
    + +

    ◆ signal_condition

    + +
    +
    + + + + +
    int(* evthread_condition_callbacks::signal_condition) (void *cond, int broadcast)
    +
    + +

    Function to signal a condition variable.

    +

    If 'broadcast' is 1, all threads waiting on 'cond' should be woken; otherwise, only on one thread is worken. Should return 0 on success, -1 on failure. This function will only be called while holding the associated lock for the condition.

    + +
    +
    + +

    ◆ wait_condition

    + +
    +
    + + + + +
    int(* evthread_condition_callbacks::wait_condition) (void *cond, void *lock, const struct timeval *timeout)
    +
    + +

    Function to wait for a condition variable.

    +

    The lock 'lock' will be held when this function is called; should be released while waiting for the condition to be come signalled, and should be held again when this function returns. If timeout is provided, it is interval of seconds to wait for the event to become signalled; if it is NULL, the function should wait indefinitely.

    +

    The function should return -1 on error; 0 if the condition was signalled, or 1 on a timeout.

    + +
    +
    +
    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structevthread__lock__callbacks.html b/structevthread__lock__callbacks.html new file mode 100644 index 0000000..a6c5393 --- /dev/null +++ b/structevthread__lock__callbacks.html @@ -0,0 +1,200 @@ + + + + + + + +libevent: evthread_lock_callbacks Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    evthread_lock_callbacks Struct Reference
    +
    +
    + +

    This structure describes the interface a threading library uses for locking. + More...

    + +

    #include <thread.h>

    + + + + + + + + + + + + + + + + + + + + +

    +Data Fields

    void *(* alloc )(unsigned locktype)
     Function to allocate and initialize new lock of type 'locktype'. More...
     
    +void(* free )(void *lock, unsigned locktype)
     Function to release all storage held in 'lock', which was created with type 'locktype'.
     
    int(* lock )(unsigned mode, void *lock)
     Acquire an already-allocated lock at 'lock' with mode 'mode'. More...
     
    int lock_api_version
     The current version of the locking API. More...
     
    unsigned supported_locktypes
     Which kinds of locks does this version of the locking API support? A bitfield of EVTHREAD_LOCKTYPE_RECURSIVE and EVTHREAD_LOCKTYPE_READWRITE. More...
     
    int(* unlock )(unsigned mode, void *lock)
     Release a lock at 'lock' using mode 'mode'. More...
     
    +

    Detailed Description

    +

    This structure describes the interface a threading library uses for locking.

    +

    It's used to tell evthread_set_lock_callbacks() how to use locking on this platform.

    +

    Field Documentation

    + +

    ◆ alloc

    + +
    +
    + + + + +
    void*(* evthread_lock_callbacks::alloc) (unsigned locktype)
    +
    + +

    Function to allocate and initialize new lock of type 'locktype'.

    +

    Returns NULL on failure.

    + +
    +
    + +

    ◆ lock

    + +
    +
    + + + + +
    int(* evthread_lock_callbacks::lock) (unsigned mode, void *lock)
    +
    + +

    Acquire an already-allocated lock at 'lock' with mode 'mode'.

    +

    Returns 0 on success, and nonzero on failure.

    + +
    +
    + +

    ◆ lock_api_version

    + +
    +
    + + + + +
    int evthread_lock_callbacks::lock_api_version
    +
    + +

    The current version of the locking API.

    +

    Set this to EVTHREAD_LOCK_API_VERSION

    + +
    +
    + +

    ◆ supported_locktypes

    + +
    +
    + + + + +
    unsigned evthread_lock_callbacks::supported_locktypes
    +
    + +

    Which kinds of locks does this version of the locking API support? A bitfield of EVTHREAD_LOCKTYPE_RECURSIVE and EVTHREAD_LOCKTYPE_READWRITE.

    +

    (Note that RECURSIVE locks are currently mandatory, and READWRITE locks are not currently used.)

    + +
    +
    + +

    ◆ unlock

    + +
    +
    + + + + +
    int(* evthread_lock_callbacks::unlock) (unsigned mode, void *lock)
    +
    + +

    Release a lock at 'lock' using mode 'mode'.

    +

    Returns 0 on success, and nonzero on failure.

    + +
    +
    +
    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structevutil__addrinfo.html b/structevutil__addrinfo.html new file mode 100644 index 0000000..8d3d220 --- /dev/null +++ b/structevutil__addrinfo.html @@ -0,0 +1,119 @@ + + + + + + + +libevent: evutil_addrinfo Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    evutil_addrinfo Struct Reference
    +
    +
    + +

    A definition of struct addrinfo for systems that lack it. + More...

    + +

    #include <util.h>

    + + + + + + + + + + + + + + + + + + +

    +Data Fields

    +struct sockaddr * ai_addr
     
    +size_t ai_addrlen
     
    +char * ai_canonname
     
    +int ai_family
     
    +int ai_flags
     
    +struct evutil_addrinfoai_next
     
    +int ai_protocol
     
    +int ai_socktype
     
    +

    Detailed Description

    +

    A definition of struct addrinfo for systems that lack it.

    +

    (This is just an alias for struct addrinfo if the system defines struct addrinfo.)

    +

    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structevutil__monotonic__timer.html b/structevutil__monotonic__timer.html new file mode 100644 index 0000000..e87a5bb --- /dev/null +++ b/structevutil__monotonic__timer.html @@ -0,0 +1,91 @@ + + + + + + + +libevent: evutil_monotonic_timer Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    +
    +
    evutil_monotonic_timer Struct Reference
    +
    +
    + +

    Structure to hold information about a monotonic timer. + More...

    + +

    #include <util.h>

    +

    Detailed Description

    +

    Structure to hold information about a monotonic timer.

    +

    Use this with evutil_configure_monotonic_time() and evutil_gettime_monotonic().

    +

    This is an opaque structure; you can allocate one using evutil_monotonic_timer_new().

    +
    See also
    evutil_monotonic_timer_new(), evutil_monotonic_timer_free(), evutil_configure_monotonic_time(), evutil_gettime_monotonic()
    +

    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/sync_off.png b/sync_off.png new file mode 100644 index 0000000..3b443fc Binary files /dev/null and b/sync_off.png differ diff --git a/sync_on.png b/sync_on.png new file mode 100644 index 0000000..e08320f Binary files /dev/null and b/sync_on.png differ diff --git a/tab_a.png b/tab_a.png new file mode 100644 index 0000000..3b725c4 Binary files /dev/null and b/tab_a.png differ diff --git a/tab_b.png b/tab_b.png new file mode 100644 index 0000000..e2b4a86 Binary files /dev/null and b/tab_b.png differ diff --git a/tab_h.png b/tab_h.png new file mode 100644 index 0000000..fd5cb70 Binary files /dev/null and b/tab_h.png differ diff --git a/tab_s.png b/tab_s.png new file mode 100644 index 0000000..ab478c9 Binary files /dev/null and b/tab_s.png differ diff --git a/tabs.css b/tabs.css new file mode 100644 index 0000000..7d45d36 --- /dev/null +++ b/tabs.css @@ -0,0 +1 @@ +.sm{position:relative;z-index:9999}.sm,.sm ul,.sm li{display:block;list-style:none;margin:0;padding:0;line-height:normal;direction:ltr;text-align:left;-webkit-tap-highlight-color:rgba(0,0,0,0)}.sm-rtl,.sm-rtl ul,.sm-rtl li{direction:rtl;text-align:right}.sm>li>h1,.sm>li>h2,.sm>li>h3,.sm>li>h4,.sm>li>h5,.sm>li>h6{margin:0;padding:0}.sm ul{display:none}.sm li,.sm a{position:relative}.sm a{display:block}.sm a.disabled{cursor:not-allowed}.sm:after{content:"\00a0";display:block;height:0;font:0px/0 serif;clear:both;visibility:hidden;overflow:hidden}.sm,.sm *,.sm *:before,.sm *:after{-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box}.sm-dox{background-image:url("tab_b.png")}.sm-dox a,.sm-dox a:focus,.sm-dox a:hover,.sm-dox a:active{padding:0px 12px;padding-right:43px;font-family:"Lucida Grande","Geneva","Helvetica",Arial,sans-serif;font-size:13px;font-weight:bold;line-height:36px;text-decoration:none;text-shadow:0px 1px 1px rgba(255,255,255,0.9);color:#283A5D;outline:none}.sm-dox a:hover{background-image:url("tab_a.png");background-repeat:repeat-x;color:#fff;text-shadow:0px 1px 1px #000}.sm-dox a.current{color:#D23600}.sm-dox a.disabled{color:#bbb}.sm-dox a span.sub-arrow{position:absolute;top:50%;margin-top:-14px;left:auto;right:3px;width:28px;height:28px;overflow:hidden;font:bold 12px/28px monospace !important;text-align:center;text-shadow:none;background:rgba(255,255,255,0.5);border-radius:5px}.sm-dox a.highlighted span.sub-arrow:before{display:block;content:'-'}.sm-dox>li:first-child>a,.sm-dox>li:first-child>:not(ul) a{border-radius:5px 5px 0 0}.sm-dox>li:last-child>a,.sm-dox>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul{border-radius:0 0 5px 5px}.sm-dox>li:last-child>a.highlighted,.sm-dox>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted{border-radius:0}.sm-dox ul{background:rgba(162,162,162,0.1)}.sm-dox ul a,.sm-dox ul a:focus,.sm-dox ul a:hover,.sm-dox ul a:active{font-size:12px;border-left:8px solid transparent;line-height:36px;text-shadow:none;background-color:white;background-image:none}.sm-dox ul a:hover{background-image:url("tab_a.png");background-repeat:repeat-x;color:#fff;text-shadow:0px 1px 1px #000}.sm-dox ul ul a,.sm-dox ul ul a:hover,.sm-dox ul ul a:focus,.sm-dox ul ul a:active{border-left:16px solid transparent}.sm-dox ul ul ul a,.sm-dox ul ul ul a:hover,.sm-dox ul ul ul a:focus,.sm-dox ul ul ul a:active{border-left:24px solid transparent}.sm-dox ul ul ul ul a,.sm-dox ul ul ul ul a:hover,.sm-dox ul ul ul ul a:focus,.sm-dox ul ul ul ul a:active{border-left:32px solid transparent}.sm-dox ul ul ul ul ul a,.sm-dox ul ul ul ul ul a:hover,.sm-dox ul ul ul ul ul a:focus,.sm-dox ul ul ul ul ul a:active{border-left:40px solid transparent}@media (min-width: 768px){.sm-dox ul{position:absolute;width:12em}.sm-dox li{float:left}.sm-dox.sm-rtl li{float:right}.sm-dox ul li,.sm-dox.sm-rtl ul li,.sm-dox.sm-vertical li{float:none}.sm-dox a{white-space:nowrap}.sm-dox ul a,.sm-dox.sm-vertical a{white-space:normal}.sm-dox .sm-nowrap>li>a,.sm-dox .sm-nowrap>li>:not(ul) a{white-space:nowrap}.sm-dox{padding:0 10px;background-image:url("tab_b.png");line-height:36px}.sm-dox a span.sub-arrow{top:50%;margin-top:-2px;right:12px;width:0;height:0;border-width:4px;border-style:solid dashed dashed dashed;border-color:#283A5D transparent transparent transparent;background:transparent;border-radius:0}.sm-dox a,.sm-dox a:focus,.sm-dox a:active,.sm-dox a:hover,.sm-dox a.highlighted{padding:0px 12px;background-image:url("tab_s.png");background-repeat:no-repeat;background-position:right;border-radius:0 !important}.sm-dox a:hover{background-image:url("tab_a.png");background-repeat:repeat-x;color:#fff;text-shadow:0px 1px 1px #000}.sm-dox a:hover span.sub-arrow{border-color:#fff transparent transparent transparent}.sm-dox a.has-submenu{padding-right:24px}.sm-dox li{border-top:0}.sm-dox>li>ul:before,.sm-dox>li>ul:after{content:'';position:absolute;top:-18px;left:30px;width:0;height:0;overflow:hidden;border-width:9px;border-style:dashed dashed solid dashed;border-color:transparent transparent #bbb transparent}.sm-dox>li>ul:after{top:-16px;left:31px;border-width:8px;border-color:transparent transparent #fff transparent}.sm-dox ul{border:1px solid #bbb;padding:5px 0;background:#fff;border-radius:5px !important;box-shadow:0 5px 9px rgba(0,0,0,0.2)}.sm-dox ul a span.sub-arrow{right:8px;top:50%;margin-top:-5px;border-width:5px;border-color:transparent transparent transparent #555;border-style:dashed dashed dashed solid}.sm-dox ul a,.sm-dox ul a:hover,.sm-dox ul a:focus,.sm-dox ul a:active,.sm-dox ul a.highlighted{color:#555;background-image:none;border:0 !important;color:#555;background-image:none}.sm-dox ul a:hover{background-image:url("tab_a.png");background-repeat:repeat-x;color:#fff;text-shadow:0px 1px 1px #000}.sm-dox ul a:hover span.sub-arrow{border-color:transparent transparent transparent #fff}.sm-dox span.scroll-up,.sm-dox span.scroll-down{position:absolute;display:none;visibility:hidden;overflow:hidden;background:#fff;height:36px}.sm-dox span.scroll-up:hover,.sm-dox span.scroll-down:hover{background:#eee}.sm-dox span.scroll-up:hover span.scroll-up-arrow,.sm-dox span.scroll-up:hover span.scroll-down-arrow{border-color:transparent transparent #D23600 transparent}.sm-dox span.scroll-down:hover span.scroll-down-arrow{border-color:#D23600 transparent transparent transparent}.sm-dox span.scroll-up-arrow,.sm-dox span.scroll-down-arrow{position:absolute;top:0;left:50%;margin-left:-6px;width:0;height:0;overflow:hidden;border-width:6px;border-style:dashed dashed solid dashed;border-color:transparent transparent #555 transparent}.sm-dox span.scroll-down-arrow{top:8px;border-style:solid dashed dashed dashed;border-color:#555 transparent transparent transparent}.sm-dox.sm-rtl a.has-submenu{padding-right:12px;padding-left:24px}.sm-dox.sm-rtl a span.sub-arrow{right:auto;left:12px}.sm-dox.sm-rtl.sm-vertical a.has-submenu{padding:10px 20px}.sm-dox.sm-rtl.sm-vertical a span.sub-arrow{right:auto;left:8px;border-style:dashed solid dashed dashed;border-color:transparent #555 transparent transparent}.sm-dox.sm-rtl>li>ul:before{left:auto;right:30px}.sm-dox.sm-rtl>li>ul:after{left:auto;right:31px}.sm-dox.sm-rtl ul a.has-submenu{padding:10px 20px !important}.sm-dox.sm-rtl ul a span.sub-arrow{right:auto;left:8px;border-style:dashed solid dashed dashed;border-color:transparent #555 transparent transparent}.sm-dox.sm-vertical{padding:10px 0;border-radius:5px}.sm-dox.sm-vertical a{padding:10px 20px}.sm-dox.sm-vertical a:hover,.sm-dox.sm-vertical a:focus,.sm-dox.sm-vertical a:active,.sm-dox.sm-vertical a.highlighted{background:#fff}.sm-dox.sm-vertical a.disabled{background-image:url("tab_b.png")}.sm-dox.sm-vertical a span.sub-arrow{right:8px;top:50%;margin-top:-5px;border-width:5px;border-style:dashed dashed dashed solid;border-color:transparent transparent transparent #555}.sm-dox.sm-vertical>li>ul:before,.sm-dox.sm-vertical>li>ul:after{display:none}.sm-dox.sm-vertical ul a{padding:10px 20px}.sm-dox.sm-vertical ul a:hover,.sm-dox.sm-vertical ul a:focus,.sm-dox.sm-vertical ul a:active,.sm-dox.sm-vertical ul a.highlighted{background:#eee}.sm-dox.sm-vertical ul a.disabled{background:#fff}} diff --git a/tag_8h.html b/tag_8h.html new file mode 100644 index 0000000..b05987a --- /dev/null +++ b/tag_8h.html @@ -0,0 +1,235 @@ + + + + + + + +libevent: event2/tag.h File Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    + +
    +
    tag.h File Reference
    +
    +
    + +

    Helper functions for reading and writing tagged data onto buffers. +More...

    +
    #include <event2/visibility.h>
    +#include <event2/event-config.h>
    +#include <event2/util.h>
    +
    +

    Go to the source code of this file.

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +Functions

    +EVENT2_EXPORT_SYMBOL int evtag_consume (struct evbuffer *evbuf)
     
    EVENT2_EXPORT_SYMBOL void evtag_encode_int (struct evbuffer *evbuf, ev_uint32_t number)
     Encode an integer and store it in an evbuffer. More...
     
    +EVENT2_EXPORT_SYMBOL void evtag_encode_int64 (struct evbuffer *evbuf, ev_uint64_t number)
     
    +EVENT2_EXPORT_SYMBOL void evtag_init (void)
     
    +EVENT2_EXPORT_SYMBOL void evtag_marshal (struct evbuffer *evbuf, ev_uint32_t tag, const void *data, ev_uint32_t len)
     
    +EVENT2_EXPORT_SYMBOL void evtag_marshal_buffer (struct evbuffer *evbuf, ev_uint32_t tag, struct evbuffer *data)
     
    +EVENT2_EXPORT_SYMBOL void evtag_marshal_int (struct evbuffer *evbuf, ev_uint32_t tag, ev_uint32_t integer)
     
    +EVENT2_EXPORT_SYMBOL void evtag_marshal_int64 (struct evbuffer *evbuf, ev_uint32_t tag, ev_uint64_t integer)
     
    +EVENT2_EXPORT_SYMBOL void evtag_marshal_string (struct evbuffer *buf, ev_uint32_t tag, const char *string)
     
    +EVENT2_EXPORT_SYMBOL void evtag_marshal_timeval (struct evbuffer *evbuf, ev_uint32_t tag, struct timeval *tv)
     
    +EVENT2_EXPORT_SYMBOL int evtag_payload_length (struct evbuffer *evbuf, ev_uint32_t *plength)
     
    +EVENT2_EXPORT_SYMBOL int evtag_peek (struct evbuffer *evbuf, ev_uint32_t *ptag)
     
    +EVENT2_EXPORT_SYMBOL int evtag_peek_length (struct evbuffer *evbuf, ev_uint32_t *plength)
     
    +EVENT2_EXPORT_SYMBOL int evtag_unmarshal (struct evbuffer *src, ev_uint32_t *ptag, struct evbuffer *dst)
     
    +EVENT2_EXPORT_SYMBOL int evtag_unmarshal_fixed (struct evbuffer *src, ev_uint32_t need_tag, void *data, size_t len)
     
    EVENT2_EXPORT_SYMBOL int evtag_unmarshal_header (struct evbuffer *evbuf, ev_uint32_t *ptag)
     Unmarshals the header and returns the length of the payload. More...
     
    +EVENT2_EXPORT_SYMBOL int evtag_unmarshal_int (struct evbuffer *evbuf, ev_uint32_t need_tag, ev_uint32_t *pinteger)
     
    +EVENT2_EXPORT_SYMBOL int evtag_unmarshal_int64 (struct evbuffer *evbuf, ev_uint32_t need_tag, ev_uint64_t *pinteger)
     
    +EVENT2_EXPORT_SYMBOL int evtag_unmarshal_string (struct evbuffer *evbuf, ev_uint32_t need_tag, char **pstring)
     
    +EVENT2_EXPORT_SYMBOL int evtag_unmarshal_timeval (struct evbuffer *evbuf, ev_uint32_t need_tag, struct timeval *ptv)
     
    +

    Detailed Description

    +

    Helper functions for reading and writing tagged data onto buffers.

    +

    Function Documentation

    + +

    ◆ evtag_encode_int()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL void evtag_encode_int (struct evbufferevbuf,
    ev_uint32_t number 
    )
    +
    + +

    Encode an integer and store it in an evbuffer.

    +

    We encode integers by nybbles; the first nibble contains the number of significant nibbles - 1; this allows us to encode up to 64-bit integers. This function is byte-order independent.

    +
    Parameters
    + + + +
    evbufevbuffer to store the encoded number
    numbera 32-bit integer
    +
    +
    + +
    +
    + +

    ◆ evtag_unmarshal_header()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evtag_unmarshal_header (struct evbufferevbuf,
    ev_uint32_t * ptag 
    )
    +
    + +

    Unmarshals the header and returns the length of the payload.

    +
    Parameters
    + + + +
    evbufthe buffer from which to unmarshal data
    ptaga pointer in which the tag id is being stored
    +
    +
    +
    Returns
    -1 on failure or the number of bytes in the remaining payload.
    + +
    +
    +
    + + + + diff --git a/tag_8h_source.html b/tag_8h_source.html new file mode 100644 index 0000000..9124199 --- /dev/null +++ b/tag_8h_source.html @@ -0,0 +1,209 @@ + + + + + + + +libevent: event2/tag.h Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    tag.h
    +
    +
    +Go to the documentation of this file.
    1 /*
    +
    2  * Copyright (c) 2000-2007 Niels Provos <provos@citi.umich.edu>
    +
    3  * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson
    +
    4  *
    +
    5  * Redistribution and use in source and binary forms, with or without
    +
    6  * modification, are permitted provided that the following conditions
    +
    7  * are met:
    +
    8  * 1. Redistributions of source code must retain the above copyright
    +
    9  * notice, this list of conditions and the following disclaimer.
    +
    10  * 2. Redistributions in binary form must reproduce the above copyright
    +
    11  * notice, this list of conditions and the following disclaimer in the
    +
    12  * documentation and/or other materials provided with the distribution.
    +
    13  * 3. The name of the author may not be used to endorse or promote products
    +
    14  * derived from this software without specific prior written permission.
    +
    15  *
    +
    16  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
    +
    17  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
    +
    18  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
    +
    19  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
    +
    20  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
    +
    21  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
    +
    22  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
    +
    23  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
    +
    24  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
    +
    25  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
    +
    26  */
    +
    27 #ifndef EVENT2_TAG_H_INCLUDED_
    +
    28 #define EVENT2_TAG_H_INCLUDED_
    +
    29 
    +
    36 #include <event2/visibility.h>
    +
    37 
    +
    38 #ifdef __cplusplus
    +
    39 extern "C" {
    +
    40 #endif
    +
    41 
    +
    42 #include <event2/event-config.h>
    +
    43 #ifdef EVENT__HAVE_SYS_TYPES_H
    +
    44 #include <sys/types.h>
    +
    45 #endif
    +
    46 #ifdef EVENT__HAVE_SYS_TIME_H
    +
    47 #include <sys/time.h>
    +
    48 #endif
    +
    49 
    +
    50 /* For int types. */
    +
    51 #include <event2/util.h>
    +
    52 
    +
    53 struct evbuffer;
    +
    54 
    +
    55 /*
    +
    56  * Marshaling tagged data - We assume that all tags are inserted in their
    +
    57  * numeric order - so that unknown tags will always be higher than the
    +
    58  * known ones - and we can just ignore the end of an event buffer.
    +
    59  */
    +
    60 
    +
    61 EVENT2_EXPORT_SYMBOL
    +
    62 void evtag_init(void);
    +
    63 
    +
    71 EVENT2_EXPORT_SYMBOL
    +
    72 int evtag_unmarshal_header(struct evbuffer *evbuf, ev_uint32_t *ptag);
    +
    73 
    +
    74 EVENT2_EXPORT_SYMBOL
    +
    75 void evtag_marshal(struct evbuffer *evbuf, ev_uint32_t tag, const void *data,
    +
    76  ev_uint32_t len);
    +
    77 EVENT2_EXPORT_SYMBOL
    +
    78 void evtag_marshal_buffer(struct evbuffer *evbuf, ev_uint32_t tag,
    +
    79  struct evbuffer *data);
    +
    80 
    +
    91 EVENT2_EXPORT_SYMBOL
    +
    92 void evtag_encode_int(struct evbuffer *evbuf, ev_uint32_t number);
    +
    93 EVENT2_EXPORT_SYMBOL
    +
    94 void evtag_encode_int64(struct evbuffer *evbuf, ev_uint64_t number);
    +
    95 
    +
    96 EVENT2_EXPORT_SYMBOL
    +
    97 void evtag_marshal_int(struct evbuffer *evbuf, ev_uint32_t tag,
    +
    98  ev_uint32_t integer);
    +
    99 EVENT2_EXPORT_SYMBOL
    +
    100 void evtag_marshal_int64(struct evbuffer *evbuf, ev_uint32_t tag,
    +
    101  ev_uint64_t integer);
    +
    102 
    +
    103 EVENT2_EXPORT_SYMBOL
    +
    104 void evtag_marshal_string(struct evbuffer *buf, ev_uint32_t tag,
    +
    105  const char *string);
    +
    106 
    +
    107 EVENT2_EXPORT_SYMBOL
    +
    108 void evtag_marshal_timeval(struct evbuffer *evbuf, ev_uint32_t tag,
    +
    109  struct timeval *tv);
    +
    110 
    +
    111 EVENT2_EXPORT_SYMBOL
    +
    112 int evtag_unmarshal(struct evbuffer *src, ev_uint32_t *ptag,
    +
    113  struct evbuffer *dst);
    +
    114 EVENT2_EXPORT_SYMBOL
    +
    115 int evtag_peek(struct evbuffer *evbuf, ev_uint32_t *ptag);
    +
    116 EVENT2_EXPORT_SYMBOL
    +
    117 int evtag_peek_length(struct evbuffer *evbuf, ev_uint32_t *plength);
    +
    118 EVENT2_EXPORT_SYMBOL
    +
    119 int evtag_payload_length(struct evbuffer *evbuf, ev_uint32_t *plength);
    +
    120 EVENT2_EXPORT_SYMBOL
    +
    121 int evtag_consume(struct evbuffer *evbuf);
    +
    122 
    +
    123 EVENT2_EXPORT_SYMBOL
    +
    124 int evtag_unmarshal_int(struct evbuffer *evbuf, ev_uint32_t need_tag,
    +
    125  ev_uint32_t *pinteger);
    +
    126 EVENT2_EXPORT_SYMBOL
    +
    127 int evtag_unmarshal_int64(struct evbuffer *evbuf, ev_uint32_t need_tag,
    +
    128  ev_uint64_t *pinteger);
    +
    129 
    +
    130 EVENT2_EXPORT_SYMBOL
    +
    131 int evtag_unmarshal_fixed(struct evbuffer *src, ev_uint32_t need_tag,
    +
    132  void *data, size_t len);
    +
    133 
    +
    134 EVENT2_EXPORT_SYMBOL
    +
    135 int evtag_unmarshal_string(struct evbuffer *evbuf, ev_uint32_t need_tag,
    +
    136  char **pstring);
    +
    137 
    +
    138 EVENT2_EXPORT_SYMBOL
    +
    139 int evtag_unmarshal_timeval(struct evbuffer *evbuf, ev_uint32_t need_tag,
    +
    140  struct timeval *ptv);
    +
    141 
    +
    142 #ifdef __cplusplus
    +
    143 }
    +
    144 #endif
    +
    145 
    +
    146 #endif /* EVENT2_TAG_H_INCLUDED_ */
    +
    +
    EVENT2_EXPORT_SYMBOL int evtag_unmarshal_header(struct evbuffer *evbuf, ev_uint32_t *ptag)
    Unmarshals the header and returns the length of the payload.
    +
    An evbuffer is an opaque data type for efficiently buffering data to be sent or received on the netwo...
    Definition: buffer.h:97
    +
    EVENT2_EXPORT_SYMBOL void evtag_encode_int(struct evbuffer *evbuf, ev_uint32_t number)
    Encode an integer and store it in an evbuffer.
    +
    Common convenience functions for cross-platform portability and related socket manipulations.
    + + + + diff --git a/tag__compat_8h.html b/tag__compat_8h.html new file mode 100644 index 0000000..0895fbf --- /dev/null +++ b/tag__compat_8h.html @@ -0,0 +1,103 @@ + + + + + + + +libevent: event2/tag_compat.h File Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    tag_compat.h File Reference
    +
    +
    + +

    Obsolete/deprecated functions from tag.h; provided only for backwards compatibility. +More...

    + +

    Go to the source code of this file.

    + + + + + + + + +

    +Macros

    Misnamed functions
    Deprecated:
    These macros are deprecated because their names don't follow Libevent's naming conventions.
    +

    Use evtag_encode_int and evtag_encode_int64 instead.

    +
    +#define encode_int(evbuf, number)   evtag_encode_int((evbuf), (number))
     
    +#define encode_int64(evbuf, number)   evtag_encode_int64((evbuf), (number))
     
    +

    Detailed Description

    +

    Obsolete/deprecated functions from tag.h; provided only for backwards compatibility.

    +
    + + + + diff --git a/tag__compat_8h_source.html b/tag__compat_8h_source.html new file mode 100644 index 0000000..5eff396 --- /dev/null +++ b/tag__compat_8h_source.html @@ -0,0 +1,115 @@ + + + + + + + +libevent: event2/tag_compat.h Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    tag_compat.h
    +
    +
    +Go to the documentation of this file.
    1 /*
    +
    2  * Copyright (c) 2000-2007 Niels Provos <provos@citi.umich.edu>
    +
    3  * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson
    +
    4  *
    +
    5  * Redistribution and use in source and binary forms, with or without
    +
    6  * modification, are permitted provided that the following conditions
    +
    7  * are met:
    +
    8  * 1. Redistributions of source code must retain the above copyright
    +
    9  * notice, this list of conditions and the following disclaimer.
    +
    10  * 2. Redistributions in binary form must reproduce the above copyright
    +
    11  * notice, this list of conditions and the following disclaimer in the
    +
    12  * documentation and/or other materials provided with the distribution.
    +
    13  * 3. The name of the author may not be used to endorse or promote products
    +
    14  * derived from this software without specific prior written permission.
    +
    15  *
    +
    16  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
    +
    17  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
    +
    18  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
    +
    19  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
    +
    20  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
    +
    21  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
    +
    22  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
    +
    23  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
    +
    24  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
    +
    25  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
    +
    26  */
    +
    27 #ifndef EVENT2_TAG_COMPAT_H_INCLUDED_
    +
    28 #define EVENT2_TAG_COMPAT_H_INCLUDED_
    +
    29 
    +
    45 #define encode_int(evbuf, number) evtag_encode_int((evbuf), (number))
    +
    46 #define encode_int64(evbuf, number) evtag_encode_int64((evbuf), (number))
    +
    47 
    +
    49 #endif /* EVENT2_TAG_H_INCLUDED_ */
    +
    + + + + diff --git a/thread_8h.html b/thread_8h.html new file mode 100644 index 0000000..329c0d1 --- /dev/null +++ b/thread_8h.html @@ -0,0 +1,384 @@ + + + + + + + +libevent: event2/thread.h File Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    + +
    +
    thread.h File Reference
    +
    +
    + +

    Functions for multi-threaded applications using Libevent. +More...

    +
    #include <event2/visibility.h>
    +#include <event2/event-config.h>
    +
    +

    Go to the source code of this file.

    + + + + + + + + +

    +Data Structures

    struct  evthread_condition_callbacks
     This structure describes the interface a threading library uses for condition variables. More...
     
    struct  evthread_lock_callbacks
     This structure describes the interface a threading library uses for locking. More...
     
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +Macros

    +#define EVTHREAD_CONDITION_API_VERSION   1
     
    +#define EVTHREAD_LOCK_API_VERSION   1
     
    +#define EVTHREAD_PTHREAD_PRIO_INHERIT   0x01
     
    +#define EVTHREAD_USE_PTHREADS_IMPLEMENTED   1
     Defined if Libevent was built with support for evthread_use_pthreads()
     
    +#define EVTHREAD_USE_WINDOWS_THREADS_IMPLEMENTED   1
     Defined if Libevent was built with support for evthread_use_windows_threads()
     
    Flags passed to lock functions
    +#define EVTHREAD_READ   0x08
     A flag passed to a locking callback when the lock was allocated as a read-write lock, and we want to acquire or release the lock for reading.
     
    +#define EVTHREAD_TRY   0x10
     A flag passed to a locking callback when we don't want to block waiting for the lock; if we can't get the lock immediately, we will instead return nonzero from the locking callback.
     
    +#define EVTHREAD_WRITE   0x04
     A flag passed to a locking callback when the lock was allocated as a read-write lock, and we want to acquire or release the lock for writing.
     
    Types of locks
    +#define EVTHREAD_LOCKTYPE_READWRITE   2
     
    #define EVTHREAD_LOCKTYPE_RECURSIVE   1
     A recursive lock is one that can be acquired multiple times at once by the same thread. More...
     
    + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +Functions

    EVENT2_EXPORT_SYMBOL void evthread_enable_lock_debugging (void)
     Enable debugging wrappers around the current lock callbacks. More...
     
    +EVENT2_EXPORT_SYMBOL void evthread_enable_lock_debuging (void)
     
    EVENT2_EXPORT_SYMBOL int evthread_make_base_notifiable (struct event_base *base)
     Make sure it's safe to tell an event base to wake up from another thread or a signal handler. More...
     
    EVENT2_EXPORT_SYMBOL int evthread_set_condition_callbacks (const struct evthread_condition_callbacks *)
     Sets a group of functions that Libevent should use for condition variables. More...
     
    EVENT2_EXPORT_SYMBOL void evthread_set_id_callback (unsigned long(*id_fn)(void))
     Sets the function for determining the thread id. More...
     
    EVENT2_EXPORT_SYMBOL int evthread_set_lock_callbacks (const struct evthread_lock_callbacks *)
     Sets a group of functions that Libevent should use for locking. More...
     
    EVENT2_EXPORT_SYMBOL int evthread_use_pthreads (void)
     Sets up Libevent for use with Pthreads locking and thread ID functions. More...
     
    EVENT2_EXPORT_SYMBOL int evthread_use_pthreads_with_flags (int flags)
     Sets up Libevent for use with Pthreads locking and thread ID functions. More...
     
    EVENT2_EXPORT_SYMBOL int evthread_use_windows_threads (void)
     Sets up Libevent for use with Windows builtin locking and thread ID functions. More...
     
    +

    Detailed Description

    +

    Functions for multi-threaded applications using Libevent.

    +

    When using a multi-threaded application in which multiple threads add and delete events from a single event base, Libevent needs to lock its data structures.

    +

    Like the memory-management function hooks, all of the threading functions must be set up before an event_base is created if you want the base to use them.

    +

    Most programs will either be using Windows threads or Posix threads. You can configure Libevent to use one of these evthread_use_windows_threads() or evthread_use_pthreads() respectively. If you're using another threading library, you'll need to configure threading functions manually using evthread_set_lock_callbacks() and evthread_set_condition_callbacks().

    +

    Macro Definition Documentation

    + +

    ◆ EVTHREAD_LOCKTYPE_RECURSIVE

    + +
    +
    + + + + +
    #define EVTHREAD_LOCKTYPE_RECURSIVE   1
    +
    + +

    A recursive lock is one that can be acquired multiple times at once by the same thread.

    +

    No other process can allocate the lock until the thread that has been holding it has unlocked it as many times as it locked it.

    + +
    +
    +

    Function Documentation

    + +

    ◆ evthread_enable_lock_debugging()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL void evthread_enable_lock_debugging (void )
    +
    + +

    Enable debugging wrappers around the current lock callbacks.

    +

    If Libevent makes one of several common locking errors, exit with an assertion failure.

    +

    If you're going to call this function, you must do so before any locks are allocated.

    + +
    +
    + +

    ◆ evthread_make_base_notifiable()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evthread_make_base_notifiable (struct event_basebase)
    +
    + +

    Make sure it's safe to tell an event base to wake up from another thread or a signal handler.

    +

    You shouldn't need to call this by hand; configuring the base with thread support should be necessary and sufficient.

    +
    Returns
    0 on success, -1 on failure.
    + +
    +
    + +

    ◆ evthread_set_condition_callbacks()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evthread_set_condition_callbacks (const struct evthread_condition_callbacks)
    +
    + +

    Sets a group of functions that Libevent should use for condition variables.

    +

    For full information on the required callback API, see the documentation for the individual members of evthread_condition_callbacks.

    +

    Note that if you're using Windows or the Pthreads threading library, you probably shouldn't call this function; instead, use evthread_use_windows_threads() or evthread_use_pthreads() if you can.

    + +
    +
    + +

    ◆ evthread_set_id_callback()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL void evthread_set_id_callback (unsigned long(*)(void) id_fn)
    +
    + +

    Sets the function for determining the thread id.

    +
    Parameters
    + + +
    id_fnthe identify function Libevent should invoke to determine the identity of a thread.
    +
    +
    + +
    +
    + +

    ◆ evthread_set_lock_callbacks()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evthread_set_lock_callbacks (const struct evthread_lock_callbacks)
    +
    + +

    Sets a group of functions that Libevent should use for locking.

    +

    For full information on the required callback API, see the documentation for the individual members of evthread_lock_callbacks.

    +

    Note that if you're using Windows or the Pthreads threading library, you probably shouldn't call this function; instead, use evthread_use_windows_threads() or evthread_use_posix_threads() if you can.

    + +
    +
    + +

    ◆ evthread_use_pthreads()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evthread_use_pthreads (void )
    +
    + +

    Sets up Libevent for use with Pthreads locking and thread ID functions.

    +

    Unavailable if Libevent is not build for use with pthreads. Requires libraries to link against Libevent_pthreads as well as Libevent.

    +
    Returns
    0 on success, -1 on failure.
    + +
    +
    + +

    ◆ evthread_use_pthreads_with_flags()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evthread_use_pthreads_with_flags (int flags)
    +
    + +

    Sets up Libevent for use with Pthreads locking and thread ID functions.

    +

    Use evthread_use_pthreads_with_flags() to use Pthreads locking, taking the specified flags under consideration.

    +
    Parameters
    + + +
    flagsthe flags to apply when setting up Pthreads locking.
    +
    +
    +
    See also
    EVTHREAD_PTHREAD_*
    +
    Returns
    0 on success, -1 on failure.
    + +
    +
    + +

    ◆ evthread_use_windows_threads()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evthread_use_windows_threads (void )
    +
    + +

    Sets up Libevent for use with Windows builtin locking and thread ID functions.

    +

    Unavailable if Libevent is not built for Windows.

    +
    Returns
    0 on success, -1 on failure.
    + +
    +
    +
    + + + + diff --git a/thread_8h_source.html b/thread_8h_source.html new file mode 100644 index 0000000..b29c792 --- /dev/null +++ b/thread_8h_source.html @@ -0,0 +1,228 @@ + + + + + + + +libevent: event2/thread.h Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    thread.h
    +
    +
    +Go to the documentation of this file.
    1 /*
    +
    2  * Copyright (c) 2008-2012 Niels Provos and Nick Mathewson
    +
    3  *
    +
    4  * Redistribution and use in source and binary forms, with or without
    +
    5  * modification, are permitted provided that the following conditions
    +
    6  * are met:
    +
    7  * 1. Redistributions of source code must retain the above copyright
    +
    8  * notice, this list of conditions and the following disclaimer.
    +
    9  * 2. Redistributions in binary form must reproduce the above copyright
    +
    10  * notice, this list of conditions and the following disclaimer in the
    +
    11  * documentation and/or other materials provided with the distribution.
    +
    12  * 3. The name of the author may not be used to endorse or promote products
    +
    13  * derived from this software without specific prior written permission.
    +
    14  *
    +
    15  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
    +
    16  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
    +
    17  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
    +
    18  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
    +
    19  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
    +
    20  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
    +
    21  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
    +
    22  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
    +
    23  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
    +
    24  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
    +
    25  */
    +
    26 #ifndef EVENT2_THREAD_H_INCLUDED_
    +
    27 #define EVENT2_THREAD_H_INCLUDED_
    +
    28 
    +
    49 #include <event2/visibility.h>
    +
    50 
    +
    51 #ifdef __cplusplus
    +
    52 extern "C" {
    +
    53 #endif
    +
    54 
    +
    55 #include <event2/event-config.h>
    +
    56 
    +
    64 #define EVTHREAD_WRITE 0x04
    +
    65 
    +
    67 #define EVTHREAD_READ 0x08
    +
    68 
    +
    71 #define EVTHREAD_TRY 0x10
    +
    72 
    +
    74 #if !defined(EVENT__DISABLE_THREAD_SUPPORT) || defined(EVENT_IN_DOXYGEN_)
    +
    75 
    +
    76 #define EVTHREAD_LOCK_API_VERSION 1
    +
    77 
    +
    85 #define EVTHREAD_LOCKTYPE_RECURSIVE 1
    +
    86 /* A read-write lock is one that allows multiple simultaneous readers, but
    +
    87  * where any one writer excludes all other writers and readers. */
    +
    88 #define EVTHREAD_LOCKTYPE_READWRITE 2
    +
    89 
    + + + +
    109  void *(*alloc)(unsigned locktype);
    +
    112  void (*free)(void *lock, unsigned locktype);
    +
    115  int (*lock)(unsigned mode, void *lock);
    +
    118  int (*unlock)(unsigned mode, void *lock);
    +
    119 };
    +
    120 
    +
    129 EVENT2_EXPORT_SYMBOL
    + +
    131 
    +
    132 #define EVTHREAD_CONDITION_API_VERSION 1
    +
    133 
    +
    134 struct timeval;
    +
    135 
    + + +
    148  void *(*alloc_condition)(unsigned condtype);
    +
    150  void (*free_condition)(void *cond);
    +
    157  int (*signal_condition)(void *cond, int broadcast);
    +
    168  int (*wait_condition)(void *cond, void *lock,
    +
    169  const struct timeval *timeout);
    +
    170 };
    +
    171 
    +
    180 EVENT2_EXPORT_SYMBOL
    + +
    182  const struct evthread_condition_callbacks *);
    +
    183 
    +
    190 EVENT2_EXPORT_SYMBOL
    + +
    192  unsigned long (*id_fn)(void));
    +
    193 
    +
    194 #if (defined(_WIN32) && !defined(EVENT__DISABLE_THREAD_SUPPORT)) || defined(EVENT_IN_DOXYGEN_)
    +
    195 
    +
    199 EVENT2_EXPORT_SYMBOL
    + +
    204 #define EVTHREAD_USE_WINDOWS_THREADS_IMPLEMENTED 1
    +
    205 #endif
    +
    206 
    +
    207 #if defined(EVENT__HAVE_PTHREADS) || defined(EVENT_IN_DOXYGEN_)
    +
    208 
    +
    213 EVENT2_EXPORT_SYMBOL
    +
    214 int evthread_use_pthreads(void);
    +
    215 
    +
    216 /* Enables posix mutex priority inheritance
    +
    217  * (if pthread_mutexattr_setprotocol() is supported). */
    +
    218 #define EVTHREAD_PTHREAD_PRIO_INHERIT 0x01
    +
    219 
    +
    228 EVENT2_EXPORT_SYMBOL
    +
    229 int evthread_use_pthreads_with_flags(int flags);
    +
    230 
    +
    232 #define EVTHREAD_USE_PTHREADS_IMPLEMENTED 1
    +
    233 
    +
    234 #endif
    +
    235 
    +
    242 EVENT2_EXPORT_SYMBOL
    + +
    244 
    +
    245 /* Old (misspelled) version: This is deprecated; use
    +
    246  * evthread_enable_log_debugging instead. */
    +
    247 EVENT2_EXPORT_SYMBOL
    +
    248 void evthread_enable_lock_debuging(void);
    +
    249 
    +
    250 #endif /* EVENT__DISABLE_THREAD_SUPPORT */
    +
    251 
    +
    252 struct event_base;
    +
    261 EVENT2_EXPORT_SYMBOL
    +
    262 int evthread_make_base_notifiable(struct event_base *base);
    +
    263 
    +
    264 #ifdef __cplusplus
    +
    265 }
    +
    266 #endif
    +
    267 
    +
    268 #endif /* EVENT2_THREAD_H_INCLUDED_ */
    +
    +
    EVENT2_EXPORT_SYMBOL int evthread_set_lock_callbacks(const struct evthread_lock_callbacks *)
    Sets a group of functions that Libevent should use for locking.
    +
    EVENT2_EXPORT_SYMBOL void evthread_enable_lock_debugging(void)
    Enable debugging wrappers around the current lock callbacks.
    +
    This structure describes the interface a threading library uses for condition variables.
    Definition: thread.h:140
    +
    EVENT2_EXPORT_SYMBOL void evthread_set_id_callback(unsigned long(*id_fn)(void))
    Sets the function for determining the thread id.
    +
    int lock_api_version
    The current version of the locking API.
    Definition: thread.h:98
    +
    int(* lock)(unsigned mode, void *lock)
    Acquire an already-allocated lock at 'lock' with mode 'mode'.
    Definition: thread.h:115
    +
    Structure to hold information and state for a Libevent dispatch loop.
    Definition: event.h:219
    +
    int(* signal_condition)(void *cond, int broadcast)
    Function to signal a condition variable.
    Definition: thread.h:157
    +
    unsigned supported_locktypes
    Which kinds of locks does this version of the locking API support? A bitfield of EVTHREAD_LOCKTYPE_RE...
    Definition: thread.h:106
    +
    EVENT2_EXPORT_SYMBOL int evthread_set_condition_callbacks(const struct evthread_condition_callbacks *)
    Sets a group of functions that Libevent should use for condition variables.
    +
    int(* wait_condition)(void *cond, void *lock, const struct timeval *timeout)
    Function to wait for a condition variable.
    Definition: thread.h:168
    +
    int(* unlock)(unsigned mode, void *lock)
    Release a lock at 'lock' using mode 'mode'.
    Definition: thread.h:118
    +
    EVENT2_EXPORT_SYMBOL int evthread_use_pthreads_with_flags(int flags)
    Sets up Libevent for use with Pthreads locking and thread ID functions.
    +
    This structure describes the interface a threading library uses for locking.
    Definition: thread.h:95
    +
    void(* free_condition)(void *cond)
    Function to free a condition variable.
    Definition: thread.h:150
    +
    int condition_api_version
    The current version of the conditions API.
    Definition: thread.h:143
    +
    EVENT2_EXPORT_SYMBOL int evthread_use_pthreads(void)
    Sets up Libevent for use with Pthreads locking and thread ID functions.
    +
    void(* free)(void *lock, unsigned locktype)
    Function to release all storage held in 'lock', which was created with type 'locktype'.
    Definition: thread.h:112
    +
    EVENT2_EXPORT_SYMBOL int evthread_make_base_notifiable(struct event_base *base)
    Make sure it's safe to tell an event base to wake up from another thread or a signal handler.
    +
    EVENT2_EXPORT_SYMBOL int evthread_use_windows_threads(void)
    Sets up Libevent for use with Windows builtin locking and thread ID functions.
    + + + + diff --git a/util_8h.html b/util_8h.html new file mode 100644 index 0000000..832274e --- /dev/null +++ b/util_8h.html @@ -0,0 +1,1490 @@ + + + + + + + +libevent: event2/util.h File Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    + +
    +
    util.h File Reference
    +
    +
    + +

    Common convenience functions for cross-platform portability and related socket manipulations. +More...

    +
    #include <event2/visibility.h>
    +#include <event2/event-config.h>
    +#include <stdarg.h>
    +#include <sys/socket.h>
    +#include <time.h>
    +
    +

    Go to the source code of this file.

    + + + + + + + + +

    +Data Structures

    struct  evutil_addrinfo
     A definition of struct addrinfo for systems that lack it. More...
     
    struct  evutil_monotonic_timer
     Structure to hold information about a monotonic timer. More...
     
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +Macros

    +#define EV_MONOT_FALLBACK   2
     
    +#define EV_MONOT_PRECISE   1
     
    +#define ev_socklen_t   socklen_t
     
    +#define EVUTIL_CLOSESOCKET(s)   evutil_closesocket(s)
     
    +#define evutil_offsetof(type, field)   ((off_t)(&((type *)0)->field))
     Replacement for offsetof on platforms that don't define it.
     
    #define evutil_socket_t   int
     A type wide enough to hold the output of "socket()" or "accept()". More...
     
    #define evutil_timercmp(tvp, uvp, cmp)
     Return true iff the tvp is related to uvp according to the relational operator cmp. More...
     
    +#define evutil_timerisset(tvp)   ((tvp)->tv_sec || (tvp)->tv_usec)
     
    Standard integer types.

    Integer type definitions for types that are supposed to be defined in the C99-specified stdint.h.

    +

    Shamefully, some platforms do not include stdint.h, so we need to replace it. (If you are on a platform like this, your C headers are now over 10 years out of date. You should bug them to do something about this.)

    +

    We define:

    +
    +
    ev_uint64_t, ev_uint32_t, ev_uint16_t, ev_uint8_t
    +
    unsigned integer types of exactly 64, 32, 16, and 8 bits respectively.
    +
    ev_int64_t, ev_int32_t, ev_int16_t, ev_int8_t
    +
    signed integer types of exactly 64, 32, 16, and 8 bits respectively.
    +
    ev_uintptr_t, ev_intptr_t
    +
    unsigned/signed integers large enough to hold a pointer without loss of bits.
    +
    ev_ssize_t
    +
    A signed type of the same size as size_t
    +
    ev_off_t
    +
    A signed type typically used to represent offsets within a (potentially large) file
    +
    +
    +#define ev_int16_t   ...
     
    +#define ev_int32_t   ...
     
    +#define ev_int64_t   ...
     
    +#define ev_int8_t   ...
     
    +#define ev_intptr_t   ev_int32_t
     
    +#define ev_off_t   ...
     
    +#define ev_ssize_t   ssize_t
     
    +#define ev_uint16_t   ...
     
    +#define ev_uint32_t   ...
     
    +#define ev_uint64_t   ...
     
    +#define ev_uint8_t   ...
     
    +#define ev_uintptr_t   ev_uint32_t
     
    Limits for integer types

    These macros hold the largest or smallest values possible for the ev_[u]int*_t types.

    +
    +#define EV_INT16_MAX   ((ev_int16_t) 0x7fffL)
     
    +#define EV_INT16_MIN   ((-EV_INT16_MAX) - 1)
     
    +#define EV_INT32_MAX   ((ev_int32_t) 0x7fffffffL)
     
    +#define EV_INT32_MIN   ((-EV_INT32_MAX) - 1)
     
    +#define EV_INT64_MAX   ((((ev_int64_t) 0x7fffffffL) << 32) | 0xffffffffL)
     
    +#define EV_INT64_MIN   ((-EV_INT64_MAX) - 1)
     
    +#define EV_INT8_MAX   127
     
    +#define EV_INT8_MIN   ((-EV_INT8_MAX) - 1)
     
    +#define EV_UINT16_MAX   ((ev_uint16_t)0xffffUL)
     
    +#define EV_UINT32_MAX   ((ev_uint32_t)0xffffffffUL)
     
    +#define EV_UINT64_MAX   ((((ev_uint64_t)0xffffffffUL) << 32) | 0xffffffffUL)
     
    +#define EV_UINT8_MAX   255
     
    Limits for SIZE_T and SSIZE_T
    +#define EV_SIZE_MAX   ...
     
    +#define EV_SSIZE_MAX   ...
     
    +#define EV_SSIZE_MIN   ((-EV_SSIZE_MAX) - 1)
     
    Socket error functions

    These functions are needed for making programs compatible between Windows and Unix-like platforms.

    +

    You see, Winsock handles socket errors differently from the rest of the world. Elsewhere, a socket error is like any other error and is stored in errno. But winsock functions require you to retrieve the error with a special function, and don't let you use strerror for the error codes. And handling EWOULDBLOCK is ... different.

    +
    +#define EVUTIL_INVALID_SOCKET   -1
     
    +#define EVUTIL_SET_SOCKET_ERROR(errcode)   ...
     Replace the most recent socket error with errcode.
     
    #define EVUTIL_SOCKET_ERROR()   ...
     Return the most recent socket error. More...
     
    +#define evutil_socket_error_to_string(errcode)   ...
     Convert a socket error to a string.
     
    +#define evutil_socket_geterror(sock)   ...
     Return the most recent socket error to occur on sock.
     
    Manipulation macros for struct timeval.

    We define replacements for timeradd, timersub, timerclear, timercmp, and timerisset.

    +
    #define evutil_timeradd(tvp, uvp, vvp)
     
    +#define evutil_timerclear(tvp)   (tvp)->tv_sec = (tvp)->tv_usec = 0
     
    #define evutil_timersub(tvp, uvp, vvp)
     
    evutil_getaddrinfo() error codes

    These values are possible error codes for evutil_getaddrinfo() and related functions.

    +
    +#define EVUTIL_AI_ADDRCONFIG   0x40000
     
    +#define EVUTIL_AI_ALL   0x20000
     
    +#define EVUTIL_AI_CANONNAME   0x2000
     
    +#define EVUTIL_AI_NUMERICHOST   0x4000
     
    +#define EVUTIL_AI_NUMERICSERV   0x8000
     
    +#define EVUTIL_AI_PASSIVE   0x1000
     
    +#define EVUTIL_AI_V4MAPPED   0x10000
     
    +#define EVUTIL_EAI_ADDRFAMILY   -901
     
    +#define EVUTIL_EAI_AGAIN   -902
     
    +#define EVUTIL_EAI_BADFLAGS   -903
     
    +#define EVUTIL_EAI_CANCEL   -90001
     
    +#define EVUTIL_EAI_FAIL   -904
     
    +#define EVUTIL_EAI_FAMILY   -905
     
    +#define EVUTIL_EAI_MEMORY   -906
     
    +#define EVUTIL_EAI_NODATA   -907
     
    +#define EVUTIL_EAI_NONAME   -908
     
    +#define EVUTIL_EAI_SERVICE   -909
     
    +#define EVUTIL_EAI_SOCKTYPE   -910
     
    +#define EVUTIL_EAI_SYSTEM   -911
     
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +Functions

    EVENT2_EXPORT_SYMBOL int evutil_ascii_strcasecmp (const char *str1, const char *str2)
     As strcasecmp, but always compares the characters in locale-independent ASCII. More...
     
    EVENT2_EXPORT_SYMBOL int evutil_ascii_strncasecmp (const char *str1, const char *str2, size_t n)
     As strncasecmp, but always compares the characters in locale-independent ASCII. More...
     
    EVENT2_EXPORT_SYMBOL int evutil_closesocket (evutil_socket_t sock)
     Do the platform-specific call needed to close a socket returned from socket() or accept(). More...
     
    +EVENT2_EXPORT_SYMBOL int evutil_configure_monotonic_time (struct evutil_monotonic_timer *timer, int flags)
     Set up a struct evutil_monotonic_timer; flags can include EV_MONOT_PRECISE and EV_MONOT_FALLBACK.
     
    EVENT2_EXPORT_SYMBOL int evutil_date_rfc1123 (char *date, const size_t datelen, const struct tm *tm)
     Format a date string using RFC 1123 format (used in HTTP). More...
     
    +EVENT2_EXPORT_SYMBOL void evutil_freeaddrinfo (struct evutil_addrinfo *ai)
     Release storage allocated by evutil_getaddrinfo or evdns_getaddrinfo.
     
    +const EVENT2_EXPORT_SYMBOL char * evutil_gai_strerror (int err)
     
    EVENT2_EXPORT_SYMBOL int evutil_getaddrinfo (const char *nodename, const char *servname, const struct evutil_addrinfo *hints_in, struct evutil_addrinfo **res)
     This function clones getaddrinfo for systems that don't have it. More...
     
    EVENT2_EXPORT_SYMBOL int evutil_gettime_monotonic (struct evutil_monotonic_timer *timer, struct timeval *tp)
     Query the current monotonic time from a struct evutil_monotonic_timer previously configured with evutil_configure_monotonic_time(). More...
     
    +EVENT2_EXPORT_SYMBOL int evutil_gettimeofday (struct timeval *tv, struct timezone *tz)
     
    const EVENT2_EXPORT_SYMBOL char * evutil_inet_ntop (int af, const void *src, char *dst, size_t len)
     Replacement for inet_ntop for platforms which lack it. More...
     
    EVENT2_EXPORT_SYMBOL int evutil_inet_pton (int af, const char *src, void *dst)
     Replacement for inet_pton for platforms which lack it. More...
     
    EVENT2_EXPORT_SYMBOL int evutil_inet_pton_scope (int af, const char *src, void *dst, unsigned *indexp)
     Variation of inet_pton that also parses IPv6 scopes. More...
     
    EVENT2_EXPORT_SYMBOL int evutil_make_listen_socket_ipv6only (evutil_socket_t sock)
     Set ipv6 only bind socket option to make listener work only in ipv6 sockets. More...
     
    EVENT2_EXPORT_SYMBOL int evutil_make_listen_socket_not_ipv6only (evutil_socket_t sock)
     Set ipv6 only bind socket option to make listener work in both ipv4 and ipv6 sockets. More...
     
    EVENT2_EXPORT_SYMBOL int evutil_make_listen_socket_reuseable (evutil_socket_t sock)
     Do platform-specific operations to make a listener socket reusable. More...
     
    EVENT2_EXPORT_SYMBOL int evutil_make_listen_socket_reuseable_port (evutil_socket_t sock)
     Do platform-specific operations to make a listener port reusable. More...
     
    EVENT2_EXPORT_SYMBOL int evutil_make_socket_closeonexec (evutil_socket_t sock)
     Do platform-specific operations as needed to close a socket upon a successful execution of one of the exec*() functions. More...
     
    EVENT2_EXPORT_SYMBOL int evutil_make_socket_nonblocking (evutil_socket_t sock)
     Do platform-specific operations as needed to make a socket nonblocking. More...
     
    EVENT2_EXPORT_SYMBOL int evutil_make_tcp_listen_socket_deferred (evutil_socket_t sock)
     Do platform-specific operations, if possible, to make a tcp listener socket defer accept()s until there is data to read. More...
     
    +EVENT2_EXPORT_SYMBOL void evutil_monotonic_timer_free (struct evutil_monotonic_timer *timer)
     Free a struct evutil_monotonic_timer that was allocated using evutil_monotonic_timer_new().
     
    EVENT2_EXPORT_SYMBOL struct evutil_monotonic_timerevutil_monotonic_timer_new (void)
     Allocate a new struct evutil_monotonic_timer for use with the evutil_configure_monotonic_time() and evutil_gettime_monotonic() functions. More...
     
    EVENT2_EXPORT_SYMBOL int evutil_parse_sockaddr_port (const char *str, struct sockaddr *out, int *outlen)
     Parse an IPv4 or IPv6 address, with optional port, from a string. More...
     
    EVENT2_EXPORT_SYMBOL void evutil_secure_rng_add_bytes (const char *dat, size_t datlen)
     Seed the random number generator with extra random bytes. More...
     
    EVENT2_EXPORT_SYMBOL void evutil_secure_rng_get_bytes (void *buf, size_t n)
     Generate n bytes of secure pseudorandom data, and store them in buf. More...
     
    EVENT2_EXPORT_SYMBOL int evutil_secure_rng_init (void)
     Seed the secure random number generator if needed, and return 0 on success or -1 on failure. More...
     
    EVENT2_EXPORT_SYMBOL int evutil_secure_rng_set_urandom_device_file (char *fname)
     Set a filename to use in place of /dev/urandom for seeding the secure PRNG. More...
     
    EVENT2_EXPORT_SYMBOL int evutil_set_tcp_keepalive (evutil_socket_t sock, int on, int timeout)
     Do platform-specific operations to set/unset TCP keep-alive options TCP_KEEPIDLE, TCP_KEEPINTVL and TCP_KEEPCNT on a socket. More...
     
    +EVENT2_EXPORT_SYMBOL int evutil_snprintf (char *buf, size_t buflen, const char *format,...)
     Replacement for snprintf to get consistent behavior on platforms for which the return value of snprintf does not conform to C99.
     
    EVENT2_EXPORT_SYMBOL int evutil_sockaddr_cmp (const struct sockaddr *sa1, const struct sockaddr *sa2, int include_port)
     Compare two sockaddrs; return 0 if they are equal, or less than 0 if sa1 preceeds sa2, or greater than 0 if sa1 follows sa2. More...
     
    EVENT2_EXPORT_SYMBOL int evutil_socketpair (int domain, int type, int protocol, evutil_socket_t sv[2])
     Create two new sockets that are connected to each other. More...
     
    EVENT2_EXPORT_SYMBOL ev_int64_t evutil_strtoll (const char *s, char **endptr, int base)
     Parse a 64-bit value from a string. More...
     
    +EVENT2_EXPORT_SYMBOL int evutil_vsnprintf (char *buf, size_t buflen, const char *format, va_list ap)
     Replacement for vsnprintf to get consistent behavior on platforms for which the return value of snprintf does not conform to C99.
     
    +

    Detailed Description

    +

    Common convenience functions for cross-platform portability and related socket manipulations.

    +

    Macro Definition Documentation

    + +

    ◆ EVUTIL_SOCKET_ERROR

    + +
    +
    + + + + + + + +
    #define EVUTIL_SOCKET_ERROR()   ...
    +
    + +

    Return the most recent socket error.

    +

    Not idempotent on all platforms.

    + +
    +
    + +

    ◆ evutil_socket_t

    + +
    +
    + + + + +
    #define evutil_socket_t   int
    +
    + +

    A type wide enough to hold the output of "socket()" or "accept()".

    +

    On Windows, this is an intptr_t; elsewhere, it is an int.

    + +
    +
    + +

    ◆ evutil_timeradd

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    #define evutil_timeradd( tvp,
     uvp,
     vvp 
    )
    +
    +Value:
    do { \
    +
    (vvp)->tv_sec = (tvp)->tv_sec + (uvp)->tv_sec; \
    +
    (vvp)->tv_usec = (tvp)->tv_usec + (uvp)->tv_usec; \
    +
    if ((vvp)->tv_usec >= 1000000) { \
    +
    (vvp)->tv_sec++; \
    +
    (vvp)->tv_usec -= 1000000; \
    +
    } \
    +
    } while (0)
    +
    +
    +
    + +

    ◆ evutil_timercmp

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    #define evutil_timercmp( tvp,
     uvp,
     cmp 
    )
    +
    +Value:
    (((tvp)->tv_sec == (uvp)->tv_sec) ? \
    +
    ((tvp)->tv_usec cmp (uvp)->tv_usec) : \
    +
    ((tvp)->tv_sec cmp (uvp)->tv_sec))
    +
    +

    Return true iff the tvp is related to uvp according to the relational operator cmp.

    +

    Recognized values for cmp are ==, <=, <, >=, and >.

    + +
    +
    + +

    ◆ evutil_timersub

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    #define evutil_timersub( tvp,
     uvp,
     vvp 
    )
    +
    +Value:
    do { \
    +
    (vvp)->tv_sec = (tvp)->tv_sec - (uvp)->tv_sec; \
    +
    (vvp)->tv_usec = (tvp)->tv_usec - (uvp)->tv_usec; \
    +
    if ((vvp)->tv_usec < 0) { \
    +
    (vvp)->tv_sec--; \
    +
    (vvp)->tv_usec += 1000000; \
    +
    } \
    +
    } while (0)
    +
    +
    +
    +

    Function Documentation

    + +

    ◆ evutil_ascii_strcasecmp()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_ascii_strcasecmp (const char * str1,
    const char * str2 
    )
    +
    + +

    As strcasecmp, but always compares the characters in locale-independent ASCII.

    +

    That's useful if you're handling data in ASCII-based protocols. str1 and str2 must not be NULL.

    + +
    +
    + +

    ◆ evutil_ascii_strncasecmp()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_ascii_strncasecmp (const char * str1,
    const char * str2,
    size_t n 
    )
    +
    + +

    As strncasecmp, but always compares the characters in locale-independent ASCII.

    +

    That's useful if you're handling data in ASCII-based protocols.

    + +
    +
    + +

    ◆ evutil_closesocket()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_closesocket (evutil_socket_t sock)
    +
    + +

    Do the platform-specific call needed to close a socket returned from socket() or accept().

    +
    Parameters
    + + +
    sockThe socket to be closed
    +
    +
    +
    Returns
    0 on success (whether the operation is supported or not), -1 on failure
    + +
    +
    + +

    ◆ evutil_date_rfc1123()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_date_rfc1123 (char * date,
    const size_t datelen,
    const struct tm * tm 
    )
    +
    + +

    Format a date string using RFC 1123 format (used in HTTP).

    +

    If tm is NULL, current system's time will be used. The number of characters written will be returned. One should check if the return value is smaller than datelen to check if the result is truncated or not.

    + +
    +
    + +

    ◆ evutil_getaddrinfo()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_getaddrinfo (const char * nodename,
    const char * servname,
    const struct evutil_addrinfohints_in,
    struct evutil_addrinfo ** res 
    )
    +
    + +

    This function clones getaddrinfo for systems that don't have it.

    +

    For full details, see RFC 3493, section 6.1.

    +

    Limitations:

      +
    • When the system has no getaddrinfo, we fall back to gethostbyname_r or gethostbyname, with their attendant issues.
    • +
    • The AI_V4MAPPED and AI_ALL flags are not currently implemented.
    • +
    +

    For a nonblocking variant, see evdns_getaddrinfo.

    + +
    +
    + +

    ◆ evutil_gettime_monotonic()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_gettime_monotonic (struct evutil_monotonic_timertimer,
    struct timeval * tp 
    )
    +
    + +

    Query the current monotonic time from a struct evutil_monotonic_timer previously configured with evutil_configure_monotonic_time().

    +

    Monotonic time is guaranteed never to run in reverse, but is not necessarily epoch- based, or relative to any other definite point. Use it to make reliable measurements of elapsed time between events even when the system time may be changed.

    +

    It is not safe to use this function on the same timer from multiple threads.

    + +
    +
    + +

    ◆ evutil_inet_ntop()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    const EVENT2_EXPORT_SYMBOL char* evutil_inet_ntop (int af,
    const void * src,
    char * dst,
    size_t len 
    )
    +
    + +

    Replacement for inet_ntop for platforms which lack it.

    +

    src must not be NULL.

    + +
    +
    + +

    ◆ evutil_inet_pton()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_inet_pton (int af,
    const char * src,
    void * dst 
    )
    +
    + +

    Replacement for inet_pton for platforms which lack it.

    +

    src must not be NULL.

    + +
    +
    + +

    ◆ evutil_inet_pton_scope()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_inet_pton_scope (int af,
    const char * src,
    void * dst,
    unsigned * indexp 
    )
    +
    + +

    Variation of inet_pton that also parses IPv6 scopes.

    +

    Public for unit tests. No reason to call this directly.

    + +
    +
    + +

    ◆ evutil_make_listen_socket_ipv6only()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_make_listen_socket_ipv6only (evutil_socket_t sock)
    +
    + +

    Set ipv6 only bind socket option to make listener work only in ipv6 sockets.

    +

    According to RFC3493 and most Linux distributions, default value for the sockets is to work in IPv4-mapped mode. In IPv4-mapped mode, it is not possible to bind same port from different IPv4 and IPv6 handlers.

    +

    On Windows the default value is instead to only work in IPv6 mode.

    +
    Parameters
    + + +
    sockThe socket to make in ipv6only working mode
    +
    +
    +
    Returns
    0 on success, -1 on failure
    + +
    +
    + +

    ◆ evutil_make_listen_socket_not_ipv6only()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_make_listen_socket_not_ipv6only (evutil_socket_t sock)
    +
    + +

    Set ipv6 only bind socket option to make listener work in both ipv4 and ipv6 sockets.

    +

    According to RFC3493 and most Linux distributions, default value for the sockets is to work in IPv4-mapped mode. In IPv4-mapped mode, it is not possible to bind same port from different IPv4 and IPv6 handlers.

    +

    On Windows the default value is instead to only work in IPv6 mode.

    +
    Parameters
    + + +
    sockThe socket to make in ipv6only working mode
    +
    +
    +
    Returns
    0 on success, -1 on failure
    + +
    +
    + +

    ◆ evutil_make_listen_socket_reuseable()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_make_listen_socket_reuseable (evutil_socket_t sock)
    +
    + +

    Do platform-specific operations to make a listener socket reusable.

    +

    Specifically, we want to make sure that another program will be able to bind this address right after we've closed the listener.

    +

    This differs from Windows's interpretation of "reusable", which allows multiple listeners to bind the same address at the same time.

    +
    Parameters
    + + +
    sockThe socket to make reusable
    +
    +
    +
    Returns
    0 on success, -1 on failure
    + +
    +
    + +

    ◆ evutil_make_listen_socket_reuseable_port()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_make_listen_socket_reuseable_port (evutil_socket_t sock)
    +
    + +

    Do platform-specific operations to make a listener port reusable.

    +

    Specifically, we want to make sure that multiple programs that also set the same socket option will be able to bind, and listen at the same time, for incoming connections/datagrams to be distributed evenly across all of the threads (or processes).

    +

    This feature is available only on Linux 3.9+, DragonFlyBSD 3.6+, FreeBSD 12.0+, Solaris 11.4, AIX 7.2.5 for now.

    +
    Parameters
    + + +
    sockThe socket to make reusable
    +
    +
    +
    Returns
    0 on success, -1 on failure
    + +
    +
    + +

    ◆ evutil_make_socket_closeonexec()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_make_socket_closeonexec (evutil_socket_t sock)
    +
    + +

    Do platform-specific operations as needed to close a socket upon a successful execution of one of the exec*() functions.

    +
    Parameters
    + + +
    sockThe socket to be closed
    +
    +
    +
    Returns
    0 on success, -1 on failure
    + +
    +
    + +

    ◆ evutil_make_socket_nonblocking()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_make_socket_nonblocking (evutil_socket_t sock)
    +
    + +

    Do platform-specific operations as needed to make a socket nonblocking.

    +
    Parameters
    + + +
    sockThe socket to make nonblocking
    +
    +
    +
    Returns
    0 on success, -1 on failure
    + +
    +
    + +

    ◆ evutil_make_tcp_listen_socket_deferred()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_make_tcp_listen_socket_deferred (evutil_socket_t sock)
    +
    + +

    Do platform-specific operations, if possible, to make a tcp listener socket defer accept()s until there is data to read.

    +

    Not all platforms support this. You don't want to do this for every listener socket: only the ones that implement a protocol where the client transmits before the server needs to respond.

    +
    Parameters
    + + +
    sockThe listening socket to make deferred
    +
    +
    +
    Returns
    0 on success (whether the operation is supported or not), -1 on failure
    + +
    +
    + +

    ◆ evutil_monotonic_timer_new()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL struct evutil_monotonic_timer* evutil_monotonic_timer_new (void )
    +
    + +

    Allocate a new struct evutil_monotonic_timer for use with the evutil_configure_monotonic_time() and evutil_gettime_monotonic() functions.

    +

    You must configure the timer with evutil_configure_monotonic_time() before using it.

    + +
    +
    + +

    ◆ evutil_parse_sockaddr_port()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_parse_sockaddr_port (const char * str,
    struct sockaddr * out,
    int * outlen 
    )
    +
    + +

    Parse an IPv4 or IPv6 address, with optional port, from a string.

    +

    Recognized formats are:

      +
    • "[IPv6Address]:port"
    • +
    • "[IPv6Address]"
    • +
    • "IPv6Address"
    • +
    • "IPv4Address:port"
    • +
    • "IPv4Address"
    • +
    +

    If no port is specified, the port in the output is set to 0.

    +
    Parameters
    + + + + +
    strThe string to parse.
    outA struct sockaddr to hold the result. This should probably be a struct sockaddr_storage.
    outlenA pointer to the number of bytes that that 'out' can safely hold. Set to the number of bytes used in 'out' on success.
    +
    +
    +
    Returns
    -1 if the address is not well-formed, if the port is out of range, or if out is not large enough to hold the result. Otherwise returns 0 on success.
    + +
    +
    + +

    ◆ evutil_secure_rng_add_bytes()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL void evutil_secure_rng_add_bytes (const char * dat,
    size_t datlen 
    )
    +
    + +

    Seed the random number generator with extra random bytes.

    +

    You should almost never need to call this function; it should be sufficient to invoke evutil_secure_rng_init(), or let Libevent take care of calling evutil_secure_rng_init() on its own.

    +

    If you call this function as a replacement for the regular entropy sources, then you need to be sure that your input contains a fairly large amount of strong entropy. Doing so is notoriously hard: most people who try get it wrong. Watch out!

    +

    This function does nothing when the system provides arc4random() function because it will provide proper entropy.

    +
    Parameters
    + + + +
    data buffer full of a strong source of random numbers
    datlenthe number of bytes to read from datlen
    +
    +
    + +
    +
    + +

    ◆ evutil_secure_rng_get_bytes()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL void evutil_secure_rng_get_bytes (void * buf,
    size_t n 
    )
    +
    + +

    Generate n bytes of secure pseudorandom data, and store them in buf.

    +

    Current versions of Libevent use an ARC4-based random number generator, seeded using the platform's entropy source (/dev/urandom on Unix-like systems; BCryptGenRandom on Windows). This is not actually as secure as it should be: ARC4 is a pretty lousy cipher, and the current implementation provides only rudimentary prediction- and backtracking-resistance. Don't use this for serious cryptographic applications.

    + +
    +
    + +

    ◆ evutil_secure_rng_init()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_secure_rng_init (void )
    +
    + +

    Seed the secure random number generator if needed, and return 0 on success or -1 on failure.

    +

    It is okay to call this function more than once; it will still return 0 if the RNG has been successfully seeded and -1 if it can't be seeded.

    +

    Ordinarily you don't need to call this function from your own code; Libevent will seed the RNG itself the first time it needs good random numbers. You only need to call it if (a) you want to double-check that one of the seeding methods did succeed, or (b) you plan to drop the capability to seed (by chrooting, or dropping capabilities, or whatever), and you want to make sure that seeding happens before your program loses the ability to do it.

    + +
    +
    + +

    ◆ evutil_secure_rng_set_urandom_device_file()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_secure_rng_set_urandom_device_file (char * fname)
    +
    + +

    Set a filename to use in place of /dev/urandom for seeding the secure PRNG.

    +

    Return 0 on success, -1 on failure.

    +

    Call this function BEFORE calling any other initialization or RNG functions.

    +

    (This string will NOT be copied internally. Do not free it while any user of the secure RNG might be running. Don't pass anything other than a real /dev/...random device file here, or you might lose security.)

    +

    This API is unstable, and might change in a future libevent version.

    + +
    +
    + +

    ◆ evutil_set_tcp_keepalive()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_set_tcp_keepalive (evutil_socket_t sock,
    int on,
    int timeout 
    )
    +
    + +

    Do platform-specific operations to set/unset TCP keep-alive options TCP_KEEPIDLE, TCP_KEEPINTVL and TCP_KEEPCNT on a socket.

    +
    Parameters
    + + + + +
    sockThe socket to be set TCP keep-alive
    onNonzero value to enable TCP keep-alive, 0 to disable
    timeoutThe timeout in seconds with no activity until the first keepalive probe is sent
    +
    +
    +
    Returns
    0 on success, -1 on failure
    + +
    +
    + +

    ◆ evutil_sockaddr_cmp()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_sockaddr_cmp (const struct sockaddr * sa1,
    const struct sockaddr * sa2,
    int include_port 
    )
    +
    + +

    Compare two sockaddrs; return 0 if they are equal, or less than 0 if sa1 preceeds sa2, or greater than 0 if sa1 follows sa2.

    +

    If include_port is true, consider the port as well as the address. Only implemented for AF_INET and AF_INET6 addresses. The ordering is not guaranteed to remain the same between Libevent versions.

    + +
    +
    + +

    ◆ evutil_socketpair()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evutil_socketpair (int domain,
    int type,
    int protocol,
    evutil_socket_t sv[2] 
    )
    +
    + +

    Create two new sockets that are connected to each other.

    +

    On Unix, this simply calls socketpair() and creates an unnamed pair of connected sockets in the specified domain, of the specified type, and using the optionally specified protocol.

    +

    On Windows, it will try to use the AF_UNIX to create unix socket pair if available, otherwise it instead uses AF_INET to create socket pair, binding the loopback network interface 127.0.0.1.

    +

    Including the bitwise OR of the EVUTIL_SOCK_NONBLOCK and/or EVUTIL_SOCK_CLOEXEC in the type argument will apply to both file descriptors.

    +

    (This may fail on some Windows hosts where firewall software has cleverly decided to keep 127.0.0.1 from talking to itself.)

    +

    Parameters and return values are as for socketpair()

    + +
    +
    + +

    ◆ evutil_strtoll()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL ev_int64_t evutil_strtoll (const char * s,
    char ** endptr,
    int base 
    )
    +
    + +

    Parse a 64-bit value from a string.

    +

    Arguments are as for strtol.

    + +
    +
    +
    + + + + diff --git a/util_8h_source.html b/util_8h_source.html new file mode 100644 index 0000000..a2244d3 --- /dev/null +++ b/util_8h_source.html @@ -0,0 +1,717 @@ + + + + + + + +libevent: event2/util.h Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    util.h
    +
    +
    +Go to the documentation of this file.
    1 /*
    +
    2  * Copyright (c) 2007-2012 Niels Provos and Nick Mathewson
    +
    3  *
    +
    4  * Redistribution and use in source and binary forms, with or without
    +
    5  * modification, are permitted provided that the following conditions
    +
    6  * are met:
    +
    7  * 1. Redistributions of source code must retain the above copyright
    +
    8  * notice, this list of conditions and the following disclaimer.
    +
    9  * 2. Redistributions in binary form must reproduce the above copyright
    +
    10  * notice, this list of conditions and the following disclaimer in the
    +
    11  * documentation and/or other materials provided with the distribution.
    +
    12  * 3. The name of the author may not be used to endorse or promote products
    +
    13  * derived from this software without specific prior written permission.
    +
    14  *
    +
    15  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
    +
    16  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
    +
    17  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
    +
    18  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
    +
    19  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
    +
    20  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
    +
    21  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
    +
    22  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
    +
    23  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
    +
    24  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
    +
    25  */
    +
    26 #ifndef EVENT2_UTIL_H_INCLUDED_
    +
    27 #define EVENT2_UTIL_H_INCLUDED_
    +
    28 
    +
    35 #include <event2/visibility.h>
    +
    36 
    +
    37 #ifdef __cplusplus
    +
    38 extern "C" {
    +
    39 #endif
    +
    40 
    +
    41 #include <event2/event-config.h>
    +
    42 #ifdef EVENT__HAVE_SYS_TIME_H
    +
    43 #include <sys/time.h>
    +
    44 #endif
    +
    45 #ifdef EVENT__HAVE_STDINT_H
    +
    46 #include <stdint.h>
    +
    47 #elif defined(EVENT__HAVE_INTTYPES_H)
    +
    48 #include <inttypes.h>
    +
    49 #endif
    +
    50 #ifdef EVENT__HAVE_SYS_TYPES_H
    +
    51 #include <sys/types.h>
    +
    52 #endif
    +
    53 #ifdef EVENT__HAVE_STDDEF_H
    +
    54 #include <stddef.h>
    +
    55 #endif
    +
    56 #ifdef _MSC_VER
    +
    57 #include <BaseTsd.h>
    +
    58 #endif
    +
    59 #include <stdarg.h>
    +
    60 #ifdef EVENT__HAVE_NETDB_H
    +
    61 #include <netdb.h>
    +
    62 #endif
    +
    63 
    +
    64 #ifdef _WIN32
    +
    65 #include <winsock2.h>
    +
    66 #ifdef EVENT__HAVE_GETADDRINFO
    +
    67 /* for EAI_* definitions. */
    +
    68 #include <ws2tcpip.h>
    +
    69 #endif
    +
    70 #else
    +
    71 #ifdef EVENT__HAVE_ERRNO_H
    +
    72 #include <errno.h>
    +
    73 #endif
    +
    74 #include <sys/socket.h>
    +
    75 #endif
    +
    76 
    +
    77 #include <time.h>
    +
    78 
    +
    79 #ifdef __sun
    +
    80 #ifdef SO_FLOW_NAME
    +
    81 /* Since it's impossible to detect the Solaris 11.4 version via OS macros,
    +
    82  * so we check the presence of the socket option SO_FLOW_NAME that was first
    +
    83  * introduced to Solaris 11.4 and define a custom macro for determining 11.4.
    +
    84  *
    +
    85  * Note that this might be a false positive if the code is compiled on a system
    +
    86  * but run on another system with an older version of Solaris.
    +
    87  */
    +
    88 #define EVENT__SOLARIS_11_4 (1)
    +
    89 #else
    +
    90 #define EVENT__SOLARIS_11_4 (0)
    +
    91 #endif
    +
    92 #endif
    +
    93 
    +
    94 /* Some openbsd autoconf versions get the name of this macro wrong. */
    +
    95 #if defined(EVENT__SIZEOF_VOID__) && !defined(EVENT__SIZEOF_VOID_P)
    +
    96 #define EVENT__SIZEOF_VOID_P EVENT__SIZEOF_VOID__
    +
    97 #endif
    +
    98 
    +
    128 #ifdef EVENT__HAVE_UINT64_T
    +
    129 #define ev_uint64_t uint64_t
    +
    130 #define ev_int64_t int64_t
    +
    131 #elif defined(_WIN32)
    +
    132 #define ev_uint64_t unsigned __int64
    +
    133 #define ev_int64_t signed __int64
    +
    134 #elif EVENT__SIZEOF_LONG_LONG == 8
    +
    135 #define ev_uint64_t unsigned long long
    +
    136 #define ev_int64_t long long
    +
    137 #elif EVENT__SIZEOF_LONG == 8
    +
    138 #define ev_uint64_t unsigned long
    +
    139 #define ev_int64_t long
    +
    140 #elif defined(EVENT_IN_DOXYGEN_)
    +
    141 #define ev_uint64_t ...
    +
    142 #define ev_int64_t ...
    +
    143 #else
    +
    144 #error "No way to define ev_uint64_t"
    +
    145 #endif
    +
    146 
    +
    147 #ifdef EVENT__HAVE_UINT32_T
    +
    148 #define ev_uint32_t uint32_t
    +
    149 #define ev_int32_t int32_t
    +
    150 #elif defined(_WIN32)
    +
    151 #define ev_uint32_t unsigned int
    +
    152 #define ev_int32_t signed int
    +
    153 #elif EVENT__SIZEOF_LONG == 4
    +
    154 #define ev_uint32_t unsigned long
    +
    155 #define ev_int32_t signed long
    +
    156 #elif EVENT__SIZEOF_INT == 4
    +
    157 #define ev_uint32_t unsigned int
    +
    158 #define ev_int32_t signed int
    +
    159 #elif defined(EVENT_IN_DOXYGEN_)
    +
    160 #define ev_uint32_t ...
    +
    161 #define ev_int32_t ...
    +
    162 #else
    +
    163 #error "No way to define ev_uint32_t"
    +
    164 #endif
    +
    165 
    +
    166 #ifdef EVENT__HAVE_UINT16_T
    +
    167 #define ev_uint16_t uint16_t
    +
    168 #define ev_int16_t int16_t
    +
    169 #elif defined(_WIN32)
    +
    170 #define ev_uint16_t unsigned short
    +
    171 #define ev_int16_t signed short
    +
    172 #elif EVENT__SIZEOF_INT == 2
    +
    173 #define ev_uint16_t unsigned int
    +
    174 #define ev_int16_t signed int
    +
    175 #elif EVENT__SIZEOF_SHORT == 2
    +
    176 #define ev_uint16_t unsigned short
    +
    177 #define ev_int16_t signed short
    +
    178 #elif defined(EVENT_IN_DOXYGEN_)
    +
    179 #define ev_uint16_t ...
    +
    180 #define ev_int16_t ...
    +
    181 #else
    +
    182 #error "No way to define ev_uint16_t"
    +
    183 #endif
    +
    184 
    +
    185 #ifdef EVENT__HAVE_UINT8_T
    +
    186 #define ev_uint8_t uint8_t
    +
    187 #define ev_int8_t int8_t
    +
    188 #elif defined(EVENT_IN_DOXYGEN_)
    +
    189 #define ev_uint8_t ...
    +
    190 #define ev_int8_t ...
    +
    191 #else
    +
    192 #define ev_uint8_t unsigned char
    +
    193 #define ev_int8_t signed char
    +
    194 #endif
    +
    195 
    +
    196 #ifdef EVENT__HAVE_UINTPTR_T
    +
    197 #define ev_uintptr_t uintptr_t
    +
    198 #define ev_intptr_t intptr_t
    +
    199 #elif EVENT__SIZEOF_VOID_P <= 4
    +
    200 #define ev_uintptr_t ev_uint32_t
    +
    201 #define ev_intptr_t ev_int32_t
    +
    202 #elif EVENT__SIZEOF_VOID_P <= 8
    +
    203 #define ev_uintptr_t ev_uint64_t
    +
    204 #define ev_intptr_t ev_int64_t
    +
    205 #elif defined(EVENT_IN_DOXYGEN_)
    +
    206 #define ev_uintptr_t ...
    +
    207 #define ev_intptr_t ...
    +
    208 #else
    +
    209 #error "No way to define ev_uintptr_t"
    +
    210 #endif
    +
    211 
    +
    212 #ifdef EVENT__ssize_t
    +
    213 #define ev_ssize_t EVENT__ssize_t
    +
    214 #else
    +
    215 #define ev_ssize_t ssize_t
    +
    216 #endif
    +
    217 
    +
    218 /* Note that we define ev_off_t based on the compile-time size of off_t that
    +
    219  * we used to build Libevent, and not based on the current size of off_t.
    +
    220  * (For example, we don't define ev_off_t to off_t.). We do this because
    +
    221  * some systems let you build your software with different off_t sizes
    +
    222  * at runtime, and so putting in any dependency on off_t would risk API
    +
    223  * mismatch.
    +
    224  */
    +
    225 #ifdef _WIN32
    +
    226 #define ev_off_t ev_int64_t
    +
    227 #elif EVENT__SIZEOF_OFF_T == 8
    +
    228 #define ev_off_t ev_int64_t
    +
    229 #elif EVENT__SIZEOF_OFF_T == 4
    +
    230 #define ev_off_t ev_int32_t
    +
    231 #elif defined(EVENT_IN_DOXYGEN_)
    +
    232 #define ev_off_t ...
    +
    233 #else
    +
    234 #define ev_off_t off_t
    +
    235 #endif
    +
    236 
    +
    238 /* Limits for integer types.
    +
    239 
    +
    240  We're making two assumptions here:
    +
    241  - The compiler does constant folding properly.
    +
    242  - The platform does signed arithmetic in two's complement.
    +
    243 */
    +
    244 
    +
    253 #ifndef EVENT__HAVE_STDINT_H
    +
    254 #define EV_UINT64_MAX ((((ev_uint64_t)0xffffffffUL) << 32) | 0xffffffffUL)
    +
    255 #define EV_INT64_MAX ((((ev_int64_t) 0x7fffffffL) << 32) | 0xffffffffL)
    +
    256 #define EV_INT64_MIN ((-EV_INT64_MAX) - 1)
    +
    257 #define EV_UINT32_MAX ((ev_uint32_t)0xffffffffUL)
    +
    258 #define EV_INT32_MAX ((ev_int32_t) 0x7fffffffL)
    +
    259 #define EV_INT32_MIN ((-EV_INT32_MAX) - 1)
    +
    260 #define EV_UINT16_MAX ((ev_uint16_t)0xffffUL)
    +
    261 #define EV_INT16_MAX ((ev_int16_t) 0x7fffL)
    +
    262 #define EV_INT16_MIN ((-EV_INT16_MAX) - 1)
    +
    263 #define EV_UINT8_MAX 255
    +
    264 #define EV_INT8_MAX 127
    +
    265 #define EV_INT8_MIN ((-EV_INT8_MAX) - 1)
    +
    266 #else
    +
    267 #define EV_UINT64_MAX UINT64_MAX
    +
    268 #define EV_INT64_MAX INT64_MAX
    +
    269 #define EV_INT64_MIN INT64_MIN
    +
    270 #define EV_UINT32_MAX UINT32_MAX
    +
    271 #define EV_INT32_MAX INT32_MAX
    +
    272 #define EV_INT32_MIN INT32_MIN
    +
    273 #define EV_UINT16_MAX UINT16_MAX
    +
    274 #define EV_INT16_MIN INT16_MIN
    +
    275 #define EV_INT16_MAX INT16_MAX
    +
    276 #define EV_UINT8_MAX UINT8_MAX
    +
    277 #define EV_INT8_MAX INT8_MAX
    +
    278 #define EV_INT8_MIN INT8_MIN
    +
    279 
    +
    280 #endif
    +
    281 
    +
    282 
    +
    288 #if EVENT__SIZEOF_SIZE_T == 8
    +
    289 #define EV_SIZE_MAX EV_UINT64_MAX
    +
    290 #define EV_SSIZE_MAX EV_INT64_MAX
    +
    291 #elif EVENT__SIZEOF_SIZE_T == 4
    +
    292 #define EV_SIZE_MAX EV_UINT32_MAX
    +
    293 #define EV_SSIZE_MAX EV_INT32_MAX
    +
    294 #elif defined(EVENT_IN_DOXYGEN_)
    +
    295 #define EV_SIZE_MAX ...
    +
    296 #define EV_SSIZE_MAX ...
    +
    297 #else
    +
    298 #error "No way to define SIZE_MAX"
    +
    299 #endif
    +
    300 
    +
    301 #define EV_SSIZE_MIN ((-EV_SSIZE_MAX) - 1)
    +
    302 
    +
    304 #ifdef _WIN32
    +
    305 #define ev_socklen_t int
    +
    306 #elif defined(EVENT__socklen_t)
    +
    307 #define ev_socklen_t EVENT__socklen_t
    +
    308 #else
    +
    309 #define ev_socklen_t socklen_t
    +
    310 #endif
    +
    311 
    +
    312 #ifdef EVENT__HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY
    +
    313 #if !defined(EVENT__HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY) \
    +
    314  && !defined(ss_family)
    +
    315 #define ss_family __ss_family
    +
    316 #endif
    +
    317 #endif
    +
    318 
    +
    322 #ifdef _WIN32
    +
    323 #define evutil_socket_t intptr_t
    +
    324 #else
    +
    325 #define evutil_socket_t int
    +
    326 #endif
    +
    327 
    + +
    341 #ifdef EVENT_IN_DOXYGEN_
    +
    342 {/*Empty body so that doxygen will generate documentation here.*/}
    +
    343 #endif
    +
    344 ;
    +
    345 
    +
    346 #define EV_MONOT_PRECISE 1
    +
    347 #define EV_MONOT_FALLBACK 2
    +
    348 
    +
    355 EVENT2_EXPORT_SYMBOL int
    +
    356 evutil_date_rfc1123(char *date, const size_t datelen, const struct tm *tm);
    +
    357 
    +
    363 EVENT2_EXPORT_SYMBOL
    + +
    365 
    +
    369 EVENT2_EXPORT_SYMBOL
    + +
    371 
    +
    375 EVENT2_EXPORT_SYMBOL
    + +
    377  int flags);
    +
    378 
    +
    389 EVENT2_EXPORT_SYMBOL
    + +
    391  struct timeval *tp);
    +
    392 
    +
    409 EVENT2_EXPORT_SYMBOL
    +
    410 int evutil_socketpair(int domain, int type, int protocol, evutil_socket_t sv[2]);
    +
    416 EVENT2_EXPORT_SYMBOL
    + +
    418 
    +
    430 EVENT2_EXPORT_SYMBOL
    + +
    432 
    +
    446 EVENT2_EXPORT_SYMBOL
    + +
    448 
    +
    460 EVENT2_EXPORT_SYMBOL
    + +
    462 
    +
    474 EVENT2_EXPORT_SYMBOL
    + +
    476 
    +
    483 EVENT2_EXPORT_SYMBOL
    + +
    485 
    +
    493 EVENT2_EXPORT_SYMBOL
    + +
    495 #define EVUTIL_CLOSESOCKET(s) evutil_closesocket(s)
    +
    496 
    +
    508 EVENT2_EXPORT_SYMBOL
    + +
    510 
    +
    520 EVENT2_EXPORT_SYMBOL
    +
    521 int evutil_set_tcp_keepalive(evutil_socket_t sock, int on, int timeout);
    +
    522 
    +
    523 #ifdef _WIN32
    +
    524 
    +
    525 #define EVUTIL_SOCKET_ERROR() WSAGetLastError()
    +
    526 
    +
    527 #define EVUTIL_SET_SOCKET_ERROR(errcode) \
    +
    528  do { WSASetLastError(errcode); } while (0)
    +
    529 
    +
    530 EVENT2_EXPORT_SYMBOL
    + +
    533 EVENT2_EXPORT_SYMBOL
    +
    534 const char *evutil_socket_error_to_string(int errcode);
    +
    535 #define EVUTIL_INVALID_SOCKET INVALID_SOCKET
    +
    536 #elif defined(EVENT_IN_DOXYGEN_)
    +
    537 
    +
    552 #define EVUTIL_SOCKET_ERROR() ...
    +
    553 
    +
    554 #define EVUTIL_SET_SOCKET_ERROR(errcode) ...
    +
    555 
    +
    556 #define evutil_socket_geterror(sock) ...
    +
    557 
    +
    558 #define evutil_socket_error_to_string(errcode) ...
    +
    559 #define EVUTIL_INVALID_SOCKET -1
    +
    560 
    +
    561 #else /* !EVENT_IN_DOXYGEN_ && !_WIN32 */
    +
    562 #define EVUTIL_SOCKET_ERROR() (errno)
    +
    563 #define EVUTIL_SET_SOCKET_ERROR(errcode) \
    +
    564  do { errno = (errcode); } while (0)
    +
    565 #define evutil_socket_geterror(sock) (errno)
    +
    566 #define evutil_socket_error_to_string(errcode) (strerror(errcode))
    +
    567 #define EVUTIL_INVALID_SOCKET -1
    +
    568 #endif /* !_WIN32 */
    +
    569 
    +
    570 
    +
    579 #ifdef EVENT__HAVE_TIMERADD
    +
    580 #define evutil_timeradd(tvp, uvp, vvp) timeradd((tvp), (uvp), (vvp))
    +
    581 #define evutil_timersub(tvp, uvp, vvp) timersub((tvp), (uvp), (vvp))
    +
    582 #else
    +
    583 #define evutil_timeradd(tvp, uvp, vvp) \
    +
    584  do { \
    +
    585  (vvp)->tv_sec = (tvp)->tv_sec + (uvp)->tv_sec; \
    +
    586  (vvp)->tv_usec = (tvp)->tv_usec + (uvp)->tv_usec; \
    +
    587  if ((vvp)->tv_usec >= 1000000) { \
    +
    588  (vvp)->tv_sec++; \
    +
    589  (vvp)->tv_usec -= 1000000; \
    +
    590  } \
    +
    591  } while (0)
    +
    592 #define evutil_timersub(tvp, uvp, vvp) \
    +
    593  do { \
    +
    594  (vvp)->tv_sec = (tvp)->tv_sec - (uvp)->tv_sec; \
    +
    595  (vvp)->tv_usec = (tvp)->tv_usec - (uvp)->tv_usec; \
    +
    596  if ((vvp)->tv_usec < 0) { \
    +
    597  (vvp)->tv_sec--; \
    +
    598  (vvp)->tv_usec += 1000000; \
    +
    599  } \
    +
    600  } while (0)
    +
    601 #endif /* !EVENT__HAVE_TIMERADD */
    +
    602 
    +
    603 #ifdef EVENT__HAVE_TIMERCLEAR
    +
    604 #define evutil_timerclear(tvp) timerclear(tvp)
    +
    605 #else
    +
    606 #define evutil_timerclear(tvp) (tvp)->tv_sec = (tvp)->tv_usec = 0
    +
    607 #endif
    +
    608 
    +
    612 #define evutil_timercmp(tvp, uvp, cmp) \
    +
    613  (((tvp)->tv_sec == (uvp)->tv_sec) ? \
    +
    614  ((tvp)->tv_usec cmp (uvp)->tv_usec) : \
    +
    615  ((tvp)->tv_sec cmp (uvp)->tv_sec))
    +
    616 
    +
    617 #ifdef EVENT__HAVE_TIMERISSET
    +
    618 #define evutil_timerisset(tvp) timerisset(tvp)
    +
    619 #else
    +
    620 #define evutil_timerisset(tvp) ((tvp)->tv_sec || (tvp)->tv_usec)
    +
    621 #endif
    +
    622 
    +
    624 #ifdef offsetof
    +
    625 #define evutil_offsetof(type, field) offsetof(type, field)
    +
    626 #else
    +
    627 #define evutil_offsetof(type, field) ((off_t)(&((type *)0)->field))
    +
    628 #endif
    +
    629 
    +
    630 /* big-int related functions */
    +
    632 EVENT2_EXPORT_SYMBOL
    +
    633 ev_int64_t evutil_strtoll(const char *s, char **endptr, int base);
    +
    634 
    +
    636 #ifdef EVENT__HAVE_GETTIMEOFDAY
    +
    637 #define evutil_gettimeofday(tv, tz) gettimeofday((tv), (tz))
    +
    638 #else
    +
    639 struct timezone;
    +
    640 EVENT2_EXPORT_SYMBOL
    +
    641 int evutil_gettimeofday(struct timeval *tv, struct timezone *tz);
    +
    642 #endif
    +
    643 
    +
    647 EVENT2_EXPORT_SYMBOL
    +
    648 int evutil_snprintf(char *buf, size_t buflen, const char *format, ...)
    +
    649 #ifdef __GNUC__
    +
    650  __attribute__((format(printf, 3, 4)))
    +
    651 #endif
    +
    652 ;
    +
    656 EVENT2_EXPORT_SYMBOL
    +
    657 int evutil_vsnprintf(char *buf, size_t buflen, const char *format, va_list ap)
    +
    658 #ifdef __GNUC__
    +
    659  __attribute__((format(printf, 3, 0)))
    +
    660 #endif
    +
    661 ;
    +
    662 
    +
    664 EVENT2_EXPORT_SYMBOL
    +
    665 const char *evutil_inet_ntop(int af, const void *src, char *dst, size_t len);
    +
    669 EVENT2_EXPORT_SYMBOL
    +
    670 int evutil_inet_pton_scope(int af, const char *src, void *dst,
    +
    671  unsigned *indexp);
    +
    673 EVENT2_EXPORT_SYMBOL
    +
    674 int evutil_inet_pton(int af, const char *src, void *dst);
    +
    675 struct sockaddr;
    +
    676 
    +
    697 EVENT2_EXPORT_SYMBOL
    +
    698 int evutil_parse_sockaddr_port(const char *str, struct sockaddr *out, int *outlen);
    +
    699 
    +
    705 EVENT2_EXPORT_SYMBOL
    +
    706 int evutil_sockaddr_cmp(const struct sockaddr *sa1, const struct sockaddr *sa2,
    +
    707  int include_port);
    +
    708 
    +
    713 EVENT2_EXPORT_SYMBOL
    +
    714 int evutil_ascii_strcasecmp(const char *str1, const char *str2);
    +
    718 EVENT2_EXPORT_SYMBOL
    +
    719 int evutil_ascii_strncasecmp(const char *str1, const char *str2, size_t n);
    +
    720 
    +
    721 /* Here we define evutil_addrinfo to the native addrinfo type, or redefine it
    +
    722  * if this system has no getaddrinfo(). */
    +
    723 #ifdef EVENT__HAVE_STRUCT_ADDRINFO
    +
    724 #define evutil_addrinfo addrinfo
    +
    725 #else
    +
    726 
    + +
    732  int ai_flags; /* AI_PASSIVE, AI_CANONNAME, AI_NUMERICHOST */
    +
    733  int ai_family; /* PF_xxx */
    +
    734  int ai_socktype; /* SOCK_xxx */
    +
    735  int ai_protocol; /* 0 or IPPROTO_xxx for IPv4 and IPv6 */
    +
    736  size_t ai_addrlen; /* length of ai_addr */
    +
    737  char *ai_canonname; /* canonical name for nodename */
    +
    738  struct sockaddr *ai_addr; /* binary address */
    +
    739  struct evutil_addrinfo *ai_next; /* next structure in linked list */
    +
    740 };
    +
    741 #endif
    +
    742 
    +
    749 #if defined(EAI_ADDRFAMILY) && defined(EVENT__HAVE_GETADDRINFO)
    +
    750 #define EVUTIL_EAI_ADDRFAMILY EAI_ADDRFAMILY
    +
    751 #else
    +
    752 #define EVUTIL_EAI_ADDRFAMILY -901
    +
    753 #endif
    +
    754 #if defined(EAI_AGAIN) && defined(EVENT__HAVE_GETADDRINFO)
    +
    755 #define EVUTIL_EAI_AGAIN EAI_AGAIN
    +
    756 #else
    +
    757 #define EVUTIL_EAI_AGAIN -902
    +
    758 #endif
    +
    759 #if defined(EAI_BADFLAGS) && defined(EVENT__HAVE_GETADDRINFO)
    +
    760 #define EVUTIL_EAI_BADFLAGS EAI_BADFLAGS
    +
    761 #else
    +
    762 #define EVUTIL_EAI_BADFLAGS -903
    +
    763 #endif
    +
    764 #if defined(EAI_FAIL) && defined(EVENT__HAVE_GETADDRINFO)
    +
    765 #define EVUTIL_EAI_FAIL EAI_FAIL
    +
    766 #else
    +
    767 #define EVUTIL_EAI_FAIL -904
    +
    768 #endif
    +
    769 #if defined(EAI_FAMILY) && defined(EVENT__HAVE_GETADDRINFO)
    +
    770 #define EVUTIL_EAI_FAMILY EAI_FAMILY
    +
    771 #else
    +
    772 #define EVUTIL_EAI_FAMILY -905
    +
    773 #endif
    +
    774 #if defined(EAI_MEMORY) && defined(EVENT__HAVE_GETADDRINFO)
    +
    775 #define EVUTIL_EAI_MEMORY EAI_MEMORY
    +
    776 #else
    +
    777 #define EVUTIL_EAI_MEMORY -906
    +
    778 #endif
    +
    779 /* This test is a bit complicated, since some MS SDKs decide to
    +
    780  * remove NODATA or redefine it to be the same as NONAME, in a
    +
    781  * fun interpretation of RFC 2553 and RFC 3493. */
    +
    782 #if defined(EAI_NODATA) && defined(EVENT__HAVE_GETADDRINFO) && (!defined(EAI_NONAME) || EAI_NODATA != EAI_NONAME)
    +
    783 #define EVUTIL_EAI_NODATA EAI_NODATA
    +
    784 #else
    +
    785 #define EVUTIL_EAI_NODATA -907
    +
    786 #endif
    +
    787 #if defined(EAI_NONAME) && defined(EVENT__HAVE_GETADDRINFO)
    +
    788 #define EVUTIL_EAI_NONAME EAI_NONAME
    +
    789 #else
    +
    790 #define EVUTIL_EAI_NONAME -908
    +
    791 #endif
    +
    792 #if defined(EAI_SERVICE) && defined(EVENT__HAVE_GETADDRINFO)
    +
    793 #define EVUTIL_EAI_SERVICE EAI_SERVICE
    +
    794 #else
    +
    795 #define EVUTIL_EAI_SERVICE -909
    +
    796 #endif
    +
    797 #if defined(EAI_SOCKTYPE) && defined(EVENT__HAVE_GETADDRINFO)
    +
    798 #define EVUTIL_EAI_SOCKTYPE EAI_SOCKTYPE
    +
    799 #else
    +
    800 #define EVUTIL_EAI_SOCKTYPE -910
    +
    801 #endif
    +
    802 #if defined(EAI_SYSTEM) && defined(EVENT__HAVE_GETADDRINFO)
    +
    803 #define EVUTIL_EAI_SYSTEM EAI_SYSTEM
    +
    804 #else
    +
    805 #define EVUTIL_EAI_SYSTEM -911
    +
    806 #endif
    +
    807 
    +
    808 #define EVUTIL_EAI_CANCEL -90001
    +
    809 
    +
    810 #if defined(AI_PASSIVE) && defined(EVENT__HAVE_GETADDRINFO)
    +
    811 #define EVUTIL_AI_PASSIVE AI_PASSIVE
    +
    812 #else
    +
    813 #define EVUTIL_AI_PASSIVE 0x1000
    +
    814 #endif
    +
    815 #if defined(AI_CANONNAME) && defined(EVENT__HAVE_GETADDRINFO)
    +
    816 #define EVUTIL_AI_CANONNAME AI_CANONNAME
    +
    817 #else
    +
    818 #define EVUTIL_AI_CANONNAME 0x2000
    +
    819 #endif
    +
    820 #if defined(AI_NUMERICHOST) && defined(EVENT__HAVE_GETADDRINFO)
    +
    821 #define EVUTIL_AI_NUMERICHOST AI_NUMERICHOST
    +
    822 #else
    +
    823 #define EVUTIL_AI_NUMERICHOST 0x4000
    +
    824 #endif
    +
    825 #if defined(AI_NUMERICSERV) && defined(EVENT__HAVE_GETADDRINFO)
    +
    826 #define EVUTIL_AI_NUMERICSERV AI_NUMERICSERV
    +
    827 #else
    +
    828 #define EVUTIL_AI_NUMERICSERV 0x8000
    +
    829 #endif
    +
    830 #if defined(AI_V4MAPPED) && defined(EVENT__HAVE_GETADDRINFO)
    +
    831 #define EVUTIL_AI_V4MAPPED AI_V4MAPPED
    +
    832 #else
    +
    833 #define EVUTIL_AI_V4MAPPED 0x10000
    +
    834 #endif
    +
    835 #if defined(AI_ALL) && defined(EVENT__HAVE_GETADDRINFO)
    +
    836 #define EVUTIL_AI_ALL AI_ALL
    +
    837 #else
    +
    838 #define EVUTIL_AI_ALL 0x20000
    +
    839 #endif
    +
    840 #if defined(AI_ADDRCONFIG) && defined(EVENT__HAVE_GETADDRINFO)
    +
    841 #define EVUTIL_AI_ADDRCONFIG AI_ADDRCONFIG
    +
    842 #else
    +
    843 #define EVUTIL_AI_ADDRCONFIG 0x40000
    +
    844 #endif
    +
    845 
    +
    847 struct evutil_addrinfo;
    +
    859 EVENT2_EXPORT_SYMBOL
    +
    860 int evutil_getaddrinfo(const char *nodename, const char *servname,
    +
    861  const struct evutil_addrinfo *hints_in, struct evutil_addrinfo **res);
    +
    862 
    +
    864 EVENT2_EXPORT_SYMBOL
    +
    865 void evutil_freeaddrinfo(struct evutil_addrinfo *ai);
    +
    866 
    +
    867 EVENT2_EXPORT_SYMBOL
    +
    868 const char *evutil_gai_strerror(int err);
    +
    869 
    +
    879 EVENT2_EXPORT_SYMBOL
    +
    880 void evutil_secure_rng_get_bytes(void *buf, size_t n);
    +
    881 
    +
    898 EVENT2_EXPORT_SYMBOL
    +
    899 int evutil_secure_rng_init(void);
    +
    900 
    +
    914 EVENT2_EXPORT_SYMBOL
    + +
    916 
    +
    934 EVENT2_EXPORT_SYMBOL
    +
    935 void evutil_secure_rng_add_bytes(const char *dat, size_t datlen);
    +
    936 
    +
    937 #ifdef __cplusplus
    +
    938 }
    +
    939 #endif
    +
    940 
    +
    941 #endif /* EVENT1_EVUTIL_H_INCLUDED_ */
    +
    +
    Structure to hold information about a monotonic timer.
    Definition: util.h:340
    +
    EVENT2_EXPORT_SYMBOL int evutil_inet_pton(int af, const char *src, void *dst)
    Replacement for inet_pton for platforms which lack it.
    +
    EVENT2_EXPORT_SYMBOL int evutil_date_rfc1123(char *date, const size_t datelen, const struct tm *tm)
    Format a date string using RFC 1123 format (used in HTTP).
    +
    EVENT2_EXPORT_SYMBOL int evutil_gettime_monotonic(struct evutil_monotonic_timer *timer, struct timeval *tp)
    Query the current monotonic time from a struct evutil_monotonic_timer previously configured with evut...
    +
    EVENT2_EXPORT_SYMBOL int evutil_set_tcp_keepalive(evutil_socket_t sock, int on, int timeout)
    Do platform-specific operations to set/unset TCP keep-alive options TCP_KEEPIDLE, TCP_KEEPINTVL and T...
    +
    EVENT2_EXPORT_SYMBOL int evutil_ascii_strcasecmp(const char *str1, const char *str2)
    As strcasecmp, but always compares the characters in locale-independent ASCII.
    +
    EVENT2_EXPORT_SYMBOL int evutil_make_listen_socket_ipv6only(evutil_socket_t sock)
    Set ipv6 only bind socket option to make listener work only in ipv6 sockets.
    +
    EVENT2_EXPORT_SYMBOL int evutil_getaddrinfo(const char *nodename, const char *servname, const struct evutil_addrinfo *hints_in, struct evutil_addrinfo **res)
    This function clones getaddrinfo for systems that don't have it.
    +
    EVENT2_EXPORT_SYMBOL int evutil_ascii_strncasecmp(const char *str1, const char *str2, size_t n)
    As strncasecmp, but always compares the characters in locale-independent ASCII.
    +
    EVENT2_EXPORT_SYMBOL int evutil_make_socket_nonblocking(evutil_socket_t sock)
    Do platform-specific operations as needed to make a socket nonblocking.
    +
    EVENT2_EXPORT_SYMBOL int evutil_secure_rng_init(void)
    Seed the secure random number generator if needed, and return 0 on success or -1 on failure.
    +
    EVENT2_EXPORT_SYMBOL int evutil_parse_sockaddr_port(const char *str, struct sockaddr *out, int *outlen)
    Parse an IPv4 or IPv6 address, with optional port, from a string.
    +
    EVENT2_EXPORT_SYMBOL int evutil_secure_rng_set_urandom_device_file(char *fname)
    Set a filename to use in place of /dev/urandom for seeding the secure PRNG.
    +
    #define evutil_socket_error_to_string(errcode)
    Convert a socket error to a string.
    Definition: util.h:558
    +
    const EVENT2_EXPORT_SYMBOL char * evutil_inet_ntop(int af, const void *src, char *dst, size_t len)
    Replacement for inet_ntop for platforms which lack it.
    +
    #define evutil_socket_geterror(sock)
    Return the most recent socket error to occur on sock.
    Definition: util.h:556
    +
    EVENT2_EXPORT_SYMBOL int evutil_snprintf(char *buf, size_t buflen, const char *format,...)
    Replacement for snprintf to get consistent behavior on platforms for which the return value of snprin...
    +
    EVENT2_EXPORT_SYMBOL int evutil_make_listen_socket_not_ipv6only(evutil_socket_t sock)
    Set ipv6 only bind socket option to make listener work in both ipv4 and ipv6 sockets.
    +
    EVENT2_EXPORT_SYMBOL int evutil_make_socket_closeonexec(evutil_socket_t sock)
    Do platform-specific operations as needed to close a socket upon a successful execution of one of the...
    +
    EVENT2_EXPORT_SYMBOL int evutil_configure_monotonic_time(struct evutil_monotonic_timer *timer, int flags)
    Set up a struct evutil_monotonic_timer; flags can include EV_MONOT_PRECISE and EV_MONOT_FALLBACK.
    +
    EVENT2_EXPORT_SYMBOL int evutil_socketpair(int domain, int type, int protocol, evutil_socket_t sv[2])
    Create two new sockets that are connected to each other.
    +
    EVENT2_EXPORT_SYMBOL void evutil_freeaddrinfo(struct evutil_addrinfo *ai)
    Release storage allocated by evutil_getaddrinfo or evdns_getaddrinfo.
    +
    EVENT2_EXPORT_SYMBOL struct evutil_monotonic_timer * evutil_monotonic_timer_new(void)
    Allocate a new struct evutil_monotonic_timer for use with the evutil_configure_monotonic_time() and e...
    +
    EVENT2_EXPORT_SYMBOL int evutil_inet_pton_scope(int af, const char *src, void *dst, unsigned *indexp)
    Variation of inet_pton that also parses IPv6 scopes.
    +
    EVENT2_EXPORT_SYMBOL ev_int64_t evutil_strtoll(const char *s, char **endptr, int base)
    Parse a 64-bit value from a string.
    +
    EVENT2_EXPORT_SYMBOL int evutil_make_tcp_listen_socket_deferred(evutil_socket_t sock)
    Do platform-specific operations, if possible, to make a tcp listener socket defer accept()s until the...
    +
    EVENT2_EXPORT_SYMBOL void evutil_secure_rng_add_bytes(const char *dat, size_t datlen)
    Seed the random number generator with extra random bytes.
    +
    EVENT2_EXPORT_SYMBOL int evutil_sockaddr_cmp(const struct sockaddr *sa1, const struct sockaddr *sa2, int include_port)
    Compare two sockaddrs; return 0 if they are equal, or less than 0 if sa1 preceeds sa2,...
    +
    EVENT2_EXPORT_SYMBOL int evutil_closesocket(evutil_socket_t sock)
    Do the platform-specific call needed to close a socket returned from socket() or accept().
    +
    EVENT2_EXPORT_SYMBOL void evutil_monotonic_timer_free(struct evutil_monotonic_timer *timer)
    Free a struct evutil_monotonic_timer that was allocated using evutil_monotonic_timer_new().
    +
    A definition of struct addrinfo for systems that lack it.
    Definition: util.h:731
    +
    EVENT2_EXPORT_SYMBOL int evutil_make_listen_socket_reuseable_port(evutil_socket_t sock)
    Do platform-specific operations to make a listener port reusable.
    +
    EVENT2_EXPORT_SYMBOL int evutil_make_listen_socket_reuseable(evutil_socket_t sock)
    Do platform-specific operations to make a listener socket reusable.
    +
    EVENT2_EXPORT_SYMBOL int evutil_vsnprintf(char *buf, size_t buflen, const char *format, va_list ap)
    Replacement for vsnprintf to get consistent behavior on platforms for which the return value of snpri...
    +
    EVENT2_EXPORT_SYMBOL void evutil_secure_rng_get_bytes(void *buf, size_t n)
    Generate n bytes of secure pseudorandom data, and store them in buf.
    +
    #define evutil_socket_t
    A type wide enough to hold the output of "socket()" or "accept()".
    Definition: util.h:325
    + + + + diff --git a/watch_8h.html b/watch_8h.html new file mode 100644 index 0000000..920102d --- /dev/null +++ b/watch_8h.html @@ -0,0 +1,357 @@ + + + + + + + +libevent: event2/watch.h File Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    + +
    +
    watch.h File Reference
    +
    +
    + +

    "Prepare" and "check" watchers. +More...

    +
    #include <event2/visibility.h>
    +
    +

    Go to the source code of this file.

    + + + + + + + + +

    +Typedefs

    typedef void(* evwatch_check_cb) (struct evwatch *, const struct evwatch_check_cb_info *, void *)
     Check callback, invoked by event_base_loop immediately after polling for I/O and before processing any active events. More...
     
    typedef void(* evwatch_prepare_cb) (struct evwatch *, const struct evwatch_prepare_cb_info *, void *)
     Prepare callback, invoked by event_base_loop immediately before polling for I/O. More...
     
    + + + + + + + + + + + + + + + + +

    +Functions

    EVENT2_EXPORT_SYMBOL struct event_baseevwatch_base (struct evwatch *watcher)
     Get the event_base that a given evwatch is registered with. More...
     
    EVENT2_EXPORT_SYMBOL struct evwatch * evwatch_check_new (struct event_base *base, evwatch_check_cb callback, void *arg)
     Register a new "check" watcher, to be called in the event loop after polling for events and before handling them. More...
     
    EVENT2_EXPORT_SYMBOL void evwatch_free (struct evwatch *watcher)
     Deregister and deallocate a watcher. More...
     
    EVENT2_EXPORT_SYMBOL int evwatch_prepare_get_timeout (const struct evwatch_prepare_cb_info *info, struct timeval *timeout)
     Get the timeout (the expected polling duration) passed to the underlying implementation's dispatch. More...
     
    EVENT2_EXPORT_SYMBOL struct evwatch * evwatch_prepare_new (struct event_base *base, evwatch_prepare_cb callback, void *arg)
     Register a new "prepare" watcher, to be called in the event loop prior to polling for events. More...
     
    +

    Detailed Description

    +

    "Prepare" and "check" watchers.

    +

    "Prepare" and "check" watchers. A "prepare" watcher is a callback that fires immediately before polling for I/O. A "check" watcher is a callback that fires immediately after polling and before processing any active events. This may be useful for embedding other libraries' event loops (e.g. UI toolkits) into libevent's.

    +

    Typedef Documentation

    + +

    ◆ evwatch_check_cb

    + +
    +
    + + + + +
    typedef void(* evwatch_check_cb) (struct evwatch *, const struct evwatch_check_cb_info *, void *)
    +
    + +

    Check callback, invoked by event_base_loop immediately after polling for I/O and before processing any active events.

    +
    Parameters
    + + + + +
    watcherthe check watcher that invoked this callback.
    infocontextual information passed from event_base_loop.
    argadditional user-defined argument, set in evwatch_check_new.
    +
    +
    + +
    +
    + +

    ◆ evwatch_prepare_cb

    + +
    +
    + + + + +
    typedef void(* evwatch_prepare_cb) (struct evwatch *, const struct evwatch_prepare_cb_info *, void *)
    +
    + +

    Prepare callback, invoked by event_base_loop immediately before polling for I/O.

    +
    Parameters
    + + + + +
    watcherthe prepare watcher that invoked this callback.
    infocontextual information passed from event_base_loop.
    argadditional user-defined argument, set in evwatch_prepare_new.
    +
    +
    + +
    +
    +

    Function Documentation

    + +

    ◆ evwatch_base()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL struct event_base* evwatch_base (struct evwatch * watcher)
    +
    + +

    Get the event_base that a given evwatch is registered with.

    +
    Parameters
    + + +
    watcherthe watcher to get the event_base for.
    +
    +
    +
    Returns
    the event_base for the given watcher.
    + +
    +
    + +

    ◆ evwatch_check_new()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL struct evwatch* evwatch_check_new (struct event_basebase,
    evwatch_check_cb callback,
    void * arg 
    )
    +
    + +

    Register a new "check" watcher, to be called in the event loop after polling for events and before handling them.

    +

    Watchers will be called in the order they were registered.

    +
    Parameters
    + + + + +
    basethe event_base to operate on.
    callbackthe callback function to invoke.
    argadditional user-defined argument provided to the callback.
    +
    +
    +
    Returns
    a pointer to the newly allocated event watcher.
    + +
    +
    + +

    ◆ evwatch_free()

    + +
    +
    + + + + + + + + +
    EVENT2_EXPORT_SYMBOL void evwatch_free (struct evwatch * watcher)
    +
    + +

    Deregister and deallocate a watcher.

    +

    Any watchers not freed using evwatch_free will eventually be deallocated in event_base_free (calling evwatch_free on a watcher after event_base_free has been called on its corresponding event_base is an error).

    +
    Parameters
    + + +
    watcherthe watcher to deregister and deallocate.
    +
    +
    + +
    +
    + +

    ◆ evwatch_prepare_get_timeout()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL int evwatch_prepare_get_timeout (const struct evwatch_prepare_cb_info * info,
    struct timeval * timeout 
    )
    +
    + +

    Get the timeout (the expected polling duration) passed to the underlying implementation's dispatch.

    +

    This value will only be set if there are pending EV_TIMEOUT events and if the event_base isn't in EVLOOP_NONBLOCK mode. It may be a useful performance statistic to compare the expected polling duration against the actual polling duration (that is, the time difference measured between this prepare callback and the following check callback).

    +
    Parameters
    + + + +
    infothe "prepare" callback info.
    timeoutaddress of a timeval to write the polling duration to.
    +
    +
    +
    Returns
    1 if a value was written to *timeout, or 0 if not.
    + +
    +
    + +

    ◆ evwatch_prepare_new()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    EVENT2_EXPORT_SYMBOL struct evwatch* evwatch_prepare_new (struct event_basebase,
    evwatch_prepare_cb callback,
    void * arg 
    )
    +
    + +

    Register a new "prepare" watcher, to be called in the event loop prior to polling for events.

    +

    Watchers will be called in the order they were registered.

    +
    Parameters
    + + + + +
    basethe event_base to operate on.
    callbackthe callback function to invoke.
    argadditional user-defined argument provided to the callback.
    +
    +
    +
    Returns
    a pointer to the newly allocated event watcher.
    + +
    +
    +
    + + + + diff --git a/watch_8h_source.html b/watch_8h_source.html new file mode 100644 index 0000000..b261ce1 --- /dev/null +++ b/watch_8h_source.html @@ -0,0 +1,152 @@ + + + + + + + +libevent: event2/watch.h Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    libevent +  2.2.1 +
    +
    Event notification library
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    watch.h
    +
    +
    +Go to the documentation of this file.
    1 /*
    +
    2  * Redistribution and use in source and binary forms, with or without
    +
    3  * modification, are permitted provided that the following conditions
    +
    4  * are met:
    +
    5  * 1. Redistributions of source code must retain the above copyright
    +
    6  * notice, this list of conditions and the following disclaimer.
    +
    7  * 2. Redistributions in binary form must reproduce the above copyright
    +
    8  * notice, this list of conditions and the following disclaimer in the
    +
    9  * documentation and/or other materials provided with the distribution.
    +
    10  * 3. The name of the author may not be used to endorse or promote products
    +
    11  * derived from this software without specific prior written permission.
    +
    12  *
    +
    13  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
    +
    14  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
    +
    15  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
    +
    16  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
    +
    17  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
    +
    18  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
    +
    19  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
    +
    20  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
    +
    21  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
    +
    22  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
    +
    23  */
    +
    24 #ifndef EVENT2_WATCH_H_INCLUDED_
    +
    25 #define EVENT2_WATCH_H_INCLUDED_
    +
    26 
    +
    39 #ifdef __cplusplus
    +
    40 extern "C" {
    +
    41 #endif
    +
    42 
    +
    43 #include <event2/visibility.h>
    +
    44 
    +
    45 struct event_base;
    +
    46 struct evwatch;
    +
    47 struct evwatch_prepare_cb_info;
    +
    48 struct evwatch_check_cb_info;
    +
    49 struct timeval;
    +
    50 
    +
    59 typedef void (*evwatch_prepare_cb)(struct evwatch *, const struct evwatch_prepare_cb_info *, void *);
    +
    60 
    +
    69 typedef void (*evwatch_check_cb)(struct evwatch *, const struct evwatch_check_cb_info *, void *);
    +
    70 
    +
    81 EVENT2_EXPORT_SYMBOL
    +
    82 struct evwatch *evwatch_prepare_new(struct event_base *base, evwatch_prepare_cb callback, void *arg);
    +
    83 
    +
    94 EVENT2_EXPORT_SYMBOL
    +
    95 struct evwatch *evwatch_check_new(struct event_base *base, evwatch_check_cb callback, void *arg);
    +
    96 
    +
    103 EVENT2_EXPORT_SYMBOL
    +
    104 struct event_base *evwatch_base(struct evwatch *watcher);
    +
    105 
    +
    114 EVENT2_EXPORT_SYMBOL
    +
    115 void evwatch_free(struct evwatch *watcher);
    +
    116 
    +
    129 EVENT2_EXPORT_SYMBOL
    +
    130 int evwatch_prepare_get_timeout(const struct evwatch_prepare_cb_info *info, struct timeval *timeout);
    +
    131 
    +
    132 #ifdef __cplusplus
    +
    133 }
    +
    134 #endif
    +
    135 
    +
    136 #endif /* EVENT2_WATCH_H_INCLUDED_ */
    +
    +
    EVENT2_EXPORT_SYMBOL struct event_base * evwatch_base(struct evwatch *watcher)
    Get the event_base that a given evwatch is registered with.
    +
    void(* evwatch_prepare_cb)(struct evwatch *, const struct evwatch_prepare_cb_info *, void *)
    Prepare callback, invoked by event_base_loop immediately before polling for I/O.
    Definition: watch.h:59
    +
    void(* evwatch_check_cb)(struct evwatch *, const struct evwatch_check_cb_info *, void *)
    Check callback, invoked by event_base_loop immediately after polling for I/O and before processing an...
    Definition: watch.h:69
    +
    Structure to hold information and state for a Libevent dispatch loop.
    Definition: event.h:219
    +
    EVENT2_EXPORT_SYMBOL int evwatch_prepare_get_timeout(const struct evwatch_prepare_cb_info *info, struct timeval *timeout)
    Get the timeout (the expected polling duration) passed to the underlying implementation's dispatch.
    +
    EVENT2_EXPORT_SYMBOL struct evwatch * evwatch_check_new(struct event_base *base, evwatch_check_cb callback, void *arg)
    Register a new "check" watcher, to be called in the event loop after polling for events and before ha...
    +
    EVENT2_EXPORT_SYMBOL struct evwatch * evwatch_prepare_new(struct event_base *base, evwatch_prepare_cb callback, void *arg)
    Register a new "prepare" watcher, to be called in the event loop prior to polling for events.
    +
    EVENT2_EXPORT_SYMBOL void evwatch_free(struct evwatch *watcher)
    Deregister and deallocate a watcher.
    + + + +