aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2008-03-30 03:34:44 +0000
committerChristian Grothoff <christian@grothoff.org>2008-03-30 03:34:44 +0000
commita7ea20473a18f5a88028c7245e8e4eaad5982a5a (patch)
tree6f9de3fa0f9d8e0e8976dee84a98c3d51ddd2ae9
parent7d2532ba8b0f271931b180e84f8e962af37df415 (diff)
downloadlibmicrohttpd-a7ea20473a18f5a88028c7245e8e4eaad5982a5a.tar.gz
libmicrohttpd-a7ea20473a18f5a88028c7245e8e4eaad5982a5a.zip
Karl Berry wrote:
Also, a trivial point, you use en-dashes for hyphenated phrases, such as "thread-safe" and "key-value". In normal English typesetting these are just hyphens, so "thread-safe" rather than "thread--safe".
-rw-r--r--doc/microhttpd.texi48
1 files changed, 24 insertions, 24 deletions
diff --git a/doc/microhttpd.texi b/doc/microhttpd.texi
index e21dcc37..8d061179 100644
--- a/doc/microhttpd.texi
+++ b/doc/microhttpd.texi
@@ -118,7 +118,7 @@ define their own extensions of the @http{} standard and use those with
118@mhd{}. 118@mhd{}.
119 119
120All functions are guaranteed to be completely reentrant and 120All functions are guaranteed to be completely reentrant and
121thread--safe. 121thread-safe.
122 122
123 123
124 124
@@ -196,7 +196,7 @@ timeout).
196 196
197@item MHD_OPTION_NOTIFY_COMPLETED 197@item MHD_OPTION_NOTIFY_COMPLETED
198Register a function that should be called whenever a request has been 198Register a function that should be called whenever a request has been
199completed (this can be used for application--specific clean up). 199completed (this can be used for application-specific clean up).
200Requests that have never been presented to the application (via 200Requests that have never been presented to the application (via
201@cfunction{MHD_AccessHandlerCallback}) will not result in 201@cfunction{MHD_AccessHandlerCallback}) will not result in
202notifications. 202notifications.
@@ -210,7 +210,7 @@ callback. The second pointer maybe @null{}.
210 210
211 211
212@deftp {Enumeration} MHD_ValueKind 212@deftp {Enumeration} MHD_ValueKind
213The @code{MHD_ValueKind} specifies the source of the key--value pairs in 213The @code{MHD_ValueKind} specifies the source of the key-value pairs in
214the @http{} protocol. 214the @http{} protocol.
215 215
216@table @code 216@table @code
@@ -366,7 +366,7 @@ calls for this request;
366 366
367since the access handler may be called many times (i.e., for a 367since the access handler may be called many times (i.e., for a
368@code{PUT}/@code{POST} operation with plenty of upload data) this allows 368@code{PUT}/@code{POST} operation with plenty of upload data) this allows
369the application to easily associate some request--specific state; 369the application to easily associate some request-specific state;
370 370
371if necessary, this state can be cleaned up in the global 371if necessary, this state can be cleaned up in the global
372@code{MHD_RequestCompletedCallback} (which can be set with the 372@code{MHD_RequestCompletedCallback} (which can be set with the
@@ -397,8 +397,8 @@ reason for request termination see @code{MHD_OPTION_NOTIFY_COMPLETED}.
397 397
398 398
399@deftypefn {Function Pointer} int {*MHD_KeyValueIterator} (void *cls, enum MHD_ValueKind kind, const char *key, const char *value) 399@deftypefn {Function Pointer} int {*MHD_KeyValueIterator} (void *cls, enum MHD_ValueKind kind, const char *key, const char *value)
400Iterator over key--value pairs. This iterator can be used to iterate 400Iterator over key-value pairs. This iterator can be used to iterate
401over all of the cookies, headers, or @code{POST}--data fields of a 401over all of the cookies, headers, or @code{POST}-data fields of a
402request, and also to iterate over the headers that have been added to a 402request, and also to iterate over the headers that have been added to a
403response. 403response.
404 404
@@ -413,7 +413,7 @@ copy at most @var{max} bytes of content into @var{buf}. The total
413number of bytes that has been placed into @var{buf} should be returned. 413number of bytes that has been placed into @var{buf} should be returned.
414 414
415Note that returning zero will cause @mhd{} to try again, either 415Note that returning zero will cause @mhd{} to try again, either
416``immediately'' if in multi--threaded mode (in which case the callback 416``immediately'' if in multi-threaded mode (in which case the callback
417may want to do blocking operations) or in the next round if MHD_run is 417may want to do blocking operations) or in the next round if MHD_run is
418used. Returning zero for a daemon that runs in internal 418used. Returning zero for a daemon that runs in internal
419@cfunction{select} mode is an error (since it would result in busy 419@cfunction{select} mode is an error (since it would result in busy
@@ -425,10 +425,10 @@ custom value selected at callback registration time;
425 425
426@item pos 426@item pos
427position in the datastream to access; note that if an 427position in the datastream to access; note that if an
428@code{MHD_Response} object is re--used, it is possible for the same 428@code{MHD_Response} object is re-used, it is possible for the same
429content reader to be queried multiple times for the same data; however, 429content reader to be queried multiple times for the same data; however,
430if an @code{MHD_Response} is not re--used, @mhd{} guarantees that 430if an @code{MHD_Response} is not re-used, @mhd{} guarantees that
431@var{pos} will be the sum of all non--negative return values obtained 431@var{pos} will be the sum of all non-negative return values obtained
432from the content reader so far. 432from the content reader so far.
433@end table 433@end table
434 434
@@ -444,8 +444,8 @@ It should be used to free resources associated with the content reader.
444 444
445 445
446@deftypefn {Function Pointer} int {*MHD_PostDataIterator} (void *cls, enum MHD_ValueKind kind, const char *key, const char *filename, const char *content_type, const char *transfer_encoding, const char *data, size_t off, size_t size) 446@deftypefn {Function Pointer} int {*MHD_PostDataIterator} (void *cls, enum MHD_ValueKind kind, const char *key, const char *filename, const char *content_type, const char *transfer_encoding, const char *data, size_t off, size_t size)
447Iterator over key--value pairs where the value maybe made available in 447Iterator over key-value pairs where the value maybe made available in
448increments and/or may not be zero--terminated. Used for processing 448increments and/or may not be zero-terminated. Used for processing
449@code{POST} data. 449@code{POST} data.
450 450
451@table @var 451@table @var
@@ -456,13 +456,13 @@ custom value selected at callback registration time;
456type of the value; 456type of the value;
457 457
458@item key 458@item key
459zero--terminated key for the value; 459zero-terminated key for the value;
460 460
461@item filename 461@item filename
462name of the uploaded file, @null{} if not known; 462name of the uploaded file, @null{} if not known;
463 463
464@item content_type 464@item content_type
465mime--type of the data, @null{} if not known; 465mime-type of the data, @null{} if not known;
466 466
467@item transfer_encoding 467@item transfer_encoding
468encoding of the data, @null{} if not known; 468encoding of the data, @null{} if not known;
@@ -494,7 +494,7 @@ Start a webserver on the given port.
494 494
495@table @var 495@table @var
496@item flags 496@item flags
497OR--ed combination of @code{MHD_FLAG} values; 497OR-ed combination of @code{MHD_FLAG} values;
498 498
499@item port 499@item port
500port to bind to; 500port to bind to;
@@ -514,7 +514,7 @@ default handler for all @uri{}s;
514extra argument to @var{dh}. 514extra argument to @var{dh}.
515@end table 515@end table
516 516
517Additional arguments are a list of options (type--value pairs, 517Additional arguments are a list of options (type-value pairs,
518terminated with @code{MHD_OPTION_END}). It is mandatory to use 518terminated with @code{MHD_OPTION_END}). It is mandatory to use
519@code{MHD_OPTION_END} as last argument, even when there are no 519@code{MHD_OPTION_END} as last argument, even when there are no
520additional arguments. 520additional arguments.
@@ -531,7 +531,7 @@ Shutdown an @http{} daemon.
531@deftypefun int MHD_run (struct MHD_Daemon *daemon) 531@deftypefun int MHD_run (struct MHD_Daemon *daemon)
532Run webserver operations (without blocking unless in client callbacks). 532Run webserver operations (without blocking unless in client callbacks).
533This method should be called by clients in combination with 533This method should be called by clients in combination with
534@cfunction{MHD_get_fdset} if the client--controlled @cfunction{select} 534@cfunction{MHD_get_fdset} if the client-controlled @cfunction{select}
535method is used. 535method is used.
536 536
537Return @code{MHD_YES} on success, @code{MHD_NO} if this daemon was not 537Return @code{MHD_YES} on success, @code{MHD_NO} if this daemon was not
@@ -541,7 +541,7 @@ started with the right options for this call.
541 541
542@c ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 542@c ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
543 543
544@c ------------------------------------------------------------ 544@c -----------------------------------------------------------
545@node microhttpd inspect 545@node microhttpd inspect
546@appendixsec Inspection 546@appendixsec Inspection
547 547
@@ -584,7 +584,7 @@ right now).
584 584
585@c ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 585@c ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
586 586
587@c ------------------------------------------------------------ 587@c -----------------------------------------------------------
588@node microhttpd requests 588@node microhttpd requests
589@appendixsec Handling requests 589@appendixsec Handling requests
590 590
@@ -628,7 +628,7 @@ and @cfunction{free}). Prefixes are compared with @cfunction{strcmp}.
628 628
629@deftypefun int MHD_register_handler (struct MHD_Daemon *daemon, const char *uri_prefix, MHD_AccessHandlerCallback dh, void *dh_cls) 629@deftypefun int MHD_register_handler (struct MHD_Daemon *daemon, const char *uri_prefix, MHD_AccessHandlerCallback dh, void *dh_cls)
630Register an access handler for all @uri{}s beginning with 630Register an access handler for all @uri{}s beginning with
631@var{uri_prefix}, a zero--terminated @ascii{}--coded string. 631@var{uri_prefix}, a zero-terminated @ascii{}-coded string.
632 632
633Return @code{MRI_NO} if: the arguments are invalid (example: @null{} 633Return @code{MRI_NO} if: the arguments are invalid (example: @null{}
634pointers); a handler for this exact prefix already exists; an error 634pointers); a handler for this exact prefix already exists; an error
@@ -668,7 +668,7 @@ and returns the number of headers.
668@deftypefun {const char *} MHD_lookup_connection_value (struct MHD_Connection *connection, enum MHD_ValueKind kind, const char *key) 668@deftypefun {const char *} MHD_lookup_connection_value (struct MHD_Connection *connection, enum MHD_ValueKind kind, const char *key)
669Get a particular header value. If multiple values match the @var{kind}, 669Get a particular header value. If multiple values match the @var{kind},
670return one of them (the ``first'', whatever that means). @var{key} must 670return one of them (the ``first'', whatever that means). @var{key} must
671reference a zero--terminated @ascii{}--coded string representing the 671reference a zero-terminated @ascii{}-coded string representing the
672header to look for: it is compared against the headers using 672header to look for: it is compared against the headers using
673@cfunction{strcasecmp}, so case is ignored. Return @null{} if no such 673@cfunction{strcasecmp}, so case is ignored. Return @null{} if no such
674item was found. 674item was found.
@@ -866,7 +866,7 @@ MHD_destroy_response(response);
866 866
867@deftypefun int MHD_add_response_header (struct MHD_Response *response, const char *header, const char *content) 867@deftypefun int MHD_add_response_header (struct MHD_Response *response, const char *header, const char *content)
868Add a header line to the response. The strings referenced by 868Add a header line to the response. The strings referenced by
869@var{header} and @var{content} must be zero--terminated and they are 869@var{header} and @var{content} must be zero-terminated and they are
870duplicated into memory blocks embedded in @var{response}. 870duplicated into memory blocks embedded in @var{response}.
871 871
872Notice that the strings must not hold newlines, carriage returns or tab 872Notice that the strings must not hold newlines, carriage returns or tab
@@ -905,7 +905,7 @@ we know what we are doing.
905 905
906@deftypefun {const char *} MHD_get_response_header (struct MHD_Response *response, const char *key) 906@deftypefun {const char *} MHD_get_response_header (struct MHD_Response *response, const char *key)
907Find and return a pointer to the value of a particular header from the 907Find and return a pointer to the value of a particular header from the
908response. @var{key} must reference a zero--terminated string 908response. @var{key} must reference a zero-terminated string
909representing the header to look for. The search is case sensitive. 909representing the header to look for. The search is case sensitive.
910Return @null{} if header does not exist or @var{key} is @null{}. 910Return @null{} if header does not exist or @var{key} is @null{}.
911 911
@@ -1185,7 +1185,7 @@ length of @var{post_data}.
1185@end table 1185@end table
1186 1186
1187Return @code{MHD_YES} on success, @code{MHD_NO} on error 1187Return @code{MHD_YES} on success, @code{MHD_NO} on error
1188(out--of--memory, iterator aborted, parse error). 1188(out-of-memory, iterator aborted, parse error).
1189@end deftypefun 1189@end deftypefun
1190 1190
1191 1191