the upcoming 2.0 version
https://redmine.lighttpd.net/projects/lighttpd2
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
232 lines
4.9 KiB
232 lines
4.9 KiB
#ifndef _LIGHTTPD_TYPEDEFS_H_ |
|
#define _LIGHTTPD_TYPEDEFS_H_ |
|
|
|
typedef enum { |
|
LI_HTTP_TRANSFER_ENCODING_IDENTITY, |
|
LI_HTTP_TRANSFER_ENCODING_CHUNKED |
|
} liTransferEncoding; |
|
|
|
typedef enum { |
|
LI_HANDLER_GO_ON, |
|
LI_HANDLER_COMEBACK, |
|
LI_HANDLER_WAIT_FOR_EVENT, |
|
LI_HANDLER_ERROR |
|
} liHandlerResult; |
|
|
|
typedef enum { TRI_FALSE, TRI_MAYBE, TRI_TRUE } tristate_t; |
|
|
|
typedef enum { LI_GMTIME, LI_LOCALTIME } liTimeFunc; |
|
typedef enum { LI_TS_FORMAT_DEFAULT, LI_TS_FORMAT_HEADER } liTSFormat; |
|
|
|
/* structs from headers, in alphabetic order */ |
|
|
|
/* actions.h */ |
|
|
|
typedef struct liAction liAction; |
|
|
|
typedef struct liActionStack liActionStack; |
|
|
|
typedef struct liActionRegexStackElement liActionRegexStackElement; |
|
|
|
typedef struct liActionFunc liActionFunc; |
|
|
|
typedef struct liBalancerFunc liBalancerFunc; |
|
|
|
typedef enum { |
|
ACTION_TSETTING, |
|
ACTION_TFUNCTION, |
|
ACTION_TCONDITION, |
|
ACTION_TLIST, |
|
ACTION_TBALANCER |
|
} liActionType; |
|
|
|
typedef enum { |
|
BACKEND_OVERLOAD, |
|
BACKEND_DEAD |
|
} liBackendError; |
|
|
|
/* chunk.h */ |
|
|
|
typedef struct liChunkFile liChunkFile; |
|
|
|
typedef struct liChunk liChunk; |
|
|
|
typedef struct liCQLimit liCQLimit; |
|
|
|
typedef struct liChunkQueue liChunkQueue; |
|
|
|
typedef struct liChunkIter liChunkIter; |
|
|
|
/* chunk_parser.h */ |
|
|
|
typedef struct liChunkParserCtx liChunkParserCtx; |
|
|
|
typedef struct liChunkParserMark liChunkParserMark; |
|
|
|
/* condition.h */ |
|
|
|
typedef struct liConditionRValue liConditionRValue; |
|
|
|
typedef struct liConditionLValue liConditionLValue; |
|
|
|
typedef struct liCondition liCondition; |
|
|
|
/* connection.h */ |
|
|
|
typedef struct liConnection liConnection; |
|
|
|
/* http_headers.h */ |
|
|
|
typedef struct liHttpHeader liHttpHeader; |
|
|
|
typedef struct liHttpHeaders liHttpHeaders; |
|
|
|
/* li_http_request_parser.h */ |
|
|
|
typedef struct liHttpRequestCtx liHttpRequestCtx; |
|
|
|
/* li_http_response_parser.h */ |
|
|
|
typedef struct liHttpResponseCtx liHttpResponseCtx; |
|
|
|
/* log.h */ |
|
|
|
typedef struct liLog liLog; |
|
typedef struct liLogEntry liLogEntry; |
|
typedef struct liLogTimestamp liLogTimestamp; |
|
|
|
typedef enum { |
|
LI_LOG_LEVEL_DEBUG, |
|
LI_LOG_LEVEL_INFO, |
|
LI_LOG_LEVEL_WARNING, |
|
LI_LOG_LEVEL_ERROR, |
|
LI_LOG_LEVEL_ABORT, |
|
LI_LOG_LEVEL_BACKEND |
|
} liLogLevel; |
|
|
|
typedef enum { |
|
LI_LOG_TYPE_STDERR, |
|
LI_LOG_TYPE_FILE, |
|
LI_LOG_TYPE_PIPE, |
|
LI_LOG_TYPE_SYSLOG, |
|
LI_LOG_TYPE_NONE |
|
} liLogType; |
|
|
|
/* network.h */ |
|
|
|
typedef enum { |
|
LI_NETWORK_STATUS_SUCCESS, /**< some IO was actually done (read/write) or cq was empty for write */ |
|
LI_NETWORK_STATUS_FATAL_ERROR, |
|
LI_NETWORK_STATUS_CONNECTION_CLOSE, |
|
LI_NETWORK_STATUS_WAIT_FOR_EVENT, /**< read/write returned -1 with errno=EAGAIN/EWOULDBLOCK; no real IO was done |
|
internal: some io may be done */ |
|
LI_NETWORK_STATUS_WAIT_FOR_AIO_EVENT /**< nothing done yet, read/write will be done somewhere else */ |
|
} liNetworkStatus; |
|
|
|
/* options.h */ |
|
|
|
typedef struct liOptionSet liOptionSet; |
|
|
|
typedef union liOptionValue liOptionValue; |
|
|
|
/* plugin.h */ |
|
typedef struct liPlugin liPlugin; |
|
|
|
typedef struct liPluginOption liPluginOption; |
|
|
|
typedef struct liServerOption liServerOption; |
|
|
|
typedef struct liPluginAction liPluginAction; |
|
|
|
typedef struct liServerAction liServerAction; |
|
|
|
typedef struct liPluginSetup liPluginSetup; |
|
|
|
typedef struct liServerSetup liServerSetup; |
|
|
|
typedef struct liPluginAngel liPluginAngel; |
|
|
|
/* request.h */ |
|
|
|
typedef enum { |
|
LI_HTTP_METHOD_UNSET = -1, |
|
LI_HTTP_METHOD_GET, |
|
LI_HTTP_METHOD_POST, |
|
LI_HTTP_METHOD_HEAD, |
|
LI_HTTP_METHOD_OPTIONS, |
|
LI_HTTP_METHOD_PROPFIND, /* WebDAV */ |
|
LI_HTTP_METHOD_MKCOL, |
|
LI_HTTP_METHOD_PUT, |
|
LI_HTTP_METHOD_DELETE, |
|
LI_HTTP_METHOD_COPY, |
|
LI_HTTP_METHOD_MOVE, |
|
LI_HTTP_METHOD_PROPPATCH, |
|
LI_HTTP_METHOD_REPORT, /* DeltaV */ |
|
LI_HTTP_METHOD_CHECKOUT, |
|
LI_HTTP_METHOD_CHECKIN, |
|
LI_HTTP_METHOD_VERSION_CONTROL, |
|
LI_HTTP_METHOD_UNCHECKOUT, |
|
LI_HTTP_METHOD_MKACTIVITY, |
|
LI_HTTP_METHOD_MERGE, |
|
LI_HTTP_METHOD_LOCK, |
|
LI_HTTP_METHOD_UNLOCK, |
|
LI_HTTP_METHOD_LABEL, |
|
LI_HTTP_METHOD_CONNECT |
|
} liHttpMethod; |
|
|
|
typedef enum { |
|
LI_HTTP_VERSION_UNSET = -1, |
|
LI_HTTP_VERSION_1_0, |
|
LI_HTTP_VERSION_1_1 |
|
} liHttpVersion; |
|
|
|
typedef struct liRequest liRequest; |
|
|
|
typedef struct liRequestUri liRequestUri; |
|
|
|
typedef struct liPhysical liPhysical; |
|
|
|
/* respone.h */ |
|
|
|
typedef struct liResponse liResponse; |
|
|
|
/* server.h */ |
|
|
|
typedef struct liServer liServer; |
|
|
|
typedef struct liServerSocket liServerSocket; |
|
|
|
/* value.h */ |
|
|
|
typedef struct liValue liValue; |
|
|
|
typedef enum { |
|
LI_VALUE_NONE, |
|
LI_VALUE_BOOLEAN, |
|
LI_VALUE_NUMBER, |
|
LI_VALUE_STRING, |
|
LI_VALUE_LIST, |
|
LI_VALUE_HASH, |
|
LI_VALUE_ACTION, /**< shouldn't be used for options, but may be needed for constructing actions */ |
|
LI_VALUE_CONDITION /**< shouldn't be used for options, but may be needed for constructing actions */ |
|
} liValueType; |
|
|
|
/* virtualrequest.h */ |
|
|
|
typedef struct liVRequest liVRequest; |
|
|
|
typedef struct liVRequestRef liVRequestRef; |
|
|
|
typedef struct liFilter liFilter; |
|
|
|
typedef struct liFilters liFilters; |
|
|
|
/* worker.h */ |
|
|
|
typedef struct liWorker liWorker; |
|
|
|
typedef struct liStatCacheEntryData liStatCacheEntryData; |
|
typedef struct liStatCacheEntry liStatCacheEntry; |
|
typedef struct liStatCache liStatCache; |
|
|
|
#endif
|
|
|